hotfix usuwania scenerii & changeloga

This commit is contained in:
2024-01-04 15:41:42 +01:00
parent c25bd16ab1
commit f7eeaa342a
3 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -115,7 +115,7 @@ export default defineComponent({
async updateListToDb() {
try {
const mappedChangeList = this.store.changeList.map((v) => {
if (/^#/.test(v.id)) {
if (/^#/.test(v.id.toString())) {
return { ...v, id: undefined };
}
return { ...v };
+2 -2
View File
@@ -39,8 +39,8 @@ export default defineComponent({
const sceneryId = sceneryData.id;
// Sceneria niewpisana do bazy danych (id stworzone przez stronę)
if (sceneryId.startsWith('#')) {
this.store.changeList.filter((item) => item.id != sceneryId);
if (sceneryId.toString().startsWith('#')) {
this.store.changeList = this.store.changeList.filter((item) => item.id != sceneryId);
return;
}
+2 -2
View File
@@ -56,7 +56,7 @@ export interface SceneryRoutesInfo {
}
export interface SceneryRowItem {
id: string;
id: string | number;
hash: string;
name: string;
abbr: string;
@@ -79,7 +79,7 @@ export interface SceneryRowItem {
export type ChangeItem = {
[key in ChangeProp]?: any;
} & {
id: string;
id: string | number;
name: string;
toRemove?: boolean;