fix(接口测试): 解决接口定义导入没有模块的接口的默认值问题
--bug=1011526 --user=郭雨琦 【接口测试】-接口定义中-导入的接口模块默认全部为空了+左侧更多操作中创建接口后默认模块是空,以上两种情况导致左侧树不统计接口数量 https://www.tapd.cn/55049933/bugtrace/bugs/view/1155049933001011526
This commit is contained in:
parent
9fee04375a
commit
5bea2ee847
|
@ -746,6 +746,11 @@ public class ApiDefinitionService {
|
||||||
} else {
|
} else {
|
||||||
apiDefinition.setUserId(apiDefinition.getUserId());
|
apiDefinition.setUserId(apiDefinition.getUserId());
|
||||||
}
|
}
|
||||||
|
if(apiDefinition.getModuleId()==null){
|
||||||
|
if (StringUtils.isEmpty(apiDefinition.getModuleId()) || "default-module".equals(apiDefinition.getModuleId())) {
|
||||||
|
initModulePathAndId(apiDefinition.getProjectId(), apiDefinition);
|
||||||
|
}
|
||||||
|
}
|
||||||
apiDefinition.setDescription(apiDefinition.getDescription());
|
apiDefinition.setDescription(apiDefinition.getDescription());
|
||||||
|
|
||||||
List<ApiDefinition> sameRequest;
|
List<ApiDefinition> sameRequest;
|
||||||
|
|
Loading…
Reference in New Issue