修改内容
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
<el-descriptions-item label="创建时间:">{{ data.baseInfo.createTime || '' }}</el-descriptions-item>
|
||||
<el-descriptions-item label="登记设备数量:">{{ totalRegisteredDevices }} 个</el-descriptions-item>
|
||||
<el-descriptions-item label="状态:">
|
||||
<el-tag :type="data.baseInfo.status === 2 ? 'success' : 'warning'">{{ getStatusText(data.baseInfo.status) }}</el-tag>
|
||||
<el-tag :type="getStatusType(data.baseInfo.status)">{{ getStatusText(data.baseInfo.status) }}</el-tag>
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="车身照片:">
|
||||
<span style="vertical-align: top">
|
||||
@@ -1108,14 +1108,30 @@ const totalRegisteredDevices = computed(() => {
|
||||
const getStatusText = (status) => {
|
||||
const statusMap = {
|
||||
1: '待装车',
|
||||
2: '装车中',
|
||||
3: '运输中',
|
||||
4: '已送达',
|
||||
5: '已完成'
|
||||
2: '已装车/预付款已支付',
|
||||
3: '已装车/尾款待支付',
|
||||
4: '已核验/待买家付款',
|
||||
5: '尾款已付款',
|
||||
6: '发票待开/进项票',
|
||||
7: '发票待开/销项'
|
||||
};
|
||||
return statusMap[status] || '未知状态';
|
||||
};
|
||||
|
||||
// 根据状态返回标签类型(颜色)
|
||||
const getStatusType = (status) => {
|
||||
const typeMap = {
|
||||
1: 'info', // 待装车 - 灰色
|
||||
2: 'success', // 已装车/预付款已支付 - 绿色
|
||||
3: 'warning', // 已装车/尾款待支付 - 橙色
|
||||
4: 'warning', // 已核验/待买家付款 - 橙色
|
||||
5: 'success', // 尾款已付款 - 绿色
|
||||
6: 'primary', // 发票待开/进项票 - 蓝色
|
||||
7: 'primary' // 发票待开/销项 - 蓝色
|
||||
};
|
||||
return typeMap[status] || 'info';
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
data.id = route.query.id;
|
||||
data.status = route.query.status;
|
||||
|
||||
Reference in New Issue
Block a user