summaryrefslogtreecommitdiff
path: root/src/client/app
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2019-06-21 15:11:56 +0900
committersyuilo <syuilotan@yahoo.co.jp>2019-06-21 15:11:56 +0900
commitfa0023e54168624bebd6cdd479c1df0e63cb868d (patch)
tree0e71ab4ef94bcf4db1752c95dfce76b883712b92 /src/client/app
parentImprove sync (diff)
downloadsharkey-fa0023e54168624bebd6cdd479c1df0e63cb868d.tar.gz
sharkey-fa0023e54168624bebd6cdd479c1df0e63cb868d.tar.bz2
sharkey-fa0023e54168624bebd6cdd479c1df0e63cb868d.zip
Fix bug
Diffstat (limited to 'src/client/app')
-rw-r--r--src/client/app/common/views/deck/deck.vue5
-rw-r--r--src/client/app/store.ts5
2 files changed, 6 insertions, 4 deletions
diff --git a/src/client/app/common/views/deck/deck.vue b/src/client/app/common/views/deck/deck.vue
index 070312d839..36e0f8161e 100644
--- a/src/client/app/common/views/deck/deck.vue
+++ b/src/client/app/common/views/deck/deck.vue
@@ -106,10 +106,7 @@ export default Vue.extend({
deck.layout = deck.columns.map(c => [c.id]);
- this.$store.commit('device/set', {
- key: 'deck',
- value: deck
- });
+ this.$store.commit('setDeck', deck);
}
},
diff --git a/src/client/app/store.ts b/src/client/app/store.ts
index b06edb1ed9..852d2c393d 100644
--- a/src/client/app/store.ts
+++ b/src/client/app/store.ts
@@ -129,6 +129,11 @@ export default (os: MiOS) => new Vuex.Store({
os.store.dispatch('settings/updateHomeProfile');
},
+ setDeck(state, data) {
+ Vue.set(state.settings.deckProfiles, state.device.deckProfile, data);
+ os.store.dispatch('settings/updateDeckProfile');
+ },
+
addHomeWidget(state, widget) {
state.settings.homeProfiles[state.device.homeProfile].unshift(widget);
os.store.dispatch('settings/updateHomeProfile');