| | |
| | | oriLoc.setLocSts(complete?LocStsType.IDLE.val():LocStsType.STOCK.val()); |
| | | oriLoc.setUpdateTime(now); |
| | | if (!locService.updateById(oriLoc)) { |
| | | throw new BusinessException("Loc [" + task.getOriLoc$() + "] 库位修改状态失败 !!!"); |
| | | throw new BusinessException("Loc [" + oriLoc.getLocNo() + "] 库位修改状态失败 !!!"); |
| | | } |
| | | |
| | | destLoc.setLocSts(complete?LocStsType.STOCK.val():LocStsType.IDLE.val()); |
| | | destLoc.setUpdateTime(now); |
| | | if (!locService.updateById(destLoc)) { |
| | | throw new BusinessException("Loc [" + task.getDestLoc$() + "] 库位修改状态失败 !!!"); |
| | | throw new BusinessException("Loc [" + destLoc.getLocNo() + "] 库位修改状态失败 !!!"); |
| | | } |
| | | break; |
| | | case LOC_TO_STA: |
| | |
| | | oriLoc.setLocSts(complete?LocStsType.IDLE.val():LocStsType.STOCK.val()); |
| | | oriLoc.setUpdateTime(now); |
| | | if (!locService.updateById(oriLoc)) { |
| | | throw new BusinessException("Loc [" + task.getOriLoc$() + "] 库位修改状态失败 !!!"); |
| | | throw new BusinessException("Loc [" + oriLoc.getLocNo() + "] 库位修改状态失败 !!!"); |
| | | } |
| | | |
| | | destSta = staService.getById(task.getDestSta()); |
| | | destSta.setStaSts(complete?StaStsType.STOCK.val():StaStsType.IDLE.val()); |
| | | destSta.setUpdateTime(now); |
| | | if (!staService.updateById(destSta)) { |
| | | throw new BusinessException("Sta [" + destSta.getStaNo() + "] 站点修改状态失败 !!!"); |
| | | } |
| | | break; |
| | | case STA_TO_LOC: |
| | | oriSta = staService.getById(task.getOriSta()); |
| | | oriSta.setStaSts(complete?StaStsType.IDLE.val():StaStsType.STOCK.val()); |
| | | oriSta.setUpdateTime(now); |
| | | if (!staService.updateById(oriSta)) { |
| | | throw new BusinessException("Sta [" + oriSta.getStaNo() + "] 站点修改状态失败 !!!"); |
| | | } |
| | | |
| | | destLoc = locService.getById(task.getDestLoc()); |
| | | destLoc.setLocSts(complete?LocStsType.STOCK.val():LocStsType.IDLE.val()); |
| | | destLoc.setUpdateTime(now); |
| | | if (!locService.updateById(destLoc)) { |
| | | throw new BusinessException("Loc [" + task.getDestLoc$() + "] 库位修改状态失败 !!!"); |
| | | throw new BusinessException("Loc [" + destLoc.getLocNo() + "] 库位修改状态失败 !!!"); |
| | | } |
| | | break; |
| | | case STA_TO_STA: |
| | | oriSta = staService.getById(task.getOriSta()); |
| | | oriSta.setStaSts(complete?StaStsType.IDLE.val():StaStsType.STOCK.val()); |
| | | oriSta.setUpdateTime(now); |
| | | if (!staService.updateById(oriSta)) { |
| | | throw new BusinessException("Sta [" + oriSta.getStaNo() + "] 站点修改状态失败 !!!"); |
| | | } |
| | | |
| | | destSta = staService.getById(task.getDestSta()); |
| | | destSta.setStaSts(complete?StaStsType.STOCK.val():StaStsType.IDLE.val()); |
| | | destSta.setUpdateTime(now); |
| | | if (!staService.updateById(destSta)) { |
| | | throw new BusinessException("Sta [" + destSta.getStaNo() + "] 站点修改状态失败 !!!"); |
| | | } |
| | | break; |
| | | case TO_CHARGE: |
| | | case TO_STANDBY: |