feat: 开站目录变更quick-start
This commit is contained in:
78
src/views/system/quick-start/hooks/useStep.ts
Normal file
78
src/views/system/quick-start/hooks/useStep.ts
Normal file
@@ -0,0 +1,78 @@
|
||||
import { reactive } from 'vue';
|
||||
|
||||
/**步骤信息状态类型 */
|
||||
type StepStateType = {
|
||||
/**步骤名称 */
|
||||
stepName: string;
|
||||
|
||||
/**当前选中 */
|
||||
current: number;
|
||||
/**步骤项 */
|
||||
steps: {
|
||||
title: string;
|
||||
description: string;
|
||||
}[];
|
||||
/**步骤下一步 */
|
||||
stepNext: boolean;
|
||||
/**步骤信息状态 */
|
||||
states: any[];
|
||||
};
|
||||
|
||||
/**步骤信息状态 */
|
||||
export const stepState: StepStateType = reactive({
|
||||
stepName: 'Start',
|
||||
|
||||
current: 0,
|
||||
steps: [
|
||||
{
|
||||
title: '版权声明',
|
||||
description: '确认是否安装',
|
||||
},
|
||||
{
|
||||
title: '网元信息',
|
||||
description: '记录下所安装网元基础信息',
|
||||
},
|
||||
{
|
||||
title: '网元安装',
|
||||
description: '安装包上传执行安装启动服务等待10秒停止服务',
|
||||
},
|
||||
{
|
||||
title: '网元配置',
|
||||
description: '修改网元的配置文件',
|
||||
},
|
||||
{
|
||||
title: '网元激活',
|
||||
description: '获取激活码和上传授权文件,启动验证激活码',
|
||||
},
|
||||
{
|
||||
title: '完成安装',
|
||||
description: '获取网元服务状态',
|
||||
},
|
||||
],
|
||||
stepNext: false,
|
||||
states: [],
|
||||
});
|
||||
|
||||
/**步骤信息状态复位 */
|
||||
export function fnRestStepState() {
|
||||
stepState.stepName = 'Start';
|
||||
|
||||
stepState.current = 0;
|
||||
stepState.stepNext = false;
|
||||
stepState.states = [];
|
||||
}
|
||||
|
||||
/**跳转步骤组件 */
|
||||
export function fnToStepName(stepName: string) {
|
||||
stepState.stepName = stepName;
|
||||
}
|
||||
|
||||
export function fnStepNext() {
|
||||
stepState.current++;
|
||||
stepState.stepNext = false;
|
||||
}
|
||||
|
||||
export function fnStepPrev() {
|
||||
stepState.current--;
|
||||
stepState.stepNext = true;
|
||||
}
|
||||
Reference in New Issue
Block a user