update:
测试rgv避让逻辑
This commit is contained in:
		| @@ -1352,10 +1352,10 @@ public class AsynRunTaskService extends BaseService { | |||||||
|                     if (status!=1){ |                     if (status!=1){ | ||||||
|                         logger.info("===执行任务:"+currTask.getTaskCode()+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位2,执行失败==="); |                         logger.info("===执行任务:"+currTask.getTaskCode()+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位2,执行失败==="); | ||||||
|                         webSocketServer.sendtoAll(LocalDateTime.now()+"执行任务:"+currTask.getTaskCode()+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位2,执行失败"); |                         webSocketServer.sendtoAll(LocalDateTime.now()+"执行任务:"+currTask.getTaskCode()+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位2,执行失败"); | ||||||
|                         return; |                     }else { | ||||||
|                     } |  | ||||||
|                         logger.info("===执行任务:"+currTaskId+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位2,执行成功==="); |                         logger.info("===执行任务:"+currTaskId+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位2,执行成功==="); | ||||||
|                     } |                     } | ||||||
|  |                 } | ||||||
|             }else { |             }else { | ||||||
|                 logger.info("RGV2不在线,跳过检测是否避让。"); |                 logger.info("RGV2不在线,跳过检测是否避让。"); | ||||||
|             } |             } | ||||||
| @@ -1375,10 +1375,10 @@ public class AsynRunTaskService extends BaseService { | |||||||
|                     if (status!=1){ |                     if (status!=1){ | ||||||
|                         logger.info("===执行任务:"+currTaskId+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位12,执行失败==="); |                         logger.info("===执行任务:"+currTaskId+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位12,执行失败==="); | ||||||
|                         webSocketServer.sendtoAll(LocalDateTime.now()+"执行任务:"+currTask.getTaskCode()+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位12,执行失败"); |                         webSocketServer.sendtoAll(LocalDateTime.now()+"执行任务:"+currTask.getTaskCode()+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位12,执行失败"); | ||||||
|                         return; |                     }else { | ||||||
|                     } |  | ||||||
|                         logger.info("===执行任务:"+currTaskId+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位12,执行成功==="); |                         logger.info("===执行任务:"+currTaskId+" 时车辆位置冲突,执行车辆位移任务,车辆"+anotherVehicleId+"移动到点位12,执行成功==="); | ||||||
|                     } |                     } | ||||||
|  |                 } | ||||||
|             }else { |             }else { | ||||||
|                 logger.info("RGV1不在线,跳过检测是否避让。"); |                 logger.info("RGV1不在线,跳过检测是否避让。"); | ||||||
|             } |             } | ||||||
|   | |||||||
| @@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; | |||||||
| import com.mt.wms.core.base.BaseService; | import com.mt.wms.core.base.BaseService; | ||||||
| import com.mt.wms.core.dal.entity.*; | import com.mt.wms.core.dal.entity.*; | ||||||
| import com.mt.wms.core.dal.service.*; | import com.mt.wms.core.dal.service.*; | ||||||
|  | import com.mt.wms.core.dal.service.impl.CurrTaskServiceBizImpl; | ||||||
| import com.mt.wms.core.utils.BeanUtils; | import com.mt.wms.core.utils.BeanUtils; | ||||||
| import com.mt.wms.core.utils.CodeGeneratorHelper; | import com.mt.wms.core.utils.CodeGeneratorHelper; | ||||||
| import com.mt.wms.core.utils.HttpClient; | import com.mt.wms.core.utils.HttpClient; | ||||||
| @@ -81,16 +82,10 @@ public class ScheduledTask extends BaseService { | |||||||
|     @Resource |     @Resource | ||||||
|     private TaskDetHisServiceBiz taskDetHisServiceBiz; |     private TaskDetHisServiceBiz taskDetHisServiceBiz; | ||||||
|  |  | ||||||
|  |  | ||||||
|     //@Scheduled(fixedDelay = 1000*20) |     //@Scheduled(fixedDelay = 1000*20) | ||||||
|     @Test |     @Test | ||||||
|     public void test() throws IOException { |     public void test() throws IOException { | ||||||
|         CurrTask currTask = currTaskServiceBiz.getById(342); |  | ||||||
|         if (currTask.getIsOut()==1){ |  | ||||||
|                 int count = autoExeTaskServiceBiz.count(new QueryWrapper<AutoExeTask>().eq(AutoExeTask.F_TASK_ID, currTask.getId())); |  | ||||||
|             System.out.println(count>0);; |  | ||||||
|             }else { |  | ||||||
|             System.out.println(true); |  | ||||||
|             } |  | ||||||
|  |  | ||||||
|     } |     } | ||||||
|     //@Scheduled(fixedDelay = 1000*60) |     //@Scheduled(fixedDelay = 1000*60) | ||||||
|   | |||||||
		Referens i nytt ärende
	
	Block a user