| | |
| | | return error("无效的任务状态"); |
| | | } |
| | | |
| | | // 如果是取消状态,保存取消原因 |
| | | if (newStatus == TaskStatus.CANCELLED && StringUtils.isNotEmpty(request.getCancelReason())) { |
| | | sysTaskService.saveCancelInfo(taskId, request.getCancelReason()); |
| | | } |
| | | |
| | | // 如果包含GPS位置信息,使用带位置的方法 |
| | | if (request.getLatitude() != null && request.getLongitude() != null) { |
| | | String address= mapService.reverseGeocoding(request.getLongitude(), request.getLatitude()); |
| | |
| | | private Double altitude; |
| | | private Double speed; |
| | | private Double heading; |
| | | |
| | | // 取消相关字段 |
| | | private String cancelReason; // 取消原因(关联数据字典task_cancel_reason) |
| | | |
| | | public String getTaskStatus() { |
| | | return taskStatus; |
| | |
| | | public void setHeading(Double heading) { |
| | | this.heading = heading; |
| | | } |
| | | |
| | | public String getCancelReason() { |
| | | return cancelReason; |
| | | } |
| | | |
| | | public void setCancelReason(String cancelReason) { |
| | | this.cancelReason = cancelReason; |
| | | } |
| | | } |
| | | } |