This commit is contained in:
2019-03-11 22:48:38 +00:00
parent 73b0c1b31e
commit 1b0becca01
3 changed files with 16 additions and 16 deletions

View File

@@ -17,19 +17,9 @@ function addNavItem(title, icon, route) {
// on change of authentication status // on change of authentication status
export default function initialize() { export default function initialize() {
if (store.state.authenticated) { if (store.state.authenticated) {
//GET LOCALIZED TEXT FOR SHELL //GET ALL DEFAULT LOCALIZED TEXT FOR SHELL
locale locale
.fetch([ .fetch(locale.coreKeys)
"Home",
"Service",
"Dispatch",
"Inventory",
"Accounting",
"Administration",
"Operations",
"HelpAboutAyaNova",
"Logout"
])
.then(function() { .then(function() {
//put nav items into store //put nav items into store
//Everyone has a home //Everyone has a home

View File

@@ -41,9 +41,19 @@ export default {
}); });
}); });
}, },
//Keys that all edit forms have in common (saves retyping them over and over) //Keys that will always be required for any AyaNova work for any user
commonKeysEditForm: [ coreKeys: [
//TODO: some of these are not going to be required / missed some I'm sure //main nav options
"Home",
"Service",
"Dispatch",
"Inventory",
"Accounting",
"Administration",
"Operations",
"HelpAboutAyaNova",
"Logout",
//form required options
"Active", "Active",
"Add", "Add",
"Cancel", "Cancel",

View File

@@ -141,7 +141,7 @@ export default {
"WidgetCustom14", "WidgetCustom14",
"WidgetCustom15", "WidgetCustom15",
"WidgetCustom16" "WidgetCustom16"
].concat(this.$gzlocale.commonKeysEditForm); ];
this.$gzlocale this.$gzlocale
.fetch(ltKeysRequired) .fetch(ltKeysRequired)
.then(() => (this.formReady = true)) .then(() => (this.formReady = true))