added the menu controller
This commit is contained in:
@@ -2,6 +2,7 @@ import { ActionTree, Module } from 'vuex';
|
||||
|
||||
const store = {
|
||||
selectedArea: undefined,
|
||||
headerTitle: undefined
|
||||
};
|
||||
|
||||
const actions: ActionTree<any, any> = {
|
||||
@@ -10,11 +11,15 @@ const actions: ActionTree<any, any> = {
|
||||
const mutations = {
|
||||
saveArea: (state: any, area: any) => {
|
||||
state.selectedArea = area;
|
||||
},
|
||||
saveHeaderTitle: (state: any, title: string) => {
|
||||
state.headerTitle = title;
|
||||
}
|
||||
};
|
||||
|
||||
const getters = {
|
||||
selectedArea: (state: any) => state.selectedArea,
|
||||
headerTitle: (state: any) => state.headerTitle
|
||||
};
|
||||
|
||||
const globalStore: Module<any, any> = {
|
||||
|
||||
@@ -26,8 +26,6 @@ const actions: ActionTree<any, any> = {
|
||||
Promise<any> => {
|
||||
const response = await statusRepository.getIcons(lastUpdate);
|
||||
|
||||
console.log(response);
|
||||
|
||||
commit('saveIcons', response);
|
||||
|
||||
return response;
|
||||
|
||||
Reference in New Issue
Block a user