fix: 看站完成确认提示
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
<script setup lang="ts">
|
||||
import { bootloaderDone } from '@/api';
|
||||
import { stepState, fnToStepName } from '../hooks/useStep';
|
||||
import { Modal } from 'ant-design-vue/lib';
|
||||
import { RESULT_CODE_SUCCESS } from '@/constants/result-constants';
|
||||
@@ -8,6 +7,7 @@ import { useRouter } from 'vue-router';
|
||||
import useAppStore from '@/store/modules/app';
|
||||
import useI18n from '@/hooks/useI18n';
|
||||
import { onMounted, ref } from 'vue';
|
||||
import { bootloaderDone } from '@/api/system/quick-start/bootloader';
|
||||
const { t } = useI18n();
|
||||
const router = useRouter();
|
||||
|
||||
@@ -28,27 +28,8 @@ function fnGetList() {
|
||||
infoList.value.push({
|
||||
type: 'warning',
|
||||
title: '已经进行网元安装配置',
|
||||
description: '如有部分异常网元请进入系统后可自行配置',
|
||||
description: '如有部分异常网元请进入系统后自行配置',
|
||||
});
|
||||
|
||||
// listAllNeInfo({
|
||||
// bandStatus: true,
|
||||
// }).then(res => {
|
||||
// if (res.code === RESULT_CODE_SUCCESS && Array.isArray(res.data)) {
|
||||
// for (const item of res.data) {
|
||||
// const online = item.serverState.online;
|
||||
// let description = 'Service Config Error';
|
||||
// if (online) {
|
||||
// description = `The License SN:${item.serverState.sn} and Expire:${item.serverState.expire}`;
|
||||
// }
|
||||
// infoList.value.push({
|
||||
// type: online ? 'success' : 'warning',
|
||||
// title: `${item.neType} ${item.neId}`,
|
||||
// description,
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
}
|
||||
|
||||
/**返回上一步 */
|
||||
@@ -68,16 +49,22 @@ function fnStepPrev() {
|
||||
|
||||
/**引导完成 */
|
||||
function fnGuideDone() {
|
||||
bootloaderDone()
|
||||
.then(res => {
|
||||
if (res.code === RESULT_CODE_SUCCESS) {
|
||||
removeToken();
|
||||
useAppStore().bootloader = false;
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
router.push({ name: 'Login' });
|
||||
});
|
||||
Modal.confirm({
|
||||
title: t('common.tipTitle'),
|
||||
content: '确认开始使用吗?',
|
||||
onOk() {
|
||||
bootloaderDone()
|
||||
.then(res => {
|
||||
if (res.code === RESULT_CODE_SUCCESS) {
|
||||
removeToken();
|
||||
useAppStore().bootloader = false;
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
router.push({ name: 'Login' });
|
||||
});
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
|
||||
Reference in New Issue
Block a user