diff --git a/db/routines/vn/procedures/productionControl.sql b/db/routines/vn/procedures/productionControl.sql index ba8764c77..71536e12e 100644 --- a/db/routines/vn/procedures/productionControl.sql +++ b/db/routines/vn/procedures/productionControl.sql @@ -276,6 +276,7 @@ proc: BEGIN JOIN productionConfig pc SET pb.hasPlantTray = TRUE WHERE p.isPlantTray + AND s.quantity >= b.packing AND pb.isOwn; DROP TEMPORARY TABLE