| | |
| | | throw new CoolException("入库请求库位失败:路径不存在" + staDescId +"," + sourceStaNo); |
| | | } |
| | | |
| | | Short locType1 = 1; |
| | | LocMast locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_sts", "O").eq("loc_type1", locType1).orderBy("lev1").orderBy("bay1").orderBy("row1")); |
| | | if (locMast == null) { |
| | | log.error("入库请求库位失败:无库位" + locType1); |
| | | throw new CoolException("入库请求库位失败:无库位" + locType1); |
| | | LocMast locMast = locMastService.selectOne(new EntityWrapper<LocMast>() |
| | | .eq("loc_sts", "O") |
| | | .eq("loc_type1", locTypeDto.getLocType1()) |
| | | .eq("loc_type2", locTypeDto.getLocType2()) |
| | | .orderBy("lev1") |
| | | .orderBy("bay1") |
| | | .orderBy("row1")); |
| | | if (locMast == null && locTypeDto.getLocType1() ==1) { |
| | | LocMast locMast1 = locMastService.selectOne(new EntityWrapper<LocMast>() |
| | | .eq("loc_sts", "O") |
| | | .eq("loc_type1", locTypeDto.getLocType1() + 1) |
| | | .eq("loc_type2", locTypeDto.getLocType2()) |
| | | .orderBy("lev1") |
| | | .orderBy("bay1") |
| | | .orderBy("row1")); |
| | | if (locMast1 == null){ |
| | | log.error("入库请求库位失败:无库位" + locTypeDto.getLocType1()); |
| | | throw new CoolException("入库请求库位失败:无库位" + locTypeDto.getLocType1()); |
| | | }else { |
| | | locMast =locMast1; |
| | | } |
| | | |
| | | }else if (locMast ==null){ |
| | | log.error("入库请求库位失败:无库位" + locTypeDto.getLocType1()); |
| | | throw new CoolException("入库请求库位失败:无库位" + locTypeDto.getLocType1()); |
| | | } |
| | | |
| | | StartupDto startupDto = new StartupDto(); |