diff --git a/scripts/PopupTableFieldBuilder-output.json b/scripts/PopupTableFieldBuilder-output.json
new file mode 100644
index 0000000..657706e
--- /dev/null
+++ b/scripts/PopupTableFieldBuilder-output.json
@@ -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}
\ No newline at end of file
diff --git a/scripts/extract-popupTable-baseline.py b/scripts/extract-popupTable-baseline.py
new file mode 100644
index 0000000..b4170ef
--- /dev/null
+++ b/scripts/extract-popupTable-baseline.py
@@ -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}")
diff --git a/scripts/popupTable-baseline-samples.jsonl b/scripts/popupTable-baseline-samples.jsonl
new file mode 100644
index 0000000..e69de29
diff --git a/ssw-dacli/src/main/java/ssw/dacli/form/builder/field/PopupTableFieldBuilder.java b/ssw-dacli/src/main/java/ssw/dacli/form/builder/field/PopupTableFieldBuilder.java
new file mode 100644
index 0000000..4decf6a
--- /dev/null
+++ b/ssw-dacli/src/main/java/ssw/dacli/form/builder/field/PopupTableFieldBuilder.java
@@ -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 两阶段).
+ *
+ *
对应 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.
+ *
+ *
输出结构 (45 字段 = 23 顶层 + 22 __config__):
+ *
+ * - 顶层 (23): __config__, on, style, placeholder, interfaceId, interfaceName, templateJson,
+ * hasPage, pageSize, extraOptions, columnOptions, propsValue, relationField, popupType,
+ * popupTitle, popupWidth, disabled, clearable, __vModel__, id, multiple, filterable
+ * - __config__ (22): formId, jnpfKey, label, tipLabel, labelWidth, showLabel, tag, tagIcon,
+ * tableAlign, tableFixed, className, defaultValue, required, layout, span, dragDisabled,
+ * visibility, tableName, noShow, regList, trigger, useCache
+ *
+ *
+ * popupTableSelect 特有字段 (P0 两阶段 - 表格弹窗):
+ *
+ * - interfaceId: 数据接口 ID (ctx.extra.interfaceId, 缺省 "")
+ * - interfaceName: 数据接口名称 (ctx.extra.interfaceName, 缺省 "")
+ * - templateJson: 弹窗查询参数模板 (JNPF 默认 [])
+ * - columnOptions: 弹窗表格显示列 (CLAUDE.md §6 约束 ≤5 列, 默认 [])
+ * - propsValue: 存储字段 (componentMap = "id", 有 ctx 时填)
+ * - relationField: 回显字段 (componentMap = "fullName")
+ * - popupType: popover (默认) / dialog / drawer (与 popupSelect 不同, popupTableSelect 默认 popover)
+ * - popupTitle/popupWidth: 弹窗标题/宽度 (800px)
+ * - multiple: 多选 (props default false)
+ * - filterable: popupTableSelect 默认 true (搜索) — 与 popupSelect/relationForm 不同
+ * - useCache: 缓存接口数据 (JNPF 特有, default true)
+ *
+ *
+ * 字段对齐策略: 关键字段用 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 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 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() {{
+ // componentMap 提供完整 JS 模板
+ put("change", "({ data, rowIndex, formData, setFormData, setShowOrHide, setRequired, setDisabled, onlineUtils }) => {\n // 在此编写代码\n \n}");
+ }});
+ field.put("style", new LinkedHashMap() {{
+ 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);
+ }
+ }
+}
diff --git a/ssw-dacli/src/main/resources/META-INF/services/ssw.dacli.form.builder.FieldBuilder b/ssw-dacli/src/main/resources/META-INF/services/ssw.dacli.form.builder.FieldBuilder
index 339c8e5..f9dbea6 100644
--- a/ssw-dacli/src/main/resources/META-INF/services/ssw.dacli.form.builder.FieldBuilder
+++ b/ssw-dacli/src/main/resources/META-INF/services/ssw.dacli.form.builder.FieldBuilder
@@ -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
diff --git a/ssw-dacli/src/test/java/ssw/dacli/form/builder/field/PopupTableFieldBuilderTest.java b/ssw-dacli/src/test/java/ssw/dacli/form/builder/field/PopupTableFieldBuilderTest.java
new file mode 100644
index 0000000..f6a7db5
--- /dev/null
+++ b/ssw-dacli/src/test/java/ssw/dacli/form/builder/field/PopupTableFieldBuilderTest.java
@@ -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 用例).
+ *
+ * 校验关键结构 (jnpfKey/tag/columnOptions/interfaceId/popupType=popover/filterable=true) 与 componentMap 0 误差.
+ * baseline 0 sample, 字段对齐权威源: JNPF 前端 componentMap.ts (line 1246-1291).
+ *
+ *
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 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