feat: complete overseas PDA warehouse operations
This commit is contained in:
@@ -11,6 +11,7 @@ test('all registered user-facing pages avoid rendering internal identifiers', as
|
||||
'../src/pages/login/login.vue', '../src/pages/home/home.vue', '../src/pages/module/module.vue',
|
||||
'../src/pages/operation/operation.vue', '../src/pages/pallet/pallet.vue', '../src/pages/profile/profile.vue',
|
||||
'../src/pages/dispatch/dispatch.vue', '../src/pages/outbound/outbound.vue',
|
||||
'../src/pages/stocktake/stocktake.vue', '../src/pages/move/move.vue', '../src/pages/relabel/relabel.vue', '../src/pages/query/query.vue',
|
||||
'../src/pages/history/history.vue', '../src/pages/scanner-test/scanner-test.vue',
|
||||
'../src/components/PortalHeader.vue', '../src/components/PopupHeader.vue',
|
||||
'../src/components/ReceivingSessionSummary.vue', '../src/components/ScanTargetInput.vue'
|
||||
@@ -39,13 +40,16 @@ test('operator and warehouse cards never fall back to internal IDs', async () =>
|
||||
})
|
||||
|
||||
test('operation templates expose business references only and keep diagnostic evidence', async () => {
|
||||
const [operation, pallet, summary, apiFiles] = await Promise.all([
|
||||
const [operation, pallet, summary, stocktake, move, relabel, query, apiFiles] = await Promise.all([
|
||||
read('../src/pages/operation/operation.vue'),
|
||||
read('../src/pages/pallet/pallet.vue'),
|
||||
read('../src/components/ReceivingSessionSummary.vue'),
|
||||
read('../src/pages/stocktake/stocktake.vue'), read('../src/pages/move/move.vue'),
|
||||
read('../src/pages/relabel/relabel.vue'), read('../src/pages/query/query.vue'),
|
||||
Promise.all([
|
||||
read('../src/api/inbound.js'), read('../src/api/pallet.js'),
|
||||
read('../src/api/overseas.js'), read('../src/api/receiving-adapter.js')
|
||||
read('../src/api/overseas.js'), read('../src/api/receiving-adapter.js'),
|
||||
read('../src/api/warehouse-operations.js'), read('../src/api/relabel.js')
|
||||
]).then((values) => values.join('\n'))
|
||||
])
|
||||
|
||||
@@ -59,6 +63,7 @@ test('operation templates expose business references only and keep diagnostic ev
|
||||
}
|
||||
for (const field of ['orderId', 'inboundId', 'planId', 'containerBookingId', 'sourceContainerBookingId', 'warehouseId', 'palletId', 'locationId']) {
|
||||
assert.doesNotMatch(template(pallet), new RegExp(`\\b${field}\\b`))
|
||||
for (const page of [stocktake, move, relabel, query]) assert.doesNotMatch(template(page), new RegExp(`\\b${field}\\b`))
|
||||
}
|
||||
|
||||
for (const businessField of ['containerNo', 'inboundCode', 'cartonMark', 'palletCode']) {
|
||||
@@ -66,6 +71,7 @@ test('operation templates expose business references only and keep diagnostic ev
|
||||
}
|
||||
assert.match(operation, /requestId[\s\S]*traceId/)
|
||||
assert.match(pallet, /requestId[\s\S]*traceId/)
|
||||
for (const page of [stocktake, move, relabel, query]) assert.match(page, /requestId[\s\S]*traceId/)
|
||||
assert.doesNotMatch(apiFiles, /\/api\/platform\/v1\/|inbound-code-relationships/)
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user