|
|
@@ -50,13 +50,13 @@ public class ModelCatalogTreeHandler extends AbstractTreeHandler<Object> { |
|
|
|
|
|
|
|
EntityDao<ModelCatalog> dao = DbEngine.getInstance().findDao(ModelCatalog.ENTITY_NAME); |
|
|
|
String text = "%" + params.readString("text") + "%"; |
|
|
|
List<ModelCatalog> list = dao.queryWhere(" where mc_prj_id=? and (mc_name like ? or mc_code like ?) order by mc_name", prj_id, text, text); |
|
|
|
List<ModelCatalog> list = dao.queryWhere(" mc_prj_id=? and (mc_name like ? or mc_code like ?) order by mc_name", prj_id, text, text); |
|
|
|
listRet.addAll(list); |
|
|
|
|
|
|
|
switch (type) { |
|
|
|
case TYPE_TABLE: |
|
|
|
EntityDao<ModelTable> tabledao = DbEngine.getInstance().findDao(ModelTable.class); |
|
|
|
List<ModelTable> l = tabledao.queryWhere(" where tb_prj_id=? and (tb_name like ? or tb_title like ?) order by tb_name", prj_id, text, text); |
|
|
|
List<ModelTable> l = tabledao.queryWhere(" tb_prj_id=? and (tb_name like ? or tb_title like ?) order by tb_name", prj_id, text, text); |
|
|
|
listRet.addAll(l); |
|
|
|
break; |
|
|
|
case TYPE_PAGE: |
|
|
@@ -72,7 +72,7 @@ public class ModelCatalogTreeHandler extends AbstractTreeHandler<Object> { |
|
|
|
if (id > 0) { |
|
|
|
list = mcTreeHelper.getChildren(id, (o1, o2) -> CommUtil.chineseCompare(o1.getName(), o2.getName())); |
|
|
|
} else { |
|
|
|
list = mcTreeHelper.getChildren(prj_id, (o1, o2) -> CommUtil.chineseCompare(o1.getName(), o2.getName())); |
|
|
|
list = mcTreeHelper.getChildren(-1, (o1, o2) -> CommUtil.chineseCompare(o1.getName(), o2.getName())); |
|
|
|
} |
|
|
|
|
|
|
|
listRet.addAll(list); |
|
|
|