1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
// 变量名对应含义请在 /stores/* 里边找
import type { Component } from 'vue'
import { RouteLocationNormalized } from 'vue-router'
 
export interface Layout {
    showDrawer: boolean
    shrink: boolean
    layoutMode: string
    mainAnimation: string
    menuWidth: number
    menuDefaultIcon: string
    menuCollapse: boolean
    menuUniqueOpened: boolean
    menuShowTopBar: boolean
    menuBackground: string
    menuColor: string
    menuActiveBackground: string
    menuActiveColor: string
    menuTopBarBackground: string
    headerBarTabColor: string
    headerBarBackground: string
    headerBarHoverBackground: string
    headerBarTabActiveBackground: string
    headerBarTabActiveColor: string
}
 
export interface viewMenu {
    title: string
    path: string
    name?: string
    type?: string
    icon?: string
    keepAlive?: string
    query?: anyObj
    params?: anyObj
    children?: viewMenu[]
    component?: Component
}
 
export interface NavTabs {
    activeIndex: number
    activeRoute: viewMenu | null
    tabsView: Array<viewMenu>
    tabFullScreen: boolean
    tabsViewRoutes: Array<viewMenu>
    authNode: Map<string, string[]>
}
 
export interface MemberCenter {
    open: boolean
    layoutMode: string
    activeRoute: viewMenu | RouteLocationNormalized | null
    viewRoutes: Array<viewMenu>
    showHeadline: boolean
    authNode: Map<string, string[]>
    shrink: boolean
    menuExpand: boolean
}
 
export interface AdminInfo {
    id: number
    username: string
    nickname: string
    avatar: string
    lastlogintime: string
    token: string
    refreshToken: string
    super: boolean
}
 
export interface UserInfo {
    id?: number | string
    username?: string
    name?: string
    email?: string
    mobile?: string
    phone?: string
    gender?: number
    birthday?: string
    money?: number
    score?: number
    avatar?: string
    lastlogintime?: string
    lastloginip?: string
    jointime?: string
    motto?: string
    adminToken: string
    screenToken: string
    empCode:string
    menuList: Menu[]
    fullUnitName:string
    userId?:any
    unitId?:any
    roleCodes?:any
    userInfo?:any
    departmentId?: string
}
 
export interface TaskItem {
    // 任务唯一标识
    uuid: string
    // 创建时间
    createtime: string
    // 状态
    status: number
    // 命令
    command: string
    // 命令执行日志
    message: string[]
    // 显示命令执行日志
    showMessage: boolean
    // 失败阻断后续命令执行
    blockOnFailure: boolean
    // 执行结果回调
    callback: Function
}
 
export interface Terminal {
    show: boolean
    showDot: boolean
    taskList: TaskItem[]
    packageManager: string
    showPackageManagerDialog: boolean
    showConfig: boolean
    automaticCleanupTask: string
    port: string
}
 
export interface SiteConfig {
    site_name: string
    record_number?: string
    version: string
}
export interface AreaSource {
    parentId?: string
}
export interface CommonInfo {
    areaSource: AreaSource[],
    activeMenu: string
}
 
interface permsType {
    code: string
    name: string
}
export interface Permission {
    buttonAuth: string[]
    permsList?: permsType[]
}
/* MenuState */
export interface MenuState {
    isCollapse: boolean
    menuList: Menu[]
  }