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