提交 e60a3aa7 authored 作者: ww1xhqc's avatar ww1xhqc

[数据模型] 聚合对象去重

上级 f629e10c
......@@ -60,6 +60,12 @@ public class AggregationImpl implements AggregationService {
//改CLASS名字
AggregationUtil.changeClassName(aggregationVO.getModelName(),mainTableDocument );
// save TableInfoEx (name des mainTableId)
List<TableInfo> all = tableInfoDao.findAll();
for (TableInfo tableInfo : all) {
if (aggregationVO.getModelName().equals(tableInfo.getModelName())){
throw new ApiException("名称已存在!");
}
}
TableInfo tableInfoEx = tableInfoDao.save(aggregationVO.getTableInfo());
try {
createAggregationObjectXml(aggregationVO.getAggregations(), null, tableInfoEx.getId(), mainTableById.get(), mainTableDocument.getRootElement());
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论