| | |
| | | if(orderLogistics.getState() == 1){ |
| | | this.pushOrder(orderLogistics); |
| | | }else{ |
| | | //接单后定时任务判断司机是否去接乘客,没有则推送提醒 |
| | | CancleOrder cancleOrder = cancleOrderService.query(orderLogistics.getCompanyId()); |
| | | if(null != cancleOrder){ |
| | | JSONObject object = JSON.parseObject(cancleOrder.getContent()); |
| | | long time = object.getInteger("driverTimeout") * 60000L; |
| | | new Timer().schedule(new TimerTask() { |
| | | @Override |
| | | public void run() { |
| | | OrderLogistics orderLogistics1 = OrderLogisticsServiceImpl.this.selectById(orderLogistics.getId()); |
| | | if(orderLogistics1.getState() == 2){ |
| | | pushUtil.pushDriverTimeOut(1, orderLogistics1.getUserId(), orderLogistics1.getId(), 4); |
| | | } |
| | | } |
| | | }, time); |
| | | } |
| | | // //接单后定时任务判断司机是否去接乘客,没有则推送提醒 |
| | | // CancleOrder cancleOrder = cancleOrderService.query(orderLogistics.getCompanyId()); |
| | | // if(null != cancleOrder){ |
| | | // JSONObject object = JSON.parseObject(cancleOrder.getContent()); |
| | | // long time = object.getInteger("driverTimeout") * 60000L; |
| | | // new Timer().schedule(new TimerTask() { |
| | | // @Override |
| | | // public void run() { |
| | | // OrderLogistics orderLogistics1 = OrderLogisticsServiceImpl.this.selectById(orderLogistics.getId()); |
| | | // if(orderLogistics1.getState() == 2){ |
| | | // pushUtil.pushDriverTimeOut(1, orderLogistics1.getUserId(), orderLogistics1.getId(), 4); |
| | | // } |
| | | // } |
| | | // }, time); |
| | | // } |
| | | } |
| | | |
| | | |