el-tag
This commit is contained in:
parent
db3e181254
commit
0f6ffb356b
|
@ -20,7 +20,7 @@
|
|||
</el-table-column>
|
||||
<el-table-column label="状态" prop="state">
|
||||
<template #default="scope">
|
||||
<span><el-tag :type="stateOption[scope.row.state].color">{{ stateOption[scope.row.state] }}</el-tag></span>
|
||||
<span><el-tag :type="stateOption[scope.row.state].color">{{ stateOption[scope.row.state].label }}</el-tag></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="提交时间" prop="submit_time">
|
||||
|
@ -69,11 +69,12 @@ export default {
|
|||
},
|
||||
selection: [],
|
||||
stateOption: {
|
||||
10: '创建中',
|
||||
20: '已提交',
|
||||
30: '到货中',
|
||||
40: '已完成',
|
||||
10: {"label": "创建中", "color": ""},
|
||||
20: {"label": "已提交", "color": ""},
|
||||
30: {"label": "到货中", "color": ""},
|
||||
40: {"label": "已完成", "color": "success"},
|
||||
},
|
||||
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
</el-table-column>
|
||||
<el-table-column label="状态" prop="state">
|
||||
<template #default="scope">
|
||||
<span><el-tag :type="stateOption[scope.row.state].color">{{ stateOption[scope.row.state] }}</el-tag></span>
|
||||
<span><el-tag :type="stateOption[scope.row.state].color">{{ stateOption[scope.row.state].label }}</el-tag></span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="提交时间" prop="submit_time" show-overflow-tooltip>
|
||||
|
@ -66,11 +66,11 @@ export default {
|
|||
},
|
||||
selection: [],
|
||||
stateOption: {
|
||||
10: '创建中',
|
||||
20: '已提交',
|
||||
30: '下单中',
|
||||
40: '下单完成',
|
||||
50: '已完成',
|
||||
10: {"label": "创建中", "color": ""},
|
||||
20: {"label": "已提交", "color": ""},
|
||||
30: {"label": "下单中", "color": ""},
|
||||
40: {"label": "下单完成", "color": ""},
|
||||
40: {"label": "已完成", "color": "success"},
|
||||
},
|
||||
};
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue