metaService中支持详情页配置
This commit is contained in:
@@ -202,7 +202,7 @@ public final class MetaKit {
|
||||
|
||||
List<Map<String, String>> shows = metaService.getShows();
|
||||
//List<Map> edits = metaService.getEdits();
|
||||
List<String> details = metaService.getDetails();
|
||||
List<Map<String, String>> details = metaService.getDetails();
|
||||
List<Filter> filters = metaService.getFilters();
|
||||
String comment = metaService.getComment();
|
||||
|
||||
@@ -292,13 +292,13 @@ public final class MetaKit {
|
||||
});*/
|
||||
|
||||
//details
|
||||
List _details = new ArrayList();//details;
|
||||
/*List _details = new ArrayList();//details;
|
||||
details.forEach(x -> {
|
||||
Kv kv = Kv.of();
|
||||
kv.set("col", x);
|
||||
|
||||
_details.add(kv);
|
||||
});
|
||||
});*/
|
||||
|
||||
return Kv.of()
|
||||
.set("title", comment)
|
||||
@@ -306,7 +306,7 @@ public final class MetaKit {
|
||||
.set("shows", shows)
|
||||
.set("filters", _filters)
|
||||
.set("edits", _edits)
|
||||
.set("details", _details);
|
||||
.set("details", details);
|
||||
}
|
||||
|
||||
@Comment("获取导出excel表头配置k-v")
|
||||
|
||||
@@ -23,7 +23,7 @@ public class MetaService extends Doc<MetaService> {
|
||||
|
||||
private List<Map<String,String>> shows = new ArrayList<>();
|
||||
private List<Map<String,String>> edits = new ArrayList<>();
|
||||
private List<String> details = new ArrayList<>();
|
||||
private List<Map<String,String>> details = new ArrayList<>();
|
||||
private List<Filter> filters = new ArrayList<>();//{name:"", label:"", checked:true, }
|
||||
private List<Map<String,String>> exports = new ArrayList<>();
|
||||
|
||||
|
||||
@@ -161,6 +161,17 @@ public class MetadataService extends BaseService { //arango
|
||||
return JBean.OK;
|
||||
}
|
||||
|
||||
@RestMapping(name = "detailsave", comment = "详情配置保存")
|
||||
public JBean detailSave(String name, List<Map<String, String>> details, @RestParam(name = "platToken") String token) {
|
||||
if (details == null || details.size() == 0) return null;
|
||||
|
||||
MetaService metaService = MetaKit.getMetaService(name, token);
|
||||
metaService.setDetails(details);
|
||||
|
||||
MetaKit.save(metaService);
|
||||
return JBean.OK;
|
||||
}
|
||||
|
||||
@RestMapping(name = "importsort", comment = "导入字段保存")
|
||||
public JBean importSort(String serviceKey, List<String> items, @RestParam(name = "platToken") String token) {
|
||||
if (isEmpty.test(items)) return null;
|
||||
|
||||
Reference in New Issue
Block a user