Commit 765d38a0 by sunyang

排单

parent 7a7d4b5b
......@@ -3741,11 +3741,28 @@ const tableColumns = computed(() => {
width: 150,
prop: 'craftType',
align: 'center',
render: (item:ProductList) => (
<div>
<span>{processType.value.find((e) => e.value === item.craftType)?.label}</span>
</div>
)
render: (item:ProductList) => {
if (!item.craftType) {
return (
<div>
<span>-</span>
</div>
)
}
// 分割字符串并查找对应的 label
const labels = item.craftType
.split(',')
.map(type => type.trim())
.map(type => processType.value.find(e => e.value === type)?.label || type)
.filter(Boolean)
return (
<div>
<span>{labels.join(',')}</span>
</div>
)
}
},
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment