一件代发拣货
This commit is contained in:
+12
@@ -243,6 +243,18 @@ public class InboundPlanService {
|
||||
if (trimToNull(request.warehouseName()) != null) line.setDestinationWarehouseName(request.warehouseName().trim());
|
||||
lineMapper.updateById(line);
|
||||
}
|
||||
// Pallets carry the same destination snapshot and are consumed by PDA/resource assignment.
|
||||
// Update them in this transaction so a plan edit cannot leave lines and pallets pointing at
|
||||
// different warehouses.
|
||||
List<InboundPlanPallet> pallets = palletMapper.selectList(new LambdaQueryWrapper<InboundPlanPallet>()
|
||||
.eq(InboundPlanPallet::getPlanId, plan.getId())
|
||||
.eq(InboundPlanPallet::getCustomerId, plan.getCustomerId()));
|
||||
for (InboundPlanPallet pallet : pallets) {
|
||||
pallet.setDestinationWarehouseId(String.valueOf(request.overseasWarehouseId()));
|
||||
if (trimToNull(request.warehouseCode()) != null) pallet.setDestinationWarehouseCode(request.warehouseCode().trim());
|
||||
if (trimToNull(request.warehouseName()) != null) pallet.setDestinationWarehouseName(request.warehouseName().trim());
|
||||
palletMapper.updateById(pallet);
|
||||
}
|
||||
return detail(customerId, plan);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user