feat: complete overseas PDA warehouse operations

This commit is contained in:
2026-09-04 12:42:17 +08:00
parent e8f5d053ee
commit f960b9fe5f
18 changed files with 678 additions and 66 deletions
+12 -5
View File
@@ -9,16 +9,23 @@ test('only operations backed by a dedicated overseas PDA contract are enabled',
{ module: 'inbound', name: '拆柜收货' },
{ module: 'outbound', name: '排车拣货' },
{ module: 'outbound', name: '出库作业' },
{ module: 'inventory', name: '托盘管理' }
{ module: 'inventory', name: '库存盘点' },
{ module: 'inventory', name: '商品移库' },
{ module: 'inventory', name: '托盘管理' },
{ module: 'relabel', name: '换标收货' },
{ module: 'relabel', name: '换标执行' },
{ module: 'relabel', name: '换标复核' },
{ module: 'query', name: '库存查询' },
{ module: 'query', name: '库位查询' },
{ module: 'query', name: '托盘查询' }
])
assert.equal(operations.find((item) => item.name === '托盘管理')?.route, '/pages/pallet/pallet')
assert.equal(operations.find((item) => item.name === '排车拣货')?.route, '/pages/dispatch/dispatch')
assert.equal(operations.find((item) => item.name === '出库作业')?.route, '/pages/outbound/outbound')
const pendingNames = ['库存盘点', '商品移库', '换标收货', '换标执行', '换标复核', '库存查询', '库位查询', '托盘查询']
for (const name of pendingNames) {
for (const name of ['库存盘点', '商品移库', '换标收货', '换标执行', '换标复核', '库存查询', '库位查询', '托盘查询']) {
const operation = operations.find((item) => item.name === name)
assert.equal(operation?.available, false, `${name} must fail closed until its PDA API exists`)
assert.equal(operation?.badge, undefined)
assert.equal(operation?.available, true)
assert.match(operation?.route || '', /^\/pages\//)
}
})