fix(lastleg): preserve source validation during partial dispatch picking
This commit is contained in:
+4
-2
@@ -133,8 +133,10 @@ public class AppointmentWorkDispatchBinding implements AppointmentWorkDispatchPo
|
||||
return new Allocation(row.palletId(),row.batchKey(),version,row.customerId(),row.sourceKey(),row.destinationKey(),row.packages());
|
||||
}
|
||||
private void validatePhysical(String customer,PhysicalItem item,List<Allocation> selected,boolean received,boolean picked) {
|
||||
var physical=picked?mapper.pickedPhysical(item.itemId(),customer)
|
||||
:received?mapper.receivedPhysical(item.planPalletId(),customer):mapper.physical(item.planPalletId(),customer);
|
||||
var physical=new ArrayList<>(picked?mapper.pickedPhysical(item.itemId(),customer)
|
||||
:received?mapper.receivedPhysical(item.planPalletId(),customer):mapper.physical(item.planPalletId(),customer));
|
||||
// 扫码已从库位扣减;审核与后续扫码须合并本明细已拣逐票归属,发车仍只认真实已拣。
|
||||
if(received && !picked) physical.addAll(mapper.pickedPhysical(item.itemId(),customer));
|
||||
if(physical.isEmpty()) throw conflict("托盘缺少真实逐票分配,不能按整票或整托总数猜测批次");
|
||||
var canonical=AppointmentWorkPhysicalSources.canonical(physical,sources);
|
||||
var remaining=new HashMap<String,Long>();
|
||||
|
||||
Reference in New Issue
Block a user