roleConst.js
744 Bytes
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
const roleCreateStructure = {
id: Number,
roleName: '',
description: '',
departName: '',
rights: Array,
state: 1,
createTime: ''
}
const userRoleDetailColumn = [{
label: '序号',
prop: 'userId'
}, {
label: '账号',
prop: 'username'
}, {
label: '用户名称',
prop: 'realname'
}, {
label: '状态',
prop: 'state',
formatter: (cellValue) => {
return cellValue < 1 ? '禁止' : '启动'
}
}]
const userRoleDetailConsole = {
label: '操作',
prop: 'option',
button: [{
label: '删除',
type: 'text',
callback: (index, rows) => {
rows.splice(index, 1)
// this.$alert(rows[index])
}
}]
}
export {
roleCreateStructure,
userRoleDetailColumn,
userRoleDetailConsole
}