| | |
| | | throw new CoolException("请提取一个商品,或者刷新重新组托!"); |
| | | } |
| | | // 判断是否有相同条码的数据 |
| | | if (waitPakinService.selectCount(new EntityWrapper<WaitPakin>(). |
| | | eq("zpallet", param.getBarcode()).eq("io_status", "N")) > 0) { |
| | | throw new CoolException(param.getBarcode() + "数据正在进行入库"); |
| | | } |
| | | // if (waitPakinService.selectCount(new EntityWrapper<WaitPakin>(). |
| | | // eq("zpallet", param.getBarcode()).eq("io_status", "N")) > 0) { |
| | | // throw new CoolException(param.getBarcode() + "数据正在进行入库"); |
| | | // } |
| | | |
| | | if(param.getBarcode().length()!=9){ |
| | | throw new CoolException("条码长度不是9位===>>" + param.getBarcode()); |
| | |
| | | |
| | | int countLoc = locDetlService.selectCount(new EntityWrapper<LocDetl>().eq("zpallet",param.getBarcode())); |
| | | int countWrk = wrkDetlService.selectCount(new EntityWrapper<WrkDetl>().eq("zpallet",param.getBarcode())); |
| | | int countwait = waitPakinService.selectCount(new EntityWrapper<WaitPakin>().eq("zpallet",param.getBarcode())); |
| | | if (countLoc > 0 || countWrk > 0 || countwait > 0) { |
| | | throw new CoolException("组托档/工作档/库存条码数据已存在===>>" + param.getBarcode()); |
| | | // int countwait = waitPakinService.selectCount(new EntityWrapper<WaitPakin>().eq("zpallet",param.getBarcode())); |
| | | if (countLoc > 0 || countWrk > 0) { |
| | | throw new CoolException("工作档/库存条码数据已存在===>>" + param.getBarcode()); |
| | | } |
| | | |
| | | Date now = new Date(); |
| | |
| | | String barcode2 = map.get("barcode2").toString(); |
| | | |
| | | int countLoc = locDetlService.selectCount(new EntityWrapper<LocDetl>().eq("zpallet",barcode2)); |
| | | int countWrk = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("zpallet",barcode2).ne("io_type",200)); |
| | | int countWrk = wrkMastService.selectCount(new EntityWrapper<WrkMast>().eq("barcode",barcode2).ne("io_type",200)); |
| | | int countwait = waitPakinService.selectCount(new EntityWrapper<WaitPakin>().eq("zpallet",barcode2)); |
| | | if (countLoc > 0 || countWrk > 0 || countwait > 0) { |
| | | throw new CoolException("该条码已被使用===>>" + barcode2); |