fix(接口测试): 修复添加接口,回收站内有相同url的提示重复的缺陷
--bug=1037289 --user=王孝刚 【接口测试】接口定义-新建接口-回收站内有相同url的也提示重复了 https://www.tapd.cn/55049933/s/1477576
This commit is contained in:
parent
002e44f680
commit
8cfa6c3499
|
@ -519,7 +519,8 @@ public class ApiDefinitionService extends MoveNodeService {
|
|||
.andPathEqualTo(apiDefinition.getPath())
|
||||
.andMethodEqualTo(apiDefinition.getMethod())
|
||||
.andProtocolEqualTo(apiDefinition.getProtocol())
|
||||
.andProjectIdEqualTo(apiDefinition.getProjectId());
|
||||
.andProjectIdEqualTo(apiDefinition.getProjectId())
|
||||
.andDeletedEqualTo(false);
|
||||
if (CollectionUtils.isNotEmpty(apiDefinitionMapper.selectByExample(example))) {
|
||||
throw new MSException(ApiResultCode.API_DEFINITION_EXIST);
|
||||
}
|
||||
|
@ -539,7 +540,8 @@ public class ApiDefinitionService extends MoveNodeService {
|
|||
.andIdNotEqualTo(originApiDefinition.getId())
|
||||
.andProtocolEqualTo(originApiDefinition.getProtocol())
|
||||
.andProjectIdEqualTo(originApiDefinition.getProjectId())
|
||||
.andRefIdNotEqualTo(originApiDefinition.getRefId());
|
||||
.andRefIdNotEqualTo(originApiDefinition.getRefId())
|
||||
.andDeletedEqualTo(false);
|
||||
if (apiDefinitionMapper.countByExample(example) > 0) {
|
||||
throw new MSException(ApiResultCode.API_DEFINITION_EXIST);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue