This commit is contained in:
2020-02-10 19:58:06 +00:00
parent f4f1338c1c
commit 080a1ae794
3 changed files with 485 additions and 0 deletions

View File

@@ -20,6 +20,7 @@ export default new Vuex.Store({
userType: 0,
homePage: undefined,
localeText: {},
enums: {}, //all enum values with localized text to match stored as key e.g. enums:{AuthorizationRoles:[{0:"no role"},{1:"Limited role"}],UserTypes:[{0:"Technician"},{1:"Client user"}]}
locale: {
languageOverride: "en-US",
timeZoneOverride: "America/New_York",
@@ -52,6 +53,7 @@ export default new Vuex.Store({
state.homePage = undefined;
state.navItems = [];
state.localeText = {};
state.enums = {};
state.formCustomTemplate = {};
state.apiUrl = "";
state.locale.languageOverride = "en-US";
@@ -77,6 +79,9 @@ export default new Vuex.Store({
state.locale.hour12 = data.hour12;
state.locale.timeZoneOverride = data.timeZoneOverride;
},
setEnum(state, data) {
state.enums[data.enumKey] = data.items; //{enumKey:"AuthorizationRoles",items:[{0:"no role"},{1:"Limited role"}]}
},
setAPIURL(state, data) {
state.apiUrl = data;
},