| | |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.domain.enums.TaskStatusType; |
| | | import com.zy.asrs.domain.enums.WorkNoType; |
| | | import com.zy.asrs.entity.LocMast; |
| | | import com.zy.asrs.entity.StaDesc; |
| | | import com.zy.asrs.entity.TaskWrk; |
| | | import com.zy.asrs.entity.ToWmsDTO; |
| | | import com.zy.asrs.entity.*; |
| | | import com.zy.asrs.entity.param.TaskOverParam; |
| | | import com.zy.asrs.entity.param.WMSAndAGVInterfaceParam; |
| | | import com.zy.asrs.entity.param.TaskCreateParam; |
| | |
| | | private CommonService commonService; |
| | | @Autowired |
| | | private LocMastService locMastService; |
| | | @Autowired |
| | | private BasDevpService basDevpService; |
| | | |
| | | |
| | | |
| | |
| | | taskWrk.setWrkNo(workNo1); |
| | | taskWrk.setStatus(TaskStatusType.RECEIVE.id);//任务状态:接收 |
| | | taskWrk.setCreateTime(now); |
| | | taskWrk.setModiTime(now); |
| | | taskWrk.setAssignTime(new Date()); |
| | | taskWrk.setModiUser(6666L); |
| | | try{ |
| | | if (param.getIoType()>1){ |
| | | if (Utils.locNoRowBoolean(locMast.getRow1())){ |
| | | param.setTaskPriority(11); |
| | | } |
| | | } |
| | | }catch (Exception e){ |
| | | } |
| | | taskWrk.setIoType(param.getIoType());//任务类型 |
| | | taskWrk.setIoPri(param.getTaskPriority());//优先级 |
| | | taskWrk.setBarcode(param.getBarcode());//条码 |
| | |
| | | taskWrk.setWrkSts(11); |
| | | if (!Cools.isEmpty(param.getStartPoint())) { |
| | | taskWrk.setStartPoint(param.getStartPoint());//起点 |
| | | taskWrk.setOriginStartPoint(param.getStartPoint()); |
| | | taskWrk.setTargetPoint(param.getTargetPoint()); |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | } |
| | | |
| | | // @Override |
| | | // public R getAgvPickAndPlaceV1(TaskOverParam param) { |
| | | // BasDevp basDevp = basDevpService.selectById(param.getStaNo()); |
| | | // if (Cools.isEmpty(basDevp)){ |
| | | // return R.error("站点号有误"+param.getStaNo()); |
| | | // } |
| | | // if (param.getType()==0 && basDevp.getAgvStartPick()==1){ |
| | | // return R.ok(); |
| | | // }else if (param.getType()==1 && basDevp.getAgvStartPlace()==1){ |
| | | // return R.ok(); |
| | | // }else { |
| | | // return R.error("不允许"); |
| | | // } |
| | | // } |
| | | |
| | | // @Override |
| | | // public R getAgvPickAndPlaceV2(TaskOverParam param) { |
| | | // BasDevp basDevp = basDevpService.selectById(param.getStaNo()); |
| | | // if (Cools.isEmpty(basDevp)){ |
| | | // return R.error("站点号有误"+param.getStaNo()); |
| | | // } |
| | | // if (param.getType()==0){ |
| | | // basDevp.setAgvTargetPick(1); |
| | | // basDevpService.updateById(basDevp); |
| | | // return R.ok(); |
| | | // }else if (param.getType()==1){ |
| | | // basDevp.setAgvTargetPlace(1); |
| | | // basDevpService.updateById(basDevp); |
| | | // return R.ok(); |
| | | // }else { |
| | | // return R.error("请求类型异常"+param.getType()); |
| | | // } |
| | | // } |
| | | |
| | | public List<Integer> getInEnableRoadway(){ |
| | | int[] roadway = null; |
| | | List<Integer> list = new ArrayList<>(); |