Merge branch 'release/test' of http://git.buggoglobal.com/html/admin-web into dev

This commit is contained in:
2026-09-01 10:18:48 +08:00
221 changed files with 6764 additions and 5701 deletions
@@ -23,6 +23,28 @@ describe('last-mile order presentation adapter', () => {
expect(row.rejectedAt).toBe('—')
})
it('shows the backend customerName and never guesses the owner from customerId', () => {
expect(toLastMileOrderListItem({
id: '1', customerId: '190000000000000001', customerName: '华远贸易', orderNo: 'LMO-260827-0001',
}).owner).toBe('华远贸易')
expect(toLastMileOrderListItem({
id: '2', customerId: '190000000000000002', customerName: null, orderNo: 'LMO-260827-0002',
}).owner).toBe('—')
})
it('preserves real metrics and distinguishes zero from unknown fields and times', () => {
const estimatedArrivalAt = '2026-08-27T12:30:00Z'
const row = toLastMileOrderListItem({
id: '3', customerId: '190000000000000003', orderNo: 'LMO-260827-0003',
palletCount: 3, packageCount: 0, volumeCbm: 12.75, productQuantity: null, volumeWeightKg: 88.6,
estimatedArrivalAt, actualArrivalAt: null, estimatedWarehouseAt: null,
})
expect(row).toMatchObject({
pallets: 3, cartons: 0, volume: 12.75, quantity: '—', volumeWeight: 88.6,
portEta: formatOverseasDateTime(estimatedArrivalAt), portAta: '—', warehouseEta: '—',
})
})
it.each([
['RELABEL_APPLICATION', '换标下单'],
['WAREHOUSE_TRANSFER', '仓储转运'],