@aspire-ui/element-component-pro 1.0.9 → 1.0.10

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.
@@ -1,4 +1,4 @@
1
- import { reactive as je, defineComponent as oe, h as ue, useSlots as Se, ref as k, computed as S, onMounted as ve, nextTick as Oe, onUnmounted as Fe, watch as J, unref as fe } from "vue";
1
+ import { reactive as je, defineComponent as oe, h as ue, useSlots as Se, ref as k, computed as F, onMounted as me, nextTick as Oe, onUnmounted as Fe, watch as J, unref as fe } from "vue";
2
2
  import { MessageBox as qe } from "element-ui";
3
3
  const we = je({});
4
4
  function Re() {
@@ -54,8 +54,8 @@ const He = /* @__PURE__ */ oe({
54
54
  load: null
55
55
  },
56
56
  emits: ["register", "fetch-success", "fetch-error", "selection-change", "row-click", "row-dblclick", "sort-change", "expand-change"],
57
- setup(i, { expose: e, emit: l }) {
58
- const t = i, n = oe({
57
+ setup(r, { expose: e, emit: l }) {
58
+ const t = r, n = oe({
59
59
  name: "EcpProTableDefaultCellRenderer",
60
60
  props: {
61
61
  column: { type: Object, required: !0 },
@@ -65,20 +65,20 @@ const He = /* @__PURE__ */ oe({
65
65
  },
66
66
  setup(o) {
67
67
  return () => {
68
- var h, P;
68
+ var h, S;
69
69
  const s = o.column;
70
70
  if (s != null && s.customRender) {
71
71
  const E = s.customRender({ text: o.value, record: o.record, index: o.index });
72
72
  return typeof E == "string" || typeof E == "number" ? ue("span", String(E)) : E;
73
73
  }
74
74
  if (s != null && s.valueEnum) {
75
- const E = ((P = (h = s.valueEnum) == null ? void 0 : h[o.value]) == null ? void 0 : P.text) ?? o.value;
75
+ const E = ((S = (h = s.valueEnum) == null ? void 0 : h[o.value]) == null ? void 0 : S.text) ?? o.value;
76
76
  return ue("span", E == null ? "" : String(E));
77
77
  }
78
78
  return ue("span", o.value == null ? "" : String(o.value));
79
79
  };
80
80
  }
81
- }), d = oe({
81
+ }), u = oe({
82
82
  name: "EcpProTableBodyCellRenderer",
83
83
  props: {
84
84
  slotRender: { type: Function, required: !0 },
@@ -94,65 +94,65 @@ const He = /* @__PURE__ */ oe({
94
94
  const s = o.slotRender, h = s == null ? void 0 : s({ column: o.column, record: o.record, index: o.index, value: o.value });
95
95
  if (((G) => G == null ? [] : Array.isArray(G) ? G.filter((te) => te != null && te !== !1 && !te.isComment) : [G])(h).length > 0)
96
96
  return h;
97
- const I = { ...o.column };
98
- return o.customRender && (I.customRender = o.customRender), o.valueEnum && (I.valueEnum = o.valueEnum), ue(n, { props: { column: I, record: o.record, index: o.index, value: o.value } });
97
+ const O = { ...o.column };
98
+ return o.customRender && (O.customRender = o.customRender), o.valueEnum && (O.valueEnum = o.valueEnum), ue(n, { props: { column: O, record: o.record, index: o.index, value: o.value } });
99
99
  };
100
100
  }
101
- }), a = Se(), f = k(), r = k(), y = k(0), O = k(t.loading ?? !1), v = k([]), x = k({}), u = k([]), F = k({}), _ = k([]), D = k(null), z = k({
101
+ }), a = Se(), f = k(), i = k(), g = k(0), z = k(t.loading ?? !1), m = k([]), P = k({}), d = k([]), x = k({}), _ = k([]), D = k(null), I = k({
102
102
  page: 1,
103
103
  pageSize: t.pagination && typeof t.pagination == "object" ? t.pagination.pageSize ?? 10 : 10,
104
104
  pageSizes: t.pagination && typeof t.pagination == "object" ? t.pagination.pageSizes ?? [10, 20, 50, 100] : [10, 20, 50, 100],
105
105
  total: 0
106
- }), { getSetting: g } = Re(), m = S(() => ({ ...g("ProTable"), ...t, ...F.value })), W = S(() => !!m.value.title || !!a.tableTitle || !!a.toolbar), b = S(() => D.value !== null ? D.value : !!t.pagination && typeof t.pagination == "object"), M = S(() => m.value.rowKey || "id"), j = S(() => new Set(_.value.map((o) => o[M.value]))), R = S(
107
- () => u.value.filter((o) => !o.hideInTable && !o.defaultHidden)
108
- ), N = S(() => {
106
+ }), { getSetting: y } = Re(), v = F(() => ({ ...y("ProTable"), ...t, ...x.value })), L = F(() => !!v.value.title || !!a.tableTitle || !!a.toolbar), b = F(() => D.value !== null ? D.value : !!t.pagination && typeof t.pagination == "object"), M = F(() => v.value.rowKey || "id"), j = F(() => new Set(_.value.map((o) => o[M.value]))), R = F(
107
+ () => d.value.filter((o) => !o.hideInTable && !o.defaultHidden)
108
+ ), N = F(() => {
109
109
  var s, h;
110
110
  let o = 0;
111
- return m.value.rowSelection && (o += Number(m.value.rowSelection.width) || 48), m.value.showIndexColumn && (o += Number((s = m.value.indexColumnProps) == null ? void 0 : s.width) || 60), m.value.actionColumn && (o += Number((h = m.value.actionColumn) == null ? void 0 : h.width) || 150), o;
112
- }), L = (o) => typeof o == "number" && o > 0, Z = S(() => R.value.filter((s) => Q(s) && L(s.width)).reduce((s, h) => s + (typeof h.width == "number" ? h.width : 0), 0)), ee = S(() => R.value.filter((s) => Q(s) && typeof s.width == "string").reduce((s, h) => s + (Number(q(h)) || 80), 0)), H = (o) => o == null ? null : typeof o == "number" ? o : parseInt(String(o).replace(/px$/i, ""), 10) || null, q = (o) => {
111
+ return v.value.rowSelection && (o += Number(v.value.rowSelection.width) || 48), v.value.showIndexColumn && (o += Number((s = v.value.indexColumnProps) == null ? void 0 : s.width) || 60), v.value.actionColumn && (o += Number((h = v.value.actionColumn) == null ? void 0 : h.width) || 150), o;
112
+ }), W = (o) => typeof o == "number" && o > 0, Z = F(() => R.value.filter((s) => Q(s) && W(s.width)).reduce((s, h) => s + (typeof h.width == "number" ? h.width : 0), 0)), ee = F(() => R.value.filter((s) => Q(s) && typeof s.width == "string").reduce((s, h) => s + (Number(q(h)) || 80), 0)), H = (o) => o == null ? null : typeof o == "number" ? o : parseInt(String(o).replace(/px$/i, ""), 10) || null, q = (o) => {
113
113
  const s = o.width;
114
- if (L(s) && Z.value > 0 && y.value > 0 && typeof s == "number") {
115
- const h = y.value - N.value - ee.value;
116
- let P = Math.floor(h * s / Z.value);
117
- const E = H(o.minWidth) ?? 60, I = H(o.maxWidth);
118
- return P = Math.max(E, P), I != null && (P = Math.min(I, P)), P;
114
+ if (W(s) && Z.value > 0 && g.value > 0 && typeof s == "number") {
115
+ const h = g.value - N.value - ee.value;
116
+ let S = Math.floor(h * s / Z.value);
117
+ const E = H(o.minWidth) ?? 60, O = H(o.maxWidth);
118
+ return S = Math.max(E, S), O != null && (S = Math.min(O, S)), S;
119
119
  }
120
120
  if (typeof s == "string") {
121
- const h = H(s) ?? 80, P = H(o.minWidth), E = H(o.maxWidth);
122
- let I = h;
123
- return P != null && (I = Math.max(P, I)), E != null && (I = Math.min(E, I)), I;
121
+ const h = H(s) ?? 80, S = H(o.minWidth), E = H(o.maxWidth);
122
+ let O = h;
123
+ return S != null && (O = Math.max(S, O)), E != null && (O = Math.min(E, O)), O;
124
124
  }
125
125
  return o.width;
126
- }, Q = (o) => o.ifShow === !1 ? !1 : typeof o.ifShow == "function" ? o.ifShow({ column: o }) : !0, U = S(() => {
126
+ }, Q = (o) => o.ifShow === !1 ? !1 : typeof o.ifShow == "function" ? o.ifShow({ column: o }) : !0, U = F(() => {
127
127
  var s;
128
- const o = (s = m.value.rowSelection) == null ? void 0 : s.getCheckboxProps;
129
- return o ? v.value.filter((h) => {
130
- var P;
131
- return !((P = o(h)) != null && P.disabled);
132
- }) : v.value;
133
- }), Y = S(() => U.value.length > 0), re = S(() => U.value.length === 0 ? !1 : U.value.every((o) => j.value.has(o[M.value]))), p = S(() => {
128
+ const o = (s = v.value.rowSelection) == null ? void 0 : s.getCheckboxProps;
129
+ return o ? m.value.filter((h) => {
130
+ var S;
131
+ return !((S = o(h)) != null && S.disabled);
132
+ }) : m.value;
133
+ }), Y = F(() => U.value.length > 0), re = F(() => U.value.length === 0 ? !1 : U.value.every((o) => j.value.has(o[M.value]))), p = F(() => {
134
134
  const o = U.value.filter((s) => j.value.has(s[M.value])).length;
135
135
  return o > 0 && o < U.value.length;
136
136
  }), $ = (o) => j.value.has(o[M.value]), T = (o) => {
137
- var s, h, P;
138
- return ((P = (h = (s = m.value.rowSelection) == null ? void 0 : s.getCheckboxProps) == null ? void 0 : h.call(s, o)) == null ? void 0 : P.disabled) ?? !1;
137
+ var s, h, S;
138
+ return ((S = (h = (s = v.value.rowSelection) == null ? void 0 : s.getCheckboxProps) == null ? void 0 : h.call(s, o)) == null ? void 0 : S.disabled) ?? !1;
139
139
  }, V = (o) => {
140
- var s, h, P;
141
- return ((P = (h = (s = m.value.rowSelection) == null ? void 0 : s.getRadioProps) == null ? void 0 : h.call(s, o)) == null ? void 0 : P.disabled) ?? !1;
140
+ var s, h, S;
141
+ return ((S = (h = (s = v.value.rowSelection) == null ? void 0 : s.getRadioProps) == null ? void 0 : h.call(s, o)) == null ? void 0 : S.disabled) ?? !1;
142
142
  }, K = () => {
143
143
  const o = _.value.map((s) => s[M.value]);
144
144
  l("selection-change", { keys: o, rows: _.value });
145
145
  }, X = (o, s) => {
146
146
  const h = o[M.value];
147
- s ? _.value = [..._.value.filter((P) => P[M.value] !== h), o] : _.value = _.value.filter((P) => P[M.value] !== h), K();
147
+ s ? _.value = [..._.value.filter((S) => S[M.value] !== h), o] : _.value = _.value.filter((S) => S[M.value] !== h), K();
148
148
  }, ne = (o) => {
149
149
  _.value = [o], K();
150
150
  }, ae = (o) => {
151
151
  if (o) {
152
- const s = new Set(_.value.map((P) => P[M.value])), h = U.value.filter((P) => !s.has(P[M.value]));
152
+ const s = new Set(_.value.map((S) => S[M.value])), h = U.value.filter((S) => !s.has(S[M.value]));
153
153
  _.value = [..._.value, ...h];
154
154
  } else {
155
- const s = new Set(v.value.map((h) => h[M.value]));
155
+ const s = new Set(m.value.map((h) => h[M.value]));
156
156
  _.value = _.value.filter((h) => !s.has(h[M.value]));
157
157
  }
158
158
  K();
@@ -160,34 +160,34 @@ const He = /* @__PURE__ */ oe({
160
160
  if (!t.api) {
161
161
  if (t.dataSource)
162
162
  return;
163
- v.value = [];
163
+ m.value = [];
164
164
  return;
165
165
  }
166
- O.value = !0;
166
+ z.value = !0;
167
167
  try {
168
- const s = m.value.fetchSetting ?? {}, h = s.pageField ?? "page", P = s.sizeField ?? "pageSize", E = s.listField ?? "list", I = s.totalField ?? "total", G = {
169
- [h]: (o == null ? void 0 : o.page) ?? z.value.page,
170
- [P]: (o == null ? void 0 : o.pageSize) ?? z.value.pageSize,
168
+ const s = v.value.fetchSetting ?? {}, h = s.pageField ?? "page", S = s.sizeField ?? "pageSize", E = s.listField ?? "list", O = s.totalField ?? "total", G = {
169
+ [h]: (o == null ? void 0 : o.page) ?? I.value.page,
170
+ [S]: (o == null ? void 0 : o.pageSize) ?? I.value.pageSize,
171
171
  ...t.searchInfo,
172
172
  ...o == null ? void 0 : o.searchInfo
173
173
  };
174
- (o == null ? void 0 : o.page) != null && (z.value.page = o.page), (o == null ? void 0 : o.pageSize) != null && (z.value.pageSize = o.pageSize);
174
+ (o == null ? void 0 : o.page) != null && (I.value.page = o.page), (o == null ? void 0 : o.pageSize) != null && (I.value.pageSize = o.pageSize);
175
175
  const te = t.beforeFetch ? t.beforeFetch(G) : G, xe = await t.api(te);
176
- x.value = xe || {};
177
- const ye = t.afterFetch ? t.afterFetch(xe) : xe, Me = ye[E] ?? ye.items ?? ye.list ?? [], Te = ye[I] ?? 0;
178
- v.value = Me, z.value.total = Te, l("fetch-success", { items: Me, total: Te });
176
+ P.value = xe || {};
177
+ const ye = t.afterFetch ? t.afterFetch(xe) : xe, Me = ye[E] ?? ye.items ?? ye.list ?? [], Te = ye[O] ?? 0;
178
+ m.value = Me, I.value.total = Te, l("fetch-success", { items: Me, total: Te });
179
179
  } catch (s) {
180
180
  l("fetch-error", s);
181
181
  } finally {
182
- O.value = !1;
182
+ z.value = !1;
183
183
  }
184
- }, ie = () => le(void 0), me = (o) => {
185
- m.value.clearSelectOnPageChange && (_.value = []), z.value.pageSize = o, z.value.page = 1, le(void 0);
184
+ }, ie = () => le(void 0), ve = (o) => {
185
+ v.value.clearSelectOnPageChange && (_.value = []), I.value.pageSize = o, I.value.page = 1, le(void 0);
186
186
  }, he = (o) => {
187
- m.value.clearSelectOnPageChange && (_.value = []), z.value.page = o, le(void 0);
188
- }, _e = (o, s, h) => l("row-click", o, h), be = (o, s, h) => l("row-dblclick", o, h), ge = ({ prop: o, order: s }) => l("sort-change", { prop: o, order: s }), pe = (o, s) => l("expand-change", o, s), de = (o) => v.value.findIndex((s) => s[M.value] === o), ce = {
187
+ v.value.clearSelectOnPageChange && (_.value = []), I.value.page = o, le(void 0);
188
+ }, _e = (o, s, h) => l("row-click", o, h), be = (o, s, h) => l("row-dblclick", o, h), ge = ({ prop: o, order: s }) => l("sort-change", { prop: o, order: s }), pe = (o, s) => l("expand-change", o, s), de = (o) => m.value.findIndex((s) => s[M.value] === o), ce = {
189
189
  setProps: (o) => {
190
- F.value = { ...F.value, ...o };
190
+ x.value = { ...x.value, ...o };
191
191
  },
192
192
  reload: (o) => le(o),
193
193
  redoHeight: () => {
@@ -195,23 +195,23 @@ const He = /* @__PURE__ */ oe({
195
195
  (s = (o = f.value) == null ? void 0 : o.doLayout) == null || s.call(o);
196
196
  },
197
197
  setLoading: (o) => {
198
- O.value = o;
198
+ z.value = o;
199
199
  },
200
- getDataSource: () => v.value,
201
- getRawDataSource: () => x.value,
200
+ getDataSource: () => m.value,
201
+ getRawDataSource: () => P.value,
202
202
  setTableData: (o) => {
203
- v.value = o ?? [];
203
+ m.value = o ?? [];
204
204
  },
205
- getColumns: () => u.value,
205
+ getColumns: () => d.value,
206
206
  setColumns: (o) => {
207
207
  if (Array.isArray(o) && o.length > 0 && typeof o[0] == "string") {
208
- const s = o, h = (t.columns ?? []).filter((E) => s.includes(E.key ?? E.dataIndex)), P = s.map((E) => h.find((I) => (I.key ?? I.dataIndex) === E)).filter(Boolean);
209
- P.length && (u.value = P);
208
+ const s = o, h = (t.columns ?? []).filter((E) => s.includes(E.key ?? E.dataIndex)), S = s.map((E) => h.find((O) => (O.key ?? O.dataIndex) === E)).filter(Boolean);
209
+ S.length && (d.value = S);
210
210
  } else
211
- u.value = o ?? [];
211
+ d.value = o ?? [];
212
212
  },
213
213
  setPagination: (o) => {
214
- o != null && o.page && (z.value.page = o.page), o != null && o.pageSize && (z.value.pageSize = o.pageSize), (o == null ? void 0 : o.total) !== void 0 && (z.value.total = o.total);
214
+ o != null && o.page && (I.value.page = o.page), o != null && o.pageSize && (I.value.pageSize = o.pageSize), (o == null ? void 0 : o.total) !== void 0 && (I.value.total = o.total);
215
215
  },
216
216
  getSelectRowKeys: () => _.value.map((o) => o[M.value]),
217
217
  getSelectRows: () => _.value,
@@ -219,147 +219,147 @@ const He = /* @__PURE__ */ oe({
219
219
  _.value = [], K();
220
220
  },
221
221
  setSelectedRowKeys: (o) => {
222
- const s = new Set(o), h = v.value.filter((P) => s.has(P[M.value]));
223
- o.forEach((P) => {
224
- h.some((E) => E[M.value] === P) || h.push({ [M.value]: P });
222
+ const s = new Set(o), h = m.value.filter((S) => s.has(S[M.value]));
223
+ o.forEach((S) => {
224
+ h.some((E) => E[M.value] === S) || h.push({ [M.value]: S });
225
225
  }), _.value = h, K();
226
226
  },
227
227
  deleteSelectRowByKey: (o) => {
228
228
  _.value = _.value.filter((s) => s[M.value] !== o), K();
229
229
  },
230
230
  updateTableData: (o, s, h) => {
231
- o < 0 || o >= v.value.length || (v.value = [...v.value], v.value[o] = { ...v.value[o], [s]: h });
231
+ o < 0 || o >= m.value.length || (m.value = [...m.value], m.value[o] = { ...m.value[o], [s]: h });
232
232
  },
233
233
  updateTableDataRecord: (o, s) => {
234
234
  const h = de(o);
235
235
  if (!(h < 0))
236
- return v.value = [...v.value], v.value[h] = { ...v.value[h], ...s }, v.value[h];
236
+ return m.value = [...m.value], m.value[h] = { ...m.value[h], ...s }, m.value[h];
237
237
  },
238
238
  deleteTableDataRecord: (o) => {
239
239
  const s = Array.isArray(o) ? o : [o], h = new Set(s);
240
- v.value = v.value.filter((P) => !h.has(P[M.value]));
240
+ m.value = m.value.filter((S) => !h.has(S[M.value]));
241
241
  },
242
242
  insertTableDataRecord: (o, s) => {
243
- const h = [...v.value];
244
- return s == null || s >= h.length ? h.push(o) : h.splice(s, 0, o), v.value = h, o;
243
+ const h = [...m.value];
244
+ return s == null || s >= h.length ? h.push(o) : h.splice(s, 0, o), m.value = h, o;
245
245
  },
246
- getPaginationRef: () => b.value ? { page: z.value.page, pageSize: Number(z.value.pageSize) || 10, total: z.value.total } : !1,
246
+ getPaginationRef: () => b.value ? { page: I.value.page, pageSize: Number(I.value.pageSize) || 10, total: I.value.total } : !1,
247
247
  getShowPagination: () => b.value,
248
248
  setShowPagination: (o) => {
249
249
  D.value = o;
250
250
  },
251
- getRowSelection: () => m.value.rowSelection,
251
+ getRowSelection: () => v.value.rowSelection,
252
252
  expandAll: () => {
253
- var P;
254
- const o = ((P = m.value.treeProps) == null ? void 0 : P.children) ?? "children", s = (E) => {
255
- const I = [];
253
+ var S;
254
+ const o = ((S = v.value.treeProps) == null ? void 0 : S.children) ?? "children", s = (E) => {
255
+ const O = [];
256
256
  return E.forEach((G) => {
257
- I.push(G);
257
+ O.push(G);
258
258
  const te = G[o];
259
- Array.isArray(te) && te.length > 0 && I.push(...s(te));
260
- }), I;
259
+ Array.isArray(te) && te.length > 0 && O.push(...s(te));
260
+ }), O;
261
261
  };
262
- s(v.value).forEach((E) => {
263
- var I, G;
264
- return (G = (I = f.value) == null ? void 0 : I.toggleRowExpansion) == null ? void 0 : G.call(I, E, !0);
262
+ s(m.value).forEach((E) => {
263
+ var O, G;
264
+ return (G = (O = f.value) == null ? void 0 : O.toggleRowExpansion) == null ? void 0 : G.call(O, E, !0);
265
265
  });
266
266
  },
267
267
  collapseAll: () => {
268
- var P;
269
- const o = ((P = m.value.treeProps) == null ? void 0 : P.children) ?? "children", s = (E) => {
270
- const I = [];
268
+ var S;
269
+ const o = ((S = v.value.treeProps) == null ? void 0 : S.children) ?? "children", s = (E) => {
270
+ const O = [];
271
271
  return E.forEach((G) => {
272
- I.push(G);
272
+ O.push(G);
273
273
  const te = G[o];
274
- Array.isArray(te) && te.length > 0 && I.push(...s(te));
275
- }), I;
274
+ Array.isArray(te) && te.length > 0 && O.push(...s(te));
275
+ }), O;
276
276
  };
277
- s(v.value).forEach((E) => {
278
- var I, G;
279
- return (G = (I = f.value) == null ? void 0 : I.toggleRowExpansion) == null ? void 0 : G.call(I, E, !1);
277
+ s(m.value).forEach((E) => {
278
+ var O, G;
279
+ return (G = (O = f.value) == null ? void 0 : O.toggleRowExpansion) == null ? void 0 : G.call(O, E, !1);
280
280
  });
281
281
  }
282
282
  };
283
283
  e(ce);
284
284
  const c = () => {
285
- u.value = [...t.columns ?? []];
285
+ d.value = [...t.columns ?? []];
286
286
  }, w = () => {
287
- t.api && m.value.immediate !== !1 ? le(void 0) : t.dataSource && (v.value = [...t.dataSource], !t.api && t.pagination !== !1 && (z.value.total = t.dataSource.length));
287
+ t.api && v.value.immediate !== !1 ? le(void 0) : t.dataSource && (m.value = [...t.dataSource], !t.api && t.pagination !== !1 && (I.value.total = t.dataSource.length));
288
288
  }, B = () => {
289
- r.value && (y.value = r.value.offsetWidth || 0);
289
+ i.value && (g.value = i.value.offsetWidth || 0);
290
290
  };
291
291
  let A = null, C = null;
292
- return ve(() => {
292
+ return me(() => {
293
293
  c(), l("register", ce), w(), typeof window < "u" && (window.addEventListener("resize", B), A = new ResizeObserver(B), Oe(() => {
294
- B(), C = r.value, C && (A == null || A.observe(C));
294
+ B(), C = i.value, C && (A == null || A.observe(C));
295
295
  }));
296
296
  }), Fe(() => {
297
297
  typeof window < "u" && (window.removeEventListener("resize", B), A && C && (A.unobserve(C), C = null));
298
298
  }), J(() => t.columns, c, { deep: !0 }), J(() => t.dataSource, () => {
299
- !t.api && t.dataSource && (v.value = [...t.dataSource]);
299
+ !t.api && t.dataSource && (m.value = [...t.dataSource]);
300
300
  }, { deep: !0 }), J(() => t.loading, (o) => {
301
- O.value = o ?? !1;
302
- }), { __sfc: !0, DefaultCellRenderer: n, BodyCellRenderer: d, props: t, emit: l, slots: a, tableRef: f, tableWrapRef: r, containerWidth: y, loading: O, innerData: v, rawDataSource: x, innerColumns: u, innerProps: F, selectedRows: _, showPaginationRef: D, pagination: z, getComponentSetting: g, effectiveProps: m, showTitleBar: W, showPagination: b, rowKeyField: M, selectedKeysSet: j, displayColumns: R, fixedColumnsWidth: N, isRatioWidth: L, totalRatio: Z, fixedDataColumnsWidth: ee, parseWidthPx: H, getColumnWidth: q, shouldShowColumn: Q, selectableRows: U, hasSelectableRows: Y, isAllCurrentPageSelected: re, isIndeterminate: p, isRowSelected: $, getCheckboxDisabled: T, getRadioDisabled: V, emitSelectionChange: K, handleCheckboxChange: X, handleRadioSelect: ne, handleSelectAll: ae, fetchData: le, handleReload: ie, handleSizeChange: me, handleCurrentChange: he, handleRowClick: _e, handleRowDblclick: be, handleSortChange: ge, handleExpandChange: pe, findRowIndex: de, tableAction: ce, syncColumns: c, loadData: w, updateContainerWidth: B, resizeObserver: A, observedEl: C };
301
+ z.value = o ?? !1;
302
+ }), { __sfc: !0, DefaultCellRenderer: n, BodyCellRenderer: u, props: t, emit: l, slots: a, tableRef: f, tableWrapRef: i, containerWidth: g, loading: z, innerData: m, rawDataSource: P, innerColumns: d, innerProps: x, selectedRows: _, showPaginationRef: D, pagination: I, getComponentSetting: y, effectiveProps: v, showTitleBar: L, showPagination: b, rowKeyField: M, selectedKeysSet: j, displayColumns: R, fixedColumnsWidth: N, isRatioWidth: W, totalRatio: Z, fixedDataColumnsWidth: ee, parseWidthPx: H, getColumnWidth: q, shouldShowColumn: Q, selectableRows: U, hasSelectableRows: Y, isAllCurrentPageSelected: re, isIndeterminate: p, isRowSelected: $, getCheckboxDisabled: T, getRadioDisabled: V, emitSelectionChange: K, handleCheckboxChange: X, handleRadioSelect: ne, handleSelectAll: ae, fetchData: le, handleReload: ie, handleSizeChange: ve, handleCurrentChange: he, handleRowClick: _e, handleRowDblclick: be, handleSortChange: ge, handleExpandChange: pe, findRowIndex: de, tableAction: ce, syncColumns: c, loadData: w, updateContainerWidth: B, resizeObserver: A, observedEl: C };
303
303
  }
304
304
  });
305
- function se(i, e, l, t, n, d, a, f) {
306
- var r = typeof i == "function" ? i.options : i;
307
- e && (r.render = e, r.staticRenderFns = l, r._compiled = !0), t && (r.functional = !0), d && (r._scopeId = "data-v-" + d);
308
- var y;
309
- if (a ? (y = function(x) {
310
- x = x || // cached call
305
+ function se(r, e, l, t, n, u, a, f) {
306
+ var i = typeof r == "function" ? r.options : r;
307
+ e && (i.render = e, i.staticRenderFns = l, i._compiled = !0), t && (i.functional = !0), u && (i._scopeId = "data-v-" + u);
308
+ var g;
309
+ if (a ? (g = function(P) {
310
+ P = P || // cached call
311
311
  this.$vnode && this.$vnode.ssrContext || // stateful
312
- this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !x && typeof __VUE_SSR_CONTEXT__ < "u" && (x = __VUE_SSR_CONTEXT__), n && n.call(this, x), x && x._registeredComponents && x._registeredComponents.add(a);
313
- }, r._ssrRegister = y) : n && (y = f ? function() {
312
+ this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext, !P && typeof __VUE_SSR_CONTEXT__ < "u" && (P = __VUE_SSR_CONTEXT__), n && n.call(this, P), P && P._registeredComponents && P._registeredComponents.add(a);
313
+ }, i._ssrRegister = g) : n && (g = f ? function() {
314
314
  n.call(
315
315
  this,
316
- (r.functional ? this.parent : this).$root.$options.shadowRoot
316
+ (i.functional ? this.parent : this).$root.$options.shadowRoot
317
317
  );
318
- } : n), y)
319
- if (r.functional) {
320
- r._injectStyles = y;
321
- var O = r.render;
322
- r.render = function(u, F) {
323
- return y.call(F), O(u, F);
318
+ } : n), g)
319
+ if (i.functional) {
320
+ i._injectStyles = g;
321
+ var z = i.render;
322
+ i.render = function(d, x) {
323
+ return g.call(x), z(d, x);
324
324
  };
325
325
  } else {
326
- var v = r.beforeCreate;
327
- r.beforeCreate = v ? [].concat(v, y) : [y];
326
+ var m = i.beforeCreate;
327
+ i.beforeCreate = m ? [].concat(m, g) : [g];
328
328
  }
329
329
  return {
330
- exports: i,
331
- options: r
330
+ exports: r,
331
+ options: i
332
332
  };
333
333
  }
334
334
  var Ge = function() {
335
- var n, d, a, f;
335
+ var n, u, a, f;
336
336
  var e = this, l = e._self._c, t = e._self._setupProxy;
337
- return l("div", { staticClass: "ecp-pro-table" }, [t.showTitleBar ? l("div", { staticClass: "ecp-pro-table__header" }, [l("div", { staticClass: "ecp-pro-table__title-wrapper" }, [l("span", { staticClass: "ecp-pro-table__title" }, [e._v(e._s(t.effectiveProps.title))]), t.effectiveProps.titleHelpMessage ? l("el-tooltip", { staticClass: "ecp-pro-table__help", attrs: { placement: "top" } }, [l("template", { slot: "content" }, [Array.isArray(t.effectiveProps.titleHelpMessage) ? l("span", e._l(t.effectiveProps.titleHelpMessage, function(r, y) {
338
- return l("div", { key: y }, [e._v(e._s(r))]);
337
+ return l("div", { staticClass: "ecp-pro-table" }, [t.showTitleBar ? l("div", { staticClass: "ecp-pro-table__header" }, [l("div", { staticClass: "ecp-pro-table__title-wrapper" }, [l("span", { staticClass: "ecp-pro-table__title" }, [e._v(e._s(t.effectiveProps.title))]), t.effectiveProps.titleHelpMessage ? l("el-tooltip", { staticClass: "ecp-pro-table__help", attrs: { placement: "top" } }, [l("template", { slot: "content" }, [Array.isArray(t.effectiveProps.titleHelpMessage) ? l("span", e._l(t.effectiveProps.titleHelpMessage, function(i, g) {
338
+ return l("div", { key: g }, [e._v(e._s(i))]);
339
339
  }), 0) : l("span", [e._v(e._s(t.effectiveProps.titleHelpMessage))])]), l("i", { staticClass: "el-icon-question" })], 2) : e._e()], 1), l("div", { staticClass: "ecp-pro-table__toolbar" }, [e._t("tableTitle"), e._t("toolbar"), e._t("toolbar-right", function() {
340
- var r;
341
- return [((r = t.effectiveProps.tableSetting) == null ? void 0 : r.redo) !== !1 ? l("el-button", { attrs: { type: "text", icon: "el-icon-refresh", size: "small" }, on: { click: t.handleReload } }, [e._v(" 刷新 ")]) : e._e()];
342
- })], 2)]) : e._e(), l("div", { directives: [{ name: "loading", rawName: "v-loading", value: t.loading, expression: "loading" }], ref: "tableWrapRef", staticClass: "ecp-pro-table__body" }, [l("el-table", e._b({ ref: "tableRef", attrs: { data: t.innerData, "row-key": t.effectiveProps.rowKey, border: t.effectiveProps.bordered, stripe: t.effectiveProps.striped, size: t.effectiveProps.size, "max-height": t.effectiveProps.maxHeight, height: t.effectiveProps.height, "default-sort": t.effectiveProps.defaultSort, "span-method": t.effectiveProps.spanMethod, "tree-props": t.effectiveProps.treeProps, "default-expand-all": t.effectiveProps.defaultExpandAll, "expand-row-keys": t.effectiveProps.expandRowKeys || [], lazy: t.effectiveProps.lazy, load: t.effectiveProps.load, "row-class-name": t.effectiveProps.rowClassName }, on: { "row-click": t.handleRowClick, "row-dblclick": t.handleRowDblclick, "sort-change": t.handleSortChange, "expand-change": t.handleExpandChange } }, "el-table", t.effectiveProps.tableProps, !1), [t.effectiveProps.rowSelection ? l("el-table-column", { attrs: { width: t.effectiveProps.rowSelection.width || 48, fixed: t.effectiveProps.rowSelection.fixed, align: "center" }, scopedSlots: e._u([{ key: "header", fn: function(r) {
340
+ var i;
341
+ return [((i = t.effectiveProps.tableSetting) == null ? void 0 : i.redo) !== !1 ? l("el-button", { attrs: { type: "text", icon: "el-icon-refresh", size: "small" }, on: { click: t.handleReload } }, [e._v(" 刷新 ")]) : e._e()];
342
+ })], 2)]) : e._e(), l("div", { directives: [{ name: "loading", rawName: "v-loading", value: t.loading, expression: "loading" }], ref: "tableWrapRef", staticClass: "ecp-pro-table__body" }, [l("el-table", e._b({ ref: "tableRef", attrs: { data: t.innerData, "row-key": t.effectiveProps.rowKey, border: t.effectiveProps.bordered, stripe: t.effectiveProps.striped, size: t.effectiveProps.size, "max-height": t.effectiveProps.maxHeight, height: t.effectiveProps.height, "default-sort": t.effectiveProps.defaultSort, "span-method": t.effectiveProps.spanMethod, "tree-props": t.effectiveProps.treeProps, "default-expand-all": t.effectiveProps.defaultExpandAll, "expand-row-keys": t.effectiveProps.expandRowKeys || [], lazy: t.effectiveProps.lazy, load: t.effectiveProps.load, "row-class-name": t.effectiveProps.rowClassName }, on: { "row-click": t.handleRowClick, "row-dblclick": t.handleRowDblclick, "sort-change": t.handleSortChange, "expand-change": t.handleExpandChange } }, "el-table", t.effectiveProps.tableProps, !1), [t.effectiveProps.rowSelection ? l("el-table-column", { attrs: { width: t.effectiveProps.rowSelection.width || 48, fixed: t.effectiveProps.rowSelection.fixed, align: "center" }, scopedSlots: e._u([{ key: "header", fn: function(i) {
343
343
  return [t.effectiveProps.rowSelection.type !== "radio" ? l("el-checkbox", { attrs: { value: t.isAllCurrentPageSelected, indeterminate: t.isIndeterminate, disabled: !t.hasSelectableRows }, on: { change: t.handleSelectAll } }) : l("span")];
344
- } }, { key: "default", fn: function(r) {
345
- var y;
346
- return [t.effectiveProps.rowSelection.type !== "radio" ? l("el-checkbox", { attrs: { value: t.isRowSelected(r.row), disabled: t.getCheckboxDisabled(r.row) }, on: { change: (O) => t.handleCheckboxChange(r.row, O) }, nativeOn: { click: function(O) {
347
- O.stopPropagation();
348
- } } }) : l("el-radio", { attrs: { value: (y = t.selectedRows[0]) == null ? void 0 : y[t.rowKeyField], label: r.row[t.rowKeyField], disabled: t.getRadioDisabled(r.row) }, on: { change: function(O) {
349
- return t.handleRadioSelect(r.row);
350
- } }, nativeOn: { click: function(O) {
351
- O.stopPropagation();
344
+ } }, { key: "default", fn: function(i) {
345
+ var g;
346
+ return [t.effectiveProps.rowSelection.type !== "radio" ? l("el-checkbox", { attrs: { value: t.isRowSelected(i.row), disabled: t.getCheckboxDisabled(i.row) }, on: { change: (z) => t.handleCheckboxChange(i.row, z) }, nativeOn: { click: function(z) {
347
+ z.stopPropagation();
348
+ } } }) : l("el-radio", { attrs: { value: (g = t.selectedRows[0]) == null ? void 0 : g[t.rowKeyField], label: i.row[t.rowKeyField], disabled: t.getRadioDisabled(i.row) }, on: { change: function(z) {
349
+ return t.handleRadioSelect(i.row);
350
+ } }, nativeOn: { click: function(z) {
351
+ z.stopPropagation();
352
352
  } } }, [l("span")])];
353
- } }], null, !1, 983730649) }) : e._e(), t.effectiveProps.showIndexColumn ? l("el-table-column", { attrs: { type: "index", label: ((n = t.effectiveProps.indexColumnProps) == null ? void 0 : n.title) || "序号", width: ((d = t.effectiveProps.indexColumnProps) == null ? void 0 : d.width) || 60, fixed: (a = t.effectiveProps.indexColumnProps) == null ? void 0 : a.fixed, align: ((f = t.effectiveProps.indexColumnProps) == null ? void 0 : f.align) || "center" } }) : e._e(), e._l(t.displayColumns, function(r) {
354
- return [t.shouldShowColumn(r) ? l("el-table-column", { key: r.dataIndex || r.key || r.title, attrs: { prop: r.dataIndex, label: r.title, width: t.getColumnWidth(r), "min-width": t.isRatioWidth(r.width) ? void 0 : r.minWidth, fixed: r.fixed, align: r.align || "left", sortable: r.sortable, formatter: r.formatter, "show-overflow-tooltip": r.ellipsis !== !1 && t.effectiveProps.ellipsis !== !1 }, scopedSlots: e._u([{ key: "header", fn: function(y) {
355
- return [r.dataIndex && e.$scopedSlots[`header-${r.dataIndex}`] ? e._t(`header-${r.dataIndex}`, null, { column: r }) : e.$scopedSlots.headerCell ? e._t("headerCell", null, { column: r }) : [l("span", [e._v(e._s(r.title))]), r.helpMessage ? l("el-tooltip", { staticClass: "ecp-pro-table__col-help", attrs: { placement: "top", effect: "dark" } }, [l("template", { slot: "content" }, [Array.isArray(r.helpMessage) ? l("span", e._l(r.helpMessage, function(O, v) {
356
- return l("div", { key: v }, [e._v(e._s(O))]);
357
- }), 0) : l("span", [e._v(e._s(r.helpMessage))])]), l("i", { staticClass: "el-icon-question" })], 2) : e._e()]];
358
- } }, { key: "default", fn: function(y) {
359
- return [r.dataIndex && e.$scopedSlots[r.dataIndex] ? e._t(r.dataIndex, null, { row: y.row, column: r, index: y.$index, value: y.row[r.dataIndex] }) : e.$scopedSlots.bodyCell ? l(t.BodyCellRenderer, { attrs: { "slot-render": e.$scopedSlots.bodyCell, column: r, record: y.row, index: y.$index, value: y.row[r.dataIndex], "custom-render": r.customRender, "value-enum": r.valueEnum } }) : l(t.DefaultCellRenderer, { attrs: { column: r, record: y.row, index: y.$index, value: y.row[r.dataIndex] } })];
353
+ } }], null, !1, 983730649) }) : e._e(), t.effectiveProps.showIndexColumn ? l("el-table-column", { attrs: { type: "index", label: ((n = t.effectiveProps.indexColumnProps) == null ? void 0 : n.title) || "序号", width: ((u = t.effectiveProps.indexColumnProps) == null ? void 0 : u.width) || 60, fixed: (a = t.effectiveProps.indexColumnProps) == null ? void 0 : a.fixed, align: ((f = t.effectiveProps.indexColumnProps) == null ? void 0 : f.align) || "center" } }) : e._e(), e._l(t.displayColumns, function(i) {
354
+ return [t.shouldShowColumn(i) ? l("el-table-column", { key: i.dataIndex || i.key || i.title, attrs: { prop: i.dataIndex, label: i.title, width: t.getColumnWidth(i), "min-width": t.isRatioWidth(i.width) ? void 0 : i.minWidth, fixed: i.fixed, align: i.align || "left", sortable: i.sortable, formatter: i.formatter, "show-overflow-tooltip": i.ellipsis !== !1 && t.effectiveProps.ellipsis !== !1 }, scopedSlots: e._u([{ key: "header", fn: function(g) {
355
+ return [i.dataIndex && e.$scopedSlots[`header-${i.dataIndex}`] ? e._t(`header-${i.dataIndex}`, null, { column: i }) : e.$scopedSlots.headerCell ? e._t("headerCell", null, { column: i }) : [l("span", [e._v(e._s(i.title))]), i.helpMessage ? l("el-tooltip", { staticClass: "ecp-pro-table__col-help", attrs: { placement: "top", effect: "dark" } }, [l("template", { slot: "content" }, [Array.isArray(i.helpMessage) ? l("span", e._l(i.helpMessage, function(z, m) {
356
+ return l("div", { key: m }, [e._v(e._s(z))]);
357
+ }), 0) : l("span", [e._v(e._s(i.helpMessage))])]), l("i", { staticClass: "el-icon-question" })], 2) : e._e()]];
358
+ } }, { key: "default", fn: function(g) {
359
+ return [i.dataIndex && e.$scopedSlots[i.dataIndex] ? e._t(i.dataIndex, null, { row: g.row, column: i, index: g.$index, value: g.row[i.dataIndex] }) : e.$scopedSlots.bodyCell ? l(t.BodyCellRenderer, { attrs: { "slot-render": e.$scopedSlots.bodyCell, column: i, record: g.row, index: g.$index, value: g.row[i.dataIndex], "custom-render": i.customRender, "value-enum": i.valueEnum } }) : l(t.DefaultCellRenderer, { attrs: { column: i, record: g.row, index: g.$index, value: g.row[i.dataIndex] } })];
360
360
  } }], null, !0) }) : e._e()];
361
- }), t.effectiveProps.actionColumn ? l("el-table-column", { attrs: { label: t.effectiveProps.actionColumn.title || "操作", width: t.effectiveProps.actionColumn.width || 150, fixed: t.effectiveProps.actionColumn.fixed || "right", align: t.effectiveProps.actionColumn.align || "center" }, scopedSlots: e._u([{ key: "default", fn: function(r) {
362
- return [e.$scopedSlots.action ? e._t("action", null, { record: r.row, column: t.effectiveProps.actionColumn, index: r.$index }) : e.$scopedSlots.bodyCell ? l(t.BodyCellRenderer, { attrs: { "slot-render": e.$scopedSlots.bodyCell, column: t.effectiveProps.actionColumn, record: r.row, index: r.$index, value: void 0, "custom-render": t.effectiveProps.actionColumn.customRender, "value-enum": t.effectiveProps.actionColumn.valueEnum } }) : e._e()];
361
+ }), t.effectiveProps.actionColumn ? l("el-table-column", { attrs: { label: t.effectiveProps.actionColumn.title || "操作", width: t.effectiveProps.actionColumn.width || 150, fixed: t.effectiveProps.actionColumn.fixed || "right", align: t.effectiveProps.actionColumn.align || "center" }, scopedSlots: e._u([{ key: "default", fn: function(i) {
362
+ return [e.$scopedSlots.action ? e._t("action", null, { record: i.row, column: t.effectiveProps.actionColumn, index: i.$index }) : e.$scopedSlots.bodyCell ? l(t.BodyCellRenderer, { attrs: { "slot-render": e.$scopedSlots.bodyCell, column: t.effectiveProps.actionColumn, record: i.row, index: i.$index, value: void 0, "custom-render": t.effectiveProps.actionColumn.customRender, "value-enum": t.effectiveProps.actionColumn.valueEnum } }) : e._e()];
363
363
  } }], null, !0) }) : e._e()], 2)], 1), t.showPagination ? l("div", { staticClass: "ecp-pro-table__pagination" }, [l("el-pagination", e._b({ attrs: { "current-page": t.pagination.page, "page-sizes": t.pagination.pageSizes, "page-size": t.pagination.pageSize, total: t.pagination.total, layout: (t.effectiveProps.pagination && typeof t.effectiveProps.pagination == "object" ? t.effectiveProps.pagination.layout : null) || "total, sizes, prev, pager, next, jumper" }, on: { "size-change": t.handleSizeChange, "current-change": t.handleCurrentChange } }, "el-pagination", t.effectiveProps.pagination && typeof t.effectiveProps.pagination == "object" && t.effectiveProps.pagination.props || {}, !1))], 1) : e._e()]);
364
364
  }, Ue = [], Je = /* @__PURE__ */ se(
365
365
  He,
@@ -371,23 +371,23 @@ var Ge = function() {
371
371
  null,
372
372
  null
373
373
  );
374
- const Ee = Je.exports, De = (i) => Array.isArray(i) ? i.length > 0 : i != null && String(i).trim() !== "", ke = (i) => Array.isArray(i) ? i.map((e) => String(e)).join(", ") : i == null ? "" : typeof i == "object" ? JSON.stringify(i) : String(i), Be = (i, e) => {
375
- if (!i)
374
+ const Ee = Je.exports, De = (r) => Array.isArray(r) ? r.length > 0 : r != null && String(r).trim() !== "", ke = (r) => Array.isArray(r) ? r.map((e) => String(e)).join(", ") : r == null ? "" : typeof r == "object" ? JSON.stringify(r) : String(r), Be = (r, e) => {
375
+ if (!r)
376
376
  return null;
377
- if (i === !0)
377
+ if (r === !0)
378
378
  return {
379
379
  content: ke(e),
380
380
  placement: "top",
381
381
  effect: "dark",
382
382
  disabled: !De(e)
383
383
  };
384
- if (typeof i == "string")
384
+ if (typeof r == "string")
385
385
  return {
386
- content: i,
386
+ content: r,
387
387
  placement: "top",
388
388
  effect: "dark"
389
389
  };
390
- const l = { ...i };
390
+ const l = { ...r };
391
391
  return Object.prototype.hasOwnProperty.call(l, "content") || (l.content = ke(e)), Object.prototype.hasOwnProperty.call(l, "placement") || (l.placement = "top"), Object.prototype.hasOwnProperty.call(l, "effect") || (l.effect = "dark"), Object.prototype.hasOwnProperty.call(l, "disabled") || (l.disabled = !De(l.content)), l;
392
392
  }, Xe = /* @__PURE__ */ oe({
393
393
  __name: "TableAction",
@@ -396,39 +396,39 @@ const Ee = Je.exports, De = (i) => Array.isArray(i) ? i.length > 0 : i != null &
396
396
  dropDownActions: { default: () => [] },
397
397
  stopButtonPropagation: { type: Boolean, default: !1 }
398
398
  },
399
- setup(i) {
400
- const e = i, l = (u) => Be(u) || {}, t = (u) => u.type ? u.type : u.color === "error" ? "danger" : u.color === "success" ? "success" : u.color === "warning" ? "warning" : "text", n = (u) => u.filter((F) => {
401
- const { ifShow: _ } = F;
402
- return typeof _ == "boolean" ? _ : typeof _ == "function" ? _(F) : !0;
403
- }), d = S(() => n(e.actions || [])), a = S(() => n(e.dropDownActions || [])), f = (u, F) => {
399
+ setup(r) {
400
+ const e = r, l = (d) => Be(d) || {}, t = (d) => d.type ? d.type : d.color === "error" ? "danger" : d.color === "success" ? "success" : d.color === "warning" ? "warning" : "text", n = (d) => d.filter((x) => {
401
+ const { ifShow: _ } = x;
402
+ return typeof _ == "boolean" ? _ : typeof _ == "function" ? _(x) : !0;
403
+ }), u = F(() => n(e.actions || [])), a = F(() => n(e.dropDownActions || [])), f = (d, x) => {
404
404
  var _;
405
- e.stopButtonPropagation && F.stopPropagation(), (_ = u.onClick) == null || _.call(u, F);
406
- }, r = (u, F) => {
407
- f(u, F);
408
- }, y = (u, F, _) => {
409
- var D, z, g, m;
410
- e.stopButtonPropagation && _.stopPropagation(), u.popConfirm && (F === "confirm" ? (z = (D = u.popConfirm).confirm) == null || z.call(D) : (m = (g = u.popConfirm).cancel) == null || m.call(g));
405
+ e.stopButtonPropagation && x.stopPropagation(), (_ = d.onClick) == null || _.call(d, x);
406
+ }, i = (d, x) => {
407
+ f(d, x);
408
+ }, g = (d, x, _) => {
409
+ var D, I, y, v;
410
+ e.stopButtonPropagation && _.stopPropagation(), d.popConfirm && (x === "confirm" ? (I = (D = d.popConfirm).confirm) == null || I.call(D) : (v = (y = d.popConfirm).cancel) == null || v.call(y));
411
411
  };
412
- return { __sfc: !0, props: e, normalizeTooltip: l, getButtonType: t, filterVisible: n, visibleActions: d, visibleDropDownActions: a, handleClick: f, handleActionClick: r, handlePopConfirm: y, handlePopConfirmConfirm: (u, F) => {
413
- y(u, "confirm", F);
414
- }, handlePopConfirmCancel: (u, F) => {
415
- y(u, "cancel", F);
416
- }, handleDropdownCommand: (u) => {
412
+ return { __sfc: !0, props: e, normalizeTooltip: l, getButtonType: t, filterVisible: n, visibleActions: u, visibleDropDownActions: a, handleClick: f, handleActionClick: i, handlePopConfirm: g, handlePopConfirmConfirm: (d, x) => {
413
+ g(d, "confirm", x);
414
+ }, handlePopConfirmCancel: (d, x) => {
415
+ g(d, "cancel", x);
416
+ }, handleDropdownCommand: (d) => {
417
417
  var D;
418
- const F = Number(u), _ = a.value[F];
418
+ const x = Number(d), _ = a.value[x];
419
419
  if (!(!_ || _.disabled)) {
420
420
  if (_.popConfirm) {
421
- const z = _.popConfirm.title, g = _.popConfirm.okText || "确定", m = _.popConfirm.cancelText || "取消";
422
- qe.confirm(z, "提示", {
423
- confirmButtonText: g,
424
- cancelButtonText: m,
421
+ const I = _.popConfirm.title, y = _.popConfirm.okText || "确定", v = _.popConfirm.cancelText || "取消";
422
+ qe.confirm(I, "提示", {
423
+ confirmButtonText: y,
424
+ cancelButtonText: v,
425
425
  type: "warning"
426
426
  }).then(() => {
427
- var W, b;
428
- return (b = (W = _.popConfirm) == null ? void 0 : W.confirm) == null ? void 0 : b.call(W);
427
+ var L, b;
428
+ return (b = (L = _.popConfirm) == null ? void 0 : L.confirm) == null ? void 0 : b.call(L);
429
429
  }).catch(() => {
430
- var W, b;
431
- return (b = (W = _.popConfirm) == null ? void 0 : W.cancel) == null ? void 0 : b.call(W);
430
+ var L, b;
431
+ return (b = (L = _.popConfirm) == null ? void 0 : L.cancel) == null ? void 0 : b.call(L);
432
432
  });
433
433
  return;
434
434
  }
@@ -439,8 +439,8 @@ const Ee = Je.exports, De = (i) => Array.isArray(i) ? i.length > 0 : i != null &
439
439
  });
440
440
  var Ze = function() {
441
441
  var e = this, l = e._self._c, t = e._self._setupProxy;
442
- return l("div", { staticClass: "ecp-table-action" }, [e._l(t.visibleActions, function(n, d) {
443
- return l("span", { key: `action-${d}`, staticClass: "ecp-table-action__item" }, [n.popConfirm ? l("el-popconfirm", { attrs: { title: n.popConfirm.title, "confirm-button-text": n.popConfirm.okText || "确定", "cancel-button-text": n.popConfirm.cancelText || "取消" }, on: { confirm: function(a) {
442
+ return l("div", { staticClass: "ecp-table-action" }, [e._l(t.visibleActions, function(n, u) {
443
+ return l("span", { key: `action-${u}`, staticClass: "ecp-table-action__item" }, [n.popConfirm ? l("el-popconfirm", { attrs: { title: n.popConfirm.title, "confirm-button-text": n.popConfirm.okText || "确定", "cancel-button-text": n.popConfirm.cancelText || "取消" }, on: { confirm: function(a) {
444
444
  return t.handlePopConfirmConfirm(n, a);
445
445
  }, cancel: function(a) {
446
446
  return t.handlePopConfirmCancel(n, a);
@@ -449,8 +449,8 @@ var Ze = function() {
449
449
  } } }, "el-button", n.props, !1), [n.icon ? l("i", { class: ["ecp-table-action__icon", n.icon] }) : e._e(), l("span", [e._v(e._s(n.label))])])], 1)], 1)]) : l(n.tooltip ? "el-tooltip" : "span", e._b({ tag: "component" }, "component", n.tooltip ? t.normalizeTooltip(n.tooltip) : {}, !1), [l("el-button", e._b({ attrs: { type: t.getButtonType(n), size: "small", disabled: n.disabled }, on: { click: function(a) {
450
450
  return t.handleActionClick(n, a);
451
451
  } } }, "el-button", n.props, !1), [n.icon ? l("i", { class: ["ecp-table-action__icon", n.icon] }) : e._e(), l("span", [e._v(e._s(n.label))])])], 1), n.divider ? l("el-divider", { attrs: { direction: "vertical" } }) : e._e()], 1);
452
- }), t.visibleDropDownActions.length ? l("el-dropdown", { attrs: { trigger: "click" }, on: { command: t.handleDropdownCommand } }, [l("span", { staticClass: "ecp-table-action__more" }, [l("el-button", { attrs: { type: "text", size: "small" } }, [e._v(" 更多"), l("i", { staticClass: "el-icon-arrow-down el-icon--right" })])], 1), l("el-dropdown-menu", { attrs: { slot: "dropdown" }, slot: "dropdown" }, e._l(t.visibleDropDownActions, function(n, d) {
453
- return l("el-dropdown-item", { key: `dropdown-${d}`, attrs: { command: d, disabled: n.disabled, divided: !!n.divider } }, [l("span", { staticClass: "ecp-table-action__dropdown-item" }, [n.icon ? l("i", { class: ["ecp-table-action__icon", n.icon] }) : e._e(), l("span", [e._v(e._s(n.label))])])]);
452
+ }), t.visibleDropDownActions.length ? l("el-dropdown", { attrs: { trigger: "click" }, on: { command: t.handleDropdownCommand } }, [l("span", { staticClass: "ecp-table-action__more" }, [l("el-button", { attrs: { type: "text", size: "small" } }, [e._v(" 更多"), l("i", { staticClass: "el-icon-arrow-down el-icon--right" })])], 1), l("el-dropdown-menu", { attrs: { slot: "dropdown" }, slot: "dropdown" }, e._l(t.visibleDropDownActions, function(n, u) {
453
+ return l("el-dropdown-item", { key: `dropdown-${u}`, attrs: { command: u, disabled: n.disabled, divided: !!n.divider } }, [l("span", { staticClass: "ecp-table-action__dropdown-item" }, [n.icon ? l("i", { class: ["ecp-table-action__icon", n.icon] }) : e._e(), l("span", [e._v(e._s(n.label))])])]);
454
454
  }), 1)], 1) : e._e()], 2);
455
455
  }, Qe = [], Ye = /* @__PURE__ */ se(
456
456
  Xe,
@@ -463,8 +463,8 @@ var Ze = function() {
463
463
  null
464
464
  );
465
465
  const Ne = Ye.exports;
466
- function Et(i) {
467
- const e = k(null), l = () => i ? fe(i) : void 0, t = () => {
466
+ function Nt(r) {
467
+ const e = k(null), l = () => r ? fe(r) : void 0, t = () => {
468
468
  const a = fe(e);
469
469
  if (!a)
470
470
  throw new Error("ProTable instance has not been registered");
@@ -474,7 +474,7 @@ function Et(i) {
474
474
  const f = l();
475
475
  f && Object.keys(f).length > 0 && a.setProps(f);
476
476
  };
477
- return i && J(
477
+ return r && J(
478
478
  () => l(),
479
479
  (a) => {
480
480
  a && e.value && e.value.setProps(a);
@@ -496,7 +496,7 @@ function Et(i) {
496
496
  clearSelectedRowKeys: () => t().clearSelectedRowKeys(),
497
497
  setSelectedRowKeys: (a) => t().setSelectedRowKeys(a),
498
498
  deleteSelectRowByKey: (a) => t().deleteSelectRowByKey(a),
499
- updateTableData: (a, f, r) => t().updateTableData(a, f, r),
499
+ updateTableData: (a, f, i) => t().updateTableData(a, f, i),
500
500
  updateTableDataRecord: (a, f) => t().updateTableDataRecord(a, f),
501
501
  deleteTableDataRecord: (a) => t().deleteTableDataRecord(a),
502
502
  insertTableDataRecord: (a, f) => t().insertTableDataRecord(a, f),
@@ -530,19 +530,19 @@ const et = /* @__PURE__ */ oe({
530
530
  multiple: { type: Boolean }
531
531
  },
532
532
  emits: ["input"],
533
- setup(i) {
534
- const e = i, l = k(!1), t = k([]), n = (a) => {
535
- e.lazy && a && d();
536
- }, d = async () => {
533
+ setup(r) {
534
+ const e = r, l = k(!1), t = k([]), n = (a) => {
535
+ e.lazy && a && u();
536
+ }, u = async () => {
537
537
  if (e.api) {
538
538
  l.value = !0;
539
539
  try {
540
- const a = await e.api(e.params), f = Array.isArray(a) ? a : (a == null ? void 0 : a.list) ?? (a == null ? void 0 : a.data) ?? [], r = e.labelField ?? "label", y = e.valueField ?? "value";
541
- t.value = f.map((O) => {
542
- const v = O;
540
+ const a = await e.api(e.params), f = Array.isArray(a) ? a : (a == null ? void 0 : a.list) ?? (a == null ? void 0 : a.data) ?? [], i = e.labelField ?? "label", g = e.valueField ?? "value";
541
+ t.value = f.map((z) => {
542
+ const m = z;
543
543
  return {
544
- label: String(v[r] ?? v.label ?? ""),
545
- value: v[y] ?? v.value
544
+ label: String(m[i] ?? m.label ?? ""),
545
+ value: m[g] ?? m.value
546
546
  };
547
547
  });
548
548
  } finally {
@@ -550,17 +550,17 @@ const et = /* @__PURE__ */ oe({
550
550
  }
551
551
  }
552
552
  };
553
- return ve(() => {
554
- e.lazy || d();
553
+ return me(() => {
554
+ e.lazy || u();
555
555
  }), J(
556
556
  () => e.api,
557
557
  () => {
558
- e.lazy ? t.value = [] : d();
558
+ e.lazy ? t.value = [] : u();
559
559
  },
560
560
  { deep: !0 }
561
561
  ), J(() => e.params, () => {
562
- e.lazy ? t.value = [] : d();
563
- }, { deep: !0 }), { __sfc: !0, props: e, loading: l, options: t, onVisibleChange: n, fetchOptions: d };
562
+ e.lazy ? t.value = [] : u();
563
+ }, { deep: !0 }), { __sfc: !0, props: e, loading: l, options: t, onVisibleChange: n, fetchOptions: u };
564
564
  }
565
565
  });
566
566
  var tt = function() {
@@ -581,78 +581,98 @@ var tt = function() {
581
581
  null
582
582
  );
583
583
  const nt = ot.exports;
584
- function $e(i) {
585
- const e = i.trim();
584
+ function $e(r) {
585
+ const e = r.trim();
586
586
  if (!e)
587
587
  return "";
588
588
  let l = 0, t = "";
589
589
  e[0] === "-" && (t = "-", l = 1);
590
590
  let n = !1;
591
591
  for (; l < e.length; l++) {
592
- const d = e[l];
593
- if (d >= "0" && d <= "9") {
594
- t += d;
592
+ const u = e[l];
593
+ if (u >= "0" && u <= "9") {
594
+ t += u;
595
595
  continue;
596
596
  }
597
- d === "." && !n && (n = !0, (t === "" || t === "-") && (t += "0"), t += ".");
597
+ u === "." && !n && (n = !0, (t === "" || t === "-") && (t += "0"), t += ".");
598
598
  }
599
599
  return t;
600
600
  }
601
- function Pe(i) {
602
- return i.replace(/,/g, "").trim();
601
+ function Pe(r) {
602
+ return r.replace(/,/g, "").trim();
603
603
  }
604
- function at(i, e) {
605
- const l = Math.pow(10, i) - 1;
604
+ function at(r, e, l) {
605
+ if (!r || r === "-")
606
+ return r;
607
+ const t = r[0] === "-";
608
+ let n = t ? r.slice(1) : r;
609
+ const u = n.indexOf(".");
610
+ if (u === -1) {
611
+ const z = Math.max(0, e);
612
+ return n = z > 0 ? n.slice(0, z) : n, t ? "-" + n : n;
613
+ }
614
+ let a = n.slice(0, u);
615
+ e > 0 && (a = a.slice(0, e));
616
+ const f = n.slice(u + 1), i = f === "" && n.endsWith(".");
617
+ if (l <= 0)
618
+ return t ? "-" + a : a;
619
+ if (i)
620
+ return (t ? "-" : "") + a + ".";
621
+ const g = f.slice(0, l);
622
+ return (t ? "-" : "") + a + "." + g;
623
+ }
624
+ function st(r, e) {
625
+ const l = Math.pow(10, r) - 1;
606
626
  return e <= 0 ? l : l + (1 - Math.pow(10, -e));
607
627
  }
608
- function ze(i, e, l) {
609
- const t = at(e, l), n = i < 0 ? -1 : 1;
610
- return Math.abs(i) <= t ? i : n * t;
628
+ function ze(r, e, l) {
629
+ const t = st(e, l), n = r < 0 ? -1 : 1;
630
+ return Math.abs(r) <= t ? r : n * t;
611
631
  }
612
- function st(i, e, l) {
632
+ function rt(r, e, l) {
613
633
  if (e <= 0)
614
634
  switch (l) {
615
635
  case "floor":
616
- return Math.floor(i);
636
+ return Math.floor(r);
617
637
  case "ceil":
618
- return Math.ceil(i);
638
+ return Math.ceil(r);
619
639
  default:
620
- return Math.round(i);
640
+ return Math.round(r);
621
641
  }
622
- const t = Math.pow(10, e), n = i * t;
623
- let d;
642
+ const t = Math.pow(10, e), n = r * t;
643
+ let u;
624
644
  switch (l) {
625
645
  case "floor":
626
- d = Math.floor(n);
646
+ u = Math.floor(n);
627
647
  break;
628
648
  case "ceil":
629
- d = Math.ceil(n);
649
+ u = Math.ceil(n);
630
650
  break;
631
651
  default:
632
- d = Math.round(n);
652
+ u = Math.round(n);
633
653
  }
634
- return d / t;
654
+ return u / t;
635
655
  }
636
- function Ce(i, e, l, t) {
637
- let n = ze(i, e, l);
638
- return n = st(n, l, t), n = ze(n, e, l), n;
656
+ function Ce(r, e, l, t) {
657
+ let n = ze(r, e, l);
658
+ return n = rt(n, l, t), n = ze(n, e, l), n;
639
659
  }
640
- function rt(i, e) {
641
- return Number.isNaN(i) || !Number.isFinite(i) ? "" : i.toFixed(Math.max(0, e));
660
+ function it(r, e) {
661
+ return Number.isNaN(r) || !Number.isFinite(r) ? "" : r.toFixed(Math.max(0, e));
642
662
  }
643
- function Ie(i, e) {
644
- if (Number.isNaN(i) || !Number.isFinite(i))
663
+ function Ie(r, e) {
664
+ if (Number.isNaN(r) || !Number.isFinite(r))
645
665
  return "";
646
- const l = i.toFixed(Math.max(0, e)), t = l.startsWith("-"), n = t ? l.slice(1) : l, [d, a] = n.split("."), f = d.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
666
+ const l = r.toFixed(Math.max(0, e)), t = l.startsWith("-"), n = t ? l.slice(1) : l, [u, a] = n.split("."), f = u.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
647
667
  return e <= 0 || a === void 0 ? (t ? "-" : "") + f : (t ? "-" : "") + f + "." + a;
648
668
  }
649
- function it(i, e) {
650
- if (Number.isNaN(i) || !Number.isFinite(i))
669
+ function ct(r, e) {
670
+ if (Number.isNaN(r) || !Number.isFinite(r))
651
671
  return "";
652
- let l = i.toFixed(Math.max(0, e));
672
+ let l = r.toFixed(Math.max(0, e));
653
673
  return l = l.replace(/(\.\d*?)0+$/, "$1"), l = l.replace(/\.$/, ""), l;
654
674
  }
655
- const ct = /* @__PURE__ */ oe({
675
+ const ut = /* @__PURE__ */ oe({
656
676
  __name: "FormattedNumberInput",
657
677
  props: {
658
678
  value: null,
@@ -660,97 +680,98 @@ const ct = /* @__PURE__ */ oe({
660
680
  disabled: { type: Boolean },
661
681
  integerDigits: { default: 5 },
662
682
  decimalPlaces: { default: 6 },
663
- rounding: { default: "round" }
683
+ rounding: { default: "round" },
684
+ inputLimit: { type: Boolean, default: !0 }
664
685
  },
665
686
  emits: ["input"],
666
- setup(i, { emit: e }) {
667
- const l = i, t = k(!1), n = k(""), d = () => Math.max(0, Math.floor(l.integerDigits ?? 5)), a = () => Math.max(0, Math.floor(l.decimalPlaces ?? 6));
668
- function f(u) {
669
- if (u == null || u === "")
687
+ setup(r, { emit: e }) {
688
+ const l = r, t = k(!1), n = k(""), u = () => Math.max(0, Math.floor(l.integerDigits ?? 5)), a = () => Math.max(0, Math.floor(l.decimalPlaces ?? 6));
689
+ function f(d) {
690
+ if (d == null || d === "")
670
691
  return null;
671
- if (typeof u == "number")
672
- return Number.isFinite(u) ? u : null;
673
- const F = Pe(String(u));
674
- if (F === "" || F === "-")
692
+ if (typeof d == "number")
693
+ return Number.isFinite(d) ? d : null;
694
+ const x = Pe(String(d));
695
+ if (x === "" || x === "-")
675
696
  return null;
676
- const _ = Number(F);
697
+ const _ = Number(x);
677
698
  return Number.isFinite(_) ? _ : null;
678
699
  }
679
- function r() {
700
+ function i() {
680
701
  if (t.value)
681
702
  return;
682
- const u = f(l.value);
683
- if (u === null) {
703
+ const d = f(l.value);
704
+ if (d === null) {
684
705
  n.value = "";
685
706
  return;
686
707
  }
687
708
  n.value = Ie(
688
- Ce(u, d(), a(), l.rounding),
709
+ Ce(d, u(), a(), l.rounding),
689
710
  a()
690
711
  );
691
712
  }
692
713
  J(
693
714
  () => [l.value, l.integerDigits, l.decimalPlaces, l.rounding],
694
- () => r(),
715
+ () => i(),
695
716
  { immediate: !0, deep: !0 }
696
717
  );
697
- function y(u) {
698
- e("input", rt(u, a()));
718
+ function g(d) {
719
+ e("input", it(d, a()));
699
720
  }
700
- function O(u) {
701
- const F = $e(u);
702
- if (n.value = F, F === "" || F === "-")
721
+ function z(d) {
722
+ let x = $e(d);
723
+ if (l.inputLimit !== !1 && (x = at(x, u(), a())), n.value = x, x === "" || x === "-")
703
724
  return;
704
- const _ = Number(F);
725
+ const _ = Number(x);
705
726
  if (!Number.isFinite(_))
706
727
  return;
707
- const D = Ce(_, d(), a(), l.rounding);
708
- y(D);
728
+ const D = Ce(_, u(), a(), l.rounding);
729
+ g(D);
709
730
  }
710
- function v() {
731
+ function m() {
711
732
  t.value = !0;
712
- const u = Pe(n.value), F = f(u === "" ? l.value : u);
713
- if (F === null) {
733
+ const d = Pe(n.value), x = f(d === "" ? l.value : d);
734
+ if (x === null) {
714
735
  n.value = "";
715
736
  return;
716
737
  }
717
- n.value = it(
718
- Ce(F, d(), a(), l.rounding),
738
+ n.value = ct(
739
+ Ce(x, u(), a(), l.rounding),
719
740
  a()
720
741
  );
721
742
  }
722
- function x() {
743
+ function P() {
723
744
  t.value = !1;
724
- const u = Pe(n.value);
725
- if (u === "" || u === "-") {
745
+ const d = Pe(n.value);
746
+ if (d === "" || d === "-") {
726
747
  n.value = "", e("input", void 0);
727
748
  return;
728
749
  }
729
- const F = Number($e(u));
730
- if (!Number.isFinite(F)) {
750
+ const x = Number($e(d));
751
+ if (!Number.isFinite(x)) {
731
752
  n.value = "", e("input", void 0);
732
753
  return;
733
754
  }
734
- const _ = Ce(F, d(), a(), l.rounding);
735
- n.value = Ie(_, a()), y(_);
755
+ const _ = Ce(x, u(), a(), l.rounding);
756
+ n.value = Ie(_, a()), g(_);
736
757
  }
737
- return { __sfc: !0, props: l, emit: e, focused: t, displayText: n, intN: d, decM: a, parseExternalToNumber: f, syncDisplayFromValue: r, emitStoredValue: y, onInput: O, onFocus: v, onBlur: x };
758
+ return { __sfc: !0, props: l, emit: e, focused: t, displayText: n, intN: u, decM: a, parseExternalToNumber: f, syncDisplayFromValue: i, emitStoredValue: g, onInput: z, onFocus: m, onBlur: P };
738
759
  }
739
760
  });
740
- var ut = function() {
761
+ var dt = function() {
741
762
  var e = this, l = e._self._c, t = e._self._setupProxy;
742
763
  return l("el-input", e._b({ attrs: { value: t.displayText, placeholder: e.placeholder, disabled: e.disabled }, on: { input: t.onInput, focus: t.onFocus, blur: t.onBlur } }, "el-input", e.$attrs, !1));
743
- }, dt = [], ft = /* @__PURE__ */ se(
744
- ct,
764
+ }, ft = [], pt = /* @__PURE__ */ se(
745
765
  ut,
746
766
  dt,
767
+ ft,
747
768
  !1,
748
769
  null,
749
770
  null,
750
771
  null,
751
772
  null
752
773
  );
753
- const Ae = ft.exports, pt = /* @__PURE__ */ oe({
774
+ const Ae = pt.exports, mt = /* @__PURE__ */ oe({
754
775
  __name: "TreeSelect",
755
776
  props: {
756
777
  value: null,
@@ -767,87 +788,87 @@ const Ae = ft.exports, pt = /* @__PURE__ */ oe({
767
788
  clearable: { type: Boolean }
768
789
  },
769
790
  emits: ["input"],
770
- setup(i, { emit: e }) {
771
- const l = i, t = k(), n = k(), d = k(!1), a = k(!1), f = k(""), r = k([]), y = k({}), O = S(() => ({
791
+ setup(r, { emit: e }) {
792
+ const l = r, t = k(), n = k(), u = k(!1), a = k(!1), f = k(""), i = k([]), g = k({}), z = F(() => ({
772
793
  label: l.labelField,
773
794
  children: l.childrenField
774
795
  }));
775
- function v(R) {
776
- const N = l.labelField ?? "label", L = l.valueField ?? "value", Z = l.childrenField ?? "children", ee = R[Z], H = {};
777
- return H[l.labelField ?? "label"] = R[N] ?? R.label, H[l.valueField ?? "value"] = R[L] ?? R.value, Array.isArray(ee) && ee.length && (H[l.childrenField ?? "children"] = ee.map((q) => v(q))), H;
796
+ function m(R) {
797
+ const N = l.labelField ?? "label", W = l.valueField ?? "value", Z = l.childrenField ?? "children", ee = R[Z], H = {};
798
+ return H[l.labelField ?? "label"] = R[N] ?? R.label, H[l.valueField ?? "value"] = R[W] ?? R.value, Array.isArray(ee) && ee.length && (H[l.childrenField ?? "children"] = ee.map((q) => m(q))), H;
778
799
  }
779
- function x(R, N = "") {
780
- const L = {}, Z = l.labelField ?? "label", ee = l.valueField ?? "value", H = l.childrenField ?? "children";
800
+ function P(R, N = "") {
801
+ const W = {}, Z = l.labelField ?? "label", ee = l.valueField ?? "value", H = l.childrenField ?? "children";
781
802
  for (const q of R) {
782
803
  const Q = String(q[Z] ?? q.label ?? ""), U = q[ee] ?? q.value;
783
- U != null && (L[String(U)] = N ? N + " / " + Q : Q);
804
+ U != null && (W[String(U)] = N ? N + " / " + Q : Q);
784
805
  const Y = q[H] ?? q.children;
785
- Array.isArray(Y) && Y.length && Object.assign(L, x(Y, Q));
806
+ Array.isArray(Y) && Y.length && Object.assign(W, P(Y, Q));
786
807
  }
787
- return L;
808
+ return W;
788
809
  }
789
- function u() {
810
+ function d() {
790
811
  const R = l.treeData;
791
812
  return Array.isArray(R) && R.length > 0;
792
813
  }
793
- function F(R) {
794
- r.value = R, y.value = x(R);
814
+ function x(R) {
815
+ i.value = R, g.value = P(R);
795
816
  }
796
817
  function _() {
797
818
  const R = l.treeData;
798
819
  if (!Array.isArray(R) || R.length === 0)
799
820
  return;
800
- const N = R.map((L) => v(L));
801
- F(N);
821
+ const N = R.map((W) => m(W));
822
+ x(N);
802
823
  }
803
- const D = S(() => l.value == null || l.value === "" ? "" : y.value[String(l.value)] ?? String(l.value)), z = (R, N) => {
824
+ const D = F(() => l.value == null || l.value === "" ? "" : g.value[String(l.value)] ?? String(l.value)), I = (R, N) => {
804
825
  if (!R)
805
826
  return !0;
806
- const L = l.labelField ?? "label";
807
- return String(N[L] ?? N.label ?? "").toLowerCase().includes(R.toLowerCase());
827
+ const W = l.labelField ?? "label";
828
+ return String(N[W] ?? N.label ?? "").toLowerCase().includes(R.toLowerCase());
808
829
  };
809
830
  J(f, (R) => {
810
831
  var N;
811
832
  (N = n.value) == null || N.filter(R);
812
833
  });
813
- let g = null;
814
- function m() {
815
- l.disabled || (d.value = !0, l.lazy && !u() && j(), Oe(() => {
816
- g = (R) => {
817
- t.value && !t.value.contains(R.target) && W();
818
- }, document.addEventListener("click", g);
834
+ let y = null;
835
+ function v() {
836
+ l.disabled || (u.value = !0, l.lazy && !d() && j(), Oe(() => {
837
+ y = (R) => {
838
+ t.value && !t.value.contains(R.target) && L();
839
+ }, document.addEventListener("click", y);
819
840
  }));
820
841
  }
821
- function W() {
822
- d.value = !1, f.value = "", g && (document.removeEventListener("click", g), g = null);
842
+ function L() {
843
+ u.value = !1, f.value = "", y && (document.removeEventListener("click", y), y = null);
823
844
  }
824
845
  function b() {
825
846
  e("input", void 0);
826
847
  }
827
848
  function M(R) {
828
- const N = l.valueField ?? "value", L = R[N] ?? R.value;
829
- e("input", L), W();
849
+ const N = l.valueField ?? "value", W = R[N] ?? R.value;
850
+ e("input", W), L();
830
851
  }
831
852
  async function j() {
832
- if (!(!l.api || u())) {
853
+ if (!(!l.api || d())) {
833
854
  a.value = !0;
834
855
  try {
835
856
  const R = await l.api(l.params), N = Array.isArray(R) ? R : (R == null ? void 0 : R.list) ?? (R == null ? void 0 : R.data) ?? [];
836
- r.value = N.map((L) => v(L)), y.value = x(r.value);
857
+ i.value = N.map((W) => m(W)), g.value = P(i.value);
837
858
  } finally {
838
859
  a.value = !1;
839
860
  }
840
861
  }
841
862
  }
842
- return ve(() => {
843
- u() ? _() : l.lazy || j();
863
+ return me(() => {
864
+ d() ? _() : l.lazy || j();
844
865
  }), J(() => l.treeData, () => {
845
- u() ? _() : (r.value = [], y.value = {}, !l.lazy && l.api && j());
866
+ d() ? _() : (i.value = [], g.value = {}, !l.lazy && l.api && j());
846
867
  }, { deep: !0 }), J(() => l.api, () => {
847
- u() || (l.lazy ? (r.value = [], y.value = {}) : j());
868
+ d() || (l.lazy ? (i.value = [], g.value = {}) : j());
848
869
  }, { deep: !0 }), J(() => l.params, () => {
849
- u() || (l.lazy ? (r.value = [], y.value = {}) : j());
850
- }, { deep: !0 }), { __sfc: !0, props: l, emit: e, rootRef: t, treeRef: n, dropdownVisible: d, loading: a, filterText: f, treeData: r, flatLabelMap: y, treeProps: O, normalizeNode: v, buildFlatLabelMap: x, hasTreeDataProp: u, applyTreeData: F, syncFromTreeDataProp: _, displayText: D, filterNodeMethod: z, clickOutsideHandler: g, openDropdown: m, closeDropdown: W, clearValue: b, onNodeClick: M, fetchData: j };
870
+ d() || (l.lazy ? (i.value = [], g.value = {}) : j());
871
+ }, { deep: !0 }), { __sfc: !0, props: l, emit: e, rootRef: t, treeRef: n, dropdownVisible: u, loading: a, filterText: f, treeData: i, flatLabelMap: g, treeProps: z, normalizeNode: m, buildFlatLabelMap: P, hasTreeDataProp: d, applyTreeData: x, syncFromTreeDataProp: _, displayText: D, filterNodeMethod: I, clickOutsideHandler: y, openDropdown: v, closeDropdown: L, clearValue: b, onNodeClick: M, fetchData: j };
851
872
  }
852
873
  });
853
874
  var vt = function() {
@@ -857,17 +878,17 @@ var vt = function() {
857
878
  } }, model: { value: t.filterText, callback: function(n) {
858
879
  t.filterText = n;
859
880
  }, expression: "filterText" } })], 1) : e._e(), l("el-tree", { directives: [{ name: "show", rawName: "v-show", value: !t.loading, expression: "!loading" }], ref: "treeRef", attrs: { data: t.treeData, props: t.treeProps, "node-key": e.valueField, "filter-node-method": e.filterable ? t.filterNodeMethod : void 0, "highlight-current": !0, "default-expand-all": "" }, on: { "node-click": t.onNodeClick } }), t.loading ? l("div", { staticClass: "ecp-tree-select__loading" }, [l("i", { staticClass: "el-icon-loading" }), e._v(" 加载中... ")]) : e._e()], 1)])], 1);
860
- }, mt = [], ht = /* @__PURE__ */ se(
861
- pt,
862
- vt,
881
+ }, ht = [], _t = /* @__PURE__ */ se(
863
882
  mt,
883
+ vt,
884
+ ht,
864
885
  !1,
865
886
  null,
866
887
  "f30bba11",
867
888
  null,
868
889
  null
869
890
  );
870
- const _t = ht.exports, bt = /* @__PURE__ */ oe({
891
+ const bt = _t.exports, gt = /* @__PURE__ */ oe({
871
892
  __name: "ProFormItem",
872
893
  props: {
873
894
  schema: null,
@@ -879,8 +900,8 @@ const _t = ht.exports, bt = /* @__PURE__ */ oe({
879
900
  onFieldChange: null,
880
901
  customComponents: null
881
902
  },
882
- setup(i) {
883
- const e = i, l = /* @__PURE__ */ new Set([
903
+ setup(r) {
904
+ const e = r, l = /* @__PURE__ */ new Set([
884
905
  "input",
885
906
  "select",
886
907
  "api-select",
@@ -893,26 +914,26 @@ const _t = ht.exports, bt = /* @__PURE__ */ oe({
893
914
  "cascader",
894
915
  "checkbox",
895
916
  "radio"
896
- ]), t = Se(), n = S(() => ({
917
+ ]), t = Se(), n = F(() => ({
897
918
  schema: e.schema,
898
919
  values: e.formModel,
899
920
  model: e.formModel,
900
921
  field: e.schema.field
901
- })), d = S(() => {
922
+ })), u = F(() => {
902
923
  const b = e.schema.ifShow;
903
924
  return b === void 0 ? !0 : typeof b == "boolean" ? b : b(n.value);
904
- }), a = S(() => {
925
+ }), a = F(() => {
905
926
  const b = e.schema.show;
906
927
  return b === void 0 ? !0 : typeof b == "boolean" ? b : b(n.value);
907
- }), f = S(() => {
928
+ }), f = F(() => {
908
929
  if (e.formDisabled)
909
930
  return !0;
910
931
  const b = e.schema.dynamicDisabled;
911
932
  return b === void 0 ? !1 : typeof b == "boolean" ? b : b(n.value);
912
- }), r = S(() => {
933
+ }), i = F(() => {
913
934
  const b = e.schema.dynamicRules;
914
935
  return b ? Array.isArray(b) ? b : b(n.value) : e.schema.rules;
915
- }), y = S(() => {
936
+ }), g = F(() => {
916
937
  const b = e.schema.componentProps;
917
938
  if (!b)
918
939
  return { props: {}, listeners: {} };
@@ -920,29 +941,29 @@ const _t = ht.exports, bt = /* @__PURE__ */ oe({
920
941
  ...n.value,
921
942
  formActionType: e.formActionType
922
943
  }) : { ...b }, j = {}, R = {};
923
- for (const [N, L] of Object.entries(M))
924
- if (N.length > 2 && /^on[A-Za-z]/.test(N) && typeof L == "function") {
944
+ for (const [N, W] of Object.entries(M))
945
+ if (N.length > 2 && /^on[A-Za-z]/.test(N) && typeof W == "function") {
925
946
  const Z = N.slice(2).charAt(0).toLowerCase() + N.slice(3);
926
- R[Z] = L;
947
+ R[Z] = W;
927
948
  } else
928
- j[N] = L;
949
+ j[N] = W;
929
950
  return { props: j, listeners: R };
930
- }), O = S(() => y.value.props), v = S(() => y.value.listeners), x = S(() => e.schema.colon ?? e.colon ?? !1), u = S(() => {
951
+ }), z = F(() => g.value.props), m = F(() => g.value.listeners), P = F(() => e.schema.colon ?? e.colon ?? !1), d = F(() => {
931
952
  const b = e.schema.tooltip;
932
953
  if (!b)
933
954
  return null;
934
955
  const M = typeof b == "function" ? b(n.value) : b;
935
956
  return Be(M, e.formModel[e.schema.field]);
936
- }), F = S(() => u.value ? "el-tooltip" : "span"), _ = S(() => u.value || {}), D = S(() => !!t.default), z = (b) => {
957
+ }), x = F(() => d.value ? "el-tooltip" : "span"), _ = F(() => d.value || {}), D = F(() => !!t.default), I = (b) => {
937
958
  const M = b == null ? void 0 : b.options;
938
959
  return Array.isArray(M) ? M : void 0;
939
- }, g = S(() => {
960
+ }, y = F(() => {
940
961
  const b = e.schema.component;
941
962
  return b == null ? null : typeof b == "string" ? l.has(b) ? null : e.customComponents && e.customComponents[b] || b : b;
942
- }), m = (b) => {
963
+ }), v = (b) => {
943
964
  var M;
944
965
  (M = e.onFieldChange) == null || M.call(e, e.schema.field, b);
945
- }, W = S(() => {
966
+ }, L = F(() => {
946
967
  const b = e.schema.render;
947
968
  return b ? {
948
969
  render() {
@@ -951,13 +972,13 @@ const _t = ht.exports, bt = /* @__PURE__ */ oe({
951
972
  }
952
973
  } : null;
953
974
  });
954
- return { __sfc: !0, BUILT_IN_COMPONENTS: l, props: e, slots: t, renderParams: n, shouldRender: d, shouldShow: a, effectiveDisabled: f, effectiveRules: r, effectiveComponentPropsAndListeners: y, effectiveComponentProps: O, effectiveComponentListeners: v, showColon: x, normalizedTooltip: u, fieldWrapperComponent: F, fieldWrapperProps: _, hasSlot: D, getOptions: z, resolvedCustomComponent: g, setFieldValue: m, renderComponent: W, ApiSelect: nt, FormattedNumberInput: Ae, TreeSelect: _t };
975
+ return { __sfc: !0, BUILT_IN_COMPONENTS: l, props: e, slots: t, renderParams: n, shouldRender: u, shouldShow: a, effectiveDisabled: f, effectiveRules: i, effectiveComponentPropsAndListeners: g, effectiveComponentProps: z, effectiveComponentListeners: m, showColon: P, normalizedTooltip: d, fieldWrapperComponent: x, fieldWrapperProps: _, hasSlot: D, getOptions: I, resolvedCustomComponent: y, setFieldValue: v, renderComponent: L, ApiSelect: nt, FormattedNumberInput: Ae, TreeSelect: bt };
955
976
  }
956
977
  });
957
- var gt = function() {
978
+ var yt = function() {
958
979
  var e = this, l = e._self._c, t = e._self._setupProxy;
959
- return t.shouldRender ? l("el-form-item", { directives: [{ name: "show", rawName: "v-show", value: t.shouldShow, expression: "shouldShow" }], attrs: { prop: e.schema.field, required: e.schema.required, rules: t.effectiveRules, "label-width": e.schema.labelWidth } }, [l("template", { slot: "label" }, [l("span", [e._v(" " + e._s(e.schema.label)), t.showColon ? l("span", { staticClass: "ecp-pro-form-item__colon" }, [e._v(":")]) : e._e()]), e.schema.helpMessage ? l("el-tooltip", e._b({ attrs: { placement: "top", effect: "light" } }, "el-tooltip", e.schema.helpComponentProps || {}, !1), [l("template", { slot: "content" }, [Array.isArray(e.schema.helpMessage) ? e._l(e.schema.helpMessage, function(n, d) {
960
- return l("div", { key: d, staticClass: "ecp-pro-form-item__help-item" }, [e._v(" " + e._s(n) + " ")]);
980
+ return t.shouldRender ? l("el-form-item", { directives: [{ name: "show", rawName: "v-show", value: t.shouldShow, expression: "shouldShow" }], attrs: { prop: e.schema.field, required: e.schema.required, rules: t.effectiveRules, "label-width": e.schema.labelWidth } }, [l("template", { slot: "label" }, [l("span", [e._v(" " + e._s(e.schema.label)), t.showColon ? l("span", { staticClass: "ecp-pro-form-item__colon" }, [e._v(":")]) : e._e()]), e.schema.helpMessage ? l("el-tooltip", e._b({ attrs: { placement: "top", effect: "light" } }, "el-tooltip", e.schema.helpComponentProps || {}, !1), [l("template", { slot: "content" }, [Array.isArray(e.schema.helpMessage) ? e._l(e.schema.helpMessage, function(n, u) {
981
+ return l("div", { key: u, staticClass: "ecp-pro-form-item__help-item" }, [e._v(" " + e._s(n) + " ")]);
961
982
  }) : l("span", [e._v(e._s(e.schema.helpMessage))])], 2), l("i", { staticClass: "el-icon-question ecp-pro-form-item__help-icon" })], 2) : e._e()], 1), e.schema.render ? [l(t.renderComponent, { tag: "component" })] : t.hasSlot ? e._t("default", null, { model: e.formModel, schema: e.schema, field: e.schema.field, values: e.formModel }) : [l(t.fieldWrapperComponent, e._b({ tag: "component" }, "component", t.fieldWrapperProps, !1), [t.resolvedCustomComponent ? l(t.resolvedCustomComponent, e._g(e._b({ tag: "component", attrs: { value: e.formModel[e.schema.field], placeholder: e.schema.placeholder || (e.autoPlaceholder ? `请输入${e.schema.label}` : void 0), disabled: t.effectiveDisabled }, on: { input: t.setFieldValue } }, "component", t.effectiveComponentProps, !1), t.effectiveComponentListeners)) : e.schema.component === "input" || !e.schema.component ? l("el-input", e._g(e._b({ attrs: { placeholder: e.schema.placeholder || (e.autoPlaceholder ? `请输入${e.schema.label}` : void 0), disabled: t.effectiveDisabled }, model: { value: e.formModel[e.schema.field], callback: function(n) {
962
983
  e.$set(e.formModel, e.schema.field, n);
963
984
  }, expression: "formModel[schema.field]" } }, "el-input", t.effectiveComponentProps, !1), t.effectiveComponentListeners)) : e.schema.component === "input-number" ? l("el-input-number", e._g(e._b({ attrs: { placeholder: e.schema.placeholder, disabled: t.effectiveDisabled }, model: { value: e.formModel[e.schema.field], callback: function(n) {
@@ -983,17 +1004,17 @@ var gt = function() {
983
1004
  }, expression: "formModel[schema.field]" } }, "el-radio-group", t.effectiveComponentProps, !1), t.effectiveComponentListeners), e._l(t.getOptions(t.effectiveComponentProps) || [], function(n) {
984
1005
  return l("el-radio", { key: String(n.value), attrs: { label: n.value } }, [e._v(" " + e._s(n.label) + " ")]);
985
1006
  }), 1) : e._e()], 1)]], 2) : e._e();
986
- }, yt = [], wt = /* @__PURE__ */ se(
987
- bt,
1007
+ }, wt = [], Ct = /* @__PURE__ */ se(
988
1008
  gt,
989
1009
  yt,
1010
+ wt,
990
1011
  !1,
991
1012
  null,
992
1013
  "d3466c67",
993
1014
  null,
994
1015
  null
995
1016
  );
996
- const Ve = wt.exports, Ct = /* @__PURE__ */ oe({
1017
+ const Ve = Ct.exports, xt = /* @__PURE__ */ oe({
997
1018
  __name: "FormActions",
998
1019
  props: {
999
1020
  showActionButtonGroup: { type: Boolean, default: !0 },
@@ -1010,28 +1031,28 @@ const Ve = wt.exports, Ct = /* @__PURE__ */ oe({
1010
1031
  actionColOptions: null
1011
1032
  },
1012
1033
  emits: ["submit", "reset", "toggle"],
1013
- setup(i) {
1034
+ setup(r) {
1014
1035
  return { __sfc: !0 };
1015
1036
  }
1016
1037
  });
1017
- var xt = function() {
1038
+ var Pt = function() {
1018
1039
  var e = this, l = e._self._c;
1019
1040
  return e._self._setupProxy, l("div", { staticClass: "ecp-form-actions" }, [e._t("submitBefore"), e.showSubmitButton ? l("el-button", { attrs: { type: "primary", icon: e.submitButtonIcon, loading: e.submitLoading }, on: { click: function(t) {
1020
1041
  return e.$emit("submit");
1021
1042
  } } }, [e._v(" " + e._s(e.submitButtonText) + " ")]) : e._e(), e._t("resetBefore"), e.showResetButton ? l("el-button", { attrs: { icon: e.resetButtonIcon }, on: { click: function(t) {
1022
1043
  return e.$emit("reset");
1023
1044
  } } }, [e._v(" " + e._s(e.resetButtonText) + " ")]) : e._e(), e._t("actions")], 2);
1024
- }, Pt = [], St = /* @__PURE__ */ se(
1025
- Ct,
1045
+ }, St = [], Ft = /* @__PURE__ */ se(
1026
1046
  xt,
1027
1047
  Pt,
1048
+ St,
1028
1049
  !1,
1029
1050
  null,
1030
1051
  "489c88d2",
1031
1052
  null,
1032
1053
  null
1033
1054
  );
1034
- const We = St.exports, Ft = /* @__PURE__ */ oe({
1055
+ const Le = Ft.exports, Rt = /* @__PURE__ */ oe({
1035
1056
  __name: "ProForm",
1036
1057
  props: {
1037
1058
  schemas: null,
@@ -1064,45 +1085,45 @@ const We = St.exports, Ft = /* @__PURE__ */ oe({
1064
1085
  components: null
1065
1086
  },
1066
1087
  emits: ["submit", "reset", "register", "update:modelValue"],
1067
- setup(i, { expose: e, emit: l }) {
1068
- const t = i, n = Se(), d = k(), a = k(), f = k(!1), r = k(!0), y = k({}), O = k({}), v = k([]), x = k({}), u = { xl: 1920, lg: 1200, md: 992, sm: 768 }, F = (c, w, B) => {
1088
+ setup(r, { expose: e, emit: l }) {
1089
+ const t = r, n = Se(), u = k(), a = k(), f = k(!1), i = k(!0), g = k({}), z = k({}), m = k([]), P = k({}), d = { xl: 1920, lg: 1200, md: 992, sm: 768 }, x = (c, w, B) => {
1069
1090
  const A = B ?? (typeof window < "u" ? window.innerWidth : 1920), C = c ?? {}, o = w ?? {}, s = o.span ?? 8;
1070
- return A >= u.xl ? C.xl ?? o.xl ?? C.lg ?? o.lg ?? C.md ?? o.md ?? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : A >= u.lg ? C.lg ?? o.lg ?? C.md ?? o.md ?? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : A >= u.md ? C.md ?? o.md ?? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : A >= u.sm ? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : C.xs ?? o.xs ?? C.span ?? s;
1071
- }, { getSetting: _ } = Re(), D = S(() => ({ ..._("ProForm"), ...t, ...x.value })), z = S(() => D.value.modelValue), g = S(() => z.value !== void 0), m = S(() => g.value ? z.value ?? {} : y.value), W = S(() => ({
1091
+ return A >= d.xl ? C.xl ?? o.xl ?? C.lg ?? o.lg ?? C.md ?? o.md ?? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : A >= d.lg ? C.lg ?? o.lg ?? C.md ?? o.md ?? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : A >= d.md ? C.md ?? o.md ?? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : A >= d.sm ? C.sm ?? o.sm ?? C.xs ?? o.xs ?? C.span ?? s : C.xs ?? o.xs ?? C.span ?? s;
1092
+ }, { getSetting: _ } = Re(), D = F(() => ({ ..._("ProForm"), ...t, ...P.value })), I = F(() => D.value.modelValue), y = F(() => I.value !== void 0), v = F(() => y.value ? I.value ?? {} : g.value), L = F(() => ({
1072
1093
  ..._("ProForm").components ?? {},
1073
1094
  ...D.value.components ?? {},
1074
- ...x.value.components ?? {}
1075
- })), b = S(() => D.value.actionColOptions ?? { span: 24 }), M = k(typeof window < "u" ? window.innerWidth : 1920), j = (c, w, B, A) => {
1095
+ ...P.value.components ?? {}
1096
+ })), b = F(() => D.value.actionColOptions ?? { span: 24 }), M = k(typeof window < "u" ? window.innerWidth : 1920), j = (c, w, B, A) => {
1076
1097
  let C = 24, o = 1, s = 0;
1077
1098
  for (const h of c) {
1078
- const P = F(h.colProps, w, A);
1079
- if (P > C) {
1099
+ const S = x(h.colProps, w, A);
1100
+ if (S > C) {
1080
1101
  if (o++, o > B)
1081
1102
  break;
1082
- C = 24 - P;
1103
+ C = 24 - S;
1083
1104
  } else
1084
- C -= P;
1105
+ C -= S;
1085
1106
  s++;
1086
1107
  }
1087
1108
  return s;
1088
- }, R = S(() => {
1089
- const c = v.value.filter((C) => Z(C));
1109
+ }, R = F(() => {
1110
+ const c = m.value.filter((C) => Z(C));
1090
1111
  if (!D.value.showAdvancedButton)
1091
1112
  return !1;
1092
1113
  const w = D.value.alwaysShowLines ?? 1, B = D.value.baseColProps, A = j(c, B, w, M.value);
1093
1114
  return c.length > A;
1094
- }), N = S(() => D.value.formListeners ?? {}), L = S(() => {
1095
- const c = v.value.filter((C) => Z(C));
1096
- if (!D.value.showAdvancedButton || !r.value)
1115
+ }), N = F(() => D.value.formListeners ?? {}), W = F(() => {
1116
+ const c = m.value.filter((C) => Z(C));
1117
+ if (!D.value.showAdvancedButton || !i.value)
1097
1118
  return c;
1098
1119
  const w = D.value.alwaysShowLines ?? 1, B = D.value.baseColProps, A = j(c, B, w, M.value);
1099
1120
  return c.slice(0, A);
1100
1121
  }), Z = (c) => {
1101
1122
  let w = !0, B = !0;
1102
- return typeof c.ifShow == "function" && (w = c.ifShow({ schema: c, values: m.value, model: m.value, field: c.field })), typeof c.ifShow == "boolean" && (w = c.ifShow), typeof c.show == "function" && (B = c.show({ schema: c, values: m.value, model: m.value, field: c.field })), typeof c.show == "boolean" && (B = c.show), w && B;
1123
+ return typeof c.ifShow == "function" && (w = c.ifShow({ schema: c, values: v.value, model: v.value, field: c.field })), typeof c.ifShow == "boolean" && (w = c.ifShow), typeof c.show == "function" && (B = c.show({ schema: c, values: v.value, model: v.value, field: c.field })), typeof c.show == "boolean" && (B = c.show), w && B;
1103
1124
  }, ee = (c) => c.colProps ?? D.value.baseColProps ?? {}, H = (c) => c.slot || c.field, q = (c, w = !0) => {
1104
1125
  const B = w ? { ...c ?? {} } : {}, A = D.value.initialValues ?? t.initialValues;
1105
- return v.value.forEach((C) => {
1126
+ return m.value.forEach((C) => {
1106
1127
  if (!(w && Object.prototype.hasOwnProperty.call(B, C.field))) {
1107
1128
  if (C.defaultValue !== void 0) {
1108
1129
  B[C.field] = C.defaultValue;
@@ -1112,26 +1133,26 @@ const We = St.exports, Ft = /* @__PURE__ */ oe({
1112
1133
  }
1113
1134
  }), B;
1114
1135
  }, Q = (c, w = !0) => {
1115
- y.value = c, w && l("update:modelValue", c);
1136
+ g.value = c, w && l("update:modelValue", c);
1116
1137
  }, U = (c) => {
1117
- const w = q({ ...m.value, ...c });
1138
+ const w = q({ ...v.value, ...c });
1118
1139
  return Q(w), w;
1119
1140
  }, Y = () => {
1120
1141
  const c = {};
1121
- v.value.forEach((w) => {
1142
+ m.value.forEach((w) => {
1122
1143
  var B;
1123
1144
  (B = w.rules) != null && B.length && (c[w.field] = w.rules);
1124
- }), Q(q(m.value), !1), O.value = c;
1145
+ }), Q(q(v.value), !1), z.value = c;
1125
1146
  }, re = (c) => {
1126
1147
  const w = { ...c };
1127
- return v.value.forEach((B) => {
1148
+ return m.value.forEach((B) => {
1128
1149
  const A = B.ifShow;
1129
1150
  if (A === void 0)
1130
1151
  return;
1131
1152
  (typeof A == "boolean" ? A : A({ schema: B, values: c, model: c, field: B.field })) || delete w[B.field];
1132
1153
  }), w;
1133
1154
  }, p = (c) => {
1134
- const w = re(c), B = x.value.fieldMapToTime;
1155
+ const w = re(c), B = P.value.fieldMapToTime;
1135
1156
  if (!(B != null && B.length))
1136
1157
  return w;
1137
1158
  const A = { ...w };
@@ -1142,7 +1163,7 @@ const We = St.exports, Ft = /* @__PURE__ */ oe({
1142
1163
  }, $ = async () => {
1143
1164
  var c;
1144
1165
  try {
1145
- await ((c = d.value) == null ? void 0 : c.validate()), D.value.submitFunc ? await D.value.submitFunc() : (f.value = !0, l("submit", p({ ...m.value })));
1166
+ await ((c = u.value) == null ? void 0 : c.validate()), D.value.submitFunc ? await D.value.submitFunc() : (f.value = !0, l("submit", p({ ...v.value })));
1146
1167
  } catch (w) {
1147
1168
  console.error("Form validation failed:", w);
1148
1169
  } finally {
@@ -1150,43 +1171,43 @@ const We = St.exports, Ft = /* @__PURE__ */ oe({
1150
1171
  }
1151
1172
  }, T = async () => {
1152
1173
  var c;
1153
- D.value.resetFunc ? await D.value.resetFunc() : ((c = d.value) == null || c.resetFields(), Y(), l("reset"), D.value.submitOnReset && await $());
1154
- }, V = (c) => (U(c), Promise.resolve()), K = () => p({ ...m.value }), X = async () => {
1174
+ D.value.resetFunc ? await D.value.resetFunc() : ((c = u.value) == null || c.resetFields(), Y(), l("reset"), D.value.submitOnReset && await $());
1175
+ }, V = (c) => (U(c), Promise.resolve()), K = () => p({ ...v.value }), X = async () => {
1155
1176
  var c;
1156
- (c = d.value) == null || c.resetFields(), Q(q(void 0, !1));
1177
+ (c = u.value) == null || c.resetFields(), Q(q(void 0, !1));
1157
1178
  }, ne = (c, w) => {
1158
1179
  U({ [c]: w });
1159
1180
  }, ae = (c) => {
1160
1181
  var w;
1161
- return ((w = d.value) == null ? void 0 : w.validate(c)) ?? Promise.resolve();
1162
- }, le = (c) => d.value ? c != null && c.length ? Promise.all(c.map((w) => new Promise((B, A) => {
1163
- d.value.validateField(w, (C) => C ? B(void 0) : A(new Error("Validation failed")));
1164
- }))) : d.value.validate() : Promise.resolve(), ie = async (c, w) => {
1182
+ return ((w = u.value) == null ? void 0 : w.validate(c)) ?? Promise.resolve();
1183
+ }, le = (c) => u.value ? c != null && c.length ? Promise.all(c.map((w) => new Promise((B, A) => {
1184
+ u.value.validateField(w, (C) => C ? B(void 0) : A(new Error("Validation failed")));
1185
+ }))) : u.value.validate() : Promise.resolve(), ie = async (c, w) => {
1165
1186
  var A;
1166
1187
  const B = (A = a.value) == null ? void 0 : A.querySelector(`[data-field="${c}"]`);
1167
1188
  return B && B.scrollIntoView({ behavior: (w == null ? void 0 : w.behavior) ?? "smooth", block: (w == null ? void 0 : w.block) ?? "nearest" }), Promise.resolve();
1168
- }, me = (c) => {
1189
+ }, ve = (c) => {
1169
1190
  var w;
1170
- (w = d.value) == null || w.clearValidate(c);
1191
+ (w = u.value) == null || w.clearValidate(c);
1171
1192
  }, he = async (c) => {
1172
1193
  (Array.isArray(c) ? c : [c]).forEach((B) => {
1173
- const A = v.value.findIndex((C) => C.field === B.field);
1174
- A >= 0 && (v.value[A] = { ...v.value[A], ...B });
1194
+ const A = m.value.findIndex((C) => C.field === B.field);
1195
+ A >= 0 && (m.value[A] = { ...m.value[A], ...B });
1175
1196
  });
1176
1197
  }, _e = async (c, w, B) => {
1177
1198
  if (B)
1178
- v.value.unshift(c);
1199
+ m.value.unshift(c);
1179
1200
  else if (w) {
1180
- const A = v.value.findIndex((C) => C.field === w);
1181
- v.value.splice(A + 1, 0, c);
1201
+ const A = m.value.findIndex((C) => C.field === w);
1202
+ m.value.splice(A + 1, 0, c);
1182
1203
  } else
1183
- v.value.push(c);
1204
+ m.value.push(c);
1184
1205
  Y();
1185
1206
  }, be = async (c) => {
1186
1207
  const w = Array.isArray(c) ? c : [c];
1187
- v.value = v.value.filter((B) => !w.includes(B.field));
1208
+ m.value = m.value.filter((B) => !w.includes(B.field));
1188
1209
  }, ge = async (c) => {
1189
- x.value = { ...x.value, ...c }, c.schemas && (v.value = [...c.schemas], Y());
1210
+ P.value = { ...P.value, ...c }, c.schemas && (m.value = [...c.schemas], Y());
1190
1211
  }, pe = {
1191
1212
  getFieldsValue: K,
1192
1213
  setFieldsValue: V,
@@ -1195,7 +1216,7 @@ const We = St.exports, Ft = /* @__PURE__ */ oe({
1195
1216
  validateFields: le,
1196
1217
  submit: $,
1197
1218
  scrollToField: ie,
1198
- clearValidate: me,
1219
+ clearValidate: ve,
1199
1220
  updateSchema: he,
1200
1221
  appendSchemaByField: _e,
1201
1222
  removeSchemaByField: be,
@@ -1203,106 +1224,106 @@ const We = St.exports, Ft = /* @__PURE__ */ oe({
1203
1224
  };
1204
1225
  e(pe);
1205
1226
  const de = () => {
1206
- v.value = [...t.schemas ?? []], Y();
1227
+ m.value = [...t.schemas ?? []], Y();
1207
1228
  }, ce = () => {
1208
1229
  typeof window < "u" && (M.value = window.innerWidth);
1209
1230
  };
1210
- return ve(() => {
1231
+ return me(() => {
1211
1232
  de(), l("register", pe), typeof window < "u" && window.addEventListener("resize", ce);
1212
1233
  }), Fe(() => {
1213
1234
  typeof window < "u" && window.removeEventListener("resize", ce);
1214
- }), J(() => z.value, (c) => {
1215
- !g.value || c === void 0 || Q(q(c), !1);
1216
- }, { deep: !0, immediate: !0 }), J(() => [t.schemas, t.initialValues], de, { deep: !0 }), { __sfc: !0, props: t, emit: l, slots: n, formRef: d, formWrapRef: a, submitLoading: f, collapsed: r, formModel: y, formRules: O, innerSchemas: v, innerProps: x, BREAKPOINTS: u, getEffectiveSpan: F, getComponentSetting: _, effectiveProps: D, controlledModelValue: z, isControlled: g, currentFormModel: m, formCustomComponents: W, effectiveActionColOptions: b, windowWidth: M, getVisibleSchemaCount: j, hasMoreFields: R, formListeners: N, displaySchemas: L, shouldShow: Z, getColProps: ee, getSlotName: H, resolveSchemaModel: q, applyFormModel: Q, updateFormModel: U, initForm: Y, filterByIfShow: re, processFieldMapToTime: p, handleSubmit: $, handleReset: T, setFieldsValue: V, getFieldsValue: K, resetFields: X, handleFieldChange: ne, validate: ae, validateFields: le, scrollToField: ie, clearValidate: me, updateSchema: he, appendSchemaByField: _e, removeSchemaByField: be, setProps: ge, formActionRef: pe, syncSchemas: de, handleResize: ce, ProFormItem: Ve, FormActions: We };
1235
+ }), J(() => I.value, (c) => {
1236
+ !y.value || c === void 0 || Q(q(c), !1);
1237
+ }, { deep: !0, immediate: !0 }), J(() => [t.schemas, t.initialValues], de, { deep: !0 }), { __sfc: !0, props: t, emit: l, slots: n, formRef: u, formWrapRef: a, submitLoading: f, collapsed: i, formModel: g, formRules: z, innerSchemas: m, innerProps: P, BREAKPOINTS: d, getEffectiveSpan: x, getComponentSetting: _, effectiveProps: D, controlledModelValue: I, isControlled: y, currentFormModel: v, formCustomComponents: L, effectiveActionColOptions: b, windowWidth: M, getVisibleSchemaCount: j, hasMoreFields: R, formListeners: N, displaySchemas: W, shouldShow: Z, getColProps: ee, getSlotName: H, resolveSchemaModel: q, applyFormModel: Q, updateFormModel: U, initForm: Y, filterByIfShow: re, processFieldMapToTime: p, handleSubmit: $, handleReset: T, setFieldsValue: V, getFieldsValue: K, resetFields: X, handleFieldChange: ne, validate: ae, validateFields: le, scrollToField: ie, clearValidate: ve, updateSchema: he, appendSchemaByField: _e, removeSchemaByField: be, setProps: ge, formActionRef: pe, syncSchemas: de, handleResize: ce, ProFormItem: Ve, FormActions: Le };
1217
1238
  }
1218
1239
  });
1219
- var Rt = function() {
1240
+ var Bt = function() {
1220
1241
  var e = this, l = e._self._c, t = e._self._setupProxy;
1221
1242
  return l("div", { ref: "formWrapRef", staticClass: "ecp-pro-form" }, [l("el-form", e._g(e._b({ ref: "formRef", staticClass: "ecp-pro-form", attrs: { model: t.currentFormModel, rules: t.formRules, "label-width": t.effectiveProps.labelWidth, "label-position": t.effectiveProps.labelPosition, size: t.effectiveProps.size, disabled: t.effectiveProps.disabled } }, "el-form", e.$attrs, !1), t.formListeners), [e._t("formHeader"), l("el-row", { style: t.effectiveProps.baseRowStyle, attrs: { gutter: t.effectiveProps.gutter } }, [e._l(t.displaySchemas, function(n) {
1222
- var d, a;
1223
- return [t.shouldShow(n) ? l("el-col", e._b({ key: n.field, attrs: { offset: ((d = n.colProps) == null ? void 0 : d.offset) ?? ((a = t.effectiveProps.baseColProps) == null ? void 0 : a.offset) ?? 0, "data-field": n.field } }, "el-col", t.getColProps(n), !1), [l(t.ProFormItem, { attrs: { schema: n, "form-model": t.currentFormModel, "form-disabled": t.effectiveProps.disabled, "auto-placeholder": t.effectiveProps.autoSetPlaceholder, "form-action-type": t.formActionRef, colon: t.effectiveProps.colon, "custom-components": t.formCustomComponents, "on-field-change": t.handleFieldChange } }, [t.slots[t.getSlotName(n)] ? [e._t(t.getSlotName(n), null, { model: t.currentFormModel, schema: n, field: n.field, values: t.currentFormModel })] : e._e()], 2)], 1) : e._e()];
1243
+ var u, a;
1244
+ return [t.shouldShow(n) ? l("el-col", e._b({ key: n.field, attrs: { offset: ((u = n.colProps) == null ? void 0 : u.offset) ?? ((a = t.effectiveProps.baseColProps) == null ? void 0 : a.offset) ?? 0, "data-field": n.field } }, "el-col", t.getColProps(n), !1), [l(t.ProFormItem, { attrs: { schema: n, "form-model": t.currentFormModel, "form-disabled": t.effectiveProps.disabled, "auto-placeholder": t.effectiveProps.autoSetPlaceholder, "form-action-type": t.formActionRef, colon: t.effectiveProps.colon, "custom-components": t.formCustomComponents, "on-field-change": t.handleFieldChange } }, [t.slots[t.getSlotName(n)] ? [e._t(t.getSlotName(n), null, { model: t.currentFormModel, schema: n, field: n.field, values: t.currentFormModel })] : e._e()], 2)], 1) : e._e()];
1224
1245
  }), t.effectiveProps.showActionButtonGroup ? l("el-col", e._b({ staticClass: "ecp-pro-form_col" }, "el-col", t.hasMoreFields ? { span: 24 } : t.effectiveProps.actionColOptions || { span: 6 }, !1), [l(t.FormActions, { attrs: { "show-action-button-group": t.effectiveProps.showActionButtonGroup, "show-submit-button": t.effectiveProps.showSubmitButton, "show-reset-button": t.effectiveProps.showResetButton, "submit-button-text": t.effectiveProps.submitButtonText, "reset-button-text": t.effectiveProps.resetButtonText, "submit-button-icon": t.effectiveProps.submitButtonIcon, "reset-button-icon": t.effectiveProps.resetButtonIcon, "submit-loading": t.submitLoading, "show-advanced-button": t.effectiveProps.showAdvancedButton, "has-more-fields": t.hasMoreFields, collapsed: t.collapsed, "action-col-options": t.effectiveActionColOptions }, on: { submit: t.handleSubmit, reset: t.handleReset, toggle: function(n) {
1225
1246
  t.collapsed = !t.collapsed;
1226
1247
  } } }, [l("template", { slot: "submitBefore" }, [e._t("submitBefore")], 2), l("template", { slot: "resetBefore" }, [e._t("resetBefore")], 2), l("template", { slot: "advanceBefore" }, [e._t("advanceBefore")], 2), l("template", { slot: "advanceAfter" }, [e._t("advanceAfter")], 2), l("template", { slot: "actions" }, [e._t("actions")], 2)], 2)], 1) : e._e()], 2), t.effectiveProps.showAdvancedButton && t.hasMoreFields ? l("el-button", { staticClass: "ecp-form-actions__advance", attrs: { type: "text" }, on: { click: function(n) {
1227
1248
  t.collapsed = !t.collapsed;
1228
1249
  } } }, [l("i", { staticClass: "el-icon-d-arrow-left", class: t.collapsed ? "down" : "up" }), e._v(" " + e._s(t.collapsed ? "展开" : "收起") + " ")]) : e._e(), e._t("formFooter")], 2)], 1);
1229
- }, Bt = [], At = /* @__PURE__ */ se(
1230
- Ft,
1250
+ }, At = [], Mt = /* @__PURE__ */ se(
1231
1251
  Rt,
1232
1252
  Bt,
1253
+ At,
1233
1254
  !1,
1234
1255
  null,
1235
1256
  "bf70afca",
1236
1257
  null,
1237
1258
  null
1238
1259
  );
1239
- const Le = At.exports;
1240
- function Nt(i) {
1241
- const e = k(null), l = k(i ? fe(i) : void 0), t = () => i ? fe(i) : void 0, n = (g) => {
1242
- e.value = g;
1243
- const m = t();
1244
- m && Object.keys(m).length > 0 && g.setProps(m);
1260
+ const We = Mt.exports;
1261
+ function Vt(r) {
1262
+ const e = k(null), l = k(r ? fe(r) : void 0), t = () => r ? fe(r) : void 0, n = (y) => {
1263
+ e.value = y;
1264
+ const v = t();
1265
+ v && Object.keys(v).length > 0 && y.setProps(v);
1245
1266
  };
1246
- return i && J(
1267
+ return r && J(
1247
1268
  () => t(),
1248
- (g) => {
1249
- l.value = g, g && e.value && e.value.setProps(g);
1269
+ (y) => {
1270
+ l.value = y, y && e.value && e.value.setProps(y);
1250
1271
  },
1251
1272
  { deep: !0 }
1252
1273
  ), [n, {
1253
1274
  register: n,
1254
1275
  formAction: e,
1255
1276
  getFieldsValue: () => {
1256
- var g;
1257
- return ((g = e.value) == null ? void 0 : g.getFieldsValue()) ?? {};
1277
+ var y;
1278
+ return ((y = e.value) == null ? void 0 : y.getFieldsValue()) ?? {};
1258
1279
  },
1259
- setFieldsValue: async (g) => {
1260
- var m;
1261
- await ((m = e.value) == null ? void 0 : m.setFieldsValue(g));
1280
+ setFieldsValue: async (y) => {
1281
+ var v;
1282
+ await ((v = e.value) == null ? void 0 : v.setFieldsValue(y));
1262
1283
  },
1263
1284
  resetFields: async () => {
1264
- var g;
1265
- await ((g = e.value) == null ? void 0 : g.resetFields());
1285
+ var y;
1286
+ await ((y = e.value) == null ? void 0 : y.resetFields());
1266
1287
  },
1267
- validate: (g) => {
1268
- var m;
1269
- return ((m = e.value) == null ? void 0 : m.validate(g)) ?? Promise.resolve();
1288
+ validate: (y) => {
1289
+ var v;
1290
+ return ((v = e.value) == null ? void 0 : v.validate(y)) ?? Promise.resolve();
1270
1291
  },
1271
- validateFields: (g) => {
1272
- var m;
1273
- return ((m = e.value) == null ? void 0 : m.validateFields(g)) ?? Promise.resolve();
1292
+ validateFields: (y) => {
1293
+ var v;
1294
+ return ((v = e.value) == null ? void 0 : v.validateFields(y)) ?? Promise.resolve();
1274
1295
  },
1275
1296
  submit: () => {
1276
- var g;
1277
- return ((g = e.value) == null ? void 0 : g.submit()) ?? Promise.resolve();
1297
+ var y;
1298
+ return ((y = e.value) == null ? void 0 : y.submit()) ?? Promise.resolve();
1278
1299
  },
1279
- scrollToField: (g, m) => {
1280
- var W;
1281
- return ((W = e.value) == null ? void 0 : W.scrollToField(g, m)) ?? Promise.resolve();
1300
+ scrollToField: (y, v) => {
1301
+ var L;
1302
+ return ((L = e.value) == null ? void 0 : L.scrollToField(y, v)) ?? Promise.resolve();
1282
1303
  },
1283
- clearValidate: (g) => {
1284
- var m;
1285
- (m = e.value) == null || m.clearValidate(g);
1304
+ clearValidate: (y) => {
1305
+ var v;
1306
+ (v = e.value) == null || v.clearValidate(y);
1286
1307
  },
1287
- updateSchema: (g) => {
1288
- var m;
1289
- return ((m = e.value) == null ? void 0 : m.updateSchema(g)) ?? Promise.resolve();
1308
+ updateSchema: (y) => {
1309
+ var v;
1310
+ return ((v = e.value) == null ? void 0 : v.updateSchema(y)) ?? Promise.resolve();
1290
1311
  },
1291
- appendSchemaByField: (g, m, W) => {
1312
+ appendSchemaByField: (y, v, L) => {
1292
1313
  var b;
1293
- return ((b = e.value) == null ? void 0 : b.appendSchemaByField(g, m, W)) ?? Promise.resolve();
1314
+ return ((b = e.value) == null ? void 0 : b.appendSchemaByField(y, v, L)) ?? Promise.resolve();
1294
1315
  },
1295
- removeSchemaByField: (g) => {
1296
- var m;
1297
- return ((m = e.value) == null ? void 0 : m.removeSchemaByField(g)) ?? Promise.resolve();
1316
+ removeSchemaByField: (y) => {
1317
+ var v;
1318
+ return ((v = e.value) == null ? void 0 : v.removeSchemaByField(y)) ?? Promise.resolve();
1298
1319
  },
1299
- setProps: async (g) => {
1300
- var m;
1301
- l.value = { ...l.value, ...g }, await ((m = e.value) == null ? void 0 : m.setProps(g));
1320
+ setProps: async (y) => {
1321
+ var v;
1322
+ l.value = { ...l.value, ...y }, await ((v = e.value) == null ? void 0 : v.setProps(y));
1302
1323
  }
1303
1324
  }];
1304
1325
  }
1305
- const Mt = /* @__PURE__ */ oe({
1326
+ const Tt = /* @__PURE__ */ oe({
1306
1327
  __name: "ProDescriptions",
1307
1328
  props: {
1308
1329
  title: null,
@@ -1317,8 +1338,8 @@ const Mt = /* @__PURE__ */ oe({
1317
1338
  collapseOptions: { default: () => ({ canExpand: !1, defaultExpand: !0, expandButtonText: "展开", collapseButtonText: "收起", visibleRows: 1 }) }
1318
1339
  },
1319
1340
  emits: ["register"],
1320
- setup(i, { expose: e, emit: l }) {
1321
- const t = i, n = k({}), d = k({}), a = k([]), f = k(typeof window < "u" ? window.innerWidth : 1920), r = k(!0), y = oe({
1341
+ setup(r, { expose: e, emit: l }) {
1342
+ const t = r, n = k({}), u = k({}), a = k([]), f = k(typeof window < "u" ? window.innerWidth : 1920), i = k(!0), g = oe({
1322
1343
  name: "EcpDescriptionValueRenderer",
1323
1344
  props: {
1324
1345
  schema: { type: Object, required: !0 },
@@ -1329,7 +1350,7 @@ const Mt = /* @__PURE__ */ oe({
1329
1350
  setup(p) {
1330
1351
  return () => {
1331
1352
  const $ = p.schema, T = p.record, V = p.value, K = (X) => {
1332
- const ne = O($, X === p.emptyText ? V : X, T), ae = ue("span", X);
1353
+ const ne = z($, X === p.emptyText ? V : X, T), ae = ue("span", X);
1333
1354
  return ne ? ue("el-tooltip", { props: ne }, [ae]) : ae;
1334
1355
  };
1335
1356
  if ($.render) {
@@ -1339,65 +1360,65 @@ const Mt = /* @__PURE__ */ oe({
1339
1360
  return Array.isArray(V) ? K(V.length ? V.join(", ") : p.emptyText) : V == null || V === "" ? K(p.emptyText) : K(typeof V == "object" ? JSON.stringify(V) : String(V));
1340
1361
  };
1341
1362
  }
1342
- }), O = (p, $, T) => {
1363
+ }), z = (p, $, T) => {
1343
1364
  const V = p.tooltip;
1344
1365
  if (!V)
1345
1366
  return null;
1346
1367
  const K = typeof V == "function" ? V({ value: $, record: T, schema: p }) : V;
1347
1368
  return Be(K, $);
1348
- }, { getSetting: v } = Re(), x = S(() => ({ ...v("ProDescriptions"), ...t, ...n.value })), u = { xxl: 1920, xl: 1200, lg: 992, md: 768, sm: 576 }, F = (p, $) => {
1369
+ }, { getSetting: m } = Re(), P = F(() => ({ ...m("ProDescriptions"), ...t, ...n.value })), d = { xxl: 1920, xl: 1200, lg: 992, md: 768, sm: 576 }, x = (p, $) => {
1349
1370
  if (typeof p == "number")
1350
1371
  return Math.max(1, p);
1351
1372
  const T = p ?? {};
1352
- return $ >= u.xxl ? T.xxl ?? T.xl ?? T.lg ?? T.md ?? T.sm ?? T.xs ?? 3 : $ >= u.xl ? T.xl ?? T.lg ?? T.md ?? T.sm ?? T.xs ?? 3 : $ >= u.lg ? T.lg ?? T.md ?? T.sm ?? T.xs ?? 3 : $ >= u.md ? T.md ?? T.sm ?? T.xs ?? 3 : $ >= u.sm ? T.sm ?? T.xs ?? 2 : T.xs ?? 1;
1353
- }, _ = S(() => F(x.value.column, f.value)), D = S(() => x.value.data ?? d.value ?? {}), z = S(() => (a.value.length ? a.value : x.value.schema ?? []).filter((p) => p.dataIndex || p.field ? typeof p.show == "function" ? p.show(D.value) : p.show !== !1 : !1).map((p) => ({
1373
+ return $ >= d.xxl ? T.xxl ?? T.xl ?? T.lg ?? T.md ?? T.sm ?? T.xs ?? 3 : $ >= d.xl ? T.xl ?? T.lg ?? T.md ?? T.sm ?? T.xs ?? 3 : $ >= d.lg ? T.lg ?? T.md ?? T.sm ?? T.xs ?? 3 : $ >= d.md ? T.md ?? T.sm ?? T.xs ?? 3 : $ >= d.sm ? T.sm ?? T.xs ?? 2 : T.xs ?? 1;
1374
+ }, _ = F(() => x(P.value.column, f.value)), D = F(() => P.value.data ?? u.value ?? {}), I = F(() => (a.value.length ? a.value : P.value.schema ?? []).filter((p) => p.dataIndex || p.field ? typeof p.show == "function" ? p.show(D.value) : p.show !== !1 : !1).map((p) => ({
1354
1375
  ...p,
1355
1376
  dataIndex: p.dataIndex || p.field || ""
1356
- }))), g = S(() => {
1377
+ }))), y = F(() => {
1357
1378
  const p = [];
1358
1379
  let $ = { items: [] }, T = 0;
1359
1380
  const V = _.value;
1360
- return z.value.forEach((K, X) => {
1361
- const ne = z.value.length - X, ae = Math.max(1, Math.min(K.span ?? 1, V)), le = ne === 1 ? V - T || V : ae;
1381
+ return I.value.forEach((K, X) => {
1382
+ const ne = I.value.length - X, ae = Math.max(1, Math.min(K.span ?? 1, V)), le = ne === 1 ? V - T || V : ae;
1362
1383
  T + le > V && (p.push($), $ = { items: [] }, T = 0);
1363
1384
  const ie = ne === 1 && T < V ? Math.max(1, V - T) : le;
1364
1385
  $.items.push({ ...K, _span: ie }), T += ie, T >= V && (p.push($), $ = { items: [] }, T = 0);
1365
1386
  }), $.items.length > 0 && p.push($), p;
1366
- }), m = S(() => {
1387
+ }), v = F(() => {
1367
1388
  var $;
1368
- if (!W.value || r.value)
1369
- return g.value;
1370
- const p = Math.max(1, (($ = x.value.collapseOptions) == null ? void 0 : $.visibleRows) ?? 1);
1371
- return g.value.slice(0, p);
1372
- }), W = S(() => {
1389
+ if (!L.value || i.value)
1390
+ return y.value;
1391
+ const p = Math.max(1, (($ = P.value.collapseOptions) == null ? void 0 : $.visibleRows) ?? 1);
1392
+ return y.value.slice(0, p);
1393
+ }), L = F(() => {
1373
1394
  var $, T;
1374
- const p = Math.max(1, (($ = x.value.collapseOptions) == null ? void 0 : $.visibleRows) ?? 1);
1375
- return !!x.value.useCollapse && !!((T = x.value.collapseOptions) != null && T.canExpand) && g.value.length > p;
1376
- }), b = S(() => !!x.value.title || !!x.value.helpMessage || W.value), M = S(() => {
1395
+ const p = Math.max(1, (($ = P.value.collapseOptions) == null ? void 0 : $.visibleRows) ?? 1);
1396
+ return !!P.value.useCollapse && !!((T = P.value.collapseOptions) != null && T.canExpand) && y.value.length > p;
1397
+ }), b = F(() => !!P.value.title || !!P.value.helpMessage || L.value), M = F(() => {
1377
1398
  var p, $;
1378
1399
  return {
1379
- expand: ((p = x.value.collapseOptions) == null ? void 0 : p.expandButtonText) ?? "展开",
1380
- collapse: (($ = x.value.collapseOptions) == null ? void 0 : $.collapseButtonText) ?? "收起"
1400
+ expand: ((p = P.value.collapseOptions) == null ? void 0 : p.expandButtonText) ?? "展开",
1401
+ collapse: (($ = P.value.collapseOptions) == null ? void 0 : $.collapseButtonText) ?? "收起"
1381
1402
  };
1382
- }), j = S(() => ({
1403
+ }), j = F(() => ({
1383
1404
  gridTemplateColumns: `repeat(${_.value}, minmax(0, 1fr))`
1384
1405
  })), R = (p) => ({
1385
1406
  gridColumn: `span ${p._span}`
1386
1407
  }), N = (p) => ({
1387
1408
  minWidth: p.labelMinWidth ? `${p.labelMinWidth}px` : void 0,
1388
1409
  ...p.labelStyle ?? {}
1389
- }), L = (p) => ({
1410
+ }), W = (p) => ({
1390
1411
  minWidth: p.contentMinWidth ? `${p.contentMinWidth}px` : void 0,
1391
1412
  ...p.contentStyle ?? {}
1392
1413
  }), Z = (p) => D.value[p.dataIndex], ee = () => {
1393
- a.value = [...x.value.schema ?? []];
1414
+ a.value = [...P.value.schema ?? []];
1394
1415
  }, H = () => {
1395
- d.value = { ...x.value.data ?? {} };
1416
+ u.value = { ...P.value.data ?? {} };
1396
1417
  }, q = async (p) => {
1397
- n.value = { ...n.value, ...p }, p.schema && (a.value = [...p.schema]), p.data && (d.value = { ...p.data });
1418
+ n.value = { ...n.value, ...p }, p.schema && (a.value = [...p.schema]), p.data && (u.value = { ...p.data });
1398
1419
  }, Q = async (p) => {
1399
- d.value = { ...d.value, ...p }, n.value = { ...n.value, data: d.value };
1400
- }, U = () => ({ ...x.value.data ?? d.value ?? {} }), Y = {
1420
+ u.value = { ...u.value, ...p }, n.value = { ...n.value, data: u.value };
1421
+ }, U = () => ({ ...P.value.data ?? u.value ?? {} }), Y = {
1401
1422
  setProps: q,
1402
1423
  setData: Q,
1403
1424
  getData: U
@@ -1406,49 +1427,49 @@ const Mt = /* @__PURE__ */ oe({
1406
1427
  const re = () => {
1407
1428
  typeof window < "u" && (f.value = window.innerWidth);
1408
1429
  };
1409
- return ve(() => {
1430
+ return me(() => {
1410
1431
  var p;
1411
- ee(), H(), r.value = ((p = x.value.collapseOptions) == null ? void 0 : p.defaultExpand) !== !1, l("register", Y), typeof window < "u" && window.addEventListener("resize", re);
1432
+ ee(), H(), i.value = ((p = P.value.collapseOptions) == null ? void 0 : p.defaultExpand) !== !1, l("register", Y), typeof window < "u" && window.addEventListener("resize", re);
1412
1433
  }), Fe(() => {
1413
1434
  typeof window < "u" && window.removeEventListener("resize", re);
1414
- }), J(() => x.value.schema, ee, { deep: !0 }), J(() => x.value.data, H, { deep: !0 }), J(() => {
1435
+ }), J(() => P.value.schema, ee, { deep: !0 }), J(() => P.value.data, H, { deep: !0 }), J(() => {
1415
1436
  var p;
1416
- return (p = x.value.collapseOptions) == null ? void 0 : p.defaultExpand;
1437
+ return (p = P.value.collapseOptions) == null ? void 0 : p.defaultExpand;
1417
1438
  }, (p) => {
1418
- p !== void 0 && (r.value = p);
1419
- }), { __sfc: !0, props: t, emit: l, innerProps: n, innerData: d, innerSchema: a, windowWidth: f, expanded: r, DescriptionValueRenderer: y, normalizeTooltip: O, getSetting: v, effectiveProps: x, breakpoints: u, resolveColumn: F, currentColumn: _, effectiveData: D, visibleSchema: z, normalizedRows: g, renderedRows: m, showCollapseButton: W, showHeader: b, collapseButtonText: M, bodyStyle: j, getItemStyle: R, getLabelStyle: N, getContentStyle: L, getItemValue: Z, syncSchema: ee, syncData: H, setProps: q, setData: Q, getData: U, descriptionAction: Y, updateWindowWidth: re };
1439
+ p !== void 0 && (i.value = p);
1440
+ }), { __sfc: !0, props: t, emit: l, innerProps: n, innerData: u, innerSchema: a, windowWidth: f, expanded: i, DescriptionValueRenderer: g, normalizeTooltip: z, getSetting: m, effectiveProps: P, breakpoints: d, resolveColumn: x, currentColumn: _, effectiveData: D, visibleSchema: I, normalizedRows: y, renderedRows: v, showCollapseButton: L, showHeader: b, collapseButtonText: M, bodyStyle: j, getItemStyle: R, getLabelStyle: N, getContentStyle: W, getItemValue: Z, syncSchema: ee, syncData: H, setProps: q, setData: Q, getData: U, descriptionAction: Y, updateWindowWidth: re };
1420
1441
  }
1421
1442
  });
1422
- var Tt = function() {
1443
+ var Dt = function() {
1423
1444
  var n;
1424
1445
  var e = this, l = e._self._c, t = e._self._setupProxy;
1425
- return l("div", { staticClass: "ecp-pro-descriptions" }, [t.showHeader ? l("div", { staticClass: "ecp-pro-descriptions__header" }, [l("div", { staticClass: "ecp-pro-descriptions__title-wrap" }, [t.effectiveProps.title ? l("span", { staticClass: "ecp-pro-descriptions__title" }, [e._v(e._s(t.effectiveProps.title))]) : e._e(), t.effectiveProps.helpMessage ? l("el-tooltip", { attrs: { placement: "top", effect: "dark" } }, [l("template", { slot: "content" }, [Array.isArray(t.effectiveProps.helpMessage) ? l("span", e._l(t.effectiveProps.helpMessage, function(d, a) {
1426
- return l("div", { key: a }, [e._v(e._s(d))]);
1427
- }), 0) : l("span", [e._v(e._s(t.effectiveProps.helpMessage))])]), l("i", { staticClass: "el-icon-question ecp-pro-descriptions__help" })], 2) : e._e(), (n = t.effectiveProps.collapseOptions) != null && n.helpMessage ? l("el-tooltip", { attrs: { placement: "top", effect: "dark" } }, [l("template", { slot: "content" }, [Array.isArray(t.effectiveProps.collapseOptions.helpMessage) ? l("span", e._l(t.effectiveProps.collapseOptions.helpMessage, function(d, a) {
1428
- return l("div", { key: `collapse-${a}` }, [e._v(e._s(d))]);
1429
- }), 0) : l("span", [e._v(e._s(t.effectiveProps.collapseOptions.helpMessage))])]), l("i", { staticClass: "el-icon-info ecp-pro-descriptions__help" })], 2) : e._e()], 1), t.showCollapseButton ? l("el-button", { staticClass: "ecp-pro-descriptions__toggle", attrs: { type: "text" }, on: { click: function(d) {
1446
+ return l("div", { staticClass: "ecp-pro-descriptions" }, [t.showHeader ? l("div", { staticClass: "ecp-pro-descriptions__header" }, [l("div", { staticClass: "ecp-pro-descriptions__title-wrap" }, [t.effectiveProps.title ? l("span", { staticClass: "ecp-pro-descriptions__title" }, [e._v(e._s(t.effectiveProps.title))]) : e._e(), t.effectiveProps.helpMessage ? l("el-tooltip", { attrs: { placement: "top", effect: "dark" } }, [l("template", { slot: "content" }, [Array.isArray(t.effectiveProps.helpMessage) ? l("span", e._l(t.effectiveProps.helpMessage, function(u, a) {
1447
+ return l("div", { key: a }, [e._v(e._s(u))]);
1448
+ }), 0) : l("span", [e._v(e._s(t.effectiveProps.helpMessage))])]), l("i", { staticClass: "el-icon-question ecp-pro-descriptions__help" })], 2) : e._e(), (n = t.effectiveProps.collapseOptions) != null && n.helpMessage ? l("el-tooltip", { attrs: { placement: "top", effect: "dark" } }, [l("template", { slot: "content" }, [Array.isArray(t.effectiveProps.collapseOptions.helpMessage) ? l("span", e._l(t.effectiveProps.collapseOptions.helpMessage, function(u, a) {
1449
+ return l("div", { key: `collapse-${a}` }, [e._v(e._s(u))]);
1450
+ }), 0) : l("span", [e._v(e._s(t.effectiveProps.collapseOptions.helpMessage))])]), l("i", { staticClass: "el-icon-info ecp-pro-descriptions__help" })], 2) : e._e()], 1), t.showCollapseButton ? l("el-button", { staticClass: "ecp-pro-descriptions__toggle", attrs: { type: "text" }, on: { click: function(u) {
1430
1451
  t.expanded = !t.expanded;
1431
1452
  } } }, [e._v(" " + e._s(t.expanded ? t.collapseButtonText.collapse : t.collapseButtonText.expand) + " "), l("i", { staticClass: "el-icon-arrow-down", class: t.expanded ? "is-expanded" : "" })]) : e._e()], 1) : e._e(), l("div", e._b({ staticClass: "ecp-pro-descriptions__body", class: [
1432
1453
  `is-${t.effectiveProps.size}`,
1433
1454
  { "is-bordered": t.effectiveProps.bordered, "is-collapsed": t.showCollapseButton && !t.expanded }
1434
- ], style: t.bodyStyle }, "div", e.$attrs, !1), [e._l(t.renderedRows, function(d, a) {
1435
- return [e._l(d.items, function(f) {
1455
+ ], style: t.bodyStyle }, "div", e.$attrs, !1), [e._l(t.renderedRows, function(u, a) {
1456
+ return [e._l(u.items, function(f) {
1436
1457
  return [l("div", { key: `${a}-${f.dataIndex || f.field}`, staticClass: "ecp-pro-descriptions__item", style: t.getItemStyle(f) }, [l("div", { staticClass: "ecp-pro-descriptions__label", style: t.getLabelStyle(f) }, [e._v(" " + e._s(f.label) + " ")]), l("div", { staticClass: "ecp-pro-descriptions__content", style: t.getContentStyle(f) }, [e.$scopedSlots[f.slot || f.dataIndex] ? e._t(f.slot || f.dataIndex, null, { value: t.getItemValue(f), record: t.effectiveData, schema: f }) : l(t.DescriptionValueRenderer, { attrs: { schema: f, value: t.getItemValue(f), record: t.effectiveData, "empty-text": t.effectiveProps.emptyText || "-" } })], 2)])];
1437
1458
  })];
1438
1459
  })], 2)]);
1439
- }, Dt = [], kt = /* @__PURE__ */ se(
1440
- Mt,
1460
+ }, kt = [], $t = /* @__PURE__ */ se(
1441
1461
  Tt,
1442
1462
  Dt,
1463
+ kt,
1443
1464
  !1,
1444
1465
  null,
1445
1466
  "7d6cd376",
1446
1467
  null,
1447
1468
  null
1448
1469
  );
1449
- const Ke = kt.exports;
1450
- function Vt(i) {
1451
- const e = k(null), l = () => i ? fe(i) : void 0, t = () => {
1470
+ const Ke = $t.exports;
1471
+ function Lt(r) {
1472
+ const e = k(null), l = () => r ? fe(r) : void 0, t = () => {
1452
1473
  const a = fe(e);
1453
1474
  if (!a)
1454
1475
  throw new Error("ProDescriptions instance has not been registered");
@@ -1458,7 +1479,7 @@ function Vt(i) {
1458
1479
  const f = l();
1459
1480
  f && Object.keys(f).length > 0 && a.setProps(f);
1460
1481
  };
1461
- return i && J(
1482
+ return r && J(
1462
1483
  () => l(),
1463
1484
  (a) => {
1464
1485
  a && e.value && e.value.setProps(a);
@@ -1470,49 +1491,50 @@ function Vt(i) {
1470
1491
  getData: () => t().getData()
1471
1492
  }];
1472
1493
  }
1473
- const $t = [
1494
+ const zt = [
1474
1495
  { name: "ProTable", component: Ee },
1475
1496
  { name: "TableAction", component: Ne },
1476
- { name: "ProForm", component: Le },
1497
+ { name: "ProForm", component: We },
1477
1498
  { name: "ProFormItem", component: Ve },
1478
- { name: "FormActions", component: We },
1499
+ { name: "FormActions", component: Le },
1479
1500
  { name: "FormattedNumberInput", component: Ae },
1480
1501
  { name: "ProDescriptions", component: Ke }
1481
1502
  ];
1482
- function zt(i) {
1483
- $t.forEach(({ name: e, component: l }) => {
1484
- i.component(e, l);
1503
+ function It(r) {
1504
+ zt.forEach(({ name: e, component: l }) => {
1505
+ r.component(e, l);
1485
1506
  });
1486
1507
  }
1487
1508
  const Wt = {
1488
- install: zt,
1509
+ install: It,
1489
1510
  ProTable: Ee,
1490
- ProForm: Le,
1511
+ ProForm: We,
1491
1512
  ProDescriptions: Ke,
1492
1513
  TableAction: Ne,
1493
1514
  FormattedNumberInput: Ae
1494
1515
  };
1495
1516
  export {
1496
- We as FormActions,
1517
+ Le as FormActions,
1497
1518
  Ae as FormattedNumberInput,
1498
1519
  Ke as ProDescriptions,
1499
- Le as ProForm,
1520
+ We as ProForm,
1500
1521
  Ve as ProFormItem,
1501
1522
  Ee as ProTable,
1502
1523
  Ne as TableAction,
1524
+ at as applyNumericInputDigitLimits,
1503
1525
  ze as clampByIntegerDigits,
1504
1526
  Wt as default,
1505
1527
  Ie as formatWithThousands,
1506
- zt as install,
1528
+ It as install,
1507
1529
  Ce as normalizeNumericValue,
1508
- it as numberToEditString,
1509
- st as roundToDecimals,
1530
+ ct as numberToEditString,
1531
+ rt as roundToDecimals,
1510
1532
  $e as sanitizeNumericInput,
1511
1533
  Pe as stripNumberGrouping,
1512
- rt as toFixedDecimalString,
1534
+ it as toFixedDecimalString,
1513
1535
  Re as useComponentSetting,
1514
- Vt as useDescription,
1515
- Nt as useForm,
1516
- Et as useProTable
1536
+ Lt as useDescription,
1537
+ Vt as useForm,
1538
+ Nt as useProTable
1517
1539
  };
1518
1540
  //# sourceMappingURL=element-component-pro.es.js.map