fix(接口自动化): 修复场景步骤移除缺陷

This commit is contained in:
fit2-zhao 2020-12-18 12:46:09 +08:00
parent aab7e61c8b
commit a59238d93c
3 changed files with 4 additions and 2 deletions

View File

@ -201,6 +201,7 @@ public class ApiDefinitionService {
test.setName(request.getName());
test.setPath(request.getPath());
test.setProjectId(request.getProjectId());
request.getRequest().setId(request.getId());
test.setRequest(JSONObject.toJSONString(request.getRequest()));
test.setUpdateTime(System.currentTimeMillis());
test.setStatus(request.getStatus());
@ -227,6 +228,7 @@ public class ApiDefinitionService {
test.setPath(request.getPath());
test.setModuleId(request.getModuleId());
test.setProjectId(request.getProjectId());
request.getRequest().setId(request.getId());
test.setRequest(JSONObject.toJSONString(request.getRequest()));
test.setCreateTime(System.currentTimeMillis());
test.setUpdateTime(System.currentTimeMillis());

@ -1 +1 @@
Subproject commit efb49c9b4be136ce48e9550dc9c8a2975d9f4d7f
Subproject commit 61397c16728a63493507679f7e0940d9099f337f

View File

@ -552,7 +552,7 @@
remove(row, node) {
const parent = node.parent
const hashTree = parent.data.hashTree || parent.data;
const index = hashTree.findIndex(d => d.id != undefined && row.id != undefined && d.id === row.id)
const index = hashTree.findIndex(d => d.resourceId != undefined && row.resourceId != undefined && d.resourceId === row.resourceId)
hashTree.splice(index, 1);
this.sort();
this.reload();