parent
08d68b66ab
commit
b0084cf063
|
@ -62,7 +62,7 @@ public interface DisposeAbility {
|
||||||
* @param taskId the task id
|
* @param taskId the task id
|
||||||
* @return the mul return type
|
* @return the mul return type
|
||||||
*/
|
*/
|
||||||
MulReturnType<ErrorCode, Long> taskStatus(Long taskId);
|
MulReturnType<ErrorCode, Long> taskStatus(String taskId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets ability device fireware.
|
* Gets ability device fireware.
|
||||||
|
|
|
@ -324,7 +324,7 @@ public class DpTechAbilityImpl implements DisposeAbility {
|
||||||
* @return the mul return type
|
* @return the mul return type
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public MulReturnType<ErrorCode, Long> taskStatus(Long taskId) {
|
public MulReturnType<ErrorCode, Long> taskStatus(String taskId) {
|
||||||
return new MulReturnType<>(ErrorCode.ERR_UNSUPPORT, -1L);
|
return new MulReturnType<>(ErrorCode.ERR_UNSUPPORT, -1L);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -222,7 +222,7 @@ public class HaoHanAbilityImpl implements DisposeAbility {
|
||||||
* @return the mul return type
|
* @return the mul return type
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public MulReturnType<ErrorCode, Long> taskStatus(Long taskId) {
|
public MulReturnType<ErrorCode, Long> taskStatus(String taskId) {
|
||||||
return new MulReturnType<>(ErrorCode.ERR_UNSUPPORT, -1L);
|
return new MulReturnType<>(ErrorCode.ERR_UNSUPPORT, -1L);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -415,7 +415,7 @@ public class PengXinAbilityImpl implements DisposeAbility {
|
||||||
* @return the mul return type
|
* @return the mul return type
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public MulReturnType<ErrorCode, Long> taskStatus(Long taskId) {
|
public MulReturnType<ErrorCode, Long> taskStatus(String taskId) {
|
||||||
if (token == null || token.length() == 0) {
|
if (token == null || token.length() == 0) {
|
||||||
return new MulReturnType<>(ErrorCode.ERR_LOGOUT, -1L);
|
return new MulReturnType<>(ErrorCode.ERR_LOGOUT, -1L);
|
||||||
}
|
}
|
||||||
|
|
|
@ -140,7 +140,7 @@ public class VirtualAbilityImpl implements DisposeAbility {
|
||||||
* @return the mul return type
|
* @return the mul return type
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public MulReturnType<ErrorCode, Long> taskStatus(Long taskId) {
|
public MulReturnType<ErrorCode, Long> taskStatus(String taskId) {
|
||||||
return new MulReturnType<>(ErrorCode.ERR_UNSUPPORT, -1L);
|
return new MulReturnType<>(ErrorCode.ERR_UNSUPPORT, -1L);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,7 @@ public interface DeviceTaskManager {
|
||||||
* @param id the id
|
* @param id the id
|
||||||
* @return the dispose device task status
|
* @return the dispose device task status
|
||||||
*/
|
*/
|
||||||
int changeDisposeDeviceTaskInfoDevStatus(Long id, Long devStatus);
|
int changeDisposeDeviceTaskInfoDevStatus(String id, Long devStatus);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets exec attack type.
|
* Sets exec attack type.
|
||||||
|
|
|
@ -87,7 +87,7 @@ public class DeviceTaskManagerImpl implements DeviceTaskManager {
|
||||||
* @return the long
|
* @return the long
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public int changeDisposeDeviceTaskInfoDevStatus(Long id, Long devStatus) {
|
public int changeDisposeDeviceTaskInfoDevStatus(String id, Long devStatus) {
|
||||||
return deviceTaskMapper.changeTaskDevStatus(id, devStatus);
|
return deviceTaskMapper.changeTaskDevStatus(id, devStatus);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -92,7 +92,7 @@ public interface DeviceTaskMapper {
|
||||||
* @param status the status
|
* @param status the status
|
||||||
* @return the int
|
* @return the int
|
||||||
*/
|
*/
|
||||||
int changeTaskDevStatus(@Param("id") Long id,
|
int changeTaskDevStatus(@Param("id") String id,
|
||||||
@Param("status") Long status);
|
@Param("status") Long status);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -716,10 +716,14 @@ public class DeviceTaskManagerServiceImpl implements DeviceTaskManagerService {
|
||||||
// 任务预计结束5分钟内,
|
// 任务预计结束5分钟内,
|
||||||
if (Helper.getTimestampDiffNow(task.getPlanEndTime()) < 5 * 60) {
|
if (Helper.getTimestampDiffNow(task.getPlanEndTime()) < 5 * 60) {
|
||||||
if (v.getEndTime() == null && Helper.getTimestampDiffNow(v.getEndTime()) < 5 * 60) {
|
if (v.getEndTime() == null && Helper.getTimestampDiffNow(v.getEndTime()) < 5 * 60) {
|
||||||
MulReturnType<ErrorCode, Long> ret = ai.getDb().taskStatus(v.getId());
|
|
||||||
|
if (v.getExternId() != null && v.getExternId().length() > 0) {
|
||||||
|
MulReturnType<ErrorCode, Long> ret = ai.getDb().taskStatus(v.getExternId());
|
||||||
|
|
||||||
if (ret.getFirstParam() == ErrorCode.ERR_OK) {
|
if (ret.getFirstParam() == ErrorCode.ERR_OK) {
|
||||||
deviceTaskManager.changeDisposeDeviceTaskInfoDevStatus(v.getId(), ret.getSecondParam());
|
deviceTaskManager.changeDisposeDeviceTaskInfoDevStatus(v.getExternId(),
|
||||||
|
ret.getSecondParam());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue