| | |
| | | ) as minQuantity -- 修改最小数 |
| | | </if> |
| | | <if test="nextProcess == null or nextProcess == ''"> -- 最后一道工序 |
| | | # c.received_quantity, -- 已入库数量 |
| | | # c.inventory_quantity, -- 库存数量 |
| | | c.received_quantity, -- 已入库数量 |
| | | c.inventory_quantity, -- 库存数量 |
| | | if(ifnull(inventory_quantity,0) |
| | | -ifnull(c.received_quantity,0) |
| | | >= a.completed_quantity,0, |
| | | (a.completed_quantity-(ifnull(c.inventory_quantity,0) |
| | | -ifnull(c.received_quantity,0))) |
| | | >= a.completed_quantity,a.completed_quantity, |
| | | (ifnull(c.inventory_quantity,0) |
| | | -ifnull(c.received_quantity,0)) |
| | | ) |
| | | as minQuantity -- 修改最小数 |
| | | </if> |