aibox-custom-component-packages 0.0.6 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (191) hide show
  1. package/es/AddOrEditSupplierDialog.mjs +836 -0
  2. package/es/ApplicationTypeTag.mjs +58 -0
  3. package/es/AuthSection.mjs +199 -0
  4. package/es/AutoShowTooltip.mjs +90 -0
  5. package/es/AvailableRangePreview.mjs +1 -1
  6. package/es/AvailableRangeSetting.mjs +16 -11
  7. package/es/CodeView.mjs +7 -0
  8. package/es/CommonTagsList.mjs +5 -5
  9. package/es/CreateMcpForm.mjs +385 -0
  10. package/es/CustomSidebar.mjs +717 -0
  11. package/es/CustomTitle.mjs +7 -0
  12. package/es/CustomToggle.mjs +224 -0
  13. package/es/DialogContainer.mjs +21 -21
  14. package/es/DocSyncSelect.mjs +2661 -0
  15. package/es/FileDisplay.mjs +4 -0
  16. package/es/FilePreview.mjs +179 -0
  17. package/es/FileUploader.mjs +263 -9
  18. package/es/Logo.mjs +72 -0
  19. package/es/McpFormDialog.mjs +8 -0
  20. package/es/McpParamsSet.mjs +630 -0
  21. package/es/MdEditor.mjs +201 -0
  22. package/es/PageContainer.mjs +582 -11
  23. package/es/ParameterTable.mjs +2290 -0
  24. package/es/PublishRecord.mjs +59 -58
  25. package/es/RadioGroup.mjs +119 -0
  26. package/es/SourcePublish.mjs +96 -94
  27. package/es/Table.mjs +2 -2
  28. package/es/assets/AddOrEditSupplierDialog.css +1 -0
  29. package/es/assets/AiboxTable.css +1 -0
  30. package/es/assets/ApplicationTypeTag.css +1 -0
  31. package/es/assets/AuthSection.css +1 -0
  32. package/es/assets/AutoShowTooltip.css +1 -0
  33. package/es/assets/CommonTagsList.css +1 -1
  34. package/es/assets/CreateMcpForm.css +1 -0
  35. package/es/assets/CustomSidebar.css +1 -0
  36. package/es/assets/CustomToggle.css +1 -0
  37. package/es/assets/DocSyncSelect.css +1 -0
  38. package/es/assets/FilePreview.css +1 -0
  39. package/es/assets/FileUploader.css +1 -0
  40. package/es/assets/Logo.css +1 -0
  41. package/es/assets/McpParamsSet.css +1 -0
  42. package/es/assets/MdEditor.css +1 -0
  43. package/es/assets/PageContainer.css +1 -0
  44. package/es/assets/ParameterTable.css +1 -0
  45. package/es/assets/PublishRecord.css +1 -1
  46. package/es/assets/RadioGroup.css +1 -0
  47. package/es/assets/SourcePublish.css +1 -1
  48. package/es/assets/index.css +1 -1
  49. package/es/assets/index2.css +1 -1
  50. package/es/assets/index3.css +1 -0
  51. package/es/assets/index4.css +1 -0
  52. package/es/assets/index5.css +1 -0
  53. package/es/assets/layout.css +1 -0
  54. package/es/assets/legacy.css +1 -0
  55. package/es/assets/usePreview.css +1 -0
  56. package/es/chunks/{BackBar.Cv1wxUcM.js → AiboxTable.CF4T_OCu.js} +123 -123
  57. package/es/chunks/{BackBar.DJV4JaUM.js → AiboxTable.DUGBBVXh.js} +123 -123
  58. package/es/chunks/{config.BU21Gda2.js → config.DPkdwjwD.js} +1 -1
  59. package/es/chunks/{config.BzCGum_W.js → config.Dklrsn-B.js} +1 -1
  60. package/es/chunks/{config.BPp4hMBq.js → config.RrNwuFkQ.js} +2 -2
  61. package/es/chunks/{config.DTMcCH58.js → config.gNZ_rT87.js} +2 -2
  62. package/es/chunks/{enums.CfSBDD6u.js → enums.Dvec-maC.js} +11 -32
  63. package/es/chunks/enums.WrpwbF4w.js +14 -0
  64. package/es/chunks/field-types.CPnMOjle.js +13 -0
  65. package/es/chunks/files.cduUqjHX.js +16 -0
  66. package/es/chunks/i18n.DDMVloiU.js +443 -0
  67. package/es/chunks/{i18n.DmqkiK-h.js → i18n.k9Q_HVMs.js} +25 -26
  68. package/es/chunks/index.BDd6hHiU.js +172 -0
  69. package/es/chunks/index.BT1khSY9.js +111 -0
  70. package/es/chunks/{index.DB0ayMv8.js → index.CDvh263l.js} +3 -3
  71. package/es/chunks/{index.aMb6IVQD.js → index.CF_YHLP5.js} +19 -19
  72. package/es/chunks/index.CSjjAi3w.js +396 -0
  73. package/es/chunks/index.CdEBk4F_.js +134 -0
  74. package/es/chunks/index.DdD1VsH1.js +396 -0
  75. package/es/chunks/index.Dx-mCS4E.js +1298 -0
  76. package/es/chunks/layout.BREUWPEJ.js +26 -0
  77. package/es/chunks/layout.CygCXa6s.js +26 -0
  78. package/es/chunks/{publish.BCb7nCo9.js → publish.DlD0o09n.js} +1 -1
  79. package/es/chunks/request.24c3shPx.js +5 -0
  80. package/es/chunks/usePreview.B5lboHeg.js +153 -0
  81. package/es/chunks/usePreview.BHvXwaNi.js +157 -0
  82. package/es/index.mjs +404 -307
  83. package/lib/AddOrEditSupplierDialog.js +1 -0
  84. package/lib/ApplicationTypeTag.js +1 -0
  85. package/lib/AuthSection.js +1 -0
  86. package/lib/AutoShowTooltip.js +1 -0
  87. package/lib/AvailableRangePreview.js +1 -1
  88. package/lib/AvailableRangeSetting.js +1 -1
  89. package/lib/CodeView.js +1 -0
  90. package/lib/CommonTagsList.js +1 -1
  91. package/lib/CreateMcpForm.js +1 -0
  92. package/lib/CustomSidebar.js +1 -0
  93. package/lib/CustomTitle.js +1 -0
  94. package/lib/CustomToggle.js +1 -0
  95. package/lib/DialogContainer.js +1 -1
  96. package/lib/DocSyncSelect.js +2 -0
  97. package/lib/FileDisplay.js +1 -0
  98. package/lib/FilePreview.js +1 -0
  99. package/lib/FileUploader.js +1 -1
  100. package/lib/Logo.js +1 -0
  101. package/lib/McpFormDialog.js +1 -0
  102. package/lib/McpParamsSet.js +1 -0
  103. package/lib/MdEditor.js +1 -0
  104. package/lib/PageContainer.js +1 -1
  105. package/lib/ParameterTable.js +1 -0
  106. package/lib/PublishRecord.js +4 -4
  107. package/lib/RadioGroup.js +1 -0
  108. package/lib/SourcePublish.js +1 -1
  109. package/lib/Table.js +1 -1
  110. package/lib/assets/AddOrEditSupplierDialog.css +1 -0
  111. package/lib/assets/AiboxTable.css +1 -0
  112. package/lib/assets/ApplicationTypeTag.css +1 -0
  113. package/lib/assets/AuthSection.css +1 -0
  114. package/lib/assets/AutoShowTooltip.css +1 -0
  115. package/lib/assets/CommonTagsList.css +1 -1
  116. package/lib/assets/CreateMcpForm.css +1 -0
  117. package/lib/assets/CustomSidebar.css +1 -0
  118. package/lib/assets/CustomToggle.css +1 -0
  119. package/lib/assets/DocSyncSelect.css +1 -0
  120. package/lib/assets/FilePreview.css +1 -0
  121. package/lib/assets/FileUploader.css +1 -0
  122. package/lib/assets/Logo.css +1 -0
  123. package/lib/assets/McpParamsSet.css +1 -0
  124. package/lib/assets/MdEditor.css +1 -0
  125. package/lib/assets/PageContainer.css +1 -0
  126. package/lib/assets/ParameterTable.css +1 -0
  127. package/lib/assets/PublishRecord.css +1 -1
  128. package/lib/assets/RadioGroup.css +1 -0
  129. package/lib/assets/SourcePublish.css +1 -1
  130. package/lib/assets/index.css +1 -1
  131. package/lib/assets/index2.css +1 -1
  132. package/lib/assets/index3.css +1 -0
  133. package/lib/assets/index4.css +1 -0
  134. package/lib/assets/index5.css +1 -0
  135. package/lib/assets/layout.css +1 -0
  136. package/lib/assets/legacy.css +1 -0
  137. package/lib/assets/usePreview.css +1 -0
  138. package/lib/chunks/AiboxTable.BnoHJ7xL.js +1 -0
  139. package/lib/chunks/AiboxTable.CJOPGJtU.js +1 -0
  140. package/lib/chunks/{config.B0XKkp1w.js → config.1oaIKLGn.js} +1 -1
  141. package/lib/chunks/{config.BCAuBVxV.js → config.BF7MO0O5.js} +1 -1
  142. package/lib/chunks/enums.DnuzPZCR.js +1 -0
  143. package/lib/chunks/enums.DpU2er5r.js +1 -0
  144. package/lib/chunks/field-types.Ch_2yDfg.js +1 -0
  145. package/lib/chunks/files.B3-8UC0v.js +1 -0
  146. package/lib/chunks/i18n.DgOp_D7R.js +1 -0
  147. package/lib/chunks/index.BNivYbtq.js +1 -0
  148. package/lib/chunks/{index.Bk-RwmaH.js → index.B_keI1Aq.js} +1 -1
  149. package/lib/chunks/{index.BsN4urmi.js → index.Bc71XWQn.js} +1 -1
  150. package/lib/chunks/index.C7aZx6RG.js +6 -0
  151. package/lib/chunks/index.CH7XdMru.js +1 -0
  152. package/lib/chunks/index.CJFk1R2u.js +59 -0
  153. package/lib/chunks/index.CaidDlAx.js +1 -0
  154. package/lib/chunks/index.DGWHQFdx.js +6 -0
  155. package/lib/chunks/layout.DbBSbLgm.js +1 -0
  156. package/lib/chunks/layout.sgE9JoNq.js +1 -0
  157. package/lib/chunks/publish.3TrK3fZf.js +1 -0
  158. package/lib/chunks/request.D8T4MgGX.js +1 -0
  159. package/lib/chunks/usePreview.2PZJSy5w.js +1 -0
  160. package/lib/chunks/usePreview.BojIDW7Z.js +1 -0
  161. package/lib/index.js +2 -4
  162. package/package.json +3 -3
  163. package/es/ExampleComponent.mjs +0 -35
  164. package/es/assets/BackBar.css +0 -1
  165. package/es/assets/ExampleComponent.css +0 -1
  166. package/es/chunks/BackBar.Bc2NIuzk.js +0 -645
  167. package/es/chunks/config.8htFF04x.js +0 -325
  168. package/es/chunks/config.CFWGjEdA.js +0 -49
  169. package/es/chunks/config.CfWAdyUH.js +0 -325
  170. package/es/chunks/i18n.Vhq-tZPw.js +0 -94
  171. package/es/chunks/i18n.ro9yz7rE.js +0 -94
  172. package/es/chunks/index.ml5i7aB5.js +0 -257
  173. package/es/chunks/index.s-YxIOfq.js +0 -301
  174. package/es/chunks/publish.D6friivo.js +0 -50
  175. package/es/chunks/publish.Dqzn7qEl.js +0 -50
  176. package/es/i18n.mjs +0 -17
  177. package/lib/ExampleComponent.js +0 -1
  178. package/lib/assets/BackBar.css +0 -1
  179. package/lib/assets/ExampleComponent.css +0 -1
  180. package/lib/chunks/BackBar.CZsNxoX1.js +0 -1
  181. package/lib/chunks/BackBar.s5_vN6jt.js +0 -1
  182. package/lib/chunks/config.Bs7sh3aP.js +0 -1
  183. package/lib/chunks/config.C1w4hgfw.js +0 -1
  184. package/lib/chunks/config.ClERt2RF.js +0 -1
  185. package/lib/chunks/enums.Dmq4PdUc.js +0 -1
  186. package/lib/chunks/i18n.CL5L6nx6.js +0 -1
  187. package/lib/chunks/i18n.aAXi5igh.js +0 -1
  188. package/lib/chunks/index.BNqTEn3K.js +0 -1
  189. package/lib/chunks/publish.Bw1acrSu.js +0 -1
  190. package/lib/chunks/publish.CA1uSVnm.js +0 -1
  191. package/lib/i18n.js +0 -1
@@ -0,0 +1,2290 @@
1
+ import { w as Ke } from "./chunks/index.bCzIhWFw.js";
2
+ import { ref as te, onMounted as Ze, resolveComponent as we, createBlock as H, openBlock as b, unref as e, withCtx as A, createVNode as v, createCommentVNode as $, createTextVNode as q, toDisplayString as F, createElementVNode as j, computed as h, provide as et, inject as tt, watch as pe, createElementBlock as W, Fragment as ae, renderList as Ie, mergeModels as ie, useModel as Ee, normalizeClass as ee, nextTick as ve, createSlots as lt } from "vue";
3
+ import { ElIcon as Y, ElInput as Z, ElButton as oe, ElTooltip as Oe, ElSelect as ye, ElOption as re, ElDatePicker as at, ElTag as nt, ElMessage as rt, ElCheckbox as Ue } from "element-plus";
4
+ import { IconUpload2 as he, Error as ge, IconScene as ot, IconAdd2 as it, IconZuoCopyCopy as Be, IconZuoCopy as Se, IconDelete2 as st, IconAdd as ut, IconTip as be } from "color-message-aibox-vue";
5
+ import { useDialog as dt, DialogContainer as ct } from "./DialogContainer.mjs";
6
+ import { AiboxTable as ke } from "./Table.mjs";
7
+ import { u as ne, g as X } from "./chunks/i18n.k9Q_HVMs.js";
8
+ import { _ as ue } from "./chunks/_plugin-vue_export-helper.CHgC5LLL.js";
9
+ import { FileUploader as Ne, getWarnTips as Le, getAcceptType as Ce, UploadTypesEnum as Re } from "./FileUploader.mjs";
10
+ import { AutoShowTooltip as Pe } from "./AutoShowTooltip.mjs";
11
+ import './assets/ParameterTable.css';const pt = { class: "action-header" }, mt = { class: "dialog-footer" }, At = {
12
+ __name: "OptionValue",
13
+ emits: ["createOption"],
14
+ setup(i, { expose: r, emit: a }) {
15
+ const { t: l } = ne(), { dialogRef: w, showDialog: f, hideDialog: p } = dt(), _ = te(1), C = te([
16
+ {
17
+ label: "",
18
+ value: ""
19
+ }
20
+ ]), O = te([
21
+ {
22
+ label: l("COMMON_OPTIONVALUE.LABEL_INDEX"),
23
+ //序号
24
+ slot: "serialNumber"
25
+ },
26
+ {
27
+ label: l("COMMON_OPTIONVALUE.LABEL_API_VALUE"),
28
+ // api接口原值
29
+ slot: "value",
30
+ minWidth: 150
31
+ },
32
+ {
33
+ label: l("COMMON_OPTIONVALUE.LABEL_OPTION_DISPLAY_VALUE"),
34
+ //选项对应显示值
35
+ slot: "label",
36
+ minWidth: 200,
37
+ headerSlot: "nowValue"
38
+ },
39
+ {
40
+ label: l("COMMON_OPTIONVALUE.LABEL_OPERATION"),
41
+ slot: "action",
42
+ fixed: "right",
43
+ minWidth: 100,
44
+ headerSlot: "actionHeader"
45
+ }
46
+ ]), m = te({}), P = () => {
47
+ C.value.push({
48
+ label: "",
49
+ value: ""
50
+ }), _.value = C.value.length;
51
+ }, D = (c) => {
52
+ console.log("option数据", c), m.value = c, c["extend-widget-item"] && c["extend-widget-item"] != "" ? C.value = JSON.parse(c["extend-widget-item"]) : C.value = [
53
+ {
54
+ label: "",
55
+ value: ""
56
+ }
57
+ ], f();
58
+ }, T = () => {
59
+ p();
60
+ }, M = (c) => {
61
+ C.value.splice(c, 1);
62
+ }, N = a, g = () => {
63
+ const c = C.value.filter(
64
+ (o) => o.label.trim() !== "" || o.value.trim() !== ""
65
+ );
66
+ for (let o of c)
67
+ if (o.label.trim() === "" || o.value.trim() === "") {
68
+ ElMessage.error(l("COMMON_OPTIONVALUE.LABEL_OPTION_VALUE_REQUIRED"));
69
+ return;
70
+ }
71
+ if (c.length === 0) {
72
+ ElMessage.error(l("COMMON_OPTIONVALUE.LABEL_OPTION_VALUE_REQUIRED_TIP"));
73
+ return;
74
+ }
75
+ let d = {
76
+ uiid: m.value.uiid,
77
+ data: JSON.stringify(c)
78
+ };
79
+ N("createOption", d), p();
80
+ };
81
+ return r({ showOption: D, hideOption: T }), Ze(() => {
82
+ }), (c, d) => {
83
+ const o = we("IconQuery"), s = we("Error");
84
+ return b(), H(e(ct), {
85
+ title: e(l)("COMMON_OPTIONVALUE.LABEL_OPTION_VALUE_SETTING"),
86
+ width: "820px",
87
+ ref_key: "dialogRef",
88
+ ref: w
89
+ }, {
90
+ footer: A(() => [
91
+ j("div", mt, [
92
+ v(e(oe), { onClick: e(p) }, {
93
+ default: A(() => [
94
+ q(F(e(l)("COMMON_BUTTON.CANCEL_TEXT")), 1)
95
+ ]),
96
+ _: 1
97
+ }, 8, ["onClick"]),
98
+ v(e(oe), {
99
+ type: "primary",
100
+ onClick: g
101
+ }, {
102
+ default: A(() => [
103
+ q(F(e(l)("COMMON_BUTTON.CONFIRM_AFFIRM")), 1)
104
+ ]),
105
+ _: 1
106
+ })
107
+ ])
108
+ ]),
109
+ default: A(() => [
110
+ v(e(ke), {
111
+ columns: O.value,
112
+ data: C.value,
113
+ hasPage: !1,
114
+ total: _.value
115
+ }, {
116
+ nowValue: A(() => [
117
+ q(F(e(l)("COMMON_OPTIONVALUE.LABEL_OPTION_VALUE")) + " ", 1),
118
+ v(e(Oe), {
119
+ placement: "top",
120
+ "max-width": 50
121
+ }, {
122
+ content: A(() => [
123
+ q(F(e(l)("COMMON_OPTIONVALUE.LABEL_OPTION_VALUE_TIP")), 1),
124
+ d[0] || (d[0] = j("br", null, null, -1)),
125
+ q(" " + F(e(l)("COMMON_OPTIONVALUE.LABEL_OPTION_VALUE_EXAMPLE")), 1),
126
+ d[1] || (d[1] = j("br", null, null, -1)),
127
+ q(" " + F(e(l)("COMMON_OPTIONVALUE.LABEL_OPTION_EXAMPLE")), 1),
128
+ d[2] || (d[2] = j("br", null, null, -1)),
129
+ q(" " + F(e(l)("COMMON_OPTIONVALUE.LABEL_OPTION_EXAMPLE_2")), 1),
130
+ d[3] || (d[3] = j("br", null, null, -1))
131
+ ]),
132
+ default: A(() => [
133
+ v(e(Y), { style: { "margin-left": "5px", cursor: "pointer" } }, {
134
+ default: A(() => [
135
+ v(o)
136
+ ]),
137
+ _: 1
138
+ })
139
+ ]),
140
+ _: 1
141
+ })
142
+ ]),
143
+ actionHeader: A(() => [
144
+ j("div", pt, [
145
+ j("span", null, F(e(l)("COMMON_OPTIONVALUE.LABEL_OPERATION")), 1),
146
+ v(e(oe), {
147
+ type: "primary",
148
+ size: "small",
149
+ onClick: P,
150
+ icon: "IconAdd"
151
+ }, {
152
+ default: A(() => [
153
+ q(F(e(l)("COMMON_BUTTON.ADD_NEW_TEXT")), 1)
154
+ ]),
155
+ _: 1
156
+ })
157
+ ])
158
+ ]),
159
+ serialNumber: A((E) => [
160
+ q(F(E.index + 1), 1)
161
+ ]),
162
+ label: A((E) => [
163
+ v(e(Z), {
164
+ modelValue: E.row.label,
165
+ "onUpdate:modelValue": (L) => E.row.label = L,
166
+ style: { width: "100%" },
167
+ placeholder: e(l)("COMMON_DATA.PLACEHOLDER_INPUT")
168
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder"])
169
+ ]),
170
+ value: A((E) => [
171
+ v(e(Z), {
172
+ modelValue: E.row.value,
173
+ "onUpdate:modelValue": (L) => E.row.value = L,
174
+ style: { width: "100%" },
175
+ placeholder: e(l)("COMMON_DATA.PLACEHOLDER_INPUT")
176
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder"])
177
+ ]),
178
+ action: A((E) => [
179
+ C.value.length > 1 ? (b(), H(e(Y), {
180
+ key: 0,
181
+ style: { cursor: "pointer", color: "red" },
182
+ onClick: (L) => M(E.index)
183
+ }, {
184
+ default: A(() => [
185
+ v(s)
186
+ ]),
187
+ _: 1
188
+ }, 8, ["onClick"])) : $("", !0)
189
+ ]),
190
+ _: 1
191
+ }, 8, ["columns", "data", "total"])
192
+ ]),
193
+ _: 1
194
+ }, 8, ["title"]);
195
+ };
196
+ }
197
+ }, yt = /* @__PURE__ */ ue(At, [["__scopeId", "data-v-2681e3ba"]]);
198
+ function ft(i) {
199
+ const r = h(() => i.isPluginMode), a = h(() => i.isDataType), l = h(() => i.justString), w = h(() => i.forceRequired), f = h(() => i.showMoreColumns), p = h(() => i.setType && i.setType.length === 1), _ = h(() => r.value && a.value), C = h(() => r.value && l.value), O = h(() => !r.value && a.value), m = h(() => !r.value && l.value), P = h(() => {
200
+ const T = r.value, M = a.value, N = i.customFieldName;
201
+ return N || (T && M ? {
202
+ name: "name",
203
+ type: "type",
204
+ value: "debugValue"
205
+ } : T ? {
206
+ name: "name",
207
+ type: "type",
208
+ value: "debugValue"
209
+ } : {
210
+ name: "dataName",
211
+ type: "dataType",
212
+ value: "debugValue"
213
+ });
214
+ });
215
+ return {
216
+ // 基础模式
217
+ isPluginMode: r,
218
+ isDataType: a,
219
+ isJustString: l,
220
+ isForceRequired: w,
221
+ showMoreColumns: f,
222
+ isSingleType: p,
223
+ // 组合模式
224
+ isPluginDataTypeMode: _,
225
+ isPluginJustStringMode: C,
226
+ isNormalDataTypeMode: O,
227
+ isNormalJustStringMode: m,
228
+ // 字段名策略
229
+ getFieldName: (T) => P.value[T] || T
230
+ };
231
+ }
232
+ const He = /* @__PURE__ */ Symbol("ParameterTableContext");
233
+ function Et(i) {
234
+ const {
235
+ props: r,
236
+ tableData: a,
237
+ emit: l,
238
+ getSnowFlakeId: w,
239
+ typeList: f,
240
+ isSingleType: p,
241
+ validationErrors: _,
242
+ focusFields: C,
243
+ tableRef: O
244
+ } = i, { t: m } = ne(), P = ft(r), D = P.getFieldName, N = {
245
+ // 基础配置
246
+ props: r,
247
+ tableData: a,
248
+ emit: l,
249
+ getSnowFlakeId: w,
250
+ typeList: f,
251
+ isSingleType: p,
252
+ // 状态管理
253
+ validationErrors: _,
254
+ focusFields: C,
255
+ tableRef: O,
256
+ // 模式策略管理器(统一模式判断逻辑)
257
+ modeStrategy: P,
258
+ // 字段映射(从 modeStrategy 获取)
259
+ getFieldName: D,
260
+ getFieldValue: (g, c) => {
261
+ const d = D(c);
262
+ return g[d];
263
+ },
264
+ setFieldValue: (g, c, d) => {
265
+ const o = D(c);
266
+ g[o] = d;
267
+ },
268
+ // 模式判断(从 modeStrategy 导出,保持向后兼容)
269
+ isPluginMode: P.isPluginMode,
270
+ isDataType: P.isDataType,
271
+ isJustString: P.isJustString,
272
+ isForceRequired: P.isForceRequired,
273
+ showMoreColumns: P.showMoreColumns,
274
+ // 组合模式判断
275
+ isPluginDataTypeMode: P.isPluginDataTypeMode,
276
+ isPluginJustStringMode: P.isPluginJustStringMode,
277
+ isNormalDataTypeMode: P.isNormalDataTypeMode,
278
+ isNormalJustStringMode: P.isNormalJustStringMode,
279
+ // 其他 props 相关的计算属性
280
+ disabled: h(() => r.disabled),
281
+ forceRequired: h(() => r.forceRequired),
282
+ location: h(() => r.location),
283
+ setType: h(() => r.setType),
284
+ disabledFields: h(() => r.disabledFields),
285
+ inputItemNamesArr: h(() => r.inputItemNamesArr),
286
+ // 工具方法
287
+ /**
288
+ * 触发表格数据响应式更新
289
+ */
290
+ triggerTableUpdate: () => {
291
+ a.value = [...a.value];
292
+ },
293
+ /**
294
+ * 判断字段是否被禁用
295
+ * @param {String} fieldName - 字段名
296
+ * @returns {Boolean} 是否禁用
297
+ */
298
+ isFieldDisabled: (g) => {
299
+ const c = r.disabledFields;
300
+ return !c || !Array.isArray(c) ? !1 : c.includes(g);
301
+ },
302
+ /**
303
+ * 判断是否可以新增行
304
+ * @returns {Boolean} 是否可以新增
305
+ */
306
+ canAddRow: () => {
307
+ if (r.disabled) return !1;
308
+ const g = r.disabledFields;
309
+ return !g || !Array.isArray(g) ? !0 : !g.includes("add");
310
+ },
311
+ /**
312
+ * 判断是否可以删除行
313
+ * @returns {Boolean} 是否可以删除
314
+ */
315
+ canDeleteRow: () => {
316
+ if (r.disabled) return !1;
317
+ const g = r.disabledFields;
318
+ return !g || !Array.isArray(g) ? !0 : !g.includes("delete");
319
+ }
320
+ };
321
+ return et(He, N), N;
322
+ }
323
+ function _e() {
324
+ const i = tt(He);
325
+ if (!i)
326
+ throw new Error(
327
+ t("COMMON_PARAMETERTABLE.ERROR_USE_PARAMETER_TABLE_CONTEXT") + t("COMMON_PARAMETERTABLE.ERROR_USE_PARAMETER_TEXT")
328
+ );
329
+ return i;
330
+ }
331
+ const _t = { class: "parameter-format-selector" }, vt = {
332
+ __name: "ParameterFormatSelector",
333
+ props: {
334
+ modelValue: {
335
+ type: String,
336
+ default: ""
337
+ },
338
+ disabled: {
339
+ type: Boolean,
340
+ default: !1
341
+ },
342
+ // 传入完整的行数据,用于编辑选项值
343
+ rowData: {
344
+ type: Object,
345
+ required: !0
346
+ }
347
+ },
348
+ emits: ["update:modelValue", "change", "optionCreated"],
349
+ setup(i, { emit: r }) {
350
+ const { t: a } = ne(), l = i, w = r, { getFieldName: f } = _e(), p = [
351
+ {
352
+ label: a("COMMON_DATA.PLACEHOLDER_SINGLE_LINE_TEXT"),
353
+ //单行文本框
354
+ value: "input",
355
+ supportTypes: ["string", "integer", "number", "boolean"]
356
+ // 通用类型都支持
357
+ },
358
+ {
359
+ label: a("COMMON_DATA.PLACEHOLDER_MULTI_LINE_TEXT"),
360
+ //多行文本框
361
+ value: "multi-input",
362
+ supportTypes: ["string", "integer", "number", "boolean"]
363
+ // 只有 string 支持多行文本
364
+ },
365
+ {
366
+ label: a("COMMON_DATA.PLACEHOLDER_CHECKBOX"),
367
+ //多选框
368
+ value: "checkbox",
369
+ supportTypes: ["string"]
370
+ // 字符串和字符串数组
371
+ },
372
+ {
373
+ label: a("COMMON_DATA.PLACEHOLDER_RADIO_BUTTON"),
374
+ //单选框
375
+ value: "radio-button",
376
+ supportTypes: ["string", "integer", "number", "boolean"]
377
+ // 只有 string 支持单选
378
+ },
379
+ {
380
+ label: a("COMMON_DATA.PLACEHOLDER_TIME_DATETIME"),
381
+ //时间日期选择器
382
+ value: "datetime",
383
+ supportTypes: ["string"]
384
+ // 时间类型
385
+ },
386
+ {
387
+ label: a("COMMON_DATA.PLACEHOLDER_IMAGE"),
388
+ //图片
389
+ value: "image",
390
+ supportTypes: ["file"]
391
+ // 图片类型
392
+ },
393
+ {
394
+ label: a("COMMON_DATA.PLACEHOLDER_FILE"),
395
+ //文件
396
+ value: "file",
397
+ supportTypes: ["file"]
398
+ // 文件类型
399
+ }
400
+ ], _ = te(l.modelValue), C = te(null), O = h(() => {
401
+ const M = l.rowData[f("type")];
402
+ return M ? p.filter((N) => N.supportTypes.includes(M)) : p;
403
+ }), m = h(() => _.value === "checkbox" || _.value === "radio-button");
404
+ pe(
405
+ () => l.modelValue,
406
+ (M) => {
407
+ _.value = M;
408
+ }
409
+ ), pe(
410
+ () => l.rowData[f("type")],
411
+ (M) => {
412
+ if (M && _.value) {
413
+ const N = p.find(
414
+ (g) => g.value === _.value
415
+ );
416
+ N && !N.supportTypes.includes(M) && (_.value = "input", w("update:modelValue", "input"), w("change", "input", l.rowData));
417
+ }
418
+ }
419
+ );
420
+ const P = () => {
421
+ w("update:modelValue", _.value), w("change", _.value, l.rowData);
422
+ }, D = () => {
423
+ C.value && C.value.showOption(l.rowData);
424
+ }, T = (M) => {
425
+ w("optionCreated", M);
426
+ };
427
+ return (M, N) => {
428
+ const g = we("IconEdit2");
429
+ return b(), W("div", _t, [
430
+ v(e(ye), {
431
+ modelValue: _.value,
432
+ "onUpdate:modelValue": N[0] || (N[0] = (c) => _.value = c),
433
+ disabled: i.disabled,
434
+ placeholder: e(a)("COMMON_DATA.PLACEHOLDER_SELECT"),
435
+ style: { width: "100%" },
436
+ onChange: P
437
+ }, {
438
+ default: A(() => [
439
+ (b(!0), W(ae, null, Ie(O.value, (c) => (b(), H(e(re), {
440
+ key: c.value,
441
+ label: c.label,
442
+ value: c.value
443
+ }, null, 8, ["label", "value"]))), 128))
444
+ ]),
445
+ _: 1
446
+ }, 8, ["modelValue", "disabled", "placeholder"]),
447
+ m.value ? (b(), H(e(Y), {
448
+ key: 0,
449
+ class: "edit-icon",
450
+ onClick: D
451
+ }, {
452
+ default: A(() => [
453
+ v(g)
454
+ ]),
455
+ _: 1
456
+ })) : $("", !0),
457
+ v(yt, {
458
+ ref_key: "optionValueDialog",
459
+ ref: C,
460
+ onCreateOption: T
461
+ }, null, 512)
462
+ ]);
463
+ };
464
+ }
465
+ }, Ot = /* @__PURE__ */ ue(vt, [["__scopeId", "data-v-acb7ffce"]]), fe = [
466
+ {
467
+ label: "String",
468
+ value: "string",
469
+ example: ""
470
+ },
471
+ {
472
+ label: "Number",
473
+ value: "number",
474
+ example: 0
475
+ },
476
+ {
477
+ label: "Integer",
478
+ value: "integer",
479
+ example: 0
480
+ },
481
+ {
482
+ label: "Boolean",
483
+ value: "boolean",
484
+ example: !1
485
+ },
486
+ {
487
+ label: "File",
488
+ value: "file",
489
+ example: ""
490
+ },
491
+ {
492
+ label: "Object",
493
+ value: "object",
494
+ example: {}
495
+ },
496
+ {
497
+ label: "Array<String>",
498
+ value: "arrayString",
499
+ example: []
500
+ },
501
+ {
502
+ label: "Array<Number>",
503
+ value: "arrayNumber",
504
+ example: []
505
+ },
506
+ {
507
+ label: "Array<Integer>",
508
+ value: "arrayInteger",
509
+ example: []
510
+ },
511
+ {
512
+ label: "Array<Boolean>",
513
+ value: "arrayBoolean",
514
+ example: []
515
+ },
516
+ {
517
+ label: "Array<File>",
518
+ value: "arrayFile",
519
+ example: []
520
+ },
521
+ {
522
+ label: "Array<Object>",
523
+ value: "arrayObject",
524
+ example: []
525
+ }
526
+ ], De = (() => {
527
+ const i = {};
528
+ return fe.forEach((r) => {
529
+ i[r.value] = r.label;
530
+ }), i;
531
+ })(), Mt = [
532
+ "arrayString",
533
+ "arrayFile",
534
+ "arrayInteger",
535
+ "arrayNumber",
536
+ "arrayObject",
537
+ "arrayBoolean",
538
+ "arrayImage"
539
+ ], hl = ["GET", "HEAD"], gl = [
540
+ {
541
+ value: "POST",
542
+ label: "POST"
543
+ },
544
+ {
545
+ value: "GET",
546
+ label: "GET"
547
+ },
548
+ {
549
+ value: "PUT",
550
+ label: "PUT"
551
+ },
552
+ {
553
+ value: "DELETE",
554
+ label: "DELETE"
555
+ },
556
+ {
557
+ value: "PATCH",
558
+ label: "PATCH"
559
+ },
560
+ {
561
+ value: "HEAD",
562
+ label: "HEAD"
563
+ }
564
+ ], se = (i) => Mt.includes(i) || i === "array", ce = (i, r) => {
565
+ const { nameField: a, typeField: l, valueField: w } = r;
566
+ if (!i.children || i.children.length === 0)
567
+ return;
568
+ const f = i[l];
569
+ if (se(f)) {
570
+ const p = [];
571
+ return i.children.forEach((_) => {
572
+ if (_.children && _.children.length > 0)
573
+ p.push(ce(_, r));
574
+ else {
575
+ const C = _[w];
576
+ let O = C !== void 0 && C !== "" ? C : "";
577
+ const m = _[l];
578
+ m === "number" || m === "integer" ? O = O === "" ? 0 : Number(O) : m === "boolean" ? O = O === "" ? !1 : !!O : m === "object" && (O = ce(_, r) || {}), p.push(O);
579
+ }
580
+ }), p;
581
+ }
582
+ if (f === "object") {
583
+ const p = {};
584
+ return i.children.forEach((_) => {
585
+ const C = _[a];
586
+ if (!(!C || C === "[Array Item]"))
587
+ if (_.children && _.children.length > 0)
588
+ p[C] = ce(_, r);
589
+ else {
590
+ const O = _[w];
591
+ let m = O !== void 0 && O !== "" ? O : "";
592
+ const P = _[l];
593
+ P === "number" || P === "integer" ? m = m === "" ? 0 : Number(m) : P === "boolean" ? m = m === "" ? !1 : !!m : P === "object" ? m = ce(_, r) || {} : se(P) && (m = ce(_, r) || []), p[C] = m;
594
+ }
595
+ }), p;
596
+ }
597
+ }, Tt = { class: "value-cell" }, ht = {
598
+ key: 2,
599
+ class: "filename-box"
600
+ }, gt = {
601
+ key: 4,
602
+ class: "filename-box"
603
+ }, bt = {
604
+ key: 1,
605
+ class: "filename-box"
606
+ }, Nt = {
607
+ key: 1,
608
+ class: "error-message"
609
+ }, Lt = {
610
+ __name: "ValueCell",
611
+ props: /* @__PURE__ */ ie({
612
+ row: {
613
+ type: Object,
614
+ required: !0
615
+ }
616
+ }, {
617
+ value: {
618
+ type: [String, Number, Boolean, Object, Array],
619
+ default: ""
620
+ },
621
+ valueModifiers: {},
622
+ type: {
623
+ type: String,
624
+ default: "string"
625
+ },
626
+ typeModifiers: {}
627
+ }),
628
+ emits: ["update:value", "update:type"],
629
+ setup(i) {
630
+ const { t: r } = ne(), a = i, l = Ee(i, "value"), w = Ee(i, "type"), f = _e(), {
631
+ isFieldDisabled: p,
632
+ props: _,
633
+ emit: C,
634
+ getFieldName: O,
635
+ validationErrors: m
636
+ } = f, P = h(() => _.isPluginMode), D = h(() => _.disabled), T = h(() => {
637
+ if (!P.value || !a.row.required) return null;
638
+ const R = a.row.uiid, y = O("value");
639
+ return m.value[R]?.[y];
640
+ }), M = h(() => !!T.value), N = h(() => D.value || a.row.disabled || p("value")), g = h(() => a.row.extendWidgetType === "file" || w.value === "file"), c = h(() => a.row[O("type")] === "image" || a.row[O("type")] === "file"), d = h(() => {
641
+ const R = a.row["extend-widget-item"];
642
+ if (!R) return [];
643
+ if (Array.isArray(R)) return R;
644
+ try {
645
+ return typeof R == "string" ? JSON.parse(R) : [];
646
+ } catch {
647
+ return [];
648
+ }
649
+ }), o = () => {
650
+ if (P.value && a.row.required) {
651
+ const R = a.row.uiid, y = O("value"), n = a.row[y];
652
+ n == null || n === "" || Array.isArray(n) && n.length === 0 || typeof n == "string" && !n.trim() ? m.value[R] = {
653
+ ...m.value[R],
654
+ [y]: r("COMMON_DATA.REQUIRED_NULL")
655
+ } : m.value[R]?.[y] && (delete m.value[R][y], Object.keys(m.value[R]).length === 0 && delete m.value[R]);
656
+ }
657
+ }, s = () => {
658
+ o(), C("debugger-data-change");
659
+ }, E = (R) => {
660
+ l.value = R, s();
661
+ }, L = () => {
662
+ l.value = "", s();
663
+ };
664
+ return (R, y) => (b(), W("div", Tt, [
665
+ !e(se)(w.value) && w.value !== "object" && w.value !== "arrayObject" ? (b(), W(ae, { key: 0 }, [
666
+ P.value ? (b(), W(ae, { key: 0 }, [
667
+ i.row.extendWidgetType === "datetime" ? (b(), H(e(at), {
668
+ key: 0,
669
+ modelValue: l.value,
670
+ "onUpdate:modelValue": y[0] || (y[0] = (n) => l.value = n),
671
+ type: "datetime",
672
+ disabled: N.value,
673
+ style: { width: "100%" },
674
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_DATETIME"),
675
+ format: "YYYY-MM-DD HH:mm:ss",
676
+ "value-format": "YYYY-MM-DD HH:mm:ss",
677
+ class: ee({ "error-input": M.value }),
678
+ onChange: s
679
+ }, null, 8, ["modelValue", "disabled", "placeholder", "class"])) : i.row.extendWidgetType === "image" && !l.value ? (b(), H(e(Ne), {
680
+ key: 1,
681
+ uploadType: e(Re).自定义,
682
+ acceptType: e(Ce)("image"),
683
+ multiple: !1,
684
+ limitSize: 1,
685
+ limitCount: 1,
686
+ warnTips: e(Le)("image"),
687
+ onOnSuccess: E
688
+ }, {
689
+ "upload-box": A(() => [
690
+ v(e(oe), {
691
+ icon: e(he),
692
+ type: "primary"
693
+ }, {
694
+ default: A(() => [
695
+ q(F(e(r)("COMMON_BUTTON.UPLOAD_IMAGE_TEXT")), 1)
696
+ ]),
697
+ _: 1
698
+ }, 8, ["icon"])
699
+ ]),
700
+ _: 1
701
+ }, 8, ["uploadType", "acceptType", "warnTips"])) : i.row.extendWidgetType === "image" && l.value ? (b(), W("div", ht, [
702
+ j("div", null, [
703
+ v(e(Pe), { content: l.value }, {
704
+ default: A(() => [
705
+ q(F(l.value.effectiveUrl), 1)
706
+ ]),
707
+ _: 1
708
+ }, 8, ["content"])
709
+ ]),
710
+ v(e(Y), {
711
+ class: "filename-icon",
712
+ onClick: L
713
+ }, {
714
+ default: A(() => [
715
+ v(e(ge))
716
+ ]),
717
+ _: 1
718
+ })
719
+ ])) : g.value && !l.value ? (b(), H(e(Ne), {
720
+ key: 3,
721
+ uploadType: e(Re).自定义,
722
+ acceptType: e(Ce)("file"),
723
+ multiple: !1,
724
+ limitSize: 1,
725
+ limitCount: 1,
726
+ warnTips: e(Le)("file"),
727
+ onOnSuccess: E
728
+ }, {
729
+ "upload-box": A(() => [
730
+ v(e(oe), {
731
+ icon: e(he),
732
+ type: "primary"
733
+ }, {
734
+ default: A(() => [
735
+ q(F(e(r)("COMMON_BUTTON.UPLOAD_FILE_TEXT")), 1)
736
+ ]),
737
+ _: 1
738
+ }, 8, ["icon"])
739
+ ]),
740
+ _: 1
741
+ }, 8, ["uploadType", "acceptType", "warnTips"])) : g.value && l.value ? (b(), W("div", gt, [
742
+ j("div", null, [
743
+ v(e(Pe), { content: l.value }, {
744
+ default: A(() => [
745
+ q(F(l.value.effectiveUrl), 1)
746
+ ]),
747
+ _: 1
748
+ }, 8, ["content"])
749
+ ]),
750
+ v(e(Y), {
751
+ class: "filename-icon",
752
+ onClick: L
753
+ }, {
754
+ default: A(() => [
755
+ v(e(ge))
756
+ ]),
757
+ _: 1
758
+ })
759
+ ])) : i.row.extendWidgetType === "checkbox" || i.row.extendWidgetType === "radio-button" ? (b(), H(e(ye), {
760
+ key: 5,
761
+ modelValue: l.value,
762
+ "onUpdate:modelValue": y[1] || (y[1] = (n) => l.value = n),
763
+ multiple: i.row.extendWidgetType === "checkbox",
764
+ style: { width: "100%" },
765
+ disabled: N.value,
766
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_SELECT"),
767
+ class: ee({ "error-select": M.value }),
768
+ onChange: s
769
+ }, {
770
+ default: A(() => [
771
+ (b(!0), W(ae, null, Ie(d.value, (n) => (b(), H(e(re), {
772
+ key: n.value,
773
+ label: n.label,
774
+ value: n.value
775
+ }, null, 8, ["label", "value"]))), 128))
776
+ ]),
777
+ _: 1
778
+ }, 8, ["modelValue", "multiple", "disabled", "placeholder", "class"])) : i.row.extendWidgetType === "multi-input" ? (b(), H(e(Z), {
779
+ key: 6,
780
+ modelValue: l.value,
781
+ "onUpdate:modelValue": y[2] || (y[2] = (n) => l.value = n),
782
+ type: "textarea",
783
+ rows: 3,
784
+ onBlur: s,
785
+ disabled: N.value,
786
+ style: { width: "100%" },
787
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_INPUT"),
788
+ class: ee({ "error-input": M.value })
789
+ }, null, 8, ["modelValue", "disabled", "placeholder", "class"])) : i.row[e(O)("type")] === "boolean" ? (b(), H(e(ye), {
790
+ key: 7,
791
+ modelValue: l.value,
792
+ "onUpdate:modelValue": y[3] || (y[3] = (n) => l.value = n),
793
+ onChange: s,
794
+ disabled: N.value,
795
+ style: { width: "100%" },
796
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_SELECT")
797
+ }, {
798
+ default: A(() => [
799
+ v(e(re), {
800
+ value: !0,
801
+ label: "true"
802
+ }),
803
+ v(e(re), {
804
+ value: !1,
805
+ label: "false"
806
+ })
807
+ ]),
808
+ _: 1
809
+ }, 8, ["modelValue", "disabled", "placeholder"])) : i.row[e(O)("type")] === "number" || i.row[e(O)("type")] === "integer" ? (b(), H(e(Z), {
810
+ key: 8,
811
+ modelValue: l.value,
812
+ "onUpdate:modelValue": y[4] || (y[4] = (n) => l.value = n),
813
+ modelModifiers: { number: !0 },
814
+ type: "number",
815
+ class: "number-input-no-spinner",
816
+ onBlur: s,
817
+ disabled: N.value,
818
+ style: { width: "100%" },
819
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_NUMBER")
820
+ }, null, 8, ["modelValue", "disabled", "placeholder"])) : (b(), H(e(Z), {
821
+ key: 9,
822
+ modelValue: l.value,
823
+ "onUpdate:modelValue": y[5] || (y[5] = (n) => l.value = n),
824
+ onBlur: s,
825
+ disabled: N.value,
826
+ style: { width: "100%" },
827
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_INPUT"),
828
+ class: ee({ "error-input": M.value })
829
+ }, null, 8, ["modelValue", "disabled", "placeholder", "class"]))
830
+ ], 64)) : (b(), W(ae, { key: 1 }, [
831
+ !l.value && c.value ? (b(), H(e(Ne), {
832
+ key: 0,
833
+ uploadType: e(Re).自定义,
834
+ acceptType: e(Ce)(i.row[e(O)("type")]),
835
+ multiple: !1,
836
+ limitSize: 1,
837
+ limitCount: 1,
838
+ warnTips: e(Le)(i.row[e(O)("type")]),
839
+ onOnSuccess: E
840
+ }, {
841
+ "upload-box": A(() => [
842
+ v(e(oe), {
843
+ icon: e(he),
844
+ type: "primary"
845
+ }, {
846
+ default: A(() => [
847
+ q(F(e(r)("COMMON_BUTTON.UPLOADING_TEXT")), 1)
848
+ ]),
849
+ _: 1
850
+ }, 8, ["icon"])
851
+ ]),
852
+ _: 1
853
+ }, 8, ["uploadType", "acceptType", "warnTips"])) : l.value && c.value ? (b(), W("div", bt, [
854
+ j("div", null, [
855
+ v(e(Pe), { content: l.value }, {
856
+ default: A(() => [
857
+ q(F(l.value.effectiveUrl), 1)
858
+ ]),
859
+ _: 1
860
+ }, 8, ["content"])
861
+ ]),
862
+ v(e(Y), {
863
+ class: "filename-icon",
864
+ onClick: L
865
+ }, {
866
+ default: A(() => [
867
+ v(e(ge))
868
+ ]),
869
+ _: 1
870
+ })
871
+ ])) : i.row[e(O)("type")] === "boolean" ? (b(), H(e(ye), {
872
+ key: 2,
873
+ modelValue: l.value,
874
+ "onUpdate:modelValue": y[6] || (y[6] = (n) => l.value = n),
875
+ onChange: s,
876
+ disabled: N.value,
877
+ style: { width: "100%" },
878
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_SELECT"),
879
+ class: ee({ "error-select": M.value })
880
+ }, {
881
+ default: A(() => [
882
+ v(e(re), {
883
+ value: !0,
884
+ label: "true"
885
+ }),
886
+ v(e(re), {
887
+ value: !1,
888
+ label: "false"
889
+ })
890
+ ]),
891
+ _: 1
892
+ }, 8, ["modelValue", "disabled", "placeholder", "class"])) : i.row[e(O)("type")] === "number" || i.row[e(O)("type")] === "integer" ? (b(), H(e(Z), {
893
+ key: 3,
894
+ modelValue: l.value,
895
+ "onUpdate:modelValue": y[7] || (y[7] = (n) => l.value = n),
896
+ modelModifiers: { number: !0 },
897
+ type: "number",
898
+ class: ee(["number-input-no-spinner", { "error-input": M.value }]),
899
+ onBlur: s,
900
+ disabled: N.value,
901
+ style: { width: "100%" },
902
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_NUMBER")
903
+ }, null, 8, ["modelValue", "class", "disabled", "placeholder"])) : (b(), H(e(Z), {
904
+ key: 4,
905
+ modelValue: l.value,
906
+ "onUpdate:modelValue": y[8] || (y[8] = (n) => l.value = n),
907
+ onBlur: s,
908
+ disabled: N.value,
909
+ style: { width: "100%" },
910
+ placeholder: e(r)("COMMON_DATA.PLACEHOLDER_INPUT"),
911
+ class: ee({ "error-input": M.value })
912
+ }, null, 8, ["modelValue", "disabled", "placeholder", "class"]))
913
+ ], 64))
914
+ ], 64)) : $("", !0),
915
+ T.value ? (b(), W("div", Nt, F(T.value), 1)) : $("", !0)
916
+ ]));
917
+ }
918
+ }, Ct = /* @__PURE__ */ ue(Lt, [["__scopeId", "data-v-36fe7764"]]), Rt = { class: "name-input-container" }, Pt = {
919
+ key: 0,
920
+ class: "array-item-display"
921
+ }, wt = {
922
+ key: 2,
923
+ class: "error-message"
924
+ }, Dt = {
925
+ __name: "NameCell",
926
+ props: /* @__PURE__ */ ie({
927
+ row: {
928
+ type: Object,
929
+ required: !0
930
+ },
931
+ arrayItemIndex: {
932
+ type: Number,
933
+ default: 1
934
+ }
935
+ }, {
936
+ name: {
937
+ type: String,
938
+ default: ""
939
+ },
940
+ nameModifiers: {}
941
+ }),
942
+ emits: /* @__PURE__ */ ie(["focus", "blur"], ["update:name"]),
943
+ setup(i, { emit: r }) {
944
+ const a = i, l = Ee(i, "name"), w = _e(), {
945
+ getFieldName: f,
946
+ getFieldValue: p,
947
+ isFieldDisabled: _,
948
+ props: C,
949
+ validationErrors: O,
950
+ focusFields: m
951
+ } = w, P = r, D = f("name"), T = h(() => p(a.row, "name") === "[Array Item]" && (!C.isDataType || C.isPluginMode)), M = h(() => C.disabled || a.row.disabled || _("name")), N = h(() => a.arrayItemIndex), g = h(() => O.value[a.row.uiid]?.[D]), c = h(() => m.value[a.row.uiid]?.[D]), d = h(() => g.value && !c.value), o = () => {
952
+ m.value[a.row.uiid] || (m.value[a.row.uiid] = {}), m.value[a.row.uiid][D] = !0, P("focus", a.row.uiid, D);
953
+ }, s = () => {
954
+ m.value[a.row.uiid] && (m.value[a.row.uiid][D] = !1), P("blur", a.row, D);
955
+ };
956
+ return (E, L) => (b(), W("div", Rt, [
957
+ T.value ? (b(), W("div", Pt, [
958
+ v(e(nt), {
959
+ type: "info",
960
+ size: "small",
961
+ class: "array-tag"
962
+ }, {
963
+ default: A(() => [
964
+ v(e(Y), null, {
965
+ default: A(() => [
966
+ v(e(ot))
967
+ ]),
968
+ _: 1
969
+ }),
970
+ q(" " + F(E.t("COMMON_PLUGIN_TOOL.LABEL_PARAM_ARRAY_ITEM")) + " " + F(N.value), 1)
971
+ ]),
972
+ _: 1
973
+ })
974
+ ])) : (b(), H(e(Z), {
975
+ key: 1,
976
+ modelValue: l.value,
977
+ "onUpdate:modelValue": L[0] || (L[0] = (R) => l.value = R),
978
+ disabled: M.value,
979
+ onFocus: o,
980
+ onBlur: s,
981
+ style: { width: "100%" },
982
+ placeholder: E.t("COMMON_PLUGIN_TOOL.LABEL_PARAM_NAME_PLACEHOLDER"),
983
+ class: ee({ "error-input": d.value })
984
+ }, null, 8, ["modelValue", "disabled", "placeholder", "class"])),
985
+ d.value ? (b(), W("div", wt, F(g.value), 1)) : $("", !0)
986
+ ]));
987
+ }
988
+ }, It = /* @__PURE__ */ ue(Dt, [["__scopeId", "data-v-526e0290"]]), Vt = { class: "type-select-container" }, Ut = { key: 1 }, Bt = {
989
+ key: 2,
990
+ class: "error-message"
991
+ }, St = {
992
+ __name: "TypeCell",
993
+ props: /* @__PURE__ */ ie({
994
+ row: {
995
+ type: Object,
996
+ required: !0
997
+ }
998
+ }, {
999
+ type: {
1000
+ type: String,
1001
+ default: "string"
1002
+ },
1003
+ typeModifiers: {}
1004
+ }),
1005
+ emits: /* @__PURE__ */ ie(["change"], ["update:type"]),
1006
+ setup(i, { emit: r }) {
1007
+ const a = i, l = Ee(i, "type"), w = r, f = _e(), {
1008
+ getFieldName: p,
1009
+ getFieldValue: _,
1010
+ isFieldDisabled: C,
1011
+ props: O,
1012
+ validationErrors: m,
1013
+ focusFields: P,
1014
+ typeList: D,
1015
+ isSingleType: T
1016
+ } = f, M = p("type");
1017
+ p("name");
1018
+ const N = h(() => !(O.justString || _(a.row, "name") === "[Array Item]" && !O.isDataType || T.value)), g = h(() => O.disabled || a.row.disabled || C("type") || a.row["extend-widget-type"] === "input" || a.row["extend-widget-type"] === "multi-input"), c = h(() => {
1019
+ const L = _(a.row, "name"), R = a.row[M];
1020
+ return L === "[Array Item]" ? De[R] || "String" : T.value && D.value.length > 0 ? D.value[0].label : O.isDataType && De[R] || "String";
1021
+ }), d = h(() => m.value[a.row.uiid]?.[M]), o = h(() => P.value[a.row.uiid]?.[M]), s = h(() => d.value && !o.value), E = () => {
1022
+ w("change", a.row);
1023
+ };
1024
+ return (L, R) => (b(), W("div", Vt, [
1025
+ N.value ? (b(), H(e(ye), {
1026
+ key: 0,
1027
+ modelValue: l.value,
1028
+ "onUpdate:modelValue": R[0] || (R[0] = (y) => l.value = y),
1029
+ "data-uiid": i.row.uiid,
1030
+ disabled: g.value,
1031
+ placeholder: "Select",
1032
+ style: { width: "100%" },
1033
+ class: ee({ "error-select": s.value }),
1034
+ onChange: E
1035
+ }, {
1036
+ default: A(() => [
1037
+ (b(!0), W(ae, null, Ie(e(D), (y) => (b(), H(e(re), {
1038
+ key: y.value,
1039
+ label: y.label,
1040
+ value: y.value
1041
+ }, null, 8, ["label", "value"]))), 128))
1042
+ ]),
1043
+ _: 1
1044
+ }, 8, ["modelValue", "data-uiid", "disabled", "class"])) : (b(), W("span", Ut, F(c.value), 1)),
1045
+ s.value ? (b(), W("div", Bt, F(d.value), 1)) : $("", !0)
1046
+ ]));
1047
+ }
1048
+ }, Ft = /* @__PURE__ */ ue(St, [["__scopeId", "data-v-210bfeea"]]), xt = {
1049
+ key: 0,
1050
+ class: "action-buttons"
1051
+ }, kt = {
1052
+ __name: "ActionCell",
1053
+ props: {
1054
+ row: {
1055
+ type: Object,
1056
+ required: !0
1057
+ },
1058
+ scope: {
1059
+ type: Object,
1060
+ required: !0
1061
+ }
1062
+ },
1063
+ emits: ["add-child", "move-up", "move-down", "delete"],
1064
+ setup(i, { emit: r }) {
1065
+ const { t: a } = ne(), l = i, w = r, f = _e(), {
1066
+ getFieldName: p,
1067
+ getFieldValue: _,
1068
+ canAddRow: C,
1069
+ canDeleteRow: O,
1070
+ props: m
1071
+ } = f, P = h(() => m.disabled), D = h(() => l.row[p("type")]), T = h(() => _(l.row, "name")), M = h(() => m.isDataType ? D.value === "object" || D.value === "arrayObject" : se(D.value) || D.value === "object"), N = h(() => m.isDataType ? D.value === "object" || D.value === "arrayObject" ? a("COMMON_ACTIONCELL.LABEL_ADD_OBJECT_PROPERTY") : a("COMMON_ACTIONCELL.LABEL_ADD_CHILD") : se(D.value) ? D.value === "arrayObject" ? a("COMMON_ACTIONCELL.LABEL_ADD_OBJECT_TO_ARRAY") : a("COMMON_ACTIONCELL.LABEL_ADD_ARRAY_ITEM") : D.value === "object" ? a("COMMON_ACTIONCELL.LABEL_ADD_PROPERTY") : a("COMMON_ACTIONCELL.LABEL_ADD_CHILD")), g = h(() => M.value && C()), c = h(() => T.value === "[Array Item]" && !m.isDataType), d = h(() => m.isDataType && T.value !== "[Array Item]"), o = h(() => l.scope._canMoveUp || !1), s = h(() => l.scope._canMoveDown || !1), E = h(() => P.value || l.row.disabled ? !1 : l.scope._showDelete && O()), L = () => {
1072
+ w("add-child", l.scope);
1073
+ }, R = () => {
1074
+ w("move-up", l.row, "up");
1075
+ }, y = () => {
1076
+ w("move-down", l.row, "down");
1077
+ }, n = () => {
1078
+ w("delete", l.scope);
1079
+ };
1080
+ return (I, V) => P.value ? $("", !0) : (b(), W("div", xt, [
1081
+ g.value ? (b(), H(e(Y), {
1082
+ key: 0,
1083
+ class: "table-form__add",
1084
+ onClick: L,
1085
+ title: N.value
1086
+ }, {
1087
+ default: A(() => [
1088
+ v(e(it))
1089
+ ]),
1090
+ _: 1
1091
+ }, 8, ["title"])) : $("", !0),
1092
+ c.value ? (b(), W(ae, { key: 1 }, [
1093
+ o.value ? (b(), H(e(Y), {
1094
+ key: 0,
1095
+ class: "table-form__action array-action",
1096
+ onClick: R,
1097
+ title: e(a)("COMMON_ACTIONCELL.LABEL_MOVE_UP")
1098
+ }, {
1099
+ default: A(() => [
1100
+ v(e(Be))
1101
+ ]),
1102
+ _: 1
1103
+ }, 8, ["title"])) : $("", !0),
1104
+ s.value ? (b(), H(e(Y), {
1105
+ key: 1,
1106
+ class: "table-form__action array-action",
1107
+ onClick: y,
1108
+ title: e(a)("COMMON_ACTIONCELL.LABEL_MOVE_DOWN")
1109
+ }, {
1110
+ default: A(() => [
1111
+ v(e(Se))
1112
+ ]),
1113
+ _: 1
1114
+ }, 8, ["title"])) : $("", !0)
1115
+ ], 64)) : $("", !0),
1116
+ d.value ? (b(), W(ae, { key: 2 }, [
1117
+ o.value ? (b(), H(e(Y), {
1118
+ key: 0,
1119
+ class: "table-form__action array-action",
1120
+ onClick: R,
1121
+ title: e(a)("COMMON_ACTIONCELL.LABEL_MOVE_UP")
1122
+ }, {
1123
+ default: A(() => [
1124
+ v(e(Be))
1125
+ ]),
1126
+ _: 1
1127
+ }, 8, ["title"])) : $("", !0),
1128
+ s.value ? (b(), H(e(Y), {
1129
+ key: 1,
1130
+ class: "table-form__action array-action",
1131
+ onClick: y,
1132
+ title: e(a)("COMMON_ACTIONCELL.LABEL_MOVE_DOWN")
1133
+ }, {
1134
+ default: A(() => [
1135
+ v(e(Se))
1136
+ ]),
1137
+ _: 1
1138
+ }, 8, ["title"])) : $("", !0)
1139
+ ], 64)) : $("", !0),
1140
+ E.value ? (b(), H(e(Y), {
1141
+ key: 3,
1142
+ class: "table-form__action",
1143
+ onClick: n,
1144
+ title: e(a)("COMMON_ACTIONCELL.LABEL_DELETE")
1145
+ }, {
1146
+ default: A(() => [
1147
+ v(e(st))
1148
+ ]),
1149
+ _: 1
1150
+ }, 8, ["title"])) : $("", !0)
1151
+ ]));
1152
+ }
1153
+ }, Ht = /* @__PURE__ */ ue(kt, [["__scopeId", "data-v-d76e5a0b"]]), jt = {
1154
+ // 参数名称列
1155
+ name: {
1156
+ get label() {
1157
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_NAME");
1158
+ },
1159
+ slot: "name",
1160
+ minWidth: 350,
1161
+ headerSlot: "keyHeader",
1162
+ required: !0
1163
+ },
1164
+ // 参数类型列
1165
+ type: {
1166
+ get label() {
1167
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_TYPE");
1168
+ },
1169
+ slot: "type",
1170
+ minWidth: 150,
1171
+ headerSlot: "typeHeader",
1172
+ required: !0
1173
+ },
1174
+ // 参数类型列(较窄,用于普通模式)
1175
+ typeNarrow: {
1176
+ get label() {
1177
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_TYPE");
1178
+ },
1179
+ slot: "type",
1180
+ minWidth: 100,
1181
+ headerSlot: "typeHeader"
1182
+ },
1183
+ // 参数描述列(必填)
1184
+ descriptionRequired: {
1185
+ get label() {
1186
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_DESC");
1187
+ },
1188
+ slot: "description",
1189
+ minWidth: 250,
1190
+ headerSlot: "descHeader",
1191
+ required: !0
1192
+ },
1193
+ // 参数描述列(非必填)
1194
+ description: {
1195
+ get label() {
1196
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_DESC");
1197
+ },
1198
+ slot: "description",
1199
+ minWidth: 150,
1200
+ headerSlot: "descHeader",
1201
+ required: !1
1202
+ },
1203
+ // 参数描述列(普通模式,较窄)
1204
+ descriptionNarrow: {
1205
+ get label() {
1206
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_DESC");
1207
+ },
1208
+ slot: "description",
1209
+ minWidth: 150
1210
+ },
1211
+ // 是否必填列
1212
+ required: {
1213
+ get label() {
1214
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_REQUIRED");
1215
+ },
1216
+ slot: "required",
1217
+ minWidth: 100
1218
+ },
1219
+ // 参数显示名列
1220
+ showName: {
1221
+ get label() {
1222
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_SHOW_NAME");
1223
+ },
1224
+ slot: "showName",
1225
+ minWidth: 200,
1226
+ headerSlot: "showNameHeader"
1227
+ },
1228
+ // 参数格式列(已注释,保留以备后用)
1229
+ // format: {
1230
+ // label: '参数格式',
1231
+ // slot: 'format',
1232
+ // minWidth: 200,
1233
+ // headerSlot: 'formatHeader'
1234
+ // },
1235
+ // 默认值列
1236
+ default: {
1237
+ get label() {
1238
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_DEFAULT_VALUE");
1239
+ },
1240
+ slot: "default",
1241
+ minWidth: 180
1242
+ },
1243
+ // 是否可见列
1244
+ isShow: {
1245
+ get label() {
1246
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_IS_SHOW");
1247
+ },
1248
+ slot: "isShow",
1249
+ minWidth: 150,
1250
+ headerSlot: "isShowHeader"
1251
+ },
1252
+ // 调试值列
1253
+ test: {
1254
+ get label() {
1255
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_TEST_VALUE");
1256
+ },
1257
+ slot: "test",
1258
+ minWidth: 180
1259
+ },
1260
+ // Mock值列(用于普通模式)
1261
+ mock: {
1262
+ get label() {
1263
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_MOCK_VALUE");
1264
+ },
1265
+ slot: "test",
1266
+ minWidth: 100
1267
+ },
1268
+ // Mock值列(较宽,用于 justString 模式)
1269
+ mockWide: {
1270
+ get label() {
1271
+ return X("COMMON_PARAMETERTABLE.ARGUMENT_PARAM_MOCK_VALUE");
1272
+ },
1273
+ slot: "test",
1274
+ minWidth: 180
1275
+ },
1276
+ // 操作列
1277
+ action: {
1278
+ get label() {
1279
+ return X("COMMON_PARAMETERTABLE.LABEL_OPERATION");
1280
+ },
1281
+ slot: "action",
1282
+ fixed: "right",
1283
+ width: 140,
1284
+ headerSlot: "actionHeader"
1285
+ }
1286
+ }, Fe = {
1287
+ // 插件模式 - 基础列
1288
+ plugin: ["name", "type", "descriptionRequired", "required", "test", "action"],
1289
+ // 插件模式 - 更多列
1290
+ pluginMore: [
1291
+ "name",
1292
+ "type",
1293
+ "descriptionRequired",
1294
+ "required",
1295
+ "showName",
1296
+ "default",
1297
+ "isShow",
1298
+ "test",
1299
+ "action"
1300
+ ],
1301
+ // 插件模式 + 数据类型模式
1302
+ pluginDataType: ["name", "type", "description", "action"],
1303
+ // 插件模式 + justString - 基础列
1304
+ pluginJustString: [
1305
+ "name",
1306
+ "descriptionRequired",
1307
+ "required",
1308
+ "test",
1309
+ "action"
1310
+ ],
1311
+ // 插件模式 + justString - 更多列
1312
+ pluginJustStringMore: [
1313
+ "name",
1314
+ "descriptionRequired",
1315
+ "required",
1316
+ "showName",
1317
+ "default",
1318
+ "isShow",
1319
+ "test",
1320
+ "action"
1321
+ ],
1322
+ // 普通模式
1323
+ normal: ["name", "typeNarrow", "mock", "action"],
1324
+ // 普通模式 + 数据类型模式
1325
+ normalDataType: ["name", "typeNarrow", "descriptionNarrow", "action"],
1326
+ // 普通模式 + justString
1327
+ normalJustString: ["name", "mockWide", "action"]
1328
+ };
1329
+ function xe(i) {
1330
+ return i.map((r) => {
1331
+ const a = jt[r];
1332
+ if (!a)
1333
+ return console.warn(`列配置 "${r}" 不存在`), null;
1334
+ const l = Object.create(Object.getPrototypeOf(a));
1335
+ return Object.defineProperties(
1336
+ l,
1337
+ Object.getOwnPropertyDescriptors(a)
1338
+ ), l;
1339
+ }).filter(Boolean);
1340
+ }
1341
+ function qt(i) {
1342
+ return i.isPluginMode && i.isDataType ? "pluginDataType" : i.justString ? i.isPluginMode ? i.showMoreColumns ? "pluginJustStringMore" : "pluginJustString" : "normalJustString" : i.isPluginMode ? i.showMoreColumns ? "pluginMore" : "plugin" : i.isDataType ? "normalDataType" : "normal";
1343
+ }
1344
+ function Wt(i) {
1345
+ return {
1346
+ columns: h(() => {
1347
+ const a = qt(i), l = Fe[a];
1348
+ return l ? xe(l) : (console.warn(`列预设 "${a}" 不存在,使用默认配置`), xe(Fe.normal));
1349
+ })
1350
+ };
1351
+ }
1352
+ function $t(i, r = null) {
1353
+ const { t: a } = ne(), {
1354
+ getFieldName: l,
1355
+ tableData: w,
1356
+ validationErrors: f,
1357
+ focusFields: p,
1358
+ isDataType: _,
1359
+ inputItemNamesArr: C
1360
+ } = i, O = (d, o, s = null) => {
1361
+ for (const E of d) {
1362
+ if (E.uiid === o)
1363
+ return s;
1364
+ if (E.children) {
1365
+ const L = O(E.children, o, E);
1366
+ if (L) return L;
1367
+ }
1368
+ }
1369
+ return null;
1370
+ }, m = (d, o) => {
1371
+ for (const s of d) {
1372
+ if (s.uiid === o)
1373
+ return d;
1374
+ if (s.children && s.children.length > 0) {
1375
+ const E = m(s.children, o);
1376
+ if (E) return E;
1377
+ }
1378
+ }
1379
+ return null;
1380
+ }, P = (d, o, s = null, E = {}) => {
1381
+ const { checkEmpty: L = !1 } = E, R = /^[a-zA-Z][a-zA-Z0-9_-]*$/, y = s || l("name");
1382
+ if (L && !d)
1383
+ return f.value[o] = {
1384
+ ...f.value[o],
1385
+ [y]: a("COMMON_PARAMETERTABLE.ERROR_PARAM_NAME_REQUIRED")
1386
+ }, !1;
1387
+ if (!d || !R.test(d))
1388
+ return f.value[o] = {
1389
+ ...f.value[o],
1390
+ [y]: a("COMMON_PARAMETERTABLE.ERROR_PARAM_NAME_INVALID")
1391
+ }, !1;
1392
+ const n = m(w.value, o);
1393
+ return n && n.find(
1394
+ (x) => x[y] === d && x.uiid !== o && x[y] !== "[Array Item]"
1395
+ ) ? (f.value[o] = {
1396
+ [y]: a(
1397
+ "COMMON_PARAMETERTABLE.ERROR_PARAM_NAME_DUPLICATE"
1398
+ )
1399
+ }, !1) : !O(w.value, o) && C.value && C.value.length > 0 && C.value.filter((k) => (k[y] || k.dataName || k.name) === d).find((k) => k.uiid !== o) ? (f.value[o] = {
1400
+ [y]: a(
1401
+ "COMMON_PARAMETERTABLE.ERROR_PARAM_NAME_DUPLICATE"
1402
+ )
1403
+ }, !1) : (f.value[o] && (delete f.value[o][y], Object.keys(f.value[o]).length === 0 && delete f.value[o]), !0);
1404
+ }, D = (d, o, s = null, E = {}) => {
1405
+ const { checkEmpty: L = !1, checkTypesMap: R = !1 } = E, y = s || l("type");
1406
+ return L && !d ? (f.value[o] = {
1407
+ ...f.value[o],
1408
+ [y]: a("COMMON_PARAMETERTABLE.ERROR_PARAM_TYPE_REQUIRED")
1409
+ // '参数类型不能为空'
1410
+ }, !1) : d === "array" ? (f.value[o] = {
1411
+ ...f.value[o],
1412
+ [y]: a("COMMON_PARAMETERTABLE.ERROR_ARRAY_TYPE_REQUIRED")
1413
+ //'请选择数组类型'
1414
+ }, !1) : R && d && !De[d] ? (f.value[o] = {
1415
+ ...f.value[o],
1416
+ [y]: a("COMMON_PARAMETERTABLE.ERROR_PARAM_TYPE_INVALID")
1417
+ // '参数类型无效'
1418
+ }, !1) : (f.value[o] && (delete f.value[o][y], Object.keys(f.value[o]).length === 0 && delete f.value[o]), !0);
1419
+ }, T = (d) => {
1420
+ if (!Array.isArray(d))
1421
+ return;
1422
+ const o = l("type");
1423
+ d.forEach((s) => {
1424
+ const E = s[o];
1425
+ E === "array" && D(E, s.uiid, o), s.children && Array.isArray(s.children) && s.children.length > 0 && T(s.children);
1426
+ });
1427
+ };
1428
+ return {
1429
+ // 方法
1430
+ validateDataName: P,
1431
+ validateDataType: D,
1432
+ validateAllDataTypes: T,
1433
+ validateAllRows: (d = !1) => {
1434
+ let o = !1;
1435
+ const s = l("name"), E = l("type"), L = l("value"), R = [];
1436
+ r && r.value && r.value.forEach((n) => {
1437
+ n.required && n.slot && R.push(n.slot);
1438
+ });
1439
+ const y = (n) => {
1440
+ Array.isArray(n) && n.forEach((I) => {
1441
+ const V = I.uiid, x = I[s], k = I[E], K = x === "[Array Item]";
1442
+ if (K || R.forEach((J) => {
1443
+ let Q = J;
1444
+ J === "name" ? Q = s : J === "type" && (Q = E);
1445
+ const z = I[Q];
1446
+ if (!z || typeof z == "string" && !z.trim()) {
1447
+ let de = a("COMMON_PARAMETERTABLE.ERROR_PARAM_REQUIRED");
1448
+ Q === s ? de = a("COMMON_PARAMETERTABLE.ERROR_PARAM_NAME_REQUIRED") : Q === E ? de = a("COMMON_PARAMETERTABLE.ERROR_PARAM_TYPE_REQUIRED") : Q === "description" && (de = a("COMMON_PARAMETERTABLE.ERROR_PARAM_DESC_REQUIRED")), f.value[V] = {
1449
+ ...f.value[V],
1450
+ [Q]: de
1451
+ }, o = !0;
1452
+ }
1453
+ }), K || P(x, V, s, {
1454
+ checkEmpty: !0
1455
+ }) || (o = !0), K || D(k, V, E, {
1456
+ checkEmpty: !0,
1457
+ checkTypesMap: _.value
1458
+ }) || (o = !0), d && !K && I.required) {
1459
+ const J = I[L];
1460
+ (!J || typeof J == "string" && !J.trim()) && (f.value[V] = {
1461
+ ...f.value[V],
1462
+ [L]: a(
1463
+ "COMMON_PARAMETERTABLE.ERROR_PARAM_TEST_VALUE_REQUIRED"
1464
+ )
1465
+ // '调试值不能为空'
1466
+ }, o = !0);
1467
+ }
1468
+ if ((k === "object" || k === "arrayObject") && I.children && Array.isArray(I.children) && I.children.length > 0) {
1469
+ const J = [];
1470
+ I.children.forEach((Q) => {
1471
+ const z = Q[s];
1472
+ z && z !== "[Array Item]" && J.includes(z) ? (f.value[Q.uiid] = {
1473
+ ...f.value[Q.uiid],
1474
+ [s]: a(
1475
+ "COMMON_PARAMETERTABLE.ERROR_PARAM_NAME_DUPLICATE"
1476
+ )
1477
+ // '参数名不能重复'
1478
+ }, o = !0) : z && z !== "[Array Item]" && J.push(z);
1479
+ }), y(I.children);
1480
+ }
1481
+ });
1482
+ };
1483
+ return y(w.value), !o;
1484
+ },
1485
+ handleFocus: (d, o) => {
1486
+ p.value[d] || (p.value[d] = {}), p.value[d][o] = !0;
1487
+ },
1488
+ handleBlur: (d, o, s, E) => {
1489
+ const L = d.uiid;
1490
+ p.value[L] && (p.value[L][o] = !1);
1491
+ const R = d[o];
1492
+ P(R, L, o), s("data-name-validate"), E();
1493
+ },
1494
+ findParentNode: O,
1495
+ getSiblings: m,
1496
+ validateDescription: (d, o) => {
1497
+ const s = d.uiid;
1498
+ o && !d.description ? f.value[s] = {
1499
+ ...f.value[s],
1500
+ description: a("COMMON_PARAMETERTABLE.ERROR_PARAM_DESC_REQUIRED")
1501
+ // '参数描述不能为空'
1502
+ } : f.value[s]?.description && delete f.value[s].description;
1503
+ }
1504
+ };
1505
+ }
1506
+ function Gt(i, r, a, l, w, f) {
1507
+ const {
1508
+ tableData: p,
1509
+ getFieldName: _,
1510
+ emit: C,
1511
+ validationErrors: O,
1512
+ tableRef: m,
1513
+ props: P,
1514
+ isJustString: D,
1515
+ disabled: T
1516
+ } = i, M = te(1), N = () => {
1517
+ p.value = [...p.value];
1518
+ }, g = () => {
1519
+ const n = r(), I = _("name"), V = _("type");
1520
+ D.value && (n[V] = "string"), p.value = [...p.value, n], M.value = p.value.length, ve(() => {
1521
+ y(), p.value.forEach((x) => {
1522
+ const k = x[I];
1523
+ k && (w(k, x.uiid, I), C("data-name-validate"));
1524
+ }), f();
1525
+ });
1526
+ }, c = (n) => {
1527
+ d(p.value, n.row.uiid), O.value[n.row.uiid] && delete O.value[n.row.uiid], N(), M.value = p.value.length, f(), C("data-name-validate");
1528
+ }, d = (n, I) => {
1529
+ for (let V = 0; V < n.length; V++) {
1530
+ if (n[V].uiid === I)
1531
+ return n.splice(V, 1), !0;
1532
+ if (n[V].children && n[V].children.length > 0 && d(n[V].children, I))
1533
+ return !0;
1534
+ }
1535
+ return !1;
1536
+ }, o = (n) => {
1537
+ const I = _("type"), x = (n.row.deep || 1) + 1, k = a(n.row[I], x);
1538
+ n.row.children ? n.row.children.push(k) : n.row.children = [k], N(), ve(() => {
1539
+ y();
1540
+ });
1541
+ }, s = (n) => {
1542
+ const I = l(p.value, n.uiid);
1543
+ return I && I.children ? I.children.findIndex((x) => x.uiid === n.uiid) > 0 : !1;
1544
+ }, E = (n) => {
1545
+ const I = l(p.value, n.uiid);
1546
+ return I && I.children ? I.children.findIndex((x) => x.uiid === n.uiid) < I.children.length - 1 : !1;
1547
+ }, L = (n, I) => {
1548
+ const V = l(p.value, n.uiid);
1549
+ if (!V || !V.children) return;
1550
+ const x = V.children.findIndex((K) => K.uiid === n.uiid);
1551
+ if (x === -1) return;
1552
+ const k = I === "up" ? x - 1 : x + 1;
1553
+ if (k >= 0 && k < V.children.length) {
1554
+ const K = V.children.splice(x, 1)[0];
1555
+ V.children.splice(k, 0, K), N();
1556
+ }
1557
+ }, R = (n) => !(T.value || n.disabled);
1558
+ function y() {
1559
+ ve(() => {
1560
+ setTimeout(() => {
1561
+ if (!m.value) return;
1562
+ let n = null;
1563
+ if (m.value.$el) {
1564
+ const I = [
1565
+ ".el-table__body-wrapper",
1566
+ ".el-scrollbar__wrap",
1567
+ ".aibox-table__body",
1568
+ ".el-table__body",
1569
+ ".table-body-wrapper",
1570
+ ".el-scrollbar__view",
1571
+ '[class*="body-wrapper"]',
1572
+ '[class*="scrollbar"]',
1573
+ '[class*="table__body"]'
1574
+ ];
1575
+ for (const V of I) {
1576
+ const x = m.value.$el.querySelectorAll(V);
1577
+ for (const k of x)
1578
+ if (k.scrollHeight > k.clientHeight) {
1579
+ n = k;
1580
+ break;
1581
+ }
1582
+ if (n) break;
1583
+ }
1584
+ }
1585
+ if (!n && m.value.$el) {
1586
+ const I = (V) => {
1587
+ if (V.scrollHeight > V.clientHeight && V.scrollHeight > 0)
1588
+ return V;
1589
+ for (const x of V.children || []) {
1590
+ const k = I(x);
1591
+ if (k) return k;
1592
+ }
1593
+ return null;
1594
+ };
1595
+ n = I(m.value.$el);
1596
+ }
1597
+ if (!n && m.value.$el && m.value.$el.scrollHeight > m.value.$el.clientHeight && (n = m.value.$el), n)
1598
+ try {
1599
+ n.scrollTo({
1600
+ top: n.scrollHeight,
1601
+ behavior: "smooth"
1602
+ });
1603
+ } catch {
1604
+ n.scrollTop = n.scrollHeight;
1605
+ }
1606
+ }, 50);
1607
+ }), C("scroll-to-bottom");
1608
+ }
1609
+ return {
1610
+ // 状态
1611
+ total: M,
1612
+ // 方法
1613
+ addNewRow: g,
1614
+ deleteLists: c,
1615
+ addLists: o,
1616
+ moveArrayItem: L,
1617
+ canMoveUp: s,
1618
+ canMoveDown: E,
1619
+ showDeleteButton: R,
1620
+ triggerTableUpdate: N
1621
+ };
1622
+ }
1623
+ function Yt(i) {
1624
+ const {
1625
+ getFieldName: r,
1626
+ getSnowFlakeId: a,
1627
+ props: l,
1628
+ typeList: w,
1629
+ isSingleType: f,
1630
+ isPluginMode: p,
1631
+ isDataType: _,
1632
+ isJustString: C,
1633
+ forceRequired: O,
1634
+ location: m
1635
+ } = i, P = (c = 1) => {
1636
+ const d = f.value ? w.value[0].value : "string", o = r("name"), s = r("type"), E = r("value"), L = {
1637
+ uiid: a(),
1638
+ [o]: "",
1639
+ [s]: d,
1640
+ [E]: "",
1641
+ description: ""
1642
+ };
1643
+ if (p.value) {
1644
+ const R = {
1645
+ required: !!O.value,
1646
+ extendName: "",
1647
+ extendWidgetType: "",
1648
+ extendDisplay: !0,
1649
+ defaultValue: ""
1650
+ };
1651
+ return _.value ? {
1652
+ ...L,
1653
+ ...R,
1654
+ deep: c
1655
+ } : {
1656
+ ...L,
1657
+ ...R
1658
+ };
1659
+ } else
1660
+ return {
1661
+ source: null,
1662
+ dataValue: "",
1663
+ ...L,
1664
+ featAttr: {
1665
+ location: m.value,
1666
+ debugValue: "",
1667
+ description: ""
1668
+ }
1669
+ };
1670
+ }, D = (c, d = 1) => {
1671
+ const o = r("name"), s = r("type"), E = {
1672
+ debugValue: "",
1673
+ description: "",
1674
+ uiid: a(),
1675
+ disabled: !1
1676
+ }, L = p.value ? {
1677
+ required: !!O.value,
1678
+ extendName: "",
1679
+ extendWidgetType: "",
1680
+ extendDisplay: !0,
1681
+ defaultValue: ""
1682
+ } : {};
1683
+ p.value && _.value && (L.deep = d);
1684
+ const R = (y) => {
1685
+ switch (y) {
1686
+ case "arrayString":
1687
+ return "string";
1688
+ case "arrayInteger":
1689
+ return "integer";
1690
+ case "arrayNumber":
1691
+ return "number";
1692
+ case "arrayBoolean":
1693
+ return "boolean";
1694
+ case "arrayImage":
1695
+ return "image";
1696
+ case "arrayFile":
1697
+ return "file";
1698
+ case "arrayObject":
1699
+ return "object";
1700
+ default:
1701
+ return l.justString, "string";
1702
+ }
1703
+ };
1704
+ if (c === "object")
1705
+ return {
1706
+ ...E,
1707
+ ...L,
1708
+ [o]: "",
1709
+ [s]: (C.value, "string")
1710
+ };
1711
+ if (c === "arrayObject")
1712
+ return _.value ? {
1713
+ ...E,
1714
+ ...L,
1715
+ [o]: "",
1716
+ [s]: "string",
1717
+ hasChildren: !1
1718
+ } : {
1719
+ ...E,
1720
+ ...L,
1721
+ [o]: "[Array Item]",
1722
+ [s]: "object",
1723
+ hasChildren: !1
1724
+ // 新创建时没有 children,后续会根据实际情况更新
1725
+ };
1726
+ {
1727
+ const y = R(c);
1728
+ return {
1729
+ ...E,
1730
+ ...L,
1731
+ [o]: "[Array Item]",
1732
+ [s]: y,
1733
+ hasChildren: !1
1734
+ // 非 object 类型的数组子项,不显示展开收起符号
1735
+ };
1736
+ }
1737
+ }, T = (c) => {
1738
+ const d = r("name"), o = r("type"), s = r("value");
1739
+ return ce(c, {
1740
+ nameField: d,
1741
+ typeField: o,
1742
+ valueField: s
1743
+ });
1744
+ }, M = (c) => {
1745
+ const d = r("type"), o = r("value");
1746
+ c.forEach((s) => {
1747
+ if (s.children && s.children.length > 0) {
1748
+ M(s.children);
1749
+ const E = s[d];
1750
+ if (se(E) || E === "object") {
1751
+ const L = T(s);
1752
+ L !== void 0 && (s[o] = L);
1753
+ }
1754
+ }
1755
+ });
1756
+ };
1757
+ return {
1758
+ createEmptyInputParam: P,
1759
+ createArrayItem: D,
1760
+ convertChildrenToDebugValue: T,
1761
+ updateParentDebugValues: M,
1762
+ debuggerChangeValue: (c, d) => {
1763
+ M(c.value), d("debugger-data-change");
1764
+ },
1765
+ changeType: (c, d, o, s, E) => {
1766
+ const L = r("type"), R = r("value"), y = c[L];
1767
+ d(y, c.uiid, L), c.children && Array.isArray(c.children) && c.children.length > 0 && o(c.children);
1768
+ const n = fe.find((V) => V.value === y), I = n ? n.example : "";
1769
+ c[R] = I, c.children && delete c.children, s(), E();
1770
+ },
1771
+ isArrayType: se
1772
+ };
1773
+ }
1774
+ function Jt(i, r, a) {
1775
+ const { t: l } = ne(), { getFieldName: w, tableData: f } = i, p = (T) => {
1776
+ T.required && (T.extendDisplay = !0), r(), a();
1777
+ }, _ = (T, M) => {
1778
+ const N = w("type");
1779
+ M["extend-widget-item"] && delete M["extend-widget-item"], (T === "checkbox" || T === "radio-button") && (M[N] = "string", M.children && delete M.children), r(), a();
1780
+ }, C = (T, M, N, g) => {
1781
+ for (const c of T) {
1782
+ if (c.uiid === M)
1783
+ return c[N] = g, !0;
1784
+ if (c.children && c.children.length > 0 && C(c.children, M, N, g))
1785
+ return !0;
1786
+ }
1787
+ return !1;
1788
+ };
1789
+ return {
1790
+ handleRequiredChange: p,
1791
+ handleFormatChange: _,
1792
+ handleOptionCreated: (T) => {
1793
+ C(
1794
+ f.value,
1795
+ T.uiid,
1796
+ "extend-widget-item",
1797
+ T.data
1798
+ ), r(), a();
1799
+ },
1800
+ parseWidgetItems: (T) => {
1801
+ if (!T) return [];
1802
+ if (Array.isArray(T)) return T;
1803
+ try {
1804
+ return typeof T == "string" ? JSON.parse(T) : [];
1805
+ } catch {
1806
+ return [];
1807
+ }
1808
+ },
1809
+ clearFiles: (T) => {
1810
+ const M = w("value");
1811
+ T[M] = "", r();
1812
+ },
1813
+ uploadSuccess: (T, M, N) => {
1814
+ rt.success(l("COMMON_PARAMETERTABLE.LABEL_UPLOAD_SUCCESS")), M[N] = T, r();
1815
+ }
1816
+ };
1817
+ }
1818
+ const Xt = {
1819
+ key: 0,
1820
+ style: { color: "red", "margin-right": "2px" }
1821
+ }, Qt = {
1822
+ key: 0,
1823
+ style: { color: "red", "margin-right": "2px" }
1824
+ }, zt = {
1825
+ key: 0,
1826
+ style: { color: "red", "margin-right": "2px" }
1827
+ }, Kt = { class: "table-header" }, Zt = { class: "header-text" }, el = { class: "tool-tip-column" }, tl = { class: "table-header" }, ll = { class: "header-text" }, al = { class: "tool-tip-column" }, nl = { class: "table-header" }, rl = { class: "header-text" }, ol = { class: "tool-tip-column" }, il = { class: "action-header" }, sl = {
1828
+ key: 0,
1829
+ class: "error-message"
1830
+ }, ul = { class: "table-form__isshow" }, dl = { class: "table-form__isshow" }, cl = {
1831
+ __name: "ParameterTable",
1832
+ props: /* @__PURE__ */ ie({
1833
+ justString: {
1834
+ type: Boolean,
1835
+ default: !1
1836
+ },
1837
+ loadingTable: {
1838
+ type: Boolean,
1839
+ default: !1
1840
+ },
1841
+ maxHeight: {
1842
+ type: Number,
1843
+ default: 300
1844
+ },
1845
+ location: {
1846
+ type: String,
1847
+ default: "params"
1848
+ },
1849
+ setType: {
1850
+ type: Array,
1851
+ default: () => []
1852
+ },
1853
+ // 区分是设置数据类型还是具体值
1854
+ isDataType: {
1855
+ type: Boolean,
1856
+ default: !1
1857
+ },
1858
+ inputItemNamesArr: {
1859
+ type: Array,
1860
+ default: () => []
1861
+ },
1862
+ // 外部控制是否可编辑
1863
+ disabled: {
1864
+ type: Boolean,
1865
+ default: !1
1866
+ },
1867
+ // 插件模式标识
1868
+ isPluginMode: {
1869
+ type: Boolean,
1870
+ default: !1
1871
+ },
1872
+ // 是否显示更多列(插件模式专用)
1873
+ showMoreColumns: {
1874
+ type: Boolean,
1875
+ default: !1
1876
+ },
1877
+ // 强制必填(默认为true且不可修改)
1878
+ forceRequired: {
1879
+ type: Boolean,
1880
+ default: !1
1881
+ },
1882
+ // 禁用字段控制,格式:['字段名', 'add', 'delete']
1883
+ // 例如:['name', 'type', 'add', 'delete'] 表示 name 和 type 字段不可编辑,且不能新增和删除
1884
+ disabledFields: {
1885
+ type: Array,
1886
+ default: () => []
1887
+ },
1888
+ customFieldName: {
1889
+ type: Object,
1890
+ default: null
1891
+ },
1892
+ getSnowFlakeId: {
1893
+ type: Function,
1894
+ default: () => () => Date.now()
1895
+ }
1896
+ }, {
1897
+ tableData: {
1898
+ default: () => []
1899
+ },
1900
+ tableDataModifiers: {}
1901
+ }),
1902
+ emits: /* @__PURE__ */ ie([
1903
+ "debugger-data-change",
1904
+ "show-option",
1905
+ "scroll-to-bottom",
1906
+ "data-name-validate",
1907
+ "name-or-type-change-value"
1908
+ ], ["update:tableData"]),
1909
+ setup(i, { expose: r, emit: a }) {
1910
+ const l = i, w = Ee(i, "tableData"), f = a, { t: p } = ne(), _ = h(() => l.setType && l.setType.length ? fe.filter((U) => l.setType.includes(U.value)) : fe), C = h(() => l.setType && l.setType.length === 1), O = te(null), m = te({}), P = te({}), D = Et({
1911
+ props: l,
1912
+ tableData: w,
1913
+ emit: f,
1914
+ getSnowFlakeId: l.getSnowFlakeId,
1915
+ typeList: _,
1916
+ isSingleType: C,
1917
+ validationErrors: m,
1918
+ focusFields: P,
1919
+ tableRef: O
1920
+ }), { canAddRow: T, canDeleteRow: M, isFieldDisabled: N, getFieldName: g } = D, { columns: c } = Wt(l), { createEmptyInputParam: d, createArrayItem: o, isArrayType: s } = Yt(D), {
1921
+ validateDataName: E,
1922
+ validateDataType: L,
1923
+ validateDescription: R,
1924
+ validateAllDataTypes: y,
1925
+ validateAllRows: n,
1926
+ handleFocus: I,
1927
+ findParentNode: V
1928
+ } = $t(D, c), x = () => {
1929
+ f("name-or-type-change-value");
1930
+ }, {
1931
+ total: k,
1932
+ addNewRow: K,
1933
+ deleteLists: J,
1934
+ addLists: Q,
1935
+ moveArrayItem: z,
1936
+ canMoveUp: de,
1937
+ canMoveDown: je,
1938
+ showDeleteButton: qe,
1939
+ triggerTableUpdate: Ve
1940
+ } = Gt(
1941
+ D,
1942
+ d,
1943
+ o,
1944
+ V,
1945
+ E,
1946
+ x
1947
+ ), {
1948
+ handleRequiredChange: We,
1949
+ handleFormatChange: $e,
1950
+ handleOptionCreated: Ge
1951
+ // parseWidgetItems, clearFiles, uploadSuccess 已移至 ValueCell 组件
1952
+ } = Jt(D, Ve, x), Me = h(() => T() || M() ? c.value : c.value.filter((B) => B.slot !== "action")), Ye = (U) => U.uiid, Je = (U) => {
1953
+ const B = V(w.value, U.uiid);
1954
+ return B && B.children ? B.children.findIndex((S) => S.uiid === U.uiid) + 1 : 1;
1955
+ }, me = (U) => Me.value && Me.value.find((u) => u.slot === U)?.required || !1, Xe = (U) => {
1956
+ const B = g("name"), u = !!U[B];
1957
+ R(U, u || me("description"));
1958
+ }, Qe = (U, B) => {
1959
+ const u = U.uiid;
1960
+ P.value[u] && (P.value[u][B] = !1);
1961
+ const S = U[B];
1962
+ E(S, u, B), f("data-name-validate"), x();
1963
+ }, ze = (U) => {
1964
+ const B = g("type"), u = g("value"), S = U[B];
1965
+ L(S, U.uiid, B), U.children && Array.isArray(U.children) && U.children.length > 0 && y(U.children);
1966
+ const G = fe.find((le) => le.value === S), Ae = G ? G.example : "";
1967
+ U[u] = Ae, U.children && delete U.children, U.hasChildren = !1, Ve(), x();
1968
+ }, Te = (U) => {
1969
+ Array.isArray(U) && U.forEach((B) => {
1970
+ const u = g("name"), S = g("type"), G = B[S], Ae = B[u], le = B.children && B.children.length > 0;
1971
+ Ae === "[Array Item]" ? (G === "object" || G === "arrayObject") && le ? (B.hasChildren = !0, Te(B.children)) : B.hasChildren = !1 : (s(G) || G === "object") && le ? (B.hasChildren = !0, Te(B.children)) : B.hasChildren = !1;
1972
+ });
1973
+ };
1974
+ return pe(
1975
+ () => w.value,
1976
+ (U) => {
1977
+ k.value = U.length, y(U), Te(U);
1978
+ },
1979
+ { immediate: !0, deep: !0 }
1980
+ ), pe(
1981
+ () => l.justString,
1982
+ (U) => {
1983
+ if (U) {
1984
+ const B = g("type"), u = (S) => {
1985
+ S.forEach((G) => {
1986
+ G[B] = "string", G.children && u(G.children);
1987
+ });
1988
+ };
1989
+ u(w.value);
1990
+ }
1991
+ },
1992
+ { immediate: !0 }
1993
+ ), pe(
1994
+ () => l.setType,
1995
+ (U) => {
1996
+ if (U && U.length === 1) {
1997
+ const B = _.value[0];
1998
+ if (B) {
1999
+ const u = g("name"), S = g("type"), G = (Ae) => {
2000
+ Ae.forEach((le) => {
2001
+ le[u] !== "[Array Item]" && (le[S] = B.value), le.children && G(le.children);
2002
+ });
2003
+ };
2004
+ G(w.value);
2005
+ }
2006
+ }
2007
+ },
2008
+ { immediate: !0 }
2009
+ ), pe(
2010
+ () => l.inputItemNamesArr,
2011
+ () => {
2012
+ Object.keys(m.value).length > 0 && ve(() => {
2013
+ n();
2014
+ });
2015
+ },
2016
+ { deep: !0 }
2017
+ ), r({
2018
+ validationErrors: m,
2019
+ validateAllRows: n
2020
+ }), (U, B) => (b(), H(e(ke), {
2021
+ ref_key: "tableRef",
2022
+ ref: O,
2023
+ columns: Me.value,
2024
+ data: w.value,
2025
+ onRowKey: Ye,
2026
+ hasPage: !1,
2027
+ total: e(k),
2028
+ "on-row-key": (u) => u.uiid,
2029
+ pages: {
2030
+ page: 1,
2031
+ size: 999
2032
+ },
2033
+ isLoading: i.loadingTable,
2034
+ "max-height": i.maxHeight,
2035
+ isSecondaryHeader: ""
2036
+ }, lt({
2037
+ keyHeader: A(() => [
2038
+ me("name") ? (b(), W("span", Xt, "*")) : $("", !0),
2039
+ q(F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_NAME")), 1)
2040
+ ]),
2041
+ typeHeader: A(() => [
2042
+ me("type") ? (b(), W("span", Qt, "*")) : $("", !0),
2043
+ q(F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_TYPE")), 1)
2044
+ ]),
2045
+ descHeader: A(() => [
2046
+ me("description") ? (b(), W("span", zt, "*")) : $("", !0),
2047
+ q(F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_DESC")), 1)
2048
+ ]),
2049
+ showNameHeader: A(() => [
2050
+ j("div", Kt, [
2051
+ j("div", Zt, F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_SHOW_NAME")), 1),
2052
+ v(e(Oe), { placement: "top" }, {
2053
+ content: A(() => [
2054
+ q(F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_SHOW_NAME_TIP")), 1)
2055
+ ]),
2056
+ default: A(() => [
2057
+ j("span", el, [
2058
+ v(e(Y), {
2059
+ class: "tool-tip-column__icon",
2060
+ size: "14px",
2061
+ color: "#999"
2062
+ }, {
2063
+ default: A(() => [
2064
+ v(e(be))
2065
+ ]),
2066
+ _: 1
2067
+ })
2068
+ ])
2069
+ ]),
2070
+ _: 1
2071
+ })
2072
+ ])
2073
+ ]),
2074
+ formatHeader: A(() => [
2075
+ j("div", tl, [
2076
+ j("div", ll, F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_FORMAT")), 1),
2077
+ v(e(Oe), { placement: "top" }, {
2078
+ content: A(() => [
2079
+ q(F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_FORMAT_TIP")), 1)
2080
+ ]),
2081
+ default: A(() => [
2082
+ j("div", al, [
2083
+ v(e(Y), {
2084
+ class: "tool-tip-column__icon",
2085
+ size: "14px",
2086
+ color: "#999"
2087
+ }, {
2088
+ default: A(() => [
2089
+ v(e(be))
2090
+ ]),
2091
+ _: 1
2092
+ })
2093
+ ])
2094
+ ]),
2095
+ _: 1
2096
+ })
2097
+ ])
2098
+ ]),
2099
+ isShowHeader: A(() => [
2100
+ j("div", nl, [
2101
+ j("div", rl, F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_VISIBLE")), 1),
2102
+ v(e(Oe), {
2103
+ placement: "top",
2104
+ "popper-style": { width: "350px" }
2105
+ }, {
2106
+ content: A(() => [
2107
+ q(F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_VISIBLE_TIP")), 1),
2108
+ B[2] || (B[2] = j("br", null, null, -1)),
2109
+ q("- " + F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_VISIBLE_INVISIBLE")), 1),
2110
+ B[3] || (B[3] = j("br", null, null, -1)),
2111
+ q("- " + F(e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_VISIBLE_INVISIBLE_DEFAULT")), 1)
2112
+ ]),
2113
+ default: A(() => [
2114
+ j("div", ol, [
2115
+ v(e(Y), {
2116
+ class: "tool-tip-column__icon",
2117
+ size: "14px",
2118
+ color: "#999"
2119
+ }, {
2120
+ default: A(() => [
2121
+ v(e(be))
2122
+ ]),
2123
+ _: 1
2124
+ })
2125
+ ])
2126
+ ]),
2127
+ _: 1
2128
+ })
2129
+ ])
2130
+ ]),
2131
+ actionHeader: A(() => [
2132
+ j("div", il, [
2133
+ j("span", null, F(e(p)("COMMON_BUTTON.OPERATION_TEXT")), 1),
2134
+ e(T)() ? (b(), H(e(oe), {
2135
+ key: 0,
2136
+ type: "primary",
2137
+ size: "small",
2138
+ onClick: e(K),
2139
+ icon: e(ut)
2140
+ }, {
2141
+ default: A(() => [
2142
+ q(F(e(p)("COMMON_BUTTON.ADD_NEW_TEXT")), 1)
2143
+ ]),
2144
+ _: 1
2145
+ }, 8, ["onClick", "icon"])) : $("", !0)
2146
+ ])
2147
+ ]),
2148
+ name: A((u) => [
2149
+ v(It, {
2150
+ name: u.row[e(g)("name")],
2151
+ "onUpdate:name": (S) => u.row[e(g)("name")] = S,
2152
+ row: u.row,
2153
+ "array-item-index": Je(u.row),
2154
+ onFocus: e(I),
2155
+ onBlur: Qe
2156
+ }, null, 8, ["name", "onUpdate:name", "row", "array-item-index", "onFocus"])
2157
+ ]),
2158
+ type: A((u) => [
2159
+ v(Ft, {
2160
+ type: u.row[e(g)("type")],
2161
+ "onUpdate:type": (S) => u.row[e(g)("type")] = S,
2162
+ row: u.row,
2163
+ onChange: ze
2164
+ }, null, 8, ["type", "onUpdate:type", "row"])
2165
+ ]),
2166
+ description: A((u) => [
2167
+ v(e(Z), {
2168
+ modelValue: u.row.description,
2169
+ "onUpdate:modelValue": (S) => u.row.description = S,
2170
+ disabled: l.disabled || u.row.disabled || e(N)("description"),
2171
+ style: { width: "100%" },
2172
+ placeholder: e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_DESC_PLACEHOLDER"),
2173
+ class: ee({
2174
+ "error-input": m.value[u.row.uiid]?.description
2175
+ }),
2176
+ onChange: (S) => e(R)(u.row, me("description")),
2177
+ onBlur: (S) => Xe(u.row)
2178
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "placeholder", "class", "onChange", "onBlur"]),
2179
+ m.value[u.row.uiid]?.description ? (b(), W("div", sl, F(m.value[u.row.uiid]?.description), 1)) : $("", !0)
2180
+ ]),
2181
+ test: A((u) => [
2182
+ v(Ct, {
2183
+ value: u.row[e(g)("value")],
2184
+ "onUpdate:value": (S) => u.row[e(g)("value")] = S,
2185
+ type: u.row[e(g)("type")],
2186
+ "onUpdate:type": (S) => u.row[e(g)("type")] = S,
2187
+ row: u.row
2188
+ }, null, 8, ["value", "onUpdate:value", "type", "onUpdate:type", "row"])
2189
+ ]),
2190
+ action: A((u) => [
2191
+ v(Ht, {
2192
+ row: u.row,
2193
+ scope: {
2194
+ ...u,
2195
+ _canMoveUp: e(de)(u.row),
2196
+ _canMoveDown: e(je)(u.row),
2197
+ _showDelete: e(qe)(u.row)
2198
+ },
2199
+ onAddChild: e(Q),
2200
+ onMoveUp: B[0] || (B[0] = (S, G) => e(z)(S, G)),
2201
+ onMoveDown: B[1] || (B[1] = (S, G) => e(z)(S, G)),
2202
+ onDelete: e(J)
2203
+ }, null, 8, ["row", "scope", "onAddChild", "onDelete"])
2204
+ ]),
2205
+ _: 2
2206
+ }, [
2207
+ l.isPluginMode ? {
2208
+ name: "required",
2209
+ fn: A((u) => [
2210
+ j("div", ul, [
2211
+ v(e(Ue), {
2212
+ modelValue: u.row.required,
2213
+ "onUpdate:modelValue": (S) => u.row.required = S,
2214
+ disabled: l.disabled || u.row.disabled || l.forceRequired || e(N)("required"),
2215
+ label: "",
2216
+ onChange: (S) => e(We)(u.row)
2217
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "onChange"])
2218
+ ])
2219
+ ]),
2220
+ key: "0"
2221
+ } : void 0,
2222
+ l.isPluginMode ? {
2223
+ name: "showName",
2224
+ fn: A((u) => [
2225
+ v(e(Z), {
2226
+ modelValue: u.row.extendName,
2227
+ "onUpdate:modelValue": (S) => u.row.extendName = S,
2228
+ disabled: l.disabled || u.row.disabled || e(N)("extendName"),
2229
+ style: { width: "100%" },
2230
+ placeholder: e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_SHOW_NAME_PLACEHOLDER")
2231
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "placeholder"])
2232
+ ]),
2233
+ key: "1"
2234
+ } : void 0,
2235
+ l.isPluginMode ? {
2236
+ name: "format",
2237
+ fn: A((u) => [
2238
+ v(Ot, {
2239
+ modelValue: u.row.extendWidgetType,
2240
+ "onUpdate:modelValue": (S) => u.row.extendWidgetType = S,
2241
+ disabled: l.disabled || u.row.disabled || e(N)("extendWidgetType"),
2242
+ "row-data": u.row,
2243
+ onChange: e($e),
2244
+ onOptionCreated: e(Ge)
2245
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "row-data", "onChange", "onOptionCreated"])
2246
+ ]),
2247
+ key: "2"
2248
+ } : void 0,
2249
+ l.isPluginMode ? {
2250
+ name: "default",
2251
+ fn: A((u) => [
2252
+ v(e(Z), {
2253
+ modelValue: u.row.defaultValue,
2254
+ "onUpdate:modelValue": (S) => u.row.defaultValue = S,
2255
+ disabled: l.disabled || u.row.disabled || e(N)("defaultValue"),
2256
+ style: { width: "100%" },
2257
+ placeholder: e(p)("COMMON_PLUGIN_TOOL.LABEL_PARAM_DEFAULT_VALUE_PLACEHOLDER")
2258
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "placeholder"])
2259
+ ]),
2260
+ key: "3"
2261
+ } : void 0,
2262
+ l.isPluginMode ? {
2263
+ name: "isShow",
2264
+ fn: A((u) => [
2265
+ j("div", dl, [
2266
+ v(e(Ue), {
2267
+ modelValue: u.row.extendDisplay,
2268
+ "onUpdate:modelValue": (S) => u.row.extendDisplay = S,
2269
+ disabled: l.disabled || u.row.disabled || u.row.required || e(N)("extendDisplay"),
2270
+ checked: u.row.required,
2271
+ label: ""
2272
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "checked"])
2273
+ ])
2274
+ ]),
2275
+ key: "4"
2276
+ } : void 0
2277
+ ]), 1032, ["columns", "data", "total", "on-row-key", "isLoading", "max-height"]));
2278
+ }
2279
+ }, pl = /* @__PURE__ */ ue(cl, [["__scopeId", "data-v-f39799d3"]]), bl = Ke(pl);
2280
+ export {
2281
+ Mt as ARRAYTYPES,
2282
+ gl as METHODSOPTIONS,
2283
+ hl as NOBODYMETHOD,
2284
+ bl as ParameterTable,
2285
+ De as TYPESMAP,
2286
+ fe as TYPESOPTIONS,
2287
+ ce as convertChildrenToDebugValue,
2288
+ bl as default,
2289
+ se as isArrayType
2290
+ };