Commit 81465cd5 by gdj

修复空中下发bug

parent 2e646258
...@@ -735,6 +735,10 @@ public class FlightTaskServiceImpl extends AbstractWaylineService implements IFl ...@@ -735,6 +735,10 @@ public class FlightTaskServiceImpl extends AbstractWaylineService implements IFl
private void addConditionsInFlight(WaylineJobDTO waylineJob, CreateInFlightJobParam param, Long beginTime, Long endTime) { private void addConditionsInFlight(WaylineJobDTO waylineJob, CreateInFlightJobParam param, Long beginTime, Long endTime) {
if (TaskTypeEnum.CONDITIONAL != param.getTaskType()) {
return;
}
waylineJob.setConditions( waylineJob.setConditions(
WaylineTaskConditionDTO.builder() WaylineTaskConditionDTO.builder()
// .executableConditions(Objects.nonNull(param.getMinStorageCapacity()) ? // .executableConditions(Objects.nonNull(param.getMinStorageCapacity()) ?
...@@ -768,15 +772,16 @@ public class FlightTaskServiceImpl extends AbstractWaylineService implements IFl ...@@ -768,15 +772,16 @@ public class FlightTaskServiceImpl extends AbstractWaylineService implements IFl
boolean isSuccess = this.prepareInFlightTask(waylineJob); boolean isSuccess = this.prepareInFlightTask(waylineJob);
if (!isSuccess) { if (!isSuccess) {
return HttpResultResponse.error("Failed to prepare job."); return HttpResultResponse.error("Failed to prepare In flight job.");
} }
// Issue an immediate task execution command. // Issue an immediate task execution command.
if (TaskTypeEnum.IMMEDIATE == waylineJob.getTaskType()) { // 不需要执行这个就可以直接起飞
if (!executeFlightTask(waylineJob.getWorkspaceId(), waylineJob.getJobId())) { // if (TaskTypeEnum.IMMEDIATE == waylineJob.getTaskType()) {
return HttpResultResponse.error("Failed to execute job."); // if (!executeFlightTask(waylineJob.getWorkspaceId(), waylineJob.getJobId())) {
} // return HttpResultResponse.error("Failed to execute job.");
} // }
// }
// 发送 邮件 // 发送 邮件
// this.sendCreatedTaskMail(waylineJob); // this.sendCreatedTaskMail(waylineJob);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment