diff options
-rw-r--r-- | .env.intel | 5 | ||||
-rw-r--r-- | src/env/components/AppNavigation/intel.js | 139 | ||||
-rw-r--r-- | src/env/router/intel.js | 231 | ||||
-rw-r--r-- | src/env/store/intel.js | 2 |
4 files changed, 375 insertions, 2 deletions
@@ -3,4 +3,7 @@ VUE_APP_ENV_NAME="intel" VUE_APP_COMPANY_NAME="intel" VUE_APP_SUBSCRIBE_SOCKET_DISABLED="true" VUE_APP_VIRTUAL_MEDIA_LIST_ENABLED="true" -CUSTOM_STYLES="true"
\ No newline at end of file +CUSTOM_STYLES="true" +CUSTOM_APP_NAV="true" +CUSTOM_STORE="true" +CUSTOM_ROUTER="true"
\ No newline at end of file diff --git a/src/env/components/AppNavigation/intel.js b/src/env/components/AppNavigation/intel.js new file mode 100644 index 00000000..55981f18 --- /dev/null +++ b/src/env/components/AppNavigation/intel.js @@ -0,0 +1,139 @@ +import IconAnalytics from '@carbon/icons-vue/es/analytics/16'; +import IconDataCheck from '@carbon/icons-vue/es/data--check/16'; +import IconSettingsAdjust from '@carbon/icons-vue/es/settings--adjust/16'; +import IconSettings from '@carbon/icons-vue/es/settings/16'; +import IconPassword from '@carbon/icons-vue/es/password/16'; +import IconChevronUp from '@carbon/icons-vue/es/chevron--up/16'; + +const AppNavigationMixin = { + components: { + iconOverview: IconAnalytics, + iconHealth: IconDataCheck, + iconControl: IconSettingsAdjust, + iconConfiguration: IconSettings, + iconAccessControl: IconPassword, + iconExpand: IconChevronUp, + }, + data() { + return { + navigationItems: [ + { + id: 'overview', + label: this.$t('appNavigation.overview'), + route: '/', + icon: 'iconOverview', + }, + { + id: 'health', + label: this.$t('appNavigation.health'), + icon: 'iconHealth', + children: [ + { + id: 'event-logs', + label: this.$t('appNavigation.eventLogs'), + route: '/health/event-logs', + }, + { + id: 'hardware-status', + label: this.$t('appNavigation.hardwareStatus'), + route: '/health/hardware-status', + }, + { + id: 'sensors', + label: this.$t('appNavigation.sensors'), + route: '/health/sensors', + }, + ], + }, + { + id: 'control', + label: this.$t('appNavigation.control'), + icon: 'iconControl', + children: [ + { + id: 'kvm', + label: this.$t('appNavigation.kvm'), + route: '/control/kvm', + }, + { + id: 'manage-power-usage', + label: this.$t('appNavigation.managePowerUsage'), + route: '/control/manage-power-usage', + }, + { + id: 'reboot-bmc', + label: this.$t('appNavigation.rebootBmc'), + route: '/control/reboot-bmc', + }, + { + id: 'serial-over-lan', + label: this.$t('appNavigation.serialOverLan'), + route: '/control/serial-over-lan', + }, + { + id: 'server-led', + label: this.$t('appNavigation.serverLed'), + route: '/control/server-led', + }, + { + id: 'server-power-operations', + label: this.$t('appNavigation.serverPowerOperations'), + route: '/control/server-power-operations', + }, + { + id: 'virtual-media', + label: this.$t('appNavigation.virtualMedia'), + route: '/control/virtual-media', + }, + ], + }, + { + id: 'configuration', + label: this.$t('appNavigation.configuration'), + icon: 'iconConfiguration', + children: [ + { + id: 'date-time-settings', + label: this.$t('appNavigation.dateTimeSettings'), + route: '/configuration/date-time-settings', + }, + { + id: 'firmware', + label: this.$t('appNavigation.firmware'), + route: '/configuration/firmware', + }, + { + id: 'network-settings', + label: this.$t('appNavigation.networkSettings'), + route: '/configuration/network-settings', + }, + { + id: 'snmp-settings', + label: this.$t('appNavigation.snmpSettings'), + route: '/snmp-settings', + }, + ], + }, + { + id: 'access-control', + label: this.$t('appNavigation.accessControl'), + icon: 'iconAccessControl', + children: [ + { + id: 'local-user-management', + label: this.$t('appNavigation.localUserManagement'), + route: '/access-control/local-user-management', + }, + { + id: 'ssl-certificates', + label: this.$t('appNavigation.sslCertificates'), + route: '/access-control/ssl-certificates', + }, + ], + }, + ], + }; + }, +}; + +export default AppNavigationMixin; diff --git a/src/env/router/intel.js b/src/env/router/intel.js index 3a25650f..56128737 100644 --- a/src/env/router/intel.js +++ b/src/env/router/intel.js @@ -1,3 +1,232 @@ -import routes from '@/router/routes'; +import AppLayout from '@/layouts/AppLayout.vue'; +import ChangePassword from '@/views/ChangePassword'; +import ConsoleLayout from '@/layouts/ConsoleLayout.vue'; +import DateTimeSettings from '@/views/Configuration/DateTimeSettings'; +import EventLogs from '@/views/Health/EventLogs'; +import Firmware from '@/views/Configuration/Firmware'; +import HardwareStatus from '@/views/Health/HardwareStatus'; +import Kvm from '@/views/Control/Kvm'; +import KvmConsole from '@/views/Control/Kvm/KvmConsole'; +import LocalUserManagement from '@/views/AccessControl/LocalUserManagement'; +import Login from '@/views/Login'; +import LoginLayout from '@/layouts/LoginLayout'; +import ManagePowerUsage from '@/views/Control/ManagePowerUsage'; +import NetworkSettings from '@/views/Configuration/NetworkSettings'; +import Overview from '@/views/Overview'; +import PageNotFound from '@/views/PageNotFound'; +import ProfileSettings from '@/views/ProfileSettings'; +import RebootBmc from '@/views/Control/RebootBmc'; +import Sensors from '@/views/Health/Sensors'; +import SerialOverLan from '@/views/Control/SerialOverLan'; +import SerialOverLanConsole from '@/views/Control/SerialOverLan/SerialOverLanConsole'; +import ServerLed from '@/views/Control/ServerLed'; +import ServerPowerOperations from '@/views/Control/ServerPowerOperations'; +import SslCertificates from '@/views/AccessControl/SslCertificates'; +import VirtualMedia from '@/views/Control/VirtualMedia'; +import i18n from '@/i18n'; + +const routes = [ + { + path: '/login', + component: LoginLayout, + children: [ + { + path: '', + name: 'login', + component: Login, + meta: { + title: i18n.t('appPageTitle.login'), + }, + }, + { + path: '/change-password', + name: 'change-password', + component: ChangePassword, + meta: { + title: i18n.t('appPageTitle.changePassword'), + requiresAuth: true, + }, + }, + ], + }, + { + path: '/console', + component: ConsoleLayout, + meta: { + requiresAuth: true, + }, + children: [ + { + path: 'serial-over-lan-console', + name: 'serial-over-lan-console', + component: SerialOverLanConsole, + meta: { + title: i18n.t('appPageTitle.serialOverLan'), + }, + }, + { + path: 'kvm', + name: 'kvm-console', + component: KvmConsole, + meta: { + title: i18n.t('appPageTitle.kvm'), + }, + }, + ], + }, + { + path: '/', + meta: { + requiresAuth: true, + }, + component: AppLayout, + children: [ + { + path: '', + name: 'overview', + component: Overview, + meta: { + title: i18n.t('appPageTitle.overview'), + }, + }, + { + path: '/profile-settings', + name: 'profile-settings', + component: ProfileSettings, + meta: { + title: i18n.t('appPageTitle.profileSettings'), + }, + }, + { + path: '/health/event-logs', + name: 'event-logs', + component: EventLogs, + meta: { + title: i18n.t('appPageTitle.eventLogs'), + }, + }, + { + path: '/health/hardware-status', + name: 'hardware-status', + component: HardwareStatus, + meta: { + title: i18n.t('appPageTitle.hardwareStatus'), + }, + }, + { + path: '/health/sensors', + name: 'sensors', + component: Sensors, + meta: { + title: i18n.t('appPageTitle.sensors'), + }, + }, + { + path: '/access-control/local-user-management', + name: 'local-users', + component: LocalUserManagement, + meta: { + title: i18n.t('appPageTitle.localUserManagement'), + }, + }, + { + path: '/access-control/ssl-certificates', + name: 'ssl-certificates', + component: SslCertificates, + meta: { + title: i18n.t('appPageTitle.sslCertificates'), + }, + }, + { + path: '/configuration/date-time-settings', + name: 'date-time-settings', + component: DateTimeSettings, + meta: { + title: i18n.t('appPageTitle.dateTimeSettings'), + }, + }, + { + path: '/configuration/firmware', + name: 'firmware', + component: Firmware, + meta: { + title: i18n.t('appPageTitle.firmware'), + }, + }, + { + path: '/control/kvm', + name: 'kvm', + component: Kvm, + meta: { + title: i18n.t('appPageTitle.kvm'), + }, + }, + { + path: '/control/manage-power-usage', + name: 'manage-power-usage', + component: ManagePowerUsage, + meta: { + title: i18n.t('appPageTitle.managePowerUsage'), + }, + }, + { + path: '/configuration/network-settings', + name: 'network-settings', + component: NetworkSettings, + meta: { + title: i18n.t('appPageTitle.networkSettings'), + }, + }, + { + path: '/control/reboot-bmc', + name: 'reboot-bmc', + component: RebootBmc, + meta: { + title: i18n.t('appPageTitle.rebootBmc'), + }, + }, + { + path: '/control/server-led', + name: 'server-led', + component: ServerLed, + meta: { + title: i18n.t('appPageTitle.serverLed'), + }, + }, + { + path: '/control/serial-over-lan', + name: 'serial-over-lan', + component: SerialOverLan, + meta: { + title: i18n.t('appPageTitle.serialOverLan'), + }, + }, + { + path: '/control/server-power-operations', + name: 'server-power-operations', + component: ServerPowerOperations, + meta: { + title: i18n.t('appPageTitle.serverPowerOperations'), + }, + }, + { + path: '/control/virtual-media', + name: 'virtual-media', + component: VirtualMedia, + meta: { + title: i18n.t('appPageTitle.virtualMedia'), + }, + }, + { + path: '*', + name: 'page-not-found', + component: PageNotFound, + meta: { + title: i18n.t('appPageTitle.pageNotFound'), + }, + }, + ], + }, +]; export default routes; diff --git a/src/env/store/intel.js b/src/env/store/intel.js index 70c9b98a..a3acedf0 100644 --- a/src/env/store/intel.js +++ b/src/env/store/intel.js @@ -4,4 +4,6 @@ import store from '@/store'; // store modules // https://vuex.vuejs.org/api/#registermodule +store.unregisterModule('ldap'); + export default store; |