更改任务测试接口参数
parent
87abe5f3cd
commit
0b688226bb
|
@ -5,6 +5,7 @@ import java.util.List;
|
|||
import java.util.UUID;
|
||||
|
||||
import com.muyu.common.security.utils.SecurityUtils;
|
||||
import com.muyu.quest.domain.Node;
|
||||
import com.muyu.quest.domain.Task;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
@ -113,9 +114,9 @@ public class TaskController extends BaseController
|
|||
/**
|
||||
* 测试任务
|
||||
*/
|
||||
@PostMapping("/testExecute/{taskCode}")
|
||||
public Result<String> testExecute(@PathVariable("taskCode") String taskCode) {
|
||||
return success(taskService.testExecute(taskCode));
|
||||
@PostMapping("/testExecute")
|
||||
public Result<String> testExecute(@RequestBody List<Node> nodeList) {
|
||||
return success(taskService.testExecute(nodeList));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -3,6 +3,7 @@ package com.muyu.quest.service;
|
|||
import java.util.List;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.muyu.quest.domain.Node;
|
||||
import com.muyu.quest.domain.Task;
|
||||
import com.muyu.quest.req.TaskReq;
|
||||
import com.muyu.quest.resp.TaskResp;
|
||||
|
@ -46,5 +47,5 @@ public interface TaskService extends IService<Task> {
|
|||
|
||||
String execute(String taskCode);
|
||||
|
||||
String testExecute(String taskCode);
|
||||
String testExecute(List<Node> nodeList);
|
||||
}
|
||||
|
|
|
@ -199,17 +199,9 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>
|
|||
}
|
||||
|
||||
@Override
|
||||
public String testExecute(String taskCode) {
|
||||
log.info("任务编码 {} 开始测试执行......",taskCode);
|
||||
// 查询SQL语句
|
||||
String findSql = "";
|
||||
// 新增SQL语句
|
||||
String addSql = "";
|
||||
|
||||
// 查询任务所有节点
|
||||
List<Node> nodeListAll = nodeService.selectNodeList(new NodeReq().buildTaskCode(taskCode));
|
||||
// 节点初始化
|
||||
HashMap<String, List<Node>> nodeMap = NodeUtils.nodeInit(nodeListAll);
|
||||
public String testExecute(List<Node> nodeListAll) {
|
||||
log.info("开始测试执行......");
|
||||
// 查询节点类型与其规范
|
||||
List<NodeType> nodeTypeList = selectNodeTypeList();
|
||||
/* 节点组成校验 */
|
||||
NodeUtils.nodeCheckMakeUp(nodeListAll, nodeTypeList);
|
||||
|
|
Loading…
Reference in New Issue