|
@ -7,6 +7,7 @@ import com.iflytop.nuclear.model.*; |
|
|
import com.iflytop.nuclear.service.*; |
|
|
import com.iflytop.nuclear.service.*; |
|
|
import com.iflytop.nuclear.vo.TaskVO; |
|
|
import com.iflytop.nuclear.vo.TaskVO; |
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
|
|
import org.springframework.context.annotation.Lazy; |
|
|
import org.springframework.stereotype.Service; |
|
|
import org.springframework.stereotype.Service; |
|
|
|
|
|
|
|
|
import java.util.ArrayList; |
|
|
import java.util.ArrayList; |
|
@ -27,6 +28,10 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task> implements Ta |
|
|
NuclearStationService nuclearStationService; |
|
|
NuclearStationService nuclearStationService; |
|
|
@Autowired |
|
|
@Autowired |
|
|
AccountService accountService; |
|
|
AccountService accountService; |
|
|
|
|
|
@Lazy |
|
|
|
|
|
@Autowired |
|
|
|
|
|
CheckServiceImpl checkServiceImpl; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
@Override |
|
|
public List<TaskVO> getTaskInfoByUsername(String username, String user_role) { |
|
|
public List<TaskVO> getTaskInfoByUsername(String username, String user_role) { |
|
@ -112,4 +117,23 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task> implements Ta |
|
|
} |
|
|
} |
|
|
return null; |
|
|
return null; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
public String nextCoordString(String coord, String taskId, String direction) { |
|
|
|
|
|
// 根据taskId查询order 规则的下一个已经写好,需要再写一个上一个 |
|
|
|
|
|
Task task = this.getById(taskId); |
|
|
|
|
|
int checkOrder = task.getCheckOrder(); |
|
|
|
|
|
if ("1".equals(direction)) { |
|
|
|
|
|
if (coord.equals("finish")) { |
|
|
|
|
|
return null; |
|
|
|
|
|
} |
|
|
|
|
|
return checkServiceImpl.getNextCoord(coord, checkOrder); |
|
|
|
|
|
}else { |
|
|
|
|
|
if (coord.equals("start")) { |
|
|
|
|
|
return null; |
|
|
|
|
|
} |
|
|
|
|
|
return checkServiceImpl.getPreCoord(coord, checkOrder); |
|
|
|
|
|
} |
|
|
|
|
|
return null; |
|
|
|
|
|
} |
|
|
} |
|
|
} |