mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-10 18:23:50 +00:00
Fix empty layout on initial load
This commit is contained in:
parent
4be917852c
commit
8a0b852912
|
@ -112,5 +112,14 @@ export const useLayoutStore = defineStore('layoutStore', {
|
|||
},
|
||||
persist: {
|
||||
key: STORE_LAYOUTS,
|
||||
afterRestore: (context) => {
|
||||
console.log('after restore - ', context.store);
|
||||
if (context.store.dashboardLayout === null) {
|
||||
context.store.dashboardLayout = JSON.parse(JSON.stringify(DEFAULT_DASHBOARD_LAYOUT));
|
||||
}
|
||||
if (context.store.tradingLayout === null) {
|
||||
context.store.tradingLayout = JSON.parse(JSON.stringify(DEFAULT_TRADING_LAYOUT));
|
||||
}
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue
Block a user