1、metaTable中加入字段主键设置

2、添加删除策略配置
3、列表配置中加入"HIDDEN"配置,以及预览中加入解析逻辑
This commit is contained in:
2019-06-10 17:55:46 +08:00
parent 1f5ea920b4
commit 4037398598
18 changed files with 350 additions and 30 deletions

View File

@@ -5,7 +5,6 @@ import net.tccn.base.PageBean;
import net.tccn.dbq.fbean.FBean;
import net.tccn.dbq.jdbc.api.DbKit;
import net.tccn.dbq.parser.ParseMysql;
import net.tccn.dbq.parser.Parser;
import net.tccn.meta.MetaService;
import net.tccn.meta.MetaTable;
@@ -15,7 +14,7 @@ import java.util.concurrent.CompletableFuture;
import java.util.concurrent.ExecutionException;
public class DbExecutors {
private final static Parser PARSER = new ParseMysql();
private final static ParseMysql PARSER = new ParseMysql();
public static PageBean findPage(FBean fBean) throws ExecutionException, InterruptedException {
//sql解析
@@ -37,4 +36,15 @@ public class DbExecutors {
return PageBean.by(rows, total);
}
public static void del(String name, Map data, String token) {
MetaService metaService = MetaKit.getMetaService(name, token);
MetaTable mainTable = MetaKit.getMetaTableByAlias(metaService.getTable());
DbKit dbKit = MetaKit.getDbKit(mainTable.getDbPlatId());
String delSql = PARSER.parseDel(name, data, token);
dbKit.exetute(delSql);
}
}