parent
77103bac83
commit
69fd679762
|
@ -858,8 +858,6 @@ public class ApiDefinitionService {
|
||||||
for (int i = 0; i < caseList.size(); i++) {
|
for (int i = 0; i < caseList.size(); i++) {
|
||||||
ApiTestCaseWithBLOBs apiTestCaseWithBLOBs = caseList.get(i);
|
ApiTestCaseWithBLOBs apiTestCaseWithBLOBs = caseList.get(i);
|
||||||
apiTestCaseWithBLOBs.setApiDefinitionId(apiDefinition.getId());
|
apiTestCaseWithBLOBs.setApiDefinitionId(apiDefinition.getId());
|
||||||
apiTestCaseWithBLOBs.setCreateUserId(Objects.requireNonNull(SessionUtils.getUser()).getId());
|
|
||||||
apiTestCaseWithBLOBs.setUpdateUserId(Objects.requireNonNull(SessionUtils.getUser()).getId());
|
|
||||||
apiTestCaseWithBLOBs.setVersionId(apiDefinition.getVersionId());
|
apiTestCaseWithBLOBs.setVersionId(apiDefinition.getVersionId());
|
||||||
if (apiTestCaseWithBLOBs.getCreateTime() == null) {
|
if (apiTestCaseWithBLOBs.getCreateTime() == null) {
|
||||||
apiTestCaseWithBLOBs.setCreateTime(System.currentTimeMillis());
|
apiTestCaseWithBLOBs.setCreateTime(System.currentTimeMillis());
|
||||||
|
@ -885,6 +883,8 @@ public class ApiDefinitionService {
|
||||||
apiTestCaseMapper.updateByPrimaryKeyWithBLOBs(apiTestCaseWithBLOBs);
|
apiTestCaseMapper.updateByPrimaryKeyWithBLOBs(apiTestCaseWithBLOBs);
|
||||||
} else {
|
} else {
|
||||||
apiTestCaseWithBLOBs.setId(UUID.randomUUID().toString());
|
apiTestCaseWithBLOBs.setId(UUID.randomUUID().toString());
|
||||||
|
apiTestCaseWithBLOBs.setCreateUserId(Objects.requireNonNull(SessionUtils.getUser()).getId());
|
||||||
|
apiTestCaseWithBLOBs.setUpdateUserId(Objects.requireNonNull(SessionUtils.getUser()).getId());
|
||||||
apiTestCaseMapper.insert(apiTestCaseWithBLOBs);
|
apiTestCaseMapper.insert(apiTestCaseWithBLOBs);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue