Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions src/router/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ import ServerPowerOperations from '@/views/Operations/ServerPowerOperations';
import Ldap from '../views/SecurityAndAccess/Ldap/Ldap.vue';
import EventLogs from '@/views/Logs/EventLogs';
import FieldCoreOverride from '@/views/ResourceManagement/FieldCoreOverride';
import ServiceLoginConsoles from '@/views/Operations/ServiceLoginConsoles/ServiceLoginConsoles.vue';
import ServiceLogin from '@/views/Operations/ServiceLoginConsoles';

const roles = {
administrator: 'Administrator',
Expand Down Expand Up @@ -64,6 +66,15 @@ export const routes = [
},
component: HostConsoleConsole,
},
// Needs reimplementation once routes is implemented
{
path: '/console/service-login-consoles',
meta: {
requiresAuth: true,
title: i18n.global.t('appPageTitle.serviceLogin'),
},
component: ServiceLoginConsoles,
},
{
path: '/',
meta: {
Expand Down Expand Up @@ -96,6 +107,14 @@ export const routes = [
title: i18n.global.t('appPageTitle.serverPowerOperations'),
},
},
{
path: '/operations/service-login',
name: 'service-login',
component: ServiceLogin,
meta: {
title: i18n.global.t('appPageTitle.serviceLogin'),
},
},
{
path: '/hardware-status/sensors',
name: 'sensors',
Expand Down
2 changes: 1 addition & 1 deletion src/store/modules/GlobalStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export const GlobalStore = defineStore('global', {
})
.catch((error) => console.log(error));
},
getSystemInfo() {
async getSystemInfo() {
api
.get('/redfish/v1/Systems/system')
.then(
Expand Down
2 changes: 1 addition & 1 deletion src/store/modules/HardwareStatus/ChassisStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export const ChassisStore = defineStore('chassisStore', {
return await api
.get('/redfish/v1/Chassis/chassis')
.then(({ data: { PowerState = null } }) => {
this.PowerState = PowerState;
this.powerState = PowerState;
})
.catch((error) => console.log(error));
},
Expand Down
64 changes: 27 additions & 37 deletions src/views/Operations/ServiceLoginConsoles/ServiceLogin.vue
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
<template>
<b-container fluid="xl">
<BContainer fluid="xl">
<page-title :title="$t('appPageTitle.serviceLogin')" />

<page-section class="mb-0">
<b-row class="d-flex">
<b-col
<BRow class="d-flex">
<BCol
sm="6"
lg="5"
xl="4"
class="d-flex flex-column justify-content-end"
>
<b-form id="form-new-dump">
<b-form-group
<BForm id="form-new-dump">
<BFormGroup
:label="$t('pageServiceLoginConsoles.selectConsoleType')"
label-for="selectConsoleType"
>
<b-form-select
<BFormSelect
id="selectConsoleType"
v-model="selectConsoleType"
:options="consoleTypeOptions"
value-field="value"
text-field="text"
>
</b-form-select>
</b-form-group>
</b-form>
</b-col>
</b-row>
</BFormSelect>
</BFormGroup>
</BForm>
</BCol>
</BRow>
</page-section>

<page-section class="mb-0">
Expand All @@ -41,35 +41,25 @@
:console-type="'console1'"
/>
</page-section>
</b-container>
</BContainer>
</template>

<script>
import PageTitle from '@/components/Global/PageTitle';
import PageSection from '@/components/Global/PageSection';
import ServiceLoginConsoles from './ServiceLoginConsoles';
<script setup>
import { ref } from 'vue';
import i18n from '@/i18n';
import PageTitle from '@/components/Global/PageTitle.vue';
import PageSection from '@/components/Global/PageSection.vue';
import ServiceLoginConsoles from './ServiceLoginConsoles.vue';

export default {
name: 'ServiceLogin',
components: {
PageSection,
PageTitle,
ServiceLoginConsoles,
const selectConsoleType = ref('bmc-console');
const consoleTypeOptions = ref([
{
value: 'bmc-console',
text: i18n.global.t('pageServiceLoginConsoles.bmcConsole'),
},
data() {
return {
selectConsoleType: 'bmc-console',
consoleTypeOptions: [
{
value: 'bmc-console',
text: this.$t('pageServiceLoginConsoles.bmcConsole'),
},
{
value: 'hypervisor-console',
text: this.$t('pageServiceLoginConsoles.hypervisorConsole'),
},
],
};
{
value: 'hypervisor-console',
text: i18n.global.t('pageServiceLoginConsoles.hypervisorConsole'),
},
};
]);
</script>
Loading