diff --git a/ayanova/src/api/initialize.js b/ayanova/src/api/initialize.js index b90c7a97..d3a2083a 100644 --- a/ayanova/src/api/initialize.js +++ b/ayanova/src/api/initialize.js @@ -20,11 +20,26 @@ function initNavPanel() { let t = window.$gz.translation.get; let role = window.$gz.role.AUTHORIZATION_ROLES; + let licenseState = window.$gz.store.state.globalSettings.licenseStatus; + //******* License issue + //Status NONE, EXPIREDTRIAL, EXPIREDPURCHASE, REVOKED + //only show license and logout + /* public enum LicenseStatus + { + NONE = 0, + ActiveTrial = 1, + ExpiredTrial = 2, + ActivePurchased = 3, + ExpiredPurchased = 4, + Revoked = 5 + } */ - //******* REVOKE - //Status 5 = revoked, they need to know and have a path to unrevocation - //only allow license and logout - if (window.$gz.store.state.globalSettings.licenseStatus == 5) { + if ( + licenseState == 0 || + licenseState == 2 || + licenseState == 4 || + licenseState == 5 + ) { addNavItem( t("HelpLicense"), "fa-ticket-alt", @@ -38,14 +53,14 @@ function initNavPanel() { return; } - //******* LAUNCH - //if it's an empty db then only the launch page is available - if (window.$gz.store.state.globalSettings.licenseStatus == 0) { - addNavItem(t("Launch"), "fa-rocket", "/adm-launch", [], key++, "launch"); - addNavItem(t("Logout"), "fa-sign-out-alt", "/login", [], key++, "logout"); - window.$gz.store.commit("setHomePage", "/adm-launch"); - return; - } + // //******* LAUNCH + // //if it's an empty db then only the launch page is available + // if (window.$gz.store.state.globalSettings.licenseStatus == 0) { + // addNavItem(t("Launch"), "fa-rocket", "/adm-launch", [], key++, "launch"); + // addNavItem(t("Logout"), "fa-sign-out-alt", "/login", [], key++, "logout"); + // window.$gz.store.commit("setHomePage", "/adm-launch"); + // return; + // } //****************** HOME //Most users except ops and client logins