|
@ -21,14 +21,15 @@ |
|
|
</template> |
|
|
</template> |
|
|
<template #bodyCell="{ column, record }"> |
|
|
<template #bodyCell="{ column, record }"> |
|
|
<template v-if="column.key === 'image'"> |
|
|
<template v-if="column.key === 'image'"> |
|
|
<a-image :src="record.image" :width="50"/> |
|
|
|
|
|
|
|
|
<template v-if="record.image" v-for="(item,index) in JSON.parse(record.image)" :key="index"> |
|
|
|
|
|
<a-image :src="item.url" :width="50"/> |
|
|
|
|
|
</template> |
|
|
</template> |
|
|
</template> |
|
|
<template v-if="column.key === 'status'"> |
|
|
<template v-if="column.key === 'status'"> |
|
|
<a-tag v-if="record.status === 0" color="green">已处理</a-tag> |
|
|
|
|
|
<a-tag v-if="record.status === 1" color="red">待处理</a-tag> |
|
|
|
|
|
|
|
|
<a-tag v-if="record.status === 0" color="red">待处理</a-tag> |
|
|
|
|
|
<a-tag v-if="record.status === 1" color="green">已处理</a-tag> |
|
|
</template> |
|
|
</template> |
|
|
<template v-if="column.key === 'action'"> |
|
|
<template v-if="column.key === 'action'"> |
|
|
<a-space> |
|
|
|
|
|
<a @click="openEdit(record)">修改</a> |
|
|
<a @click="openEdit(record)">修改</a> |
|
|
<a-divider type="vertical"/> |
|
|
<a-divider type="vertical"/> |
|
|
<a-popconfirm |
|
|
<a-popconfirm |
|
@ -37,7 +38,6 @@ |
|
|
> |
|
|
> |
|
|
<a class="ele-text-danger">删除</a> |
|
|
<a class="ele-text-danger">删除</a> |
|
|
</a-popconfirm> |
|
|
</a-popconfirm> |
|
|
</a-space> |
|
|
|
|
|
</template> |
|
|
</template> |
|
|
</template> |
|
|
</template> |
|
|
</ele-pro-table> |
|
|
</ele-pro-table> |
|
@ -110,51 +110,53 @@ const columns = ref<ColumnItem[]>([ |
|
|
dataIndex: 'carNo', |
|
|
dataIndex: 'carNo', |
|
|
key: 'carNo', |
|
|
key: 'carNo', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
|
|
|
width: 120 |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
title: '事故类型', |
|
|
title: '事故类型', |
|
|
dataIndex: 'accidentType', |
|
|
dataIndex: 'accidentType', |
|
|
key: 'accidentType', |
|
|
key: 'accidentType', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
width: 170 |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
title: '事故描述', |
|
|
|
|
|
dataIndex: 'comments', |
|
|
|
|
|
key: 'comments' |
|
|
|
|
|
|
|
|
width: 120 |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
title: '报险图片', |
|
|
|
|
|
|
|
|
title: '现场图片', |
|
|
dataIndex: 'image', |
|
|
dataIndex: 'image', |
|
|
key: 'image', |
|
|
key: 'image', |
|
|
align: 'center', |
|
|
|
|
|
width: 170 |
|
|
|
|
|
|
|
|
align: 'center' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
title: '事故描述', |
|
|
|
|
|
dataIndex: 'comments', |
|
|
|
|
|
key: 'comments', |
|
|
|
|
|
align: 'center' |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
title: '操作员', |
|
|
title: '操作员', |
|
|
dataIndex: 'realName', |
|
|
dataIndex: 'realName', |
|
|
key: 'realName', |
|
|
key: 'realName', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
width: 170 |
|
|
|
|
|
|
|
|
width: 120 |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
title: '状态', |
|
|
title: '状态', |
|
|
dataIndex: 'status', |
|
|
dataIndex: 'status', |
|
|
key: 'status', |
|
|
key: 'status', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
width: 170 |
|
|
|
|
|
|
|
|
width: 120 |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
title: '创建时间', |
|
|
title: '创建时间', |
|
|
dataIndex: 'createTime', |
|
|
dataIndex: 'createTime', |
|
|
key: 'createTime', |
|
|
key: 'createTime', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
sorter: true |
|
|
|
|
|
|
|
|
sorter: true, |
|
|
|
|
|
width: 180 |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
title: '操作', |
|
|
title: '操作', |
|
|
key: 'action', |
|
|
key: 'action', |
|
|
width: 180, |
|
|
|
|
|
|
|
|
width: 120, |
|
|
fixed: 'right', |
|
|
fixed: 'right', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
hideInSetting: true |
|
|
hideInSetting: true |
|
@ -181,7 +183,7 @@ const openMove = () => { |
|
|
/* 删除单个 */ |
|
|
/* 删除单个 */ |
|
|
const remove = (row: HjmBxLog) => { |
|
|
const remove = (row: HjmBxLog) => { |
|
|
const hide = message.loading('请求中..', 0); |
|
|
const hide = message.loading('请求中..', 0); |
|
|
removeHjmBxLog(row.hjmBxLogId) |
|
|
|
|
|
|
|
|
removeHjmBxLog(row.id) |
|
|
.then((msg) => { |
|
|
.then((msg) => { |
|
|
hide(); |
|
|
hide(); |
|
|
message.success(msg); |
|
|
message.success(msg); |
|
@ -206,7 +208,7 @@ const removeBatch = () => { |
|
|
maskClosable: true, |
|
|
maskClosable: true, |
|
|
onOk: () => { |
|
|
onOk: () => { |
|
|
const hide = message.loading('请求中..', 0); |
|
|
const hide = message.loading('请求中..', 0); |
|
|
removeBatchHjmBxLog(selection.value.map((d) => d.hjmBxLogId)) |
|
|
|
|
|
|
|
|
removeBatchHjmBxLog(selection.value.map((d) => d.id)) |
|
|
.then((msg) => { |
|
|
.then((msg) => { |
|
|
hide(); |
|
|
hide(); |
|
|
message.success(msg); |
|
|
message.success(msg); |
|
|