fix(接口定义导入): #1007599 【github#5502】接口定义模块树超过8层希望有提示
--bug=1007599 --user=宋天阳 【github#5502】接口定义模块树超过8层希望有提示 https://www.tapd.cn/55049933/s/1063419
This commit is contained in:
parent
9462574ed3
commit
334d6a6bed
|
@ -1014,7 +1014,12 @@ public class ApiDefinitionService {
|
||||||
apiImport = (ApiDefinitionImport) Objects.requireNonNull(apiImportParser).parse(file == null ? null : file.getInputStream(), request);
|
apiImport = (ApiDefinitionImport) Objects.requireNonNull(apiImportParser).parse(file == null ? null : file.getInputStream(), request);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
LogUtil.error(e.getMessage(), e);
|
LogUtil.error(e.getMessage(), e);
|
||||||
|
String returnThrowException = e.getMessage();
|
||||||
|
if(StringUtils.contains(returnThrowException,"模块树最大深度为")){
|
||||||
|
MSException.throwException(returnThrowException);
|
||||||
|
}else {
|
||||||
MSException.throwException(Translator.get("parse_data_error"));
|
MSException.throwException(Translator.get("parse_data_error"));
|
||||||
|
}
|
||||||
// 发送通知
|
// 发送通知
|
||||||
if (StringUtils.equals(request.getType(), "schedule")) {
|
if (StringUtils.equals(request.getType(), "schedule")) {
|
||||||
String scheduleId = scheduleService.getScheduleInfo(request.getResourceId());
|
String scheduleId = scheduleService.getScheduleInfo(request.getResourceId());
|
||||||
|
|
Loading…
Reference in New Issue