优化
This commit is contained in:
@@ -1,20 +1,20 @@
|
||||
<template>
|
||||
<view class="receiving-summary">
|
||||
<view class="receiving-summary-head">
|
||||
<view><text class="receiving-summary-label">{{ $t('receivingSummary.container') }}</text><text class="receiving-summary-container">{{ session?.containerNo || '—' }}</text></view>
|
||||
<view><text class="receiving-summary-label">当前柜号</text><text class="receiving-summary-container">{{ session?.containerNo || '—' }}</text></view>
|
||||
<text class="receiving-summary-status">{{ statusLabel }}</text>
|
||||
</view>
|
||||
<view class="receiving-summary-context">
|
||||
<text>{{ $t('receivingSummary.warehouse') }}:{{ session?.overseasWarehouseName || '—' }}</text>
|
||||
<text>{{ $t('receivingSummary.destinations') }}:{{ destinationSummary }}</text>
|
||||
<text>收货仓:{{ session?.overseasWarehouseName || '—' }}</text>
|
||||
<text>目的仓:{{ destinationSummary }}</text>
|
||||
</view>
|
||||
<view class="receiving-summary-metrics">
|
||||
<view><text class="metric-value">{{ inboundCodeCount }}</text><text class="metric-label">{{ $t('receivingSummary.inboundCodes') }}</text></view>
|
||||
<view><text class="metric-value">{{ plannedPalletCount }}</text><text class="metric-label">{{ $t('receivingSummary.plannedPallets') }}</text></view>
|
||||
<view><text class="metric-value">{{ totalPackages }}</text><text class="metric-label">{{ $t('receivingSummary.plannedBoxes') }}</text></view>
|
||||
<view><text class="metric-value metric-pending">{{ pendingPackages }}</text><text class="metric-label">{{ $t('receivingSummary.pendingBoxes') }}</text></view>
|
||||
<view><text class="metric-value">{{ inboundCodeCount }}</text><text class="metric-label">入仓码</text></view>
|
||||
<view><text class="metric-value">{{ plannedPalletCount }}</text><text class="metric-label">计划托数</text></view>
|
||||
<view><text class="metric-value">{{ totalPackages }}</text><text class="metric-label">计划箱数</text></view>
|
||||
<view><text class="metric-value metric-pending">{{ pendingPackages }}</text><text class="metric-label">待收箱数</text></view>
|
||||
</view>
|
||||
<view class="receiving-summary-progress"><view><text>{{ $t('operation.receivingProgress') }}</text><text>{{ receivedPackages }} / {{ totalPackages }} {{ $t('common.boxes') }}</text></view><view class="progress-track"><view class="progress-fill" :style="{ width: percent + '%' }"></view></view></view>
|
||||
<view class="receiving-summary-progress"><view><text>收货进度</text><text>{{ receivedPackages }} / {{ totalPackages }} 箱</text></view><view class="progress-track"><view class="progress-fill" :style="{ width: percent + '%' }"></view></view></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
receivedPackages() { return Math.max(0, Number(this.session?.receivedPackages || 0)) },
|
||||
pendingPackages() { return Math.max(0, Number(this.session?.pendingPackages ?? this.totalPackages - this.receivedPackages)) },
|
||||
percent() { return this.totalPackages ? Math.min(100, Math.round(this.receivedPackages / this.totalPackages * 100)) : 0 },
|
||||
statusLabel() { return this.$t(({ WAIT_SIGN: 'operation.statusWait', SIGNED: 'operation.statusSigned', RECEIVING: 'operation.statusReceiving', COMPLETED: 'operation.statusCompleted' })[this.session?.status] || 'operation.statusWait') }
|
||||
statusLabel() { return ({ WAIT_SIGN: '待签收', SIGNED: '已签收', RECEIVING: '收货中', COMPLETED: '已完成' })[this.session?.status] || '待签收' }
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user