Fix optimization issue
This commit is contained in:
parent
db6a31dd85
commit
d89b43e055
2 changed files with 29 additions and 15 deletions
|
|
@ -30,15 +30,18 @@ export class DataService extends Root<Page> {
|
|||
Serializable.childrenMap = {
|
||||
Page: {
|
||||
childrenListName: 'towers',
|
||||
childrenConstructor: Tower
|
||||
childrenConstructor: Tower,
|
||||
childrenType: 'Tower'
|
||||
},
|
||||
Tower: {
|
||||
childrenListName: 'blocks',
|
||||
childrenConstructor: Block
|
||||
childrenConstructor: Block,
|
||||
childrenType: 'Block'
|
||||
},
|
||||
Block: {
|
||||
childrenListName: null,
|
||||
childrenConstructor: null
|
||||
childrenConstructor: null,
|
||||
childrenType: null
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -114,7 +114,7 @@ export class StoreService<T> {
|
|||
return this.storedData;
|
||||
}
|
||||
|
||||
async save(data: T) {
|
||||
async save(data: T): Promise<void> {
|
||||
this.storedData = data;
|
||||
const stringified = JSON.stringify(this.storedData, null, 2);
|
||||
console.log('save');
|
||||
|
|
|
|||
Loading…
Reference in a new issue