fix(admin): clarify unassigned overseas warehouse
This commit is contained in:
@@ -24,6 +24,9 @@ const canReadOverseas = computed(() => props.canReadOverseas)
|
||||
const normalizedCode = computed(() => props.inboundCode.trim())
|
||||
|
||||
function display(value: unknown, fallback = '—') { return String(value ?? '').trim() || fallback }
|
||||
function overseasWarehouseName(value: OverseasInboundCodeRelationship['overseasWarehouse']) {
|
||||
return value ? display(value.warehouseName, '仓库名称待补充') : '尚未分配海外仓'
|
||||
}
|
||||
function close(value: boolean) { emit('update:modelValue', value) }
|
||||
|
||||
async function load() {
|
||||
@@ -77,7 +80,7 @@ watch(() => [props.modelValue, props.inboundCode, props.canReadBase, props.canRe
|
||||
<LoadErrorState v-if="overseasError" title="海外关联加载失败" :message="overseasError.message" @retry="load"><template #details><ApiErrorMeta :details="overseasError" /></template></LoadErrorState>
|
||||
<el-empty v-else-if="overseas && !overseas.found" description="服务端未找到该入仓码的海外关联数据" :image-size="56" />
|
||||
<template v-else-if="overseas">
|
||||
<dl class="compact-facts"><div><dt>客户</dt><dd>{{ display(overseas.customer?.customerName, '客户名称待补充') }}</dd></div><div><dt>海外仓</dt><dd>{{ display(overseas.overseasWarehouse?.warehouseName, '仓库名称待补充') }}<small v-if="overseas.overseasWarehouse?.warehouseCode">{{ overseas.overseasWarehouse.warehouseCode }}</small></dd></div></dl>
|
||||
<dl class="compact-facts"><div><dt>客户</dt><dd>{{ display(overseas.customer?.customerName, '客户名称待补充') }}</dd></div><div><dt>海外仓</dt><dd>{{ overseasWarehouseName(overseas.overseasWarehouse) }}<small v-if="overseas.overseasWarehouse?.warehouseCode">{{ overseas.overseasWarehouse.warehouseCode }}</small></dd></div></dl>
|
||||
<div class="compact-list"><strong>尾程订单</strong><span :title="overseas.taillegOrders.map((item) => item.orderNo).join('、')">{{ overseas.taillegOrders.map((item) => `${item.orderNo}${item.orderStatus ? `(${item.orderStatus})` : ''}`).filter(Boolean).join('、') || '—' }}</span></div>
|
||||
<div class="compact-list"><strong>入库计划</strong><span :title="overseas.inboundPlans.map((item) => item.planNo).join('、')">{{ overseas.inboundPlans.map((item) => `${item.planNo}${item.planStatus ? `(${item.planStatus})` : ''}${item.receivingStatus ? ` · ${item.receivingStatus}` : ''}`).join('、') || '—' }}</span></div>
|
||||
<div class="compact-list"><strong>托盘号</strong><span :title="overseas.palletCodes.join('、')">{{ overseas.palletCodes.join('、') || '—' }}</span></div>
|
||||
|
||||
Reference in New Issue
Block a user