导入批量修改价格明细

This commit is contained in:
wuweihua
2026-09-28 18:01:26 +08:00
parent c278ed76f7
commit b247bc2fd2
19 changed files with 777 additions and 54 deletions
@@ -73,19 +73,33 @@
<el-table-column :label="colWeight" prop="weightLabel" min-width="120" />
<el-table-column :label="colFv" min-width="130" align="right">
<template #default="{ row }">
<template v-if="row.fvValue == null">
<span class="unit">未覆盖</span>
</template>
<template v-else>
<span class="hl">{{ row.fvValue }}</span>
<span class="unit"> RMB/KG</span>
</template>
<el-tooltip placement="top" :disabled="!hasBaseFreight(row)">
<template #content>
<span>产品基础运费:{{ formatBase(row.baseFreightPrice, 4) }} RMB/KG</span>
</template>
<span class="price-tip">
<template v-if="row.fvValue == null">
<span class="unit">未覆盖</span>
</template>
<template v-else>
<span class="hl">{{ row.fvValue }}</span>
<span class="unit"> RMB/KG</span>
</template>
</span>
</el-tooltip>
</template>
</el-table-column>
<el-table-column :label="colReg" min-width="120" align="right">
<template #default="{ row }">
<span class="reg">{{ row.fvRegistrationFee }}</span>
<span class="unit"> RMB/票</span>
<el-tooltip placement="top" :disabled="!hasBaseReg(row)">
<template #content>
<span>产品基础挂号费:{{ formatBase(row.baseRegistrationFee, 2) }} RMB/票</span>
</template>
<span class="price-tip">
<span class="reg">{{ row.fvRegistrationFee }}</span>
<span class="unit"> RMB/票</span>
</span>
</el-tooltip>
</template>
</el-table-column>
</template>
@@ -211,6 +225,19 @@ const title = computed(() => {
return (v.versionNo || '-') + ' · 版本明细'
})
function hasBaseFreight(row) {
return row && row.baseFreightPrice != null && row.baseFreightPrice !== ''
}
function hasBaseReg(row) {
return row && row.baseRegistrationFee != null && row.baseRegistrationFee !== ''
}
function formatBase(v, precision) {
if (v == null || v === '') return '-'
const n = Number(v)
if (Number.isNaN(n)) return String(v)
return n.toFixed(precision)
}
function roundModeLabel(mode) {
const hit = (bms_round_mode.value || []).find(d => d.value === mode)
return hit ? hit.label : (mode || '四舍五入')
@@ -313,4 +340,11 @@ watch(
.reg { color: #d48806; font-weight: 600; }
.pct { color: #1890ff; font-weight: 600; }
.unit { font-size: 12px; color: #909399; }
.price-tip {
cursor: help;
border-bottom: 1px dashed transparent;
}
.price-tip:hover {
border-bottom-color: #c0c4cc;
}
</style>