| | |
| | | if (!locDetlDtos.isEmpty()) { |
| | | LocMast locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_no", locDetlDtos.get(0).getLocDetl().getLocNo())); |
| | | if (locMast.getLocSts().equals("F") || locMast.getLocSts().equals("D") ){ |
| | | // 启动出库开始 101.出库 |
| | | stockOut(staNo, locDetlDtos, null, userId); |
| | | if (locMast.getCrnNo() == 7){ |
| | | stockOutSXK(staNo, locDetlDtos, null, userId); |
| | | }else { |
| | | // 启动出库开始 101.出库 |
| | | stockOut(staNo, locDetlDtos, null, userId); |
| | | } |
| | | |
| | | }else { |
| | | throw new CoolException("所选库位存在状态不为F、D的库位,库位号:"+locMast.getLocNo()+" 、当前状态:"+locMast.getLocSts()+"-"+locMast.getLocSts$()); |
| | | } |
| | |
| | | } |
| | | } |
| | | |
| | | @Transactional |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void moveLocForDeepLoc(LocMast shallowLoc) { |
| | | |
| | | try { |
| | |
| | | throw new CoolException("移转失败"); |
| | | } |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); |
| | | throw new CoolException(e); |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | |
| | | |
| | | @Transactional |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public void stockOutSXK(BasDevp staNo, List<LocDetlDto> locDetlDtos, IoWorkType ioWorkType, Long userId) { |
| | | Date now = new Date(); |
| | | // 合并同类项 |
| | |
| | | .eq("loc_type1",locMast.getLocType1()) |
| | | .orderBy("bay1", true)); |
| | | } |
| | | if (locMasts.isEmpty()){ |
| | | throw new CoolException("数据错误,未找到库位组"); |
| | | } |
| | | for (LocMast locMast1 : locMasts) { |
| | | if (locMast1.getLocNo().equals(dto.getLocNo())){ |
| | | break; |