| | |
| | | import com.core.common.SnowflakeIdWorker; |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.entity.*; |
| | | import com.zy.asrs.entity.param.EmptyPlateOutParam; |
| | | import com.zy.asrs.entity.param.FullStoreParam; |
| | | import com.zy.asrs.entity.param.LocDetlAdjustParam; |
| | | import com.zy.asrs.entity.param.StockOutParam; |
| | | import com.zy.asrs.entity.param.*; |
| | | import com.zy.asrs.service.*; |
| | | import com.zy.asrs.utils.Utils; |
| | | import com.zy.common.model.*; |
| | |
| | | } else { |
| | | throw new CoolException(dto.getLocNo() + "库位不是在库状态"); |
| | | } |
| | | locMastService.breakUp(dto.getLocNo(), excludeLocNos); |
| | | // locMastService.breakUp(dto.getLocNo(), excludeLocNos); |
| | | } |
| | | } |
| | | |
| | |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public StockOutParam selectGood(String barcode) { |
| | | // 查询托盘上的物料信息 |
| | | // 去掉可能的多余引号或者空格 |
| | | barcode = barcode.replaceAll("\"", "").trim(); |
| | | |
| | | // 尝试将 barcode 转换为 int 类型 |
| | | int barcodeInt = Integer.parseInt(barcode); |
| | | |
| | | List<LocDetl> locDetls = locDetlService.selectList( |
| | | new EntityWrapper<LocDetl>().eq("zpallet", barcodeInt) |
| | | ); |
| | | |
| | | if (locDetls == null || locDetls.isEmpty()) { |
| | | return null; |
| | | } |
| | | |
| | | StockOutParam param = new StockOutParam(); |
| | | param.setOutSite(101); // 可以根据业务动态设置出站口 |
| | | param.setLocDetls(locDetls.stream().map(detl -> { |
| | | StockOutParam.LocDetl loc = new StockOutParam.LocDetl(); |
| | | loc.setLocNo(detl.getLocNo()); |
| | | loc.setMatnr(detl.getMatnr()); |
| | | loc.setBatch(detl.getBatch()); |
| | | loc.setCount(detl.getAnfme()); |
| | | return loc; |
| | | }).collect(Collectors.toList())); |
| | | |
| | | return param; |
| | | } |
| | | |
| | | } |