diff --git a/src/main/java/com/dispose/service/impl/DeviceTaskManagerServiceImpl.java b/src/main/java/com/dispose/service/impl/DeviceTaskManagerServiceImpl.java index e2fb104f..60e2db30 100644 --- a/src/main/java/com/dispose/service/impl/DeviceTaskManagerServiceImpl.java +++ b/src/main/java/com/dispose/service/impl/DeviceTaskManagerServiceImpl.java @@ -568,6 +568,8 @@ public class DeviceTaskManagerServiceImpl implements DeviceTaskManagerService { // 如果设备已经删除或者禁用,跳过处理 if (ai == null) { + // 设置任务状态为已完成 + deviceTaskManager.changeDisposeDeviceTaskInfoStatus(v.getId(), DisposeTaskStatus.TASK_FINISHED); continue; } @@ -636,6 +638,8 @@ public class DeviceTaskManagerServiceImpl implements DeviceTaskManagerService { // 如果设备已经删除或者禁用,跳过处理 if (ai == null) { + // 设置任务状态为已完成 + deviceTaskManager.changeDisposeDeviceTaskInfoStatus(v.getId(), DisposeTaskStatus.TASK_FINISHED); continue; }