diff --git a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml index 71ac1382b..3bcb8765d 100644 --- a/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml +++ b/blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml @@ -348,7 +348,7 @@ ) ordNub, COALESCE ( lds.received_quantity + lds.receivedin_quantity, 0 ) signNub, ldsk.stockup_area stockupArea, - COALESCE ( ldrs.reservation_num, 0 ) inventoryNub + (SELECT SUM(reservation_num) FROM logpm_distribution_reservation_stocklist WHERE reservation_id = ldr.id ) inventoryNub -- COUNT(DISTINCT lwtg.tray_id) AS trayNum FROM logpm_distribution_signfor lds