| | |
| | | wrapper.eq("brand", param.get("brand")); |
| | | param.remove("brand"); |
| | | } |
| | | // 仓库精确匹配 |
| | | if (!Cools.isEmpty(param.get("stash"))) { |
| | | wrapper.eq("stash", param.get("stash")); |
| | | param.remove("stash"); |
| | | } |
| | | // 没有选择的时候默认不显示已出库的物料 |
| | | if (Cools.isEmpty(param.get("status"))) { |
| | | wrapper.ne("status", "全部出库"); |
| | |
| | | } |
| | | |
| | | @RequestMapping(value = "/pla/sellout/auth") |
| | | @ManagerAuth |
| | | @ManagerAuth(memo = "sellout") |
| | | @Transactional |
| | | @Synchronized |
| | | public R sellout(@RequestBody List<Pla> plas) { |
| | |
| | | if (pla.getWeightAnfme() - pla.getQtyAnfme() - pla.getOrderWeight() < 0) { |
| | | throw new CoolException("批号:" + pla.getBatch() + ",包号:" + pla.getPackageNo() + " 剩余可出库重量不足,请调整出库重量"); |
| | | } |
| | | if (Cools.isEmpty(pla.getMassState())){ |
| | | throw new CoolException("质量指标为上传"); |
| | | } |
| | | pla.setQtyAnfme(pla.getQtyAnfme() + pla.getOrderWeight()); |
| | | pla.setHandlerBy(getUser().getUsername()); |
| | | pla.setStatus(GlobleParameter.PLA_STATUS_2); |