1import AppLayout from '@/layouts/AppLayout.vue'; 2import ChangePassword from '@/views/ChangePassword'; 3import ConsoleLayout from '@/layouts/ConsoleLayout.vue'; 4import DateTimeSettings from '@/views/Configuration/DateTimeSettings'; 5import EventLogs from '@/views/Health/EventLogs'; 6import HardwareStatus from '@/views/Health/HardwareStatus'; 7import Ldap from '@/views/AccessControl/Ldap'; 8import LocalUserManagement from '@/views/AccessControl/LocalUserManagement'; 9import Login from '@/views/Login'; 10import LoginLayout from '@/layouts/LoginLayout'; 11import ManagePowerUsage from '@/views/Control/ManagePowerUsage'; 12import NetworkSettings from '@/views/Configuration/NetworkSettings'; 13import Overview from '@/views/Overview'; 14import PageNotFound from '@/views/PageNotFound'; 15import ProfileSettings from '@/views/ProfileSettings'; 16import RebootBmc from '@/views/Control/RebootBmc'; 17import Sensors from '@/views/Health/Sensors'; 18import SerialOverLan from '@/views/Control/SerialOverLan'; 19import SerialOverLanConsole from '@/views/Control/SerialOverLan/SerialOverLanConsole'; 20import ServerLed from '@/views/Control/ServerLed'; 21import ServerPowerOperations from '@/views/Control/ServerPowerOperations'; 22import SslCertificates from '@/views/AccessControl/SslCertificates'; 23import VirtualMedia from '@/views/Control/VirtualMedia'; 24import i18n from '@/i18n'; 25 26// Custom components 27import FirmwareSingleImage from '../components/FirmwareSingleImage'; 28 29const routes = [ 30 { 31 path: '/login', 32 component: LoginLayout, 33 children: [ 34 { 35 path: '', 36 name: 'login', 37 component: Login, 38 meta: { 39 title: i18n.t('appPageTitle.login') 40 } 41 }, 42 { 43 path: '/change-password', 44 name: 'change-password', 45 component: ChangePassword, 46 meta: { 47 title: i18n.t('appPageTitle.changePassword'), 48 requiresAuth: true 49 } 50 } 51 ] 52 }, 53 { 54 path: '/console', 55 component: ConsoleLayout, 56 meta: { 57 requiresAuth: true 58 }, 59 children: [ 60 { 61 path: 'serial-over-lan-console', 62 name: 'serial-over-lan-console', 63 component: SerialOverLanConsole, 64 meta: { 65 title: i18n.t('appPageTitle.serialOverLan') 66 } 67 } 68 ] 69 }, 70 { 71 path: '/', 72 meta: { 73 requiresAuth: true 74 }, 75 component: AppLayout, 76 children: [ 77 { 78 path: '', 79 name: 'overview', 80 component: Overview, 81 meta: { 82 title: i18n.t('appPageTitle.overview') 83 } 84 }, 85 { 86 path: '/profile-settings', 87 name: 'profile-settings', 88 component: ProfileSettings, 89 meta: { 90 title: i18n.t('appPageTitle.profileSettings') 91 } 92 }, 93 { 94 path: '/health/event-logs', 95 name: 'event-logs', 96 component: EventLogs, 97 meta: { 98 title: i18n.t('appPageTitle.eventLogs') 99 } 100 }, 101 { 102 path: '/health/hardware-status', 103 name: 'hardware-status', 104 component: HardwareStatus, 105 meta: { 106 title: i18n.t('appPageTitle.hardwareStatus') 107 } 108 }, 109 { 110 path: '/health/sensors', 111 name: 'sensors', 112 component: Sensors, 113 meta: { 114 title: i18n.t('appPageTitle.sensors') 115 } 116 }, 117 { 118 path: '/access-control/ldap', 119 name: 'ldap', 120 component: Ldap, 121 meta: { 122 title: i18n.t('appPageTitle.ldap') 123 } 124 }, 125 { 126 path: '/access-control/local-user-management', 127 name: 'local-users', 128 component: LocalUserManagement, 129 meta: { 130 title: i18n.t('appPageTitle.localUserManagement') 131 } 132 }, 133 { 134 path: '/access-control/ssl-certificates', 135 name: 'ssl-certificates', 136 component: SslCertificates, 137 meta: { 138 title: i18n.t('appPageTitle.sslCertificates') 139 } 140 }, 141 { 142 path: '/configuration/date-time-settings', 143 name: 'date-time-settings', 144 component: DateTimeSettings, 145 meta: { 146 title: i18n.t('appPageTitle.dateTimeSettings') 147 } 148 }, 149 { 150 path: '/configuration/firmware', 151 name: 'firmware', 152 component: FirmwareSingleImage, 153 meta: { 154 title: i18n.t('appPageTitle.firmware') 155 } 156 }, 157 { 158 path: '/control/manage-power-usage', 159 name: 'manage-power-usage', 160 component: ManagePowerUsage, 161 meta: { 162 title: i18n.t('appPageTitle.managePowerUsage') 163 } 164 }, 165 { 166 path: '/configuration/network-settings', 167 name: 'network-settings', 168 component: NetworkSettings, 169 meta: { 170 title: i18n.t('appPageTitle.networkSettings') 171 } 172 }, 173 { 174 path: '/control/reboot-bmc', 175 name: 'reboot-bmc', 176 component: RebootBmc, 177 meta: { 178 title: i18n.t('appPageTitle.rebootBmc') 179 } 180 }, 181 { 182 path: '/control/server-led', 183 name: 'server-led', 184 component: ServerLed, 185 meta: { 186 title: i18n.t('appPageTitle.serverLed') 187 } 188 }, 189 { 190 path: '/control/serial-over-lan', 191 name: 'serial-over-lan', 192 component: SerialOverLan, 193 meta: { 194 title: i18n.t('appPageTitle.serialOverLan') 195 } 196 }, 197 { 198 path: '/control/server-power-operations', 199 name: 'server-power-operations', 200 component: ServerPowerOperations, 201 meta: { 202 title: i18n.t('appPageTitle.serverPowerOperations') 203 } 204 }, 205 { 206 path: '/control/virtual-media', 207 name: 'virtual-media', 208 component: VirtualMedia, 209 meta: { 210 title: i18n.t('appPageTitle.virtualMedia') 211 } 212 }, 213 { 214 path: '*', 215 name: 'page-not-found', 216 component: PageNotFound, 217 meta: { 218 title: i18n.t('appPageTitle.pageNotFound') 219 } 220 } 221 ] 222 } 223]; 224 225export default routes; 226