fix(生产工单报工):报工查询产出总数量
This commit is contained in:
parent
14d85f3dac
commit
3a3f4c4b6d
@ -85,6 +85,11 @@ public class ShopOrderStatisticTransController {
|
||||
List<ZShoporderStatisticsTransaction> newList = new ArrayList<>();
|
||||
String bat = SapUtil.noPrefixGenerateReqId();
|
||||
for (ZShoporderStatisticsTransaction soStatisticsTrans : shoporderStatisticsTransactionList) {
|
||||
// 获取工单已完工数量
|
||||
BigDecimal qtyOut = zShoporderStatisticsTransactionMapper.getQtyOut(soStatisticsTrans);
|
||||
if (qtyOut != null) {
|
||||
soStatisticsTrans.setQtyOut(qtyOut);
|
||||
}
|
||||
// 校验已报数量和产出数量
|
||||
if (soStatisticsTrans.getSumQtyDone().compareTo(soStatisticsTrans.getQtyOut()) >= 0) {
|
||||
throw BusinessException.build("工单【"+soStatisticsTrans.getShopOrder()+"】没有需要报工的产出数量!");
|
||||
|
||||
Loading…
Reference in New Issue
Block a user