| | |
| | | } |
| | | taskItems.add(taskItem); |
| | | |
| | | Double qty = Math.round((item.getWorkQty() + item.getOutQty()) * 10000) / 10000.0; |
| | | Double qty = Math.round((item.getWorkQty() + item.getOutQty()) * 100) / 100.0; |
| | | LocItem locItem = locItemService.getById(item.getId()); |
| | | if (Objects.isNull(locItem)) { |
| | | throw new CoolException("库存信息不存在!"); |
| | |
| | | } |
| | | |
| | | if (locItem.getAnfme().compareTo(qty) < 0) { |
| | | Double minusQty = Math.round((locItem.getAnfme() - locItem.getWorkQty()) * 10000) / 10000.0; |
| | | Double minusQty = Math.round((locItem.getAnfme() - locItem.getWorkQty()) * 100) / 100.0; |
| | | item.setWorkQty(minusQty); |
| | | } else { |
| | | item.setWorkQty(qty); |