v13-f1 Task 1.9: popupTable 0 误差 (P0 两阶段, 前端代码反推)
This commit is contained in:
1 parent
4b29146696
commit
fb7511068c
6 files changed
+374
No files matched your search
@@ -0,0 +1 @@
|
||||
{"__config__":{"formId":"formItem1781185904637","jnpfKey":"popupTableSelect","label":"下拉表格","tipLabel":"","labelWidth":null,"showLabel":true,"tag":"JnpfPopupTableSelect","tagIcon":"icon-ym icon-ym-generator-popupTableSelect","tableAlign":"left","tableFixed":"none","className":[],"defaultValue":"","required":true,"layout":"colFormItem","span":24,"dragDisabled":false,"visibility":["pc","app"],"tableName":"","noShow":false,"regList":[],"trigger":"change","useCache":true},"on":{"change":"({ data, rowIndex, formData, setFormData, setShowOrHide, setRequired, setDisabled, onlineUtils }) => {\n // 在此编写代码\n \n}"},"style":{"width":"100%"},"placeholder":"请选择","interfaceId":"iface001","interfaceName":"用户数据接口","templateJson":[],"hasPage":false,"pageSize":20,"extraOptions":[],"columnOptions":[{"value":"f_id","label":"ID"},{"value":"f_name","label":"姓名"}],"propsValue":"f_id","relationField":"f_name","popupType":"popover","popupTitle":"选择数据","popupWidth":"800px","disabled":false,"clearable":true,"__vModel__":"f_popup_tbl","id":"f_popup_tbl","multiple":false,"filterable":true}
|
||||
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env python3
|
||||
"""从 35 form baseline 提取所有 popupTable 控件的 formData 真实样本.
|
||||
popupTable 控件判定: __config__.jnpfKey == 'popupTable'."""
|
||||
import json, glob, os
|
||||
|
||||
OUT = "scripts/popupTable-baseline-samples.jsonl"
|
||||
samples = []
|
||||
for path in glob.glob("/home/ubuntu/ccWorkDir/baseline/*/form/*.json"):
|
||||
try:
|
||||
d = json.load(open(path))['data']
|
||||
fd = json.loads(d['formData']) if isinstance(d.get('formData'), str) else {}
|
||||
for f in fd.get('fields', []):
|
||||
if isinstance(f, dict):
|
||||
cfg = f.get('__config__', {})
|
||||
if isinstance(cfg, dict) and cfg.get('jnpfKey') == 'popupTable':
|
||||
samples.append({
|
||||
"source": os.path.basename(path),
|
||||
"label": f.get('label') or cfg.get('label'),
|
||||
"formData": f
|
||||
})
|
||||
except Exception as e:
|
||||
pass
|
||||
|
||||
with open(OUT, 'w') as out:
|
||||
for s in samples:
|
||||
out.write(json.dumps(s, ensure_ascii=False) + "\n")
|
||||
|
||||
print(f"Extracted {len(samples)} popupTable 控件 samples to {OUT}")
|
||||
Whitespace-only changes.
@@ -0,0 +1,138 @@
|
||||
package ssw.dacli.form.builder.field;
|
||||
|
||||
import ssw.dacli.form.builder.FieldBuilder;
|
||||
import ssw.dacli.form.builder.FieldBuildContext;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* v13 popupTableSelect 控件 formData 0 误差生成器 (Task 1.9, P0 两阶段).
|
||||
*
|
||||
* <p>对应 JNPF 设计器 jnpfKey="popupTableSelect" / tag="JnpfPopupTableSelect" (下拉表格).
|
||||
* baseline 0 误差源: scripts/popupTable-baseline-samples.jsonl (0 sample, baseline 无此控件).
|
||||
* 字段对齐权威源: JNPF 前端 componentMap.ts (line 1246-1291, popupTableSelect 控件) +
|
||||
* popupSelect/src/props.ts (line 3-24, 20 props) + popupSelect/src/PopupSelect.vue.
|
||||
*
|
||||
* <p>输出结构 (45 字段 = 23 顶层 + 22 __config__):
|
||||
* <ul>
|
||||
* <li>顶层 (23): __config__, on, style, placeholder, interfaceId, interfaceName, templateJson,
|
||||
* hasPage, pageSize, extraOptions, columnOptions, propsValue, relationField, popupType,
|
||||
* popupTitle, popupWidth, disabled, clearable, __vModel__, id, multiple, filterable</li>
|
||||
* <li>__config__ (22): formId, jnpfKey, label, tipLabel, labelWidth, showLabel, tag, tagIcon,
|
||||
* tableAlign, tableFixed, className, defaultValue, required, layout, span, dragDisabled,
|
||||
* visibility, tableName, noShow, regList, trigger, useCache</li>
|
||||
* </ul>
|
||||
*
|
||||
* <p>popupTableSelect 特有字段 (P0 两阶段 - 表格弹窗):
|
||||
* <ul>
|
||||
* <li>interfaceId: 数据接口 ID (ctx.extra.interfaceId, 缺省 "")</li>
|
||||
* <li>interfaceName: 数据接口名称 (ctx.extra.interfaceName, 缺省 "")</li>
|
||||
* <li>templateJson: 弹窗查询参数模板 (JNPF 默认 [])</li>
|
||||
* <li>columnOptions: 弹窗表格显示列 (CLAUDE.md §6 约束 ≤5 列, 默认 [])</li>
|
||||
* <li>propsValue: 存储字段 (componentMap = "id", 有 ctx 时填)</li>
|
||||
* <li>relationField: 回显字段 (componentMap = "fullName")</li>
|
||||
* <li>popupType: popover (默认) / dialog / drawer (与 popupSelect 不同, popupTableSelect 默认 popover)</li>
|
||||
* <li>popupTitle/popupWidth: 弹窗标题/宽度 (800px)</li>
|
||||
* <li>multiple: 多选 (props default false)</li>
|
||||
* <li>filterable: popupTableSelect 默认 true (搜索) — 与 popupSelect/relationForm 不同</li>
|
||||
* <li>useCache: 缓存接口数据 (JNPF 特有, default true)</li>
|
||||
* </ul>
|
||||
*
|
||||
* <p>字段对齐策略: 关键字段用 ctx 值 (label/field/required); 数据接口配置用 componentMap 默认
|
||||
* (interfaceId='', propsValue='id', relationField='fullName', popupType='popover', pageSize=20, filterable=true).
|
||||
* columnOptions 默认 [], 弹窗配置完成后用户手动添加 (CLAUDE.md §6 约束).
|
||||
*/
|
||||
public class PopupTableFieldBuilder implements FieldBuilder {
|
||||
private static final ObjectMapper mapper = new ObjectMapper();
|
||||
|
||||
@Override
|
||||
public String jnpfKey() { return "popupTableSelect"; }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public String buildFormField(FieldBuildContext ctx) {
|
||||
try {
|
||||
Map<String, Object> field = new LinkedHashMap<>();
|
||||
|
||||
// 从 ctx.extra 提取 popupTableSelect 特有参数 (允许为空)
|
||||
String interfaceId = "";
|
||||
String interfaceName = "";
|
||||
String propsValue = "id"; // componentMap = "id"
|
||||
String relationField = "fullName"; // componentMap = "fullName"
|
||||
Object templateJsonRaw = new ArrayList<>();
|
||||
Object columnOptionsRaw = new ArrayList<>();
|
||||
Object extraOptionsRaw = new ArrayList<>();
|
||||
if (ctx.extra != null) {
|
||||
if (ctx.extra.get("interfaceId") != null) interfaceId = ctx.extra.get("interfaceId").toString();
|
||||
if (ctx.extra.get("interfaceName") != null) interfaceName = ctx.extra.get("interfaceName").toString();
|
||||
if (ctx.extra.get("propsValue") != null) propsValue = ctx.extra.get("propsValue").toString();
|
||||
if (ctx.extra.get("relationField") != null) relationField = ctx.extra.get("relationField").toString();
|
||||
if (ctx.extra.get("templateJson") != null) templateJsonRaw = ctx.extra.get("templateJson");
|
||||
if (ctx.extra.get("columnOptions") != null) columnOptionsRaw = ctx.extra.get("columnOptions");
|
||||
if (ctx.extra.get("extraOptions") != null) extraOptionsRaw = ctx.extra.get("extraOptions");
|
||||
}
|
||||
|
||||
// ============================================================
|
||||
// __config__ (22 字段, 跟 componentMap 0 误差)
|
||||
// ============================================================
|
||||
Map<String, Object> config = new LinkedHashMap<>();
|
||||
config.put("formId", "formItem" + System.currentTimeMillis());
|
||||
config.put("jnpfKey", "popupTableSelect");
|
||||
config.put("label", ctx.label);
|
||||
config.put("tipLabel", ""); // componentMap = ""
|
||||
config.put("labelWidth", null); // componentMap = undefined → null
|
||||
config.put("showLabel", true); // componentMap = true
|
||||
config.put("tag", "JnpfPopupTableSelect"); // componentMap = "JnpfPopupTableSelect"
|
||||
config.put("tagIcon", "icon-ym icon-ym-generator-popupTableSelect"); // componentMap
|
||||
config.put("tableAlign", "left"); // componentMap = "left"
|
||||
config.put("tableFixed", "none"); // componentMap = "none"
|
||||
config.put("className", new ArrayList<>()); // componentMap = []
|
||||
config.put("defaultValue", ""); // componentMap = ""
|
||||
config.put("required", ctx.required);
|
||||
config.put("layout", "colFormItem"); // componentMap = "colFormItem"
|
||||
config.put("span", 24);
|
||||
config.put("dragDisabled", false); // componentMap = false
|
||||
config.put("visibility", new ArrayList<>(Arrays.asList("pc", "app"))); // componentMap = ["pc","app"]
|
||||
config.put("tableName", ""); // componentMap = ""
|
||||
config.put("noShow", false); // componentMap = false
|
||||
config.put("regList", new ArrayList<>()); // componentMap = []
|
||||
config.put("trigger", "change"); // componentMap = "change"
|
||||
config.put("useCache", true); // componentMap = true (缓存接口数据)
|
||||
field.put("__config__", config);
|
||||
|
||||
// ============================================================
|
||||
// 顶层 (23 字段, 跟 componentMap 0 误差)
|
||||
// ============================================================
|
||||
field.put("on", new LinkedHashMap<String, Object>() {{
|
||||
// componentMap 提供完整 JS 模板
|
||||
put("change", "({ data, rowIndex, formData, setFormData, setShowOrHide, setRequired, setDisabled, onlineUtils }) => {\n // 在此编写代码\n \n}");
|
||||
}});
|
||||
field.put("style", new LinkedHashMap<String, Object>() {{
|
||||
put("width", "100%"); // componentMap = {"width":"100%"}
|
||||
}});
|
||||
field.put("placeholder", "请选择"); // componentMap = "请选择"
|
||||
field.put("interfaceId", interfaceId); // 数据接口 ID (componentMap = "", 有 ctx 时填)
|
||||
field.put("interfaceName", interfaceName); // 数据接口名称 (componentMap = "")
|
||||
field.put("templateJson", templateJsonRaw); // 弹窗查询参数模板 (componentMap = [])
|
||||
field.put("hasPage", false); // componentMap = false
|
||||
field.put("pageSize", 20); // componentMap = 20
|
||||
field.put("extraOptions", extraOptionsRaw); // 弹窗显示字段 (componentMap = [])
|
||||
field.put("columnOptions", columnOptionsRaw); // 弹窗表格列 (componentMap = [], CLAUDE.md §6 ≤5 列)
|
||||
field.put("propsValue", propsValue); // 存储字段 (componentMap = "id")
|
||||
field.put("relationField", relationField); // 回显字段 (componentMap = "fullName")
|
||||
field.put("popupType", "popover"); // popupTableSelect 默认 popover (与 popupSelect/relationForm 不同)
|
||||
field.put("popupTitle", "选择数据"); // componentMap = "选择数据"
|
||||
field.put("popupWidth", "800px"); // componentMap = "800px"
|
||||
field.put("disabled", false); // componentMap = false
|
||||
field.put("clearable", true); // componentMap = true
|
||||
field.put("__vModel__", ctx.field);
|
||||
field.put("id", ctx.field);
|
||||
field.put("multiple", false); // props default false
|
||||
field.put("filterable", true); // popupTableSelect 默认 true (与 popupSelect 一致, 与 relationForm false 不同)
|
||||
|
||||
return mapper.writeValueAsString(field);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException("PopupTableFieldBuilder.buildFormField failed: " + e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -6,3 +6,4 @@ ssw.dacli.form.builder.field.TimePickerFieldBuilder
|
||||
ssw.dacli.form.builder.field.UploadFileFieldBuilder
|
||||
ssw.dacli.form.builder.field.UploadImgFieldBuilder
|
||||
ssw.dacli.form.builder.field.RelationFormFieldBuilder
|
||||
ssw.dacli.form.builder.field.PopupTableFieldBuilder
|
||||
@@ -0,0 +1,206 @@
|
||||
package ssw.dacli.form.builder.field;
|
||||
|
||||
import ssw.dacli.form.builder.FieldBuildContext;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import static org.junit.jupiter.api.Assertions.*;
|
||||
import java.nio.file.*;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* v13 Task 1.9 — PopupTableFieldBuilder 单元测试 (4 用例).
|
||||
*
|
||||
* <p>校验关键结构 (jnpfKey/tag/columnOptions/interfaceId/popupType=popover/filterable=true) 与 componentMap 0 误差.
|
||||
* baseline 0 sample, 字段对齐权威源: JNPF 前端 componentMap.ts (line 1246-1291).
|
||||
*
|
||||
* <p>CLAUDE.md §6 约束: columnOptions ≤ 5 列.
|
||||
*/
|
||||
public class PopupTableFieldBuilderTest {
|
||||
|
||||
private static final ObjectMapper M = new ObjectMapper();
|
||||
|
||||
@Test
|
||||
public void testPopupTable_basic() throws Exception {
|
||||
FieldBuildContext ctx = new FieldBuildContext();
|
||||
ctx.field = "f_popup_tbl";
|
||||
ctx.label = "下拉表格";
|
||||
ctx.required = false;
|
||||
|
||||
String json = new PopupTableFieldBuilder().buildFormField(ctx);
|
||||
var parsed = M.readTree(json);
|
||||
|
||||
// 顶层关键键
|
||||
assertNotNull(parsed.get("__config__"));
|
||||
assertNotNull(parsed.get("__vModel__"));
|
||||
assertEquals("f_popup_tbl", parsed.get("__vModel__").asText());
|
||||
|
||||
// __config__ 关键键 (跟 componentMap 0 误差)
|
||||
var cfg = parsed.get("__config__");
|
||||
assertEquals("popupTableSelect", cfg.get("jnpfKey").asText());
|
||||
assertEquals("JnpfPopupTableSelect", cfg.get("tag").asText());
|
||||
assertEquals("下拉表格", cfg.get("label").asText());
|
||||
assertEquals("colFormItem", cfg.get("layout").asText());
|
||||
assertEquals("icon-ym icon-ym-generator-popupTableSelect", cfg.get("tagIcon").asText());
|
||||
assertEquals("change", cfg.get("trigger").asText());
|
||||
// popupTableSelect 特有 (JNPF 缓存接口)
|
||||
assertTrue(cfg.get("useCache").asBoolean());
|
||||
|
||||
// popupTableSelect 特有 (componentMap 默认值)
|
||||
assertEquals("请选择", parsed.get("placeholder").asText());
|
||||
assertEquals("", parsed.get("interfaceId").asText());
|
||||
assertEquals("", parsed.get("interfaceName").asText());
|
||||
assertFalse(parsed.get("hasPage").asBoolean());
|
||||
assertEquals(20, parsed.get("pageSize").asInt());
|
||||
// propsValue/relationField 默认值 (componentMap = "id" / "fullName")
|
||||
assertEquals("id", parsed.get("propsValue").asText());
|
||||
assertEquals("fullName", parsed.get("relationField").asText());
|
||||
// 弹窗默认配置 (popupTableSelect 默认 popover, 与 popupSelect/relationForm 不同)
|
||||
assertEquals("popover", parsed.get("popupType").asText());
|
||||
assertEquals("选择数据", parsed.get("popupTitle").asText());
|
||||
assertEquals("800px", parsed.get("popupWidth").asText());
|
||||
assertTrue(parsed.get("clearable").asBoolean());
|
||||
assertTrue(parsed.get("filterable").asBoolean()); // popupTableSelect 默认 true
|
||||
assertFalse(parsed.get("disabled").asBoolean());
|
||||
assertFalse(parsed.get("multiple").asBoolean());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testPopupTable_withExtra() throws Exception {
|
||||
// 测试 ctx.extra 字段透传 (interfaceId/interfaceName/columnOptions 等)
|
||||
FieldBuildContext ctx = new FieldBuildContext();
|
||||
ctx.field = "f_popup_tbl";
|
||||
ctx.label = "下拉表格";
|
||||
ctx.required = true;
|
||||
Map<String, Object> extra = new LinkedHashMap<>();
|
||||
extra.put("interfaceId", "iface001");
|
||||
extra.put("interfaceName", "用户数据接口");
|
||||
extra.put("propsValue", "f_id");
|
||||
extra.put("relationField", "f_name");
|
||||
// 弹窗表格列 (CLAUDE.md §6 约束 ≤5 列)
|
||||
List<Map<String, Object>> cols = new ArrayList<>();
|
||||
cols.add(new LinkedHashMap<String, Object>() {{ put("value", "f_id"); put("label", "ID"); }});
|
||||
cols.add(new LinkedHashMap<String, Object>() {{ put("value", "f_name"); put("label", "姓名"); }});
|
||||
cols.add(new LinkedHashMap<String, Object>() {{ put("value", "f_code"); put("label", "编码"); }});
|
||||
extra.put("columnOptions", cols);
|
||||
// templateJson (弹窗查询参数)
|
||||
List<Map<String, Object>> tmpl = new ArrayList<>();
|
||||
tmpl.add(new LinkedHashMap<String, Object>() {{ put("field", "f_dept"); put("sourceType", 0); }});
|
||||
extra.put("templateJson", tmpl);
|
||||
ctx.extra = extra;
|
||||
|
||||
String json = new PopupTableFieldBuilder().buildFormField(ctx);
|
||||
var parsed = M.readTree(json);
|
||||
|
||||
// 透传字段
|
||||
assertEquals("iface001", parsed.get("interfaceId").asText());
|
||||
assertEquals("用户数据接口", parsed.get("interfaceName").asText());
|
||||
assertEquals("f_id", parsed.get("propsValue").asText());
|
||||
assertEquals("f_name", parsed.get("relationField").asText());
|
||||
// required 透传
|
||||
assertTrue(parsed.get("__config__").get("required").asBoolean());
|
||||
|
||||
// columnOptions (≤5 列)
|
||||
var columnOptions = parsed.get("columnOptions");
|
||||
assertTrue(columnOptions.isArray());
|
||||
assertEquals(3, columnOptions.size());
|
||||
assertEquals("ID", columnOptions.get(0).get("label").asText());
|
||||
assertEquals("姓名", columnOptions.get(1).get("label").asText());
|
||||
assertEquals("编码", columnOptions.get(2).get("label").asText());
|
||||
|
||||
// templateJson 透传
|
||||
var templateJson = parsed.get("templateJson");
|
||||
assertTrue(templateJson.isArray());
|
||||
assertEquals(1, templateJson.size());
|
||||
assertEquals("f_dept", templateJson.get(0).get("field").asText());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testPopupTable_baselineKeyStructure() throws Exception {
|
||||
// 跟 componentMap popupTableSelect 控件 formData 关键结构对齐检查
|
||||
FieldBuildContext ctx = new FieldBuildContext();
|
||||
ctx.field = "f_popup_tbl";
|
||||
ctx.label = "下拉表格";
|
||||
|
||||
String json = new PopupTableFieldBuilder().buildFormField(ctx);
|
||||
var parsed = M.readTree(json);
|
||||
var cfg = parsed.get("__config__");
|
||||
|
||||
// __config__ 必有 (22 字段)
|
||||
assertNotNull(cfg.get("formId"));
|
||||
assertNotNull(cfg.get("jnpfKey"));
|
||||
assertNotNull(cfg.get("label"));
|
||||
assertNotNull(cfg.get("tipLabel"));
|
||||
assertNotNull(cfg.get("showLabel"));
|
||||
assertNotNull(cfg.get("tag"));
|
||||
assertNotNull(cfg.get("tagIcon"));
|
||||
assertNotNull(cfg.get("tableAlign"));
|
||||
assertNotNull(cfg.get("tableFixed"));
|
||||
assertNotNull(cfg.get("className"));
|
||||
assertNotNull(cfg.get("defaultValue"));
|
||||
assertNotNull(cfg.get("required"));
|
||||
assertNotNull(cfg.get("layout"));
|
||||
assertNotNull(cfg.get("span"));
|
||||
assertNotNull(cfg.get("dragDisabled"));
|
||||
assertNotNull(cfg.get("visibility"));
|
||||
assertNotNull(cfg.get("tableName"));
|
||||
assertNotNull(cfg.get("noShow"));
|
||||
assertNotNull(cfg.get("regList"));
|
||||
assertNotNull(cfg.get("trigger"));
|
||||
assertNotNull(cfg.get("useCache")); // popupTableSelect 特有
|
||||
|
||||
// 顶层 baseline 必有 (23 字段)
|
||||
assertNotNull(parsed.get("__vModel__"));
|
||||
assertNotNull(parsed.get("style"));
|
||||
assertNotNull(parsed.get("placeholder"));
|
||||
assertNotNull(parsed.get("interfaceId"));
|
||||
assertNotNull(parsed.get("interfaceName"));
|
||||
assertNotNull(parsed.get("templateJson"));
|
||||
assertNotNull(parsed.get("hasPage"));
|
||||
assertNotNull(parsed.get("pageSize"));
|
||||
assertNotNull(parsed.get("extraOptions"));
|
||||
assertNotNull(parsed.get("columnOptions"));
|
||||
assertNotNull(parsed.get("propsValue"));
|
||||
assertNotNull(parsed.get("relationField"));
|
||||
assertNotNull(parsed.get("popupType"));
|
||||
assertNotNull(parsed.get("popupTitle"));
|
||||
assertNotNull(parsed.get("popupWidth"));
|
||||
assertNotNull(parsed.get("disabled"));
|
||||
assertNotNull(parsed.get("clearable"));
|
||||
assertNotNull(parsed.get("on"));
|
||||
assertNotNull(parsed.get("id"));
|
||||
assertNotNull(parsed.get("multiple"));
|
||||
assertNotNull(parsed.get("filterable"));
|
||||
|
||||
// on.change 必有 (componentMap 完整 JS 模板)
|
||||
assertNotNull(parsed.get("on").get("change"));
|
||||
// 触发器 = "change" (componentMap)
|
||||
assertEquals("change", cfg.get("trigger").asText());
|
||||
// 弹窗触发配置
|
||||
assertTrue(parsed.get("style").get("width").asText().equals("100%"));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testPopupTable_dumpToFile() throws Exception {
|
||||
// 工具方法: 把生成结果写到 scripts/PopupTableFieldBuilder-output.json 用于 diff 对比
|
||||
FieldBuildContext ctx = new FieldBuildContext();
|
||||
ctx.field = "f_popup_tbl";
|
||||
ctx.label = "下拉表格";
|
||||
ctx.required = true;
|
||||
Map<String, Object> extra = new LinkedHashMap<>();
|
||||
extra.put("interfaceId", "iface001");
|
||||
extra.put("interfaceName", "用户数据接口");
|
||||
extra.put("propsValue", "f_id");
|
||||
extra.put("relationField", "f_name");
|
||||
List<Map<String, Object>> cols = new ArrayList<>();
|
||||
cols.add(new LinkedHashMap<String, Object>() {{ put("value", "f_id"); put("label", "ID"); }});
|
||||
cols.add(new LinkedHashMap<String, Object>() {{ put("value", "f_name"); put("label", "姓名"); }});
|
||||
extra.put("columnOptions", cols);
|
||||
ctx.extra = extra;
|
||||
String json = new PopupTableFieldBuilder().buildFormField(ctx);
|
||||
Path out = Paths.get("../scripts/PopupTableFieldBuilder-output.json");
|
||||
Files.createDirectories(out.getParent());
|
||||
Files.writeString(out, json);
|
||||
assertTrue(Files.exists(out));
|
||||
assertTrue(Files.size(out) > 100);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user