fix bug
This commit is contained in:
@@ -419,7 +419,7 @@
|
||||
|
||||
<el-dialog
|
||||
v-model="candidateDialog.visible"
|
||||
title="添加应收应付明细进预结算单"
|
||||
title="选择结算明细"
|
||||
width="92%"
|
||||
append-to-body
|
||||
destroy-on-close
|
||||
@@ -466,6 +466,9 @@
|
||||
>
|
||||
<template #default="{ row }">
|
||||
<span v-if="column.money">{{ formatMoney(row[column.prop], row.currency) }}</span>
|
||||
<span v-else-if="column.prop === 'transportType'">
|
||||
{{ transportTypeName(row[column.prop]) }}
|
||||
</span>
|
||||
<span v-else>{{ displayValue(row[column.prop]) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
@@ -1086,8 +1089,15 @@ export default {
|
||||
},
|
||||
transportTypeName(value) {
|
||||
if (value === undefined || value === null || value === '') return '';
|
||||
const normalizedValue = String(value).trim().toLocaleLowerCase();
|
||||
const option = this.transportTypeOptions.find(
|
||||
item => String(item.dictKey) === String(value) || String(item.dictValue) === String(value)
|
||||
item =>
|
||||
String(item.dictKey ?? '')
|
||||
.trim()
|
||||
.toLocaleLowerCase() === normalizedValue ||
|
||||
String(item.dictValue ?? '')
|
||||
.trim()
|
||||
.toLocaleLowerCase() === normalizedValue
|
||||
);
|
||||
return option?.dictValue || value;
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user