1、metaTable中加入字段主键设置
2、添加删除策略配置 3、列表配置中加入"HIDDEN"配置,以及预览中加入解析逻辑
This commit is contained in:
@@ -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);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user