Browse Source

优化页面

master
李磊 3 years ago
parent
commit
70c4864037
  1. 6
      src/views/certificate/index.vue
  2. 11
      src/views/device_management/index.vue

6
src/views/certificate/index.vue

@ -152,7 +152,7 @@ export default {
} }
}, },
{ prop: 'renewalDate', label: '发换证日期', align: 'center', width: 50 }, { prop: 'renewalDate', label: '发换证日期', align: 'center', width: 50 },
{ prop: 'remarks', label: '备注', align: 'center', width: 60,formatter: this.formatterDicDataRemark }, { prop: 'remarks', label: '备注', align: 'center', width: 60, formatter: this.formatterDicDataRemark },
{ slot: 'operation' } { slot: 'operation' }
], ],
permission: { permission: {
@ -333,8 +333,8 @@ export default {
} }
return null return null
}, },
formatterDicDataRemark(cellValue){ formatterDicDataRemark(cellValue) {
if (cellValue != null) { if (cellValue != null) {
let label = '' let label = ''
this.remarksDicList.filter(dicData => dicData.code === cellValue.remarks).forEach(dicData => { this.remarksDicList.filter(dicData => dicData.code === cellValue.remarks).forEach(dicData => {
label = dicData.name label = dicData.name

11
src/views/device_management/index.vue

@ -299,17 +299,6 @@ const defaultForm = form({
checkDate: '' checkDate: ''
}) })
//
const PrefixPlusText = {
props: ['value', 'functions'],
template: `
<el-tag v-if="functions(value) === '在用'" effect="dark"><span v-html="functions(value)"></span></el-tag>
<el-tag v-else-if="functions(value) === '停用'" type="danger" effect="dark"><span v-html="functions(value)"></span></el-tag>
<el-tag v-else-if="functions(value) === '待报废'" type="warning" effect="dark"><span v-html="functions(value)"></span></el-tag>
<el-tag v-else type="info" effect="dark"><span v-html="functions(value)"></span></el-tag>
`
}
export default { export default {
name: 'InstrumentList', name: 'InstrumentList',
components: { Pagination, Query, Crud, CustomTable, Edit, TreeSelect, Move }, components: { Pagination, Query, Crud, CustomTable, Edit, TreeSelect, Move },

Loading…
Cancel
Save