This commit is contained in:
yanran200730
2022-01-12 16:20:35 +08:00
parent 0d2fb84436
commit 9715c28362
3 changed files with 18 additions and 17 deletions

View File

@@ -89,7 +89,7 @@
<div v-show="currIndex === 2">
<ai-card title="异常处理">
<template #right>
<el-button type="primary" @click="release">解除异常</el-button>
<el-button type="primary" v-if="info.status === '0'" @click="release">解除异常</el-button>
</template>
<template #content>
<ai-wrapper
@@ -107,7 +107,7 @@
</ai-card>
<ai-card title="异常情况记录">
<template #right>
<el-button type="primary" @click="isShowAdd = true">添加</el-button>
<el-button type="primary" v-if="info.status === '0'" @click="isShowAdd = true">添加</el-button>
</template>
<template #content>
<ai-table
@@ -185,7 +185,7 @@
{prop: 'createTime', label: '上报日期', align: 'center', dateFormart: 'YYYY-MM-DD'},
{prop: 'status', label: '健康状态', align: 'center', formart: v => v === '0' ? '异常' : '正常' }
],
tabList: ['基本信息', '每日上报']
tabList: ['基本信息', '每日上报', '异常处理']
}
},
@@ -205,11 +205,6 @@
this.instance.post(`/app/appepidemicreportmember/queryDetailById?id=${id}`).then(res => {
if (res.code === 0) {
this.info = res.data
if (res.data.status === '0') {
this.tabList = ['基本信息', '每日上报', '异常处理']
} else {
this.tabList = ['基本信息', '每日上报']
}
this.currIndex = 0
}
})

View File

@@ -64,7 +64,7 @@
<div v-show="currIndex === 1">
<ai-card title="异常处理">
<template #right>
<el-button type="primary" @click="release">解除异常</el-button>
<el-button type="primary" v-if="info.status === '0'" @click="release">解除异常</el-button>
</template>
<template #content>
<ai-wrapper
@@ -82,7 +82,7 @@
</ai-card>
<ai-card title="异常情况记录">
<template #right>
<el-button type="primary" @click="isShow = true">添加</el-button>
<el-button type="primary" v-if="info.status === '0'" @click="isShow = true">添加</el-button>
</template>
<template #content>
<ai-table
@@ -148,7 +148,7 @@
{prop: 'content', label: '说明', align: 'center' },
{prop: 'createTime', label: '创建时间', align: 'center'}
],
tabList: ['基本信息']
tabList: ['基本信息', '异常处理']
}
},
@@ -169,11 +169,6 @@
if (res.code === 0) {
this.info = res.data
this.info.checkPhoto = res.data.checkPhoto ? JSON.parse(res.data.checkPhoto) : []
if (res.data.status === '0') {
this.tabList = ['基本信息', '异常处理']
} else {
this.tabList = ['基本信息']
}
}
})
},

View File

@@ -116,7 +116,18 @@
label: '到达地区'
},
{ prop: 'checkTime', align: 'center', label: '核酸日期', formart: v => v.split(' ')[0] },
{ prop: 'status', align: 'center', label: '健康状态', formart: v => v === '0' ? '异常' : '正常' },
{
prop: 'status',
align: 'center',
label: '健康状态',
render: (h, {row}) => {
return h('span', {
style: {
color: row.status === '0' ? 'red' : '#333'
}
}, row.status === '0' ? '异常' : '正常')
}
},
// { prop: 'type', align: 'center', label: '今日上报' }
],
ids: [],