cc1-form 1.2.13 → 1.2.15

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.
package/dist/cc1-form.js CHANGED
@@ -1,6 +1,6 @@
1
- import { ElMessage as ce, ElLoading as me, ElForm as q, ElFormItem as te, ElInput as x, ElSwitch as Z, ElSelect as G, ElOption as K, ElRadioGroup as le, ElRadio as ne, ElTreeSelect as ue, ElDatePicker as ie, ElDialog as ae, ElButton as L, ElTableColumn as ee, ElDropdown as he, ElDropdownMenu as ge, ElDropdownItem as oe, ElPagination as de, ElTable as ye } from "element-plus";
1
+ import { ElMessage as he, ElLoading as ge, ElForm as q, ElFormItem as te, ElInput as x, ElSwitch as Z, ElSelect as G, ElOption as N, ElRadioGroup as le, ElRadio as ne, ElTreeSelect as pe, ElDatePicker as ie, ElDialog as ae, ElButton as L, ElTableColumn as ee, ElDropdown as ye, ElDropdownMenu as be, ElDropdownItem as oe, ElPagination as de, ElTable as we } from "element-plus";
2
2
  import "vue-router";
3
- import { defineComponent as J, reactive as re, onMounted as fe, resolveComponent as _, createElementBlock as b, createCommentVNode as v, openBlock as u, renderSlot as C, createVNode as D, withCtx as y, createTextVNode as U, Fragment as $, renderList as A, createBlock as g, normalizeClass as I, normalizeStyle as pe, ref as N, unref as a, createElementVNode as E, mergeProps as V, toHandlers as z, resolveDynamicComponent as W, nextTick as be, toDisplayString as O, computed as we, getCurrentInstance as ke, createSlots as Q, withModifiers as ve, resolveDirective as Ce, withDirectives as Ve, normalizeProps as ze, guardReactiveProps as $e } from "vue";
3
+ import { defineComponent as K, reactive as re, onMounted as fe, resolveComponent as _, createElementBlock as b, createCommentVNode as v, openBlock as d, renderSlot as C, createVNode as U, withCtx as y, createTextVNode as D, Fragment as $, renderList as A, createBlock as h, normalizeClass as I, normalizeStyle as ce, ref as W, unref as a, createElementVNode as E, mergeProps as V, toHandlers as z, resolveDynamicComponent as J, nextTick as ke, toDisplayString as O, computed as me, getCurrentInstance as ve, createSlots as Q, withModifiers as Ce, resolveDirective as Ve, withDirectives as ze, normalizeProps as $e, guardReactiveProps as De } from "vue";
4
4
  class M {
5
5
  /**
6
6
  * Vue Router 实例,需在应用初始化时赋值
@@ -26,7 +26,7 @@ class M {
26
26
  * @param data 数据
27
27
  * @returns 是否显示
28
28
  */
29
- static isFun = (o, ...p) => Array.isArray(o) ? o.some((s) => typeof s == "function" ? s(...p) : s) : typeof o == "function" ? o(...p) : o;
29
+ static isFun = (o, ...p) => Array.isArray(o) ? o.some((n) => typeof n == "function" ? n(...p) : n) : typeof o == "function" ? o(...p) : o;
30
30
  /**
31
31
  * 获取路由参数,自动获取query、params中的参数, 哪个有就返回哪个
32
32
  */
@@ -62,7 +62,7 @@ class M {
62
62
  * @param type 消息类型
63
63
  * @param options 其他选项
64
64
  */
65
- static showMessage(o, p, s = {}) {
65
+ static showMessage(o, p, n = {}) {
66
66
  const l = Date.now();
67
67
  if (!this.tipMessages[o] || l - this.tipMessages[o] > this.tipMessagesGap) {
68
68
  this.tipMessages[o] = l;
@@ -71,9 +71,9 @@ class M {
71
71
  message: o,
72
72
  type: p
73
73
  },
74
- s
74
+ n
75
75
  );
76
- ce(t), setTimeout(() => {
76
+ he(t), setTimeout(() => {
77
77
  delete this.tipMessages[o];
78
78
  }, this.tipMessagesGap);
79
79
  }
@@ -103,7 +103,7 @@ class M {
103
103
  */
104
104
  static loading = (o = !0, p = "Loading...") => {
105
105
  Timer.un(this.loadingTimer), this.loadingTimer = Timer.once(() => {
106
- o ? this.loadingObj = me.service({
106
+ o ? this.loadingObj = ge.service({
107
107
  lock: !0,
108
108
  text: p,
109
109
  background: "rgba(0, 0, 0, 0.3)"
@@ -117,11 +117,11 @@ class M {
117
117
  */
118
118
  static openUrl = (o, p = !0) => {
119
119
  if (p) {
120
- let s = screen.width / 2 - 500, l = screen.height / 2 - 800 / 2 - 30;
120
+ let n = screen.width / 2 - 500, l = screen.height / 2 - 800 / 2 - 30;
121
121
  window.open(
122
122
  o,
123
123
  "_blank",
124
- "toolbar=no, location=yes, directories=no, status=yes, menubar=no, scrollbars=yes, resizable=no, copyhistory=no, width=1000, height=800, top=" + l + ", left=" + s
124
+ "toolbar=no, location=yes, directories=no, status=yes, menubar=no, scrollbars=yes, resizable=no, copyhistory=no, width=1000, height=800, top=" + l + ", left=" + n
125
125
  );
126
126
  } else
127
127
  window.open(o, "DescriptiveWindowName" + StrUtil.getId(), "resizable,scrollbars=yes,status=1,width=1024, height=600, top=0, left=0");
@@ -131,7 +131,7 @@ class M {
131
131
  * @param param
132
132
  * @returns
133
133
  */
134
- static getImgPic = (o) => new Promise(async (p, s) => {
134
+ static getImgPic = (o) => new Promise(async (p, n) => {
135
135
  let l = document.getElementById(o.id);
136
136
  const t = await M.loadModule("html2canvas");
137
137
  try {
@@ -150,7 +150,7 @@ class M {
150
150
  p(r);
151
151
  });
152
152
  } catch (e) {
153
- s(e);
153
+ n(e);
154
154
  }
155
155
  });
156
156
  }
@@ -538,9 +538,9 @@ class j {
538
538
  * @returns 该字段对应类型的 options 配置,如 select 类型返回 `options.select`
539
539
  */
540
540
  static findOptions = (o, p) => {
541
- const s = o.column.find((t) => t.key === p), l = (t) => t.replace(/-([a-z])/g, (e, r) => r.toUpperCase());
542
- if (s)
543
- return s.options[l(s.type)];
541
+ const n = o.column.find((t) => t.key === p), l = (t) => t.replace(/-([a-z])/g, (e, r) => r.toUpperCase());
542
+ if (n)
543
+ return n.options[l(n.type)];
544
544
  };
545
545
  /**
546
546
  * 更新组件数据
@@ -558,9 +558,9 @@ class j {
558
558
  }))
559
559
  )
560
560
  */
561
- static setOptionsData = (o, p, s) => {
561
+ static setOptionsData = (o, p, n) => {
562
562
  const l = j.findOptions(o, p);
563
- l && (l.data = s);
563
+ l && (l.data = n);
564
564
  };
565
565
  static form = {
566
566
  openBefore: {
@@ -571,9 +571,9 @@ class j {
571
571
  * @param treeData 树形数据
572
572
  * @param option 组件配置
573
573
  */
574
- parentId: (o, p, s, l) => {
574
+ parentId: (o, p, n, l) => {
575
575
  const t = T.config.table.rowKey;
576
- o ? p.type === M.EDialog.Add ? (p.form.parentId = o[t], p.form.sort = o.children.length + 1) : p.form.parentId = o.parentId.substring(o.parentId.lastIndexOf(",") + 1) : (p.form.parentId = "0", p.form.sort = s.length + 1), j.setOptionsData(l, "parentId", [{ [t]: "0", title: "根", children: s }]);
576
+ o ? p.type === M.EDialog.Add ? (p.form.parentId = o[t], p.form.sort = o.children.length + 1) : p.form.parentId = o.parentId.substring(o.parentId.lastIndexOf(",") + 1) : (p.form.parentId = "0", p.form.sort = n.length + 1), j.setOptionsData(l, "parentId", [{ [t]: "0", title: "根", children: n }]);
577
577
  }
578
578
  }
579
579
  };
@@ -620,8 +620,8 @@ class w {
620
620
  if (typeof o == "function")
621
621
  return o(...p);
622
622
  o = String(o);
623
- let s = 0;
624
- return o.replace(/{([^}]+)}/g, (l, t) => s < p.length ? String(p[s++]) : `{${t}}`);
623
+ let n = 0;
624
+ return o.replace(/{([^}]+)}/g, (l, t) => n < p.length ? String(p[n++]) : `{${t}}`);
625
625
  }
626
626
  static setI18n = (o) => {
627
627
  w.curd = ObjectUtil.deepMerge(w.curd, o);
@@ -643,11 +643,11 @@ class P {
643
643
  * @param field 字段名
644
644
  * @param row 行数据
645
645
  */
646
- static setId = (o, p, s) => {
646
+ static setId = (o, p, n) => {
647
647
  p[o] || (p[o] = []);
648
648
  const l = T.config.table.rowKey;
649
649
  p[o].forEach((t) => {
650
- s.forEach((e) => {
650
+ n.forEach((e) => {
651
651
  let r = e.default ?? "";
652
652
  e.type === "number" && (r = e.default ?? 0), e.type === "boolean" && (r = e.default ?? !1), e.type === "time" && (r = e.default ?? /* @__PURE__ */ new Date()), t[e.value] === void 0 && (t[e.value] = r);
653
653
  }), t[l] || (t[l] = P.getIdFun());
@@ -660,15 +660,15 @@ class P {
660
660
  * @param itemFields 元素字段-如:[{label:'',value:''}]
661
661
  * @param callback 回调函数
662
662
  */
663
- static add = (o, p, s, l) => {
664
- const t = JSONUtil.cp(s);
665
- P.setId(o, p, s);
663
+ static add = (o, p, n, l) => {
664
+ const t = JSONUtil.cp(n);
665
+ P.setId(o, p, n);
666
666
  const e = T.config.table.rowKey;
667
667
  p[o].push(
668
668
  t.reduce(
669
- (r, d) => {
670
- let m = d.default ?? "";
671
- return d.type === "number" && (m = d.default ?? 0), d.type === "boolean" && (m = d.default ?? !1), d.type === "time" && (m = d.default ?? /* @__PURE__ */ new Date()), r[d.value] = m, r;
669
+ (r, s) => {
670
+ let m = s.default ?? "";
671
+ return s.type === "number" && (m = s.default ?? 0), s.type === "boolean" && (m = s.default ?? !1), s.type === "time" && (m = s.default ?? /* @__PURE__ */ new Date()), r[s.value] = m, r;
672
672
  },
673
673
  { [e]: P.getIdFun() }
674
674
  )
@@ -681,9 +681,9 @@ class P {
681
681
  * @param item 元素-如:{_id:''}
682
682
  * @param callback 回调函数
683
683
  */
684
- static remove = (o, p, s, l) => {
684
+ static remove = (o, p, n, l) => {
685
685
  const t = T.config.table.rowKey;
686
- p[o] = p[o].filter((e) => e[t] !== s[t]), l?.(p);
686
+ p[o] = p[o].filter((e) => e[t] !== n[t]), l?.(p);
687
687
  };
688
688
  /**
689
689
  * 获取没有id的数据
@@ -692,20 +692,20 @@ class P {
692
692
  * @returns 没有id的数据
693
693
  */
694
694
  static getNoIdData = (o, p) => {
695
- const s = JSONUtil.cp(o), l = T.config.table.rowKey;
696
- return s.forEach((t) => {
695
+ const n = JSONUtil.cp(o), l = T.config.table.rowKey;
696
+ return n.forEach((t) => {
697
697
  t[l] && delete t[l], p && t[p] && P.getNoIdData(t[p], p);
698
- }), s;
698
+ }), n;
699
699
  };
700
700
  }
701
- const De = {
701
+ const Ee = {
702
702
  key: 0,
703
703
  class: "column curd-form-com-list",
704
704
  style: { width: "100%", gap: "10px" }
705
- }, Ee = { key: 0 }, Oe = {
705
+ }, Oe = { key: 0 }, Se = {
706
706
  class: "row items-center",
707
707
  style: { gap: "10px", width: "100%" }
708
- }, Se = { key: 1 }, se = /* @__PURE__ */ J({
708
+ }, Me = { key: 1 }, se = /* @__PURE__ */ K({
709
709
  __name: "list",
710
710
  props: {
711
711
  row: {
@@ -743,8 +743,8 @@ const De = {
743
743
  }
744
744
  },
745
745
  emits: ["change"],
746
- setup(n, { emit: o }) {
747
- const p = n, s = re({
746
+ setup(i, { emit: o }) {
747
+ const p = i, n = re({
748
748
  show: !1,
749
749
  add: (t, e, r) => {
750
750
  P.add(t, e, r, () => {
@@ -758,73 +758,73 @@ const De = {
758
758
  }
759
759
  });
760
760
  fe(() => {
761
- P.setId(p.field, p.row, p.itemFields), s.show = !0;
761
+ P.setId(p.field, p.row, p.itemFields), n.show = !0;
762
762
  });
763
763
  const l = o;
764
764
  return (t, e) => {
765
- const r = _("el-button"), d = _("el-input");
766
- return s.show ? (u(), b("div", De, [
767
- C(t.$slots, "list-start", { row: n.row }),
768
- n.addBottom ? v("", !0) : (u(), b("div", Ee, [
769
- D(r, {
765
+ const r = _("el-button"), s = _("el-input");
766
+ return n.show ? (d(), b("div", Ee, [
767
+ C(t.$slots, "list-start", { row: i.row }),
768
+ i.addBottom ? v("", !0) : (d(), b("div", Oe, [
769
+ U(r, {
770
770
  link: "",
771
771
  type: "primary",
772
- onClick: e[0] || (e[0] = (m) => s.add(n.field, n.row, n.itemFields))
772
+ onClick: e[0] || (e[0] = (m) => n.add(i.field, i.row, i.itemFields))
773
773
  }, {
774
774
  default: y(() => e[3] || (e[3] = [
775
- U("添加")
775
+ D("添加")
776
776
  ])),
777
777
  _: 1
778
778
  })
779
779
  ])),
780
- (u(!0), b($, null, A(n.row[n.field], (m) => (u(), b("div", Oe, [
780
+ (d(!0), b($, null, A(i.row[i.field], (m) => (d(), b("div", Se, [
781
781
  C(t.$slots, "item-start", {
782
782
  item: m,
783
- row: n.row
783
+ row: i.row
784
784
  }),
785
- (u(!0), b($, null, A(n.itemFields, (c) => (u(), g(d, {
785
+ (d(!0), b($, null, A(i.itemFields, (c) => (d(), h(s, {
786
786
  modelValue: m[c.value],
787
- "onUpdate:modelValue": (f) => m[c.value] = f,
788
- style: pe({ width: n.inputWidth }),
789
- class: I(n.inputClass),
790
- placeholder: c[n.label] || c[n.value],
791
- onChange: e[1] || (e[1] = (f) => l("change"))
787
+ "onUpdate:modelValue": (u) => m[c.value] = u,
788
+ style: ce({ width: i.inputWidth }),
789
+ class: I(i.inputClass),
790
+ placeholder: c[i.label] || c[i.value],
791
+ onChange: e[1] || (e[1] = (u) => l("change"))
792
792
  }, null, 8, ["modelValue", "onUpdate:modelValue", "style", "class", "placeholder"]))), 256)),
793
793
  C(t.$slots, "item-end", {
794
794
  item: m,
795
- row: n.row
795
+ row: i.row
796
796
  }),
797
- D(r, {
797
+ U(r, {
798
798
  link: "",
799
799
  type: "danger",
800
- onClick: (c) => s.remove(n.field, n.row, m)
800
+ onClick: (c) => n.remove(i.field, i.row, m)
801
801
  }, {
802
802
  default: y(() => e[4] || (e[4] = [
803
- U("删除")
803
+ D("删除")
804
804
  ])),
805
805
  _: 2
806
806
  }, 1032, ["onClick"])
807
807
  ]))), 256)),
808
- n.addBottom ? (u(), b("div", Se, [
809
- D(r, {
808
+ i.addBottom ? (d(), b("div", Me, [
809
+ U(r, {
810
810
  link: "",
811
811
  type: "primary",
812
- onClick: e[2] || (e[2] = (m) => s.add(n.field, n.row, n.itemFields))
812
+ onClick: e[2] || (e[2] = (m) => n.add(i.field, i.row, i.itemFields))
813
813
  }, {
814
814
  default: y(() => e[5] || (e[5] = [
815
- U("添加")
815
+ D("添加")
816
816
  ])),
817
817
  _: 1
818
818
  })
819
819
  ])) : v("", !0),
820
- C(t.$slots, "list-end", { row: n.row })
820
+ C(t.$slots, "list-end", { row: i.row })
821
821
  ])) : v("", !0);
822
822
  };
823
823
  }
824
- }), Me = {
824
+ }), Te = {
825
825
  class: "row form-item-content",
826
826
  style: { width: "100%" }
827
- }, Te = { class: "col" }, Ae = { class: "col" }, Fe = ["innerHTML"], Le = /* @__PURE__ */ J({
827
+ }, Ae = { class: "col" }, Fe = { class: "col" }, Le = ["innerHTML"], je = /* @__PURE__ */ K({
828
828
  __name: "column",
829
829
  props: {
830
830
  /**
@@ -840,20 +840,20 @@ const De = {
840
840
  default: ""
841
841
  }
842
842
  },
843
- setup(n, { expose: o }) {
844
- const p = M.isFun, s = M.EDialog, l = N(), t = n, e = re({
843
+ setup(i, { expose: o }) {
844
+ const p = M.isFun, n = M.EDialog, l = W(), t = i, e = re({
845
845
  rules: {},
846
846
  show: !0,
847
847
  form: {},
848
848
  formDefault: {},
849
- type: t.type || s.Add,
849
+ type: t.type || n.Add,
850
850
  formColumn: [],
851
- getDisabled: (r) => e.type === s.View ? r.disabled?.view === void 0 ? !0 : r.disabled?.view : r.disabled?.[e.type === s.Add ? "create" : "update"],
852
- getBind: (r) => r.options?.[e.type === s.Add ? "formAdd" : "formUpdate"]?.[r.type] || r.options?.[r.type] || {},
853
- getOn: (r) => r.options?.[e.type === s.Add ? "formAdd" : "formUpdate"]?.[r.type]?.on || r.options?.[r.type]?.on || {},
854
- getColumnSpan: (r, d) => {
851
+ getDisabled: (r) => e.type === n.View ? r.disabled?.view === void 0 ? !0 : r.disabled?.view : r.disabled?.[e.type === n.Add ? "create" : "update"],
852
+ getBind: (r) => r.options?.[e.type === n.Add ? "formAdd" : "formUpdate"]?.[r.type] || r.options?.[r.type] || {},
853
+ getOn: (r) => r.options?.[e.type === n.Add ? "formAdd" : "formUpdate"]?.[r.type]?.on || r.options?.[r.type]?.on || {},
854
+ getColumnSpan: (r, s) => {
855
855
  if (r.item.form?.spanCol) {
856
- const m = t.option.form?.maxSpan || 12, c = t.option.form?.defaultSpan || m / 2, k = d.filter((i) => !M.isFun(i.item.show?.form, e.form, e.type)).reduce((i, h) => i + (h.item.form?.span || c), 0);
856
+ const m = t.option.form?.maxSpan || 12, c = t.option.form?.defaultSpan || m / 2, k = s.filter((f) => !M.isFun(f.item.show?.form, e.form, e.type)).reduce((f, g) => f + (g.item.form?.span || c), 0);
857
857
  return (r.item.form?.span || c) + k;
858
858
  }
859
859
  return r.item.form?.span;
@@ -861,187 +861,187 @@ const De = {
861
861
  initColumnForm: () => {
862
862
  const r = t.option;
863
863
  e.formColumn = [], e.rules = {}, e.formDefault = {};
864
- const d = [], m = t.option.form?.maxSpan || 12, c = t.option.form?.defaultSpan || m / 2;
865
- let f = [];
866
- const k = (h) => {
867
- if (h.children) {
868
- h.children.forEach((S) => {
864
+ const s = [], m = t.option.form?.maxSpan || 12, c = t.option.form?.defaultSpan || m / 2;
865
+ let u = [];
866
+ const k = (g) => {
867
+ if (g.children) {
868
+ g.children.forEach((S) => {
869
869
  k(S);
870
870
  });
871
871
  return;
872
872
  }
873
- if (e.formDefault[h.key] = h.value, h.isForm && (typeof h.show?.form != "boolean" || h.show?.form)) {
874
- h.form = h.form || { span: c }, h.form.span = h.form.span ?? c;
875
- const S = h.form.span, B = f.reduce((R, Y) => R + Y.span, S), F = f.length;
876
- if (f.push({ item: h, span: S }), (F === 1 && f[0].span === 0 || B >= m || S === 0 && F > 1) && (d.push(f), f = []), h.rules) {
873
+ if (e.formDefault[g.key] = g.value, g.isForm && (typeof g.show?.form != "boolean" || g.show?.form)) {
874
+ g.form = g.form || { span: c }, g.form.span = g.form.span ?? c;
875
+ const S = g.form.span, B = u.reduce((R, Y) => R + Y.span, S), F = u.length;
876
+ if (u.push({ item: g, span: S }), (F === 1 && u[0].span === 0 || B >= m || S === 0 && F > 1) && (s.push(u), u = []), g.rules) {
877
877
  const R = {
878
878
  input: w.tCurd("placeholderInput"),
879
879
  select: w.tCurd("placeholderSelect")
880
- }, Y = (R[h.type] || R.input) + h.label;
881
- e.rules[h.key] = typeof h.rules == "boolean" ? [
880
+ }, Y = (R[g.type] || R.input) + g.label;
881
+ e.rules[g.key] = typeof g.rules == "boolean" ? [
882
882
  {
883
883
  required: !0,
884
884
  message: Y,
885
885
  trigger: "blur"
886
886
  }
887
- ] : h.rules;
887
+ ] : g.rules;
888
888
  }
889
889
  }
890
- }, i = (h, S) => {
891
- h.isForm = S, Array.isArray(h.children) && h.children.forEach((B) => i(B, S));
890
+ }, f = (g, S) => {
891
+ g.isForm = S, Array.isArray(g.children) && g.children.forEach((B) => f(B, S));
892
892
  };
893
- r.column.forEach((h) => {
894
- i(h, !0), k(h);
895
- }), f.length > 0 && d.push(f), e.formColumn = d, e.form = JSONUtil.cp(e.formDefault);
893
+ r.column.forEach((g) => {
894
+ f(g, !0), k(g);
895
+ }), u.length > 0 && s.push(u), e.formColumn = s, e.form = JSONUtil.cp(e.formDefault);
896
896
  }
897
897
  });
898
898
  return e.initColumnForm(), o({
899
899
  ref: l,
900
900
  conf: e
901
- }), (r, d) => (u(), g(a(q), {
901
+ }), (r, s) => (d(), h(a(q), {
902
902
  ref_key: "ruleFormRef",
903
903
  ref: l,
904
904
  model: e.form,
905
905
  rules: e.rules
906
906
  }, {
907
907
  default: y(() => [
908
- e.show ? (u(!0), b($, { key: 0 }, A(e.formColumn, (m, c) => (u(), b($, { key: c }, [
908
+ e.show ? (d(!0), b($, { key: 0 }, A(e.formColumn, (m, c) => (d(), b($, { key: c }, [
909
909
  a(p)(
910
- m.map((f) => f.item?.show?.form),
910
+ m.map((u) => u.item?.show?.form),
911
911
  e.form,
912
912
  e.type
913
- ) ? (u(), b("div", {
913
+ ) ? (d(), b("div", {
914
914
  key: 0,
915
915
  class: I(["row curd-row", {
916
- stripe: n.option.form?.stripe === void 0 ? !0 : n.option.form?.stripe
916
+ stripe: i.option.form?.stripe === void 0 ? !0 : i.option.form?.stripe
917
917
  }])
918
918
  }, [
919
919
  C(r.$slots, "form-start", {
920
920
  row: e.form
921
921
  }),
922
- (u(!0), b($, null, A(m, (f) => (u(), b($, {
923
- key: f.item.key
922
+ (d(!0), b($, null, A(m, (u) => (d(), b($, {
923
+ key: u.item.key
924
924
  }, [
925
- a(p)(f.item.show?.form, e.form, e.type) ? (u(), b("div", {
925
+ a(p)(u.item.show?.form, e.form, e.type) ? (d(), b("div", {
926
926
  key: 0,
927
- class: I([f.item.form.span > 0 ? `col-${e.getColumnSpan(f, m)}` : "col", `form-item-col-${f.item.key}`])
927
+ class: I([u.item.form.span > 0 ? `col-${e.getColumnSpan(u, m)}` : "col", `form-item-col-${u.item.key}`])
928
928
  }, [
929
- D(a(te), {
930
- label: f.item.text?.form?.label ?? f.item.label,
931
- prop: f.item.key,
932
- "label-width": f.item.text?.form?.label == "" ? 0 : f.item.form?.labelWidth || n.option.form?.labelWidth || "100px"
929
+ U(a(te), {
930
+ label: u.item.text?.form?.label ?? u.item.label,
931
+ prop: u.item.key,
932
+ "label-width": u.item.text?.form?.label == "" ? 0 : u.item.form?.labelWidth || i.option.form?.labelWidth || "100px"
933
933
  }, {
934
934
  default: y(() => [
935
- E("div", Me, [
936
- C(r.$slots, "form-" + f.item.key + "-start", {
935
+ E("div", Te, [
936
+ C(r.$slots, "form-" + u.item.key + "-start", {
937
937
  row: e.form,
938
- item: f.item
938
+ item: u.item
939
939
  }),
940
- E("div", Te, [
941
- E("div", Ae, [
942
- C(r.$slots, "form-" + f.item.key, {
940
+ E("div", Ae, [
941
+ E("div", Fe, [
942
+ C(r.$slots, "form-" + u.item.key, {
943
943
  row: e.form,
944
- item: f.item
944
+ item: u.item
945
945
  }, () => [
946
- f.item.type === "input" ? (u(), g(a(x), V({
946
+ u.item.type === "input" ? (d(), h(a(x), V({
947
947
  key: 0,
948
- modelValue: e.form[f.item.key],
949
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
948
+ modelValue: e.form[u.item.key],
949
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
950
950
  ref_for: !0
951
- }, e.getBind(f.item), z(e.getOn(f.item)), {
952
- disabled: e.getDisabled(f.item)
953
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : f.item.type === "switch" ? (u(), g(a(Z), V({
951
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
952
+ disabled: e.getDisabled(u.item)
953
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type === "switch" ? (d(), h(a(Z), V({
954
954
  key: 1,
955
- modelValue: e.form[f.item.key],
956
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
955
+ modelValue: e.form[u.item.key],
956
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
957
957
  ref_for: !0
958
- }, e.getBind(f.item), z(e.getOn(f.item)), {
959
- disabled: e.getDisabled(f.item)
960
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : f.item.type === "select" ? (u(), g(a(G), V({
958
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
959
+ disabled: e.getDisabled(u.item)
960
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type === "select" ? (d(), h(a(G), V({
961
961
  key: 2,
962
- modelValue: e.form[f.item.key],
963
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
962
+ modelValue: e.form[u.item.key],
963
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
964
964
  ref_for: !0
965
- }, e.getBind(f.item), z(e.getOn(f.item)), {
966
- disabled: e.getDisabled(f.item),
965
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
966
+ disabled: e.getDisabled(u.item),
967
967
  style: { width: "100%" }
968
968
  }), {
969
969
  default: y(() => [
970
- (u(!0), b($, null, A(f.item.options?.select?.data, (k) => (u(), g(a(K), {
970
+ (d(!0), b($, null, A(u.item.options?.select?.data, (k) => (d(), h(a(N), {
971
971
  key: k.value,
972
972
  label: k.label,
973
973
  value: k.value
974
974
  }, null, 8, ["label", "value"]))), 128))
975
975
  ]),
976
976
  _: 2
977
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : f.item.type === "radio" ? (u(), g(a(le), V({
977
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type === "radio" ? (d(), h(a(le), V({
978
978
  key: 3,
979
- modelValue: e.form[f.item.key],
980
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
979
+ modelValue: e.form[u.item.key],
980
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
981
981
  ref_for: !0
982
- }, e.getBind(f.item), z(e.getOn(f.item)), {
983
- disabled: e.getDisabled(f.item),
982
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
983
+ disabled: e.getDisabled(u.item),
984
984
  style: { width: "100%" }
985
985
  }), {
986
986
  default: y(() => [
987
- (u(!0), b($, null, A(f.item.options?.radio?.data, (k) => (u(), g(a(ne), {
987
+ (d(!0), b($, null, A(u.item.options?.radio?.data, (k) => (d(), h(a(ne), {
988
988
  key: k.value,
989
989
  label: k.label,
990
990
  value: k.value
991
991
  }, null, 8, ["label", "value"]))), 128))
992
992
  ]),
993
993
  _: 2
994
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : f.item.type === "list" ? (u(), g(se, V({
994
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type === "list" ? (d(), h(se, V({
995
995
  key: 4,
996
996
  row: e.form,
997
- field: f.item.key,
997
+ field: u.item.key,
998
998
  ref_for: !0
999
- }, e.getBind(f.item), z(e.getOn(f.item)), {
1000
- disabled: e.getDisabled(f.item),
999
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
1000
+ disabled: e.getDisabled(u.item),
1001
1001
  style: { width: "100%" }
1002
- }), null, 16, ["row", "field", "disabled"])) : f.item.type === "treeSelect" ? (u(), g(a(ue), V({
1002
+ }), null, 16, ["row", "field", "disabled"])) : u.item.type === "treeSelect" ? (d(), h(a(pe), V({
1003
1003
  key: 5,
1004
- modelValue: e.form[f.item.key],
1005
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
1004
+ modelValue: e.form[u.item.key],
1005
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
1006
1006
  ref_for: !0
1007
- }, e.getBind(f.item), z(e.getOn(f.item)), {
1008
- disabled: e.getDisabled(f.item),
1007
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
1008
+ disabled: e.getDisabled(u.item),
1009
1009
  style: { width: "100%" }
1010
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : f.item.type === "datetime" ? (u(), g(a(ie), V({
1010
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type === "datetime" ? (d(), h(a(ie), V({
1011
1011
  key: 6,
1012
- modelValue: e.form[f.item.key],
1013
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
1012
+ modelValue: e.form[u.item.key],
1013
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
1014
1014
  ref_for: !0
1015
- }, e.getBind(f.item), z(e.getOn(f.item)), {
1016
- disabled: e.getDisabled(f.item)
1017
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : f.item.type && (a(j).customComponent[f.item.type] || a(j).customComponent[f.item.type]?.form) ? (u(), g(W(a(j).customComponent[f.item.type]?.form || a(j).customComponent[f.item.type]), V({
1015
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
1016
+ disabled: e.getDisabled(u.item)
1017
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type && (a(j).customComponent[u.item.type] || a(j).customComponent[u.item.type]?.form) ? (d(), h(J(a(j).customComponent[u.item.type]?.form || a(j).customComponent[u.item.type]), V({
1018
1018
  key: 7,
1019
- modelValue: e.form[f.item.key],
1020
- "onUpdate:modelValue": (k) => e.form[f.item.key] = k,
1019
+ modelValue: e.form[u.item.key],
1020
+ "onUpdate:modelValue": (k) => e.form[u.item.key] = k,
1021
1021
  ref_for: !0
1022
- }, e.getBind(f.item), z(e.getOn(f.item)), {
1023
- disabled: e.getDisabled(f.item)
1022
+ }, e.getBind(u.item), z(e.getOn(u.item)), {
1023
+ disabled: e.getDisabled(u.item)
1024
1024
  }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : v("", !0)
1025
1025
  ]),
1026
- C(r.$slots, "form-" + f.item.key + "-right", {
1026
+ C(r.$slots, "form-" + u.item.key + "-right", {
1027
1027
  row: e.form,
1028
- item: f.item
1028
+ item: u.item
1029
1029
  })
1030
1030
  ]),
1031
- C(r.$slots, "form-" + f.item.key + "-tip", {
1031
+ C(r.$slots, "form-" + u.item.key + "-tip", {
1032
1032
  row: e.form,
1033
- item: f.item
1033
+ item: u.item
1034
1034
  }, () => [
1035
- f.item.form?.tipText ? (u(), b("div", {
1035
+ u.item.form?.tipText ? (d(), b("div", {
1036
1036
  key: 0,
1037
1037
  class: "form-tip-text",
1038
- innerHTML: typeof f.item.form?.tipText == "function" ? f.item.form?.tipText(e.form, e.type) : f.item.form?.tipText
1039
- }, null, 8, Fe)) : v("", !0)
1038
+ innerHTML: typeof u.item.form?.tipText == "function" ? u.item.form?.tipText(e.form, e.type) : u.item.form?.tipText
1039
+ }, null, 8, Le)) : v("", !0)
1040
1040
  ])
1041
1041
  ]),
1042
- C(r.$slots, "form-" + f.item.key + "-end", {
1042
+ C(r.$slots, "form-" + u.item.key + "-end", {
1043
1043
  row: e.form,
1044
- item: f.item
1044
+ item: u.item
1045
1045
  })
1046
1046
  ])
1047
1047
  ]),
@@ -1059,7 +1059,7 @@ const De = {
1059
1059
  }, 8, ["model", "rules"]));
1060
1060
  }
1061
1061
  });
1062
- class je {
1062
+ class Be {
1063
1063
  /**
1064
1064
  * 导出数据为 Excel 文件(.xlsx),自动触发浏览器下载
1065
1065
  *
@@ -1067,20 +1067,20 @@ class je {
1067
1067
  * @param columns - 列配置数组,需包含 `key`(数据字段)和 `label`(Excel 表头)
1068
1068
  * @param fileName - 文件名(不含扩展名),支持字符串或返回字符串的函数;默认生成「导出数据_日期_时间戳」
1069
1069
  */
1070
- static exportToExcel = async (o, p, s) => {
1070
+ static exportToExcel = async (o, p, n) => {
1071
1071
  if (!o || o.length === 0) return;
1072
- const l = await M.loadModule("xlsx"), t = o.map((d) => {
1072
+ const l = await M.loadModule("xlsx"), t = o.map((s) => {
1073
1073
  const m = {};
1074
1074
  return p.forEach((c) => {
1075
- m[c.label] = d[c.key];
1075
+ m[c.label] = s[c.key];
1076
1076
  }), m;
1077
1077
  }), e = l.utils.json_to_sheet(t), r = l.utils.book_new();
1078
- l.utils.book_append_sheet(r, e, "Sheet1"), s ? typeof s == "function" && (s = s()) : s = `导出数据_${(/* @__PURE__ */ new Date()).Format("yyyy-MM-dd")}_${(/* @__PURE__ */ new Date()).getTime()}`, l.writeFile(r, `${s}.xlsx`);
1078
+ l.utils.book_append_sheet(r, e, "Sheet1"), n ? typeof n == "function" && (n = n()) : n = `导出数据_${(/* @__PURE__ */ new Date()).Format("yyyy-MM-dd")}_${(/* @__PURE__ */ new Date()).getTime()}`, l.writeFile(r, `${n}.xlsx`);
1079
1079
  };
1080
1080
  }
1081
- const H = M.EDialog, Be = (n) => {
1082
- const o = N(), p = N(), s = N(), l = re({
1083
- option: n.option,
1081
+ const H = M.EDialog, Re = (i) => {
1082
+ const o = W(), p = W(), n = W(), l = re({
1083
+ option: i.option,
1084
1084
  /** 查询区域相关配置对象 */
1085
1085
  search: {
1086
1086
  /** 查询表单列集合 */
@@ -1097,18 +1097,18 @@ const H = M.EDialog, Be = (n) => {
1097
1097
  /** 组装实际要搜索的数据对象 */
1098
1098
  getFormData: () => {
1099
1099
  let t = {};
1100
- n.option.column.forEach((r) => {
1100
+ i.option.column.forEach((r) => {
1101
1101
  (typeof r.show?.search == "function" ? r.show?.search(l.search.form) : r.show?.search) && (t[r.key] = l.search.form[r.key]);
1102
1102
  });
1103
- const e = n.option.search?.before?.(t);
1103
+ const e = i.option.search?.before?.(t);
1104
1104
  return e && (t = e), t;
1105
1105
  },
1106
1106
  /** 重置搜索表单 */
1107
1107
  reset: () => {
1108
1108
  const t = l.search.formDefault;
1109
1109
  Object.keys(t).forEach((e) => {
1110
- n.option.search?.resetMode === "none" ? t[e] = void 0 : t[e] = l.search.formDefault[e];
1111
- }), l.search.form = ObjectUtil.deepMerge(t, {}), l.page.num = 1, n.option.init !== !1 && l.table.getList();
1110
+ i.option.search?.resetMode === "none" ? t[e] = void 0 : t[e] = l.search.formDefault[e];
1111
+ }), l.search.form = ObjectUtil.deepMerge(t, {}), l.page.num = 1, i.option.init !== !1 && l.table.getList();
1112
1112
  },
1113
1113
  /** 提交搜索表单 */
1114
1114
  submit: () => {
@@ -1122,15 +1122,15 @@ const H = M.EDialog, Be = (n) => {
1122
1122
  /** 总条数 */
1123
1123
  total: 0,
1124
1124
  /** 分页控件的布局方式 */
1125
- layout: n.option.page?.layout || T.config.pagination.layout,
1125
+ layout: i.option.page?.layout || T.config.pagination.layout,
1126
1126
  /** 是否显示到工具栏 默认不显示 配置后show属性无效 */
1127
- showTools: n.option.page?.showTools || T.config.pagination.showTools,
1127
+ showTools: i.option.page?.showTools || T.config.pagination.showTools,
1128
1128
  /** 当前每页条数 */
1129
- size: n.option.page?.size || T.config.pagination.size,
1129
+ size: i.option.page?.size || T.config.pagination.size,
1130
1130
  /** 支持切换的每页条数选项 */
1131
- sizeList: n.option.page?.sizeList || T.config.pagination.pageSizes,
1131
+ sizeList: i.option.page?.sizeList || T.config.pagination.pageSizes,
1132
1132
  /** 分页器计数 */
1133
- pagerCount: n.option.page?.pagerCount || T.config.pagination.pagerCount,
1133
+ pagerCount: i.option.page?.pagerCount || T.config.pagination.pagerCount,
1134
1134
  /** 获取分页查询参数 */
1135
1135
  getQuery: (t = {}) => ({
1136
1136
  [T.config.field.page.size]: t.size || l.page.size,
@@ -1165,8 +1165,8 @@ const H = M.EDialog, Be = (n) => {
1165
1165
  else {
1166
1166
  const t = (e) => {
1167
1167
  let r = [];
1168
- return e.forEach((d) => {
1169
- r.push(d[n.option.table.rowKey]), d.children && d.children.length > 0 && (r = r.concat(t(d.children)));
1168
+ return e.forEach((s) => {
1169
+ r.push(s[i.option.table.rowKey]), s.children && s.children.length > 0 && (r = r.concat(t(s.children)));
1170
1170
  }), r;
1171
1171
  };
1172
1172
  l.table.expand.rowKeys = t(l.table.data);
@@ -1196,8 +1196,8 @@ const H = M.EDialog, Be = (n) => {
1196
1196
  const t = !l.table.header.group.expand;
1197
1197
  l.table.header.group.expand = t;
1198
1198
  const e = (r) => {
1199
- r.forEach((d) => {
1200
- d.table?.header?.group !== void 0 && (d.table.header.group = !t), d.table?.header?.groupKey !== void 0 && (d.table.header.show = t), Array.isArray(d.children) && d.children.length > 0 && e(d.children);
1199
+ r.forEach((s) => {
1200
+ s.table?.header?.group !== void 0 && (s.table.header.group = !t), s.table?.header?.groupKey !== void 0 && (s.table.header.show = t), Array.isArray(s.children) && s.children.length > 0 && e(s.children);
1201
1201
  });
1202
1202
  };
1203
1203
  e(l.table.column.list);
@@ -1207,27 +1207,27 @@ const H = M.EDialog, Be = (n) => {
1207
1207
  /** 获取数据列表接口实现 */
1208
1208
  getList: async () => {
1209
1209
  l.table.loading = !0;
1210
- const t = n.option.api.list;
1210
+ const t = i.option.api.list;
1211
1211
  try {
1212
1212
  await l.initApiData("init");
1213
1213
  let e = {};
1214
1214
  if (l.table.sort.prop) {
1215
- const { props: h, order: S } = T.config.table.sort;
1215
+ const { props: g, order: S } = T.config.table.sort;
1216
1216
  e = {
1217
- [h.field]: l.table.sort.prop,
1217
+ [g.field]: l.table.sort.prop,
1218
1218
  [S.field]: l.table.sort.order
1219
1219
  };
1220
1220
  }
1221
1221
  const r = await t({
1222
1222
  ...l.page.getQuery(),
1223
1223
  ...e
1224
- }), d = T.config.field.result, m = r.data || { [d.list]: r };
1225
- let c = (Array.isArray(m[d.list]), m[d.list]);
1226
- const f = l.update.formColumn.flat(), i = ObjectUtil.deepMerge({ data: c }, {}).data.map((h) => (Object.keys(h).forEach((B) => {
1227
- const F = f.find((R) => R.item.key === B);
1224
+ }), s = T.config.field.result, m = r.data || { [s.list]: r };
1225
+ let c = (Array.isArray(m[s.list]), m[s.list]);
1226
+ const u = l.update.formColumn.flat(), f = ObjectUtil.deepMerge({ data: c }, {}).data.map((g) => (Object.keys(g).forEach((B) => {
1227
+ const F = u.find((R) => R.item.key === B);
1228
1228
  F && ["select", "radio"].includes(F.item.type) && (F.item.table.format || (F.item.table.format = (R) => F.item.options[F.item.type].data?.find((Y) => Y.value == R[B])?.label || R[B]));
1229
- }), h));
1230
- l.table.data = n.option.data ? await n.option.data(i, c) : i, l.page.total = m[d.total] || 0;
1229
+ }), g));
1230
+ l.table.data = i.option.data ? await i.option.data(f, c) : f, l.page.total = m[s.total] || 0;
1231
1231
  } catch (e) {
1232
1232
  console.error(e);
1233
1233
  } finally {
@@ -1245,31 +1245,31 @@ const H = M.EDialog, Be = (n) => {
1245
1245
  /** 设置表格多选数据 */
1246
1246
  setList: (t, e) => {
1247
1247
  l.table.selection.list = [];
1248
- const r = s.value;
1248
+ const r = n.value;
1249
1249
  if (r?.clearSelection(), !r || !t?.length) return;
1250
- const d = n.option.table?.rowKey, m = l.table.data, c = (f) => {
1251
- const k = (i) => {
1252
- for (const h of i) {
1253
- if (d != null && d !== "") {
1254
- if (h[d] === f[d]) return h;
1255
- } else if (h === f)
1256
- return h;
1257
- if (Array.isArray(h.children) && h.children.length) {
1258
- const S = k(h.children);
1250
+ const s = i.option.table?.rowKey, m = l.table.data, c = (u) => {
1251
+ const k = (f) => {
1252
+ for (const g of f) {
1253
+ if (s != null && s !== "") {
1254
+ if (g[s] === u[s]) return g;
1255
+ } else if (g === u)
1256
+ return g;
1257
+ if (Array.isArray(g.children) && g.children.length) {
1258
+ const S = k(g.children);
1259
1259
  if (S !== void 0) return S;
1260
1260
  }
1261
1261
  }
1262
1262
  };
1263
1263
  return k(m);
1264
1264
  };
1265
- be(() => {
1266
- t.forEach((f) => {
1267
- const k = c(f) ?? f;
1265
+ ke(() => {
1266
+ t.forEach((u) => {
1267
+ const k = c(u) ?? u;
1268
1268
  if (e) {
1269
- const i = () => {
1269
+ const f = () => {
1270
1270
  r.toggleRowSelection(k, !0, !1);
1271
1271
  };
1272
- e(f) !== !1 && i();
1272
+ e(u) !== !1 && f();
1273
1273
  } else
1274
1274
  r.toggleRowSelection(k, !0, !1);
1275
1275
  });
@@ -1300,22 +1300,22 @@ const H = M.EDialog, Be = (n) => {
1300
1300
  run: {
1301
1301
  /** 执行指定方式的导出(如select、page、all) */
1302
1302
  start: async (t) => {
1303
- let e = await l.export.run[t](), r = n.option.column;
1304
- const d = ObjectUtil.deepMerge(
1303
+ let e = await l.export.run[t](), r = i.option.column;
1304
+ const s = ObjectUtil.deepMerge(
1305
1305
  {
1306
1306
  data: e,
1307
1307
  columns: r
1308
1308
  },
1309
1309
  {}
1310
- ), m = n.option.tools?.export || {};
1311
- m.before && m.before(d), je.exportToExcel(d.data, d.columns, m.fileName);
1310
+ ), m = i.option.tools?.export || {};
1311
+ m.before && m.before(s), Be.exportToExcel(s.data, s.columns, m.fileName);
1312
1312
  },
1313
1313
  /** 获取当前选中项进行导出 */
1314
1314
  select: async () => {
1315
1315
  l.export.loading = !0;
1316
1316
  try {
1317
- if (n.option.tools?.export?.select) {
1318
- await n.option.tools?.export?.select({
1317
+ if (i.option.tools?.export?.select) {
1318
+ await i.option.tools?.export?.select({
1319
1319
  ...l.page.getQuery(),
1320
1320
  items: l.table.selection.list
1321
1321
  });
@@ -1334,8 +1334,8 @@ const H = M.EDialog, Be = (n) => {
1334
1334
  page: async () => {
1335
1335
  l.export.loading = !0;
1336
1336
  try {
1337
- if (n.option.tools?.export?.page) {
1338
- await n.option.tools?.export?.page({
1337
+ if (i.option.tools?.export?.page) {
1338
+ await i.option.tools?.export?.page({
1339
1339
  ...l.page.getQuery()
1340
1340
  });
1341
1341
  return;
@@ -1353,13 +1353,13 @@ const H = M.EDialog, Be = (n) => {
1353
1353
  all: async () => {
1354
1354
  l.export.loading = !0;
1355
1355
  try {
1356
- if (n.option.tools?.export?.all) {
1357
- await n.option.tools?.export?.all({
1356
+ if (i.option.tools?.export?.all) {
1357
+ await i.option.tools?.export?.all({
1358
1358
  ...l.page.getQuery()
1359
1359
  });
1360
1360
  return;
1361
1361
  }
1362
- const t = n.option.api.list, e = await t({
1362
+ const t = i.option.api.list, e = await t({
1363
1363
  ...l.page.getQuery({
1364
1364
  size: 999999,
1365
1365
  num: 1
@@ -1401,23 +1401,23 @@ const H = M.EDialog, Be = (n) => {
1401
1401
  /** 表单所有列,二维数组结构按行分组 */
1402
1402
  formColumn: [],
1403
1403
  /** 判断是否禁用当前字段 */
1404
- getDisabled: (t, e = !1) => n.option.table?.editMode && e ? t.disabled?.table === void 0 ? !1 : t.disabled?.table : l.update.type === H.View ? t.disabled?.view === void 0 ? !0 : t.disabled?.view : t.disabled?.[l.update.type === H.Add ? "create" : "update"],
1404
+ getDisabled: (t, e = !1) => i.option.table?.editMode && e ? t.disabled?.table === void 0 ? !1 : t.disabled?.table : l.update.type === H.View ? t.disabled?.view === void 0 ? !0 : t.disabled?.view : t.disabled?.[l.update.type === H.Add ? "create" : "update"],
1405
1405
  /** 获取表单组件绑定属性 */
1406
1406
  getBind: (t) => t.options?.[l.update.type === H.Add ? "formAdd" : "formUpdate"]?.[t.type] || t.options?.[t.type] || {},
1407
1407
  /** 获取表单组件事件属性 */
1408
1408
  getOn: (t, e) => {
1409
- const d = t.options?.[l.update.type === H.Add ? "formAdd" : "formUpdate"]?.[t.type]?.on || t.options?.[t.type]?.on || {}, m = {};
1410
- return Object.keys(d).forEach((c) => {
1411
- const f = d[c];
1412
- typeof f == "function" ? m[c] = function(...k) {
1413
- return f.apply(this, [...k, e || l.update.form, t]);
1414
- } : m[c] = f;
1409
+ const s = t.options?.[l.update.type === H.Add ? "formAdd" : "formUpdate"]?.[t.type]?.on || t.options?.[t.type]?.on || {}, m = {};
1410
+ return Object.keys(s).forEach((c) => {
1411
+ const u = s[c];
1412
+ typeof u == "function" ? m[c] = function(...k) {
1413
+ return u.apply(this, [...k, e || l.update.form, t]);
1414
+ } : m[c] = u;
1415
1415
  }), m;
1416
1416
  },
1417
1417
  /** 获取表单组件绑定属性和事件 */
1418
1418
  getOptions: (t) => {
1419
1419
  try {
1420
- const r = l.update.formColumn.flat().find((d) => d.item.key === t)?.item;
1420
+ const r = l.update.formColumn.flat().find((s) => s.item.key === t)?.item;
1421
1421
  return r ? {
1422
1422
  options: r.options,
1423
1423
  // @ts-ignore
@@ -1433,10 +1433,10 @@ const H = M.EDialog, Be = (n) => {
1433
1433
  data: {},
1434
1434
  /** 返回编辑时与原值的变更数据,用于局部更新API */
1435
1435
  getApiData: (t) => {
1436
- if (n.option.form?.editAll)
1436
+ if (i.option.form?.editAll)
1437
1437
  return t;
1438
1438
  let e = {
1439
- [n.option.table?.rowKey]: l.update.edit.data[n.option.table?.rowKey]
1439
+ [i.option.table?.rowKey]: l.update.edit.data[i.option.table?.rowKey]
1440
1440
  };
1441
1441
  return Object.keys(l.update.edit.data).forEach((r) => {
1442
1442
  t[r] !== l.update.edit.data[r] && (e[r] = t[r]);
@@ -1451,7 +1451,7 @@ const H = M.EDialog, Be = (n) => {
1451
1451
  try {
1452
1452
  l.update.type = t;
1453
1453
  const r = t === H.Add;
1454
- l.update.edit.data = e, l.update.title = w.tCurd(r ? "add" : t === H.View ? "view" : "edit"), l.update.form = ObjectUtil.deepMerge(r ? l.update.formDefault : e, {}), await l.initApiData("update"), await n.option.form?.openBefore?.(l.update.form, l.update), (!n.option.table?.inlineEdit || r) && (l.update.show = !0, l.update.showContent = !0), n.option.form?.openAfter?.(l.update.form, l.update);
1454
+ l.update.edit.data = e, l.update.title = w.tCurd(r ? "add" : t === H.View ? "view" : "edit"), l.update.form = ObjectUtil.deepMerge(r ? l.update.formDefault : e, {}), await l.initApiData("update"), await i.option.form?.openBefore?.(l.update.form, l.update), (!i.option.table?.inlineEdit || r) && (l.update.show = !0, l.update.showContent = !0), i.option.form?.openAfter?.(l.update.form, l.update);
1455
1455
  } catch (r) {
1456
1456
  console.error(r);
1457
1457
  } finally {
@@ -1462,32 +1462,32 @@ const H = M.EDialog, Be = (n) => {
1462
1462
  /** 提交增改表单操作 */
1463
1463
  submit: () => {
1464
1464
  FunUtil.throttle(async () => {
1465
- await p.value?.validate(async (d, m) => new Promise((c, f) => {
1466
- d || (M.fail(w.tCurd("checkFormData")), f(!1)), c();
1465
+ await p.value?.validate(async (s, m) => new Promise((c, u) => {
1466
+ s || (M.fail(w.tCurd("checkFormData")), u(!1)), c();
1467
1467
  })), l.update.loading = !0;
1468
- const t = l.update.type === H.Add ? n.option.api.create : n.option.api.update;
1468
+ const t = l.update.type === H.Add ? i.option.api.create : i.option.api.update;
1469
1469
  try {
1470
- await n.option.form?.submitBefore?.(l.update.form, l.update);
1470
+ await i.option.form?.submitBefore?.(l.update.form, l.update);
1471
1471
  } catch {
1472
1472
  l.update.loading = !1;
1473
1473
  return;
1474
1474
  }
1475
1475
  let e = ObjectUtil.deepMerge(l.update.form, {});
1476
1476
  delete e.children;
1477
- const r = new Set(n.option.column.filter((d) => d.type === "datetime").map((d) => d.key));
1478
- Object.keys(e).forEach((d) => {
1479
- if (r.has(d) && e[d] != null) {
1480
- const m = new Date(e[d]).getTime();
1481
- isNaN(m) || (e[d] = m);
1477
+ const r = new Set(i.option.column.filter((s) => s.type === "datetime").map((s) => s.key));
1478
+ Object.keys(e).forEach((s) => {
1479
+ if (r.has(s) && e[s] != null) {
1480
+ const m = new Date(e[s]).getTime();
1481
+ isNaN(m) || (e[s] = m);
1482
1482
  }
1483
1483
  });
1484
1484
  try {
1485
1485
  if (!t) return;
1486
1486
  await t({
1487
1487
  ...e
1488
- }), l.update.close(), await l.table.getList(), n.option.form?.submitAfter?.(e, l.update);
1489
- } catch (d) {
1490
- console.error(d);
1488
+ }), l.update.close(), await l.table.getList(), i.option.form?.submitAfter?.(e, l.update);
1489
+ } catch (s) {
1490
+ console.error(s);
1491
1491
  } finally {
1492
1492
  l.update.loading = !1;
1493
1493
  }
@@ -1495,7 +1495,7 @@ const H = M.EDialog, Be = (n) => {
1495
1495
  },
1496
1496
  /** 关闭弹窗和内容 */
1497
1497
  close: () => {
1498
- l.update.show = !1, n.option.table?.inlineEdit && (l.update.form = {}), setTimeout(() => {
1498
+ l.update.show = !1, i.option.table?.inlineEdit && (l.update.form = {}), setTimeout(() => {
1499
1499
  l.update.showContent = !1;
1500
1500
  }, 350);
1501
1501
  }
@@ -1526,11 +1526,11 @@ const H = M.EDialog, Be = (n) => {
1526
1526
  submit: () => {
1527
1527
  FunUtil.throttle(async () => {
1528
1528
  l.remove.loading = !0;
1529
- const t = n.option.api.delete;
1529
+ const t = i.option.api.delete;
1530
1530
  try {
1531
1531
  if (!t) return;
1532
1532
  await t({
1533
- [n.option.table?.rowKey]: l.remove.items.map((e) => e[n.option.table?.rowKey]),
1533
+ [i.option.table?.rowKey]: l.remove.items.map((e) => e[i.option.table?.rowKey]),
1534
1534
  items: l.remove.items
1535
1535
  }), M.success(w.tCurd("operationSuccess")), l.table.data.length <= 1 && l.page.num > 1 && (l.page.num -= 1), l.remove.close(), await l.table.getList();
1536
1536
  } catch (e) {
@@ -1549,19 +1549,19 @@ const H = M.EDialog, Be = (n) => {
1549
1549
  apiDataMap: {},
1550
1550
  /** 获取并绑定curd中所有下拉数据等远程依赖 */
1551
1551
  initApiData: async (t) => {
1552
- const e = [], r = (d) => {
1553
- if (d.children && d.children.length) {
1554
- d.children.forEach((m) => r(m));
1552
+ const e = [], r = (s) => {
1553
+ if (s.children && s.children.length) {
1554
+ s.children.forEach((m) => r(m));
1555
1555
  return;
1556
1556
  }
1557
- if (d.options?.[d.type]?.dataApi && d.options?.[d.type]?.dataApiConfig?.[t]) {
1558
- if (l.apiDataMap[d.key] && d.options?.[d.type]?.dataApiConfig?.once) return;
1557
+ if (s.options?.[s.type]?.dataApi && s.options?.[s.type]?.dataApiConfig?.[t]) {
1558
+ if (l.apiDataMap[s.key] && s.options?.[s.type]?.dataApiConfig?.once) return;
1559
1559
  const m = (async () => {
1560
1560
  try {
1561
- let c = await d.options?.[d.type]?.dataApi?.(l.update.form, l.update.type);
1561
+ let c = await s.options?.[s.type]?.dataApi?.(l.update.form, l.update.type);
1562
1562
  if (c) {
1563
- const f = d.options?.[d.type]?.dataPath;
1564
- !Array.isArray(c) && f && (c = ObjectUtil.getPathValue(c, f)), d.options[d.type].data = c, d.options.search[d.type].data = c, d.options.formAdd[d.type].data = c, d.options.formUpdate[d.type].data = c, l.apiDataMap[d.key] = c;
1563
+ const u = s.options?.[s.type]?.dataPath;
1564
+ !Array.isArray(c) && u && (c = ObjectUtil.getPathValue(c, u)), s.options[s.type].data = c, s.options.search[s.type].data = c, s.options.search[s.options.search.type ?? s.type].data = c, s.options.formAdd[s.type].data = c, s.options.formUpdate[s.type].data = c, l.apiDataMap[s.key] = c;
1565
1565
  }
1566
1566
  } catch {
1567
1567
  }
@@ -1569,17 +1569,17 @@ const H = M.EDialog, Be = (n) => {
1569
1569
  e.push(m);
1570
1570
  }
1571
1571
  };
1572
- return n.option.column.forEach((d) => {
1573
- r(d);
1572
+ return i.option.column.forEach((s) => {
1573
+ r(s);
1574
1574
  }), await Promise.all(e), !0;
1575
1575
  },
1576
1576
  /** 初始化curd配置(option默认值合并等) */
1577
1577
  initCurdConfig: () => {
1578
1578
  const t = ObjectUtil.deepMerge(T.config, {});
1579
- t.table.emptyText = w.tCurd("noData"), n.option.size = n.option.size || {}, t.table.size = n.option.size.table || t.size.table, t.form.size = n.option.size.form || t.size.form, t.size.search = n.option.size.search || t.size.search;
1580
- const e = ObjectUtil.deepMerge(t, n.option || {});
1579
+ t.table.emptyText = w.tCurd("noData"), i.option.size = i.option.size || {}, t.table.size = i.option.size.table || t.size.table, t.form.size = i.option.size.form || t.size.form, t.size.search = i.option.size.search || t.size.search;
1580
+ const e = ObjectUtil.deepMerge(t, i.option || {});
1581
1581
  Object.keys(e).forEach((r) => {
1582
- n.option[r] = e[r];
1582
+ i.option[r] = e[r];
1583
1583
  });
1584
1584
  },
1585
1585
  /**
@@ -1599,20 +1599,20 @@ const H = M.EDialog, Be = (n) => {
1599
1599
  t.options
1600
1600
  );
1601
1601
  const e = (r) => {
1602
- for (const d in t) {
1603
- if (d === "table") {
1602
+ for (const s in t) {
1603
+ if (s === "table") {
1604
1604
  if (r.table = ObjectUtil.deepMerge(t.table, r.table || {}), r.children) {
1605
1605
  r.children.forEach((c) => {
1606
1606
  e(c);
1607
1607
  });
1608
1608
  return;
1609
1609
  }
1610
- } else d === "type" ? r.type = r.type || t.type : r[d] = ObjectUtil.deepMerge(t[d], r[d] || {});
1611
- r.options = r.options || {}, r.options[r.type] = r.options[r.type] || {}, r.options[r.type].size = n.option.size.form, ["search", "formAdd", "formUpdate"].forEach((c) => {
1612
- r.options[c] = r.options[c] || ObjectUtil.deepMerge(r.options, {}), r.options[c][r.type] = r.options[c][r.type] || {}, r.options[c][r.type].size = c === "search" ? n.option.size.search : n.option.size.form;
1610
+ } else s === "type" ? r.type = r.type || t.type : r[s] = ObjectUtil.deepMerge(t[s], r[s] || {});
1611
+ r.options = r.options || {}, r.options[r.type] = r.options[r.type] || {}, r.options[r.type].size = i.option.size.form, ["search", "formAdd", "formUpdate"].forEach((c) => {
1612
+ r.options[c] = r.options[c] || ObjectUtil.deepMerge(r.options, {}), r.options[c][r.type] = r.options[c][r.type] || {}, r.options[c][r.type].size = c === "search" ? i.option.size.search : i.option.size.form;
1613
1613
  }), r.table = ObjectUtil.deepMerge(r.table, r.options[r.type].table || {});
1614
1614
  }
1615
- r.type === "switch" && (r.options.switch.tableBeforeChange = async (d, m) => {
1615
+ r.type === "switch" && (r.options.switch.tableBeforeChange = async (s, m) => {
1616
1616
  const c = r.options?.switch;
1617
1617
  try {
1618
1618
  c.tableConfig?.confirm && await o.value?.open({
@@ -1620,139 +1620,139 @@ const H = M.EDialog, Be = (n) => {
1620
1620
  content: w.tCurd("confirmSwitchMessage")
1621
1621
  });
1622
1622
  try {
1623
- if (!n.option.api.update && !c.tableConfig?.api) return;
1624
- const f = m[n.option.table?.rowKey];
1625
- c.loadingMap || (c.loadingMap = {}), c.loadingMap[f] || (c.loadingMap[f] = { loading: !1 }), c.loadingMap[f].loading = !0;
1626
- const k = m[d] === c.activeValue ? c.inactiveValue : c.activeValue, i = c.tableConfig?.api ? c.tableConfig.api : n.option.api.update;
1627
- if (!i) return;
1623
+ if (!i.option.api.update && !c.tableConfig?.api) return;
1624
+ const u = m[i.option.table?.rowKey];
1625
+ c.loadingMap || (c.loadingMap = {}), c.loadingMap[u] || (c.loadingMap[u] = { loading: !1 }), c.loadingMap[u].loading = !0;
1626
+ const k = m[s] === c.activeValue ? c.inactiveValue : c.activeValue, f = c.tableConfig?.api ? c.tableConfig.api : i.option.api.update;
1627
+ if (!f) return;
1628
1628
  try {
1629
- await i(
1629
+ await f(
1630
1630
  {
1631
1631
  ...m,
1632
- [d]: k
1632
+ [s]: k
1633
1633
  },
1634
1634
  "switch"
1635
1635
  );
1636
1636
  } catch {
1637
1637
  return !1;
1638
1638
  } finally {
1639
- c.loadingMap[f].loading = !1;
1639
+ c.loadingMap[u].loading = !1;
1640
1640
  }
1641
1641
  return M.success(w.tCurd("operationSuccess")), c.tableConfig?.loadList && (l.table.loading = !0, l.table.getList(), l.table.loading = !1), !0;
1642
- } catch (f) {
1643
- return console.error(f), !1;
1642
+ } catch (u) {
1643
+ return console.error(u), !1;
1644
1644
  } finally {
1645
1645
  l.table.loading = !1;
1646
1646
  }
1647
1647
  } catch {
1648
1648
  return !1;
1649
1649
  }
1650
- }), r.type === "treeSelect" && (r.options.treeSelect.rowKey = n.option.table?.rowKey, r.options.treeSelect.nodeKey = n.option.table?.rowKey);
1650
+ }), r.type === "treeSelect" && (r.options.treeSelect.rowKey = i.option.table?.rowKey, r.options.treeSelect.nodeKey = i.option.table?.rowKey);
1651
1651
  };
1652
- n.option.column.forEach(e), n.option.table?.column?.forEach(e);
1652
+ i.option.column.forEach(e), i.option.table?.column?.forEach(e);
1653
1653
  },
1654
1654
  getColumnSpan: (t, e) => {
1655
1655
  if (t.item.form?.spanCol) {
1656
- const r = T.config.form.defaultSpan, m = e.filter((c) => !M.isFun(c.item.show?.form, l.update.form, l.update.type)).reduce((c, f) => c + (f.item.form?.span || r), 0);
1656
+ const r = T.config.form.defaultSpan, m = e.filter((c) => !M.isFun(c.item.show?.form, l.update.form, l.update.type)).reduce((c, u) => c + (u.item.form?.span || r), 0);
1657
1657
  return (t.item?.form.span || r) + m;
1658
1658
  }
1659
1659
  return t.item.form.span;
1660
1660
  },
1661
1661
  /** 初始化配置并生成表单列及默认值及规则 */
1662
1662
  initColumnForm: () => {
1663
- const t = n.option;
1663
+ const t = i.option;
1664
1664
  l.update.formColumn = [], l.table.column.show = {
1665
1665
  list: [],
1666
1666
  listSource: []
1667
1667
  };
1668
- const e = [], r = n.option.form?.maxSpan || 12, d = n.option.form?.defaultSpan || r / 2;
1668
+ const e = [], r = i.option.form?.maxSpan || 12, s = i.option.form?.defaultSpan || r / 2;
1669
1669
  let m = [];
1670
- const c = (i) => {
1671
- if (i.children) {
1672
- l.table.column.show.list.push(i.key), i.children.forEach((h) => {
1673
- c(h);
1670
+ const c = (f) => {
1671
+ if (f.children) {
1672
+ l.table.column.show.list.push(f.key), f.children.forEach((g) => {
1673
+ c(g);
1674
1674
  });
1675
1675
  return;
1676
1676
  }
1677
- if (l.update.formDefault[i.key] = i.value, i.table.table && (i.show.table && l.table.column.show.list.push(i.key), i.table.table && l.table.column.show.listSource.push(i.key)), !(i.isForm && typeof i.show?.form == "boolean") || i.show?.form) {
1678
- i.form = i.form || { span: d }, i.form.span = i.form.span ?? d;
1679
- let h = i.form.span, S = m.reduce((F, R) => F + R.span, h);
1677
+ if (l.update.formDefault[f.key] = f.value, f.table.table && (f.show.table && l.table.column.show.list.push(f.key), f.table.table && l.table.column.show.listSource.push(f.key)), !(f.isForm && typeof f.show?.form == "boolean") || f.show?.form) {
1678
+ f.form = f.form || { span: s }, f.form.span = f.form.span ?? s;
1679
+ let g = f.form.span, S = m.reduce((F, R) => F + R.span, g);
1680
1680
  const B = m.length;
1681
- if (m.push({ item: i, span: h }), (B === 1 && m[0].span === 0 || S >= r || h === 0 && B > 1) && (e.push(m), m = []), i.rules) {
1681
+ if (m.push({ item: f, span: g }), (B === 1 && m[0].span === 0 || S >= r || g === 0 && B > 1) && (e.push(m), m = []), f.rules) {
1682
1682
  const F = {
1683
1683
  input: w.tCurd("placeholderInput"),
1684
1684
  select: w.tCurd("placeholderSelect")
1685
- }, R = (F[i.type] || F.input) + i.label;
1686
- l.update.rules[i.key] = typeof i.rules == "boolean" ? [
1685
+ }, R = (F[f.type] || F.input) + f.label;
1686
+ l.update.rules[f.key] = typeof f.rules == "boolean" ? [
1687
1687
  {
1688
1688
  required: !0,
1689
1689
  message: R,
1690
1690
  trigger: "blur"
1691
1691
  }
1692
- ] : i.rules;
1692
+ ] : f.rules;
1693
1693
  }
1694
1694
  }
1695
- }, f = (i, h) => {
1696
- i.isForm = h, Array.isArray(i.children) && i.children.forEach((S) => f(S, h));
1695
+ }, u = (f, g) => {
1696
+ f.isForm = g, Array.isArray(f.children) && f.children.forEach((S) => u(S, g));
1697
1697
  };
1698
- t.column.forEach((i) => {
1699
- i.isForm = !0, f(i, !0), c(i);
1700
- }), n.option.table?.column?.forEach((i) => {
1701
- f(i, !1), c(i);
1702
- }), l.search.column.list = t.column.concat(t.table?.column || []), l.table.column.list = l.search.column.list.filter((i) => i.table?.table), l.search.column.list.sort((i, h) => i.sort?.search - h.sort?.search), l.table.column.list.sort((i, h) => i.sort?.table - h.sort?.table), m.length > 0 && e.push(m), l.update.formColumn = e;
1703
- const k = n.option.search?.formDefault;
1704
- k && Object.keys(k).forEach((i) => {
1705
- l.search.formDefault[i] = k[i];
1706
- }), t.column.forEach((i) => {
1707
- i.show?.search || (l.search.formDefault[i.key] = void 0);
1698
+ t.column.forEach((f) => {
1699
+ f.isForm = !0, u(f, !0), c(f);
1700
+ }), i.option.table?.column?.forEach((f) => {
1701
+ u(f, !1), c(f);
1702
+ }), l.search.column.list = t.column.concat(t.table?.column || []), l.table.column.list = l.search.column.list.filter((f) => f.table?.table), l.search.column.list.sort((f, g) => f.sort?.search - g.sort?.search), l.table.column.list.sort((f, g) => f.sort?.table - g.sort?.table), m.length > 0 && e.push(m), l.update.formColumn = e;
1703
+ const k = i.option.search?.formDefault;
1704
+ k && Object.keys(k).forEach((f) => {
1705
+ l.search.formDefault[f] = k[f];
1706
+ }), t.column.forEach((f) => {
1707
+ f.show?.search || (l.search.formDefault[f.key] = void 0);
1708
1708
  }), l.search.form = ObjectUtil.deepMerge(l.search.formDefault, {});
1709
1709
  }
1710
1710
  });
1711
1711
  return l.init(), fe(() => {
1712
- n.option.init !== !1 && l.table.getList();
1713
- }), { conf: l, switchConfirmRef: o, ruleFormRef: p, tableRef: s };
1714
- }, Re = { class: "dialog-footer" }, Ie = /* @__PURE__ */ J({
1712
+ i.option.init !== !1 && l.table.getList();
1713
+ }), { conf: l, switchConfirmRef: o, ruleFormRef: p, tableRef: n };
1714
+ }, Ie = { class: "dialog-footer" }, He = /* @__PURE__ */ K({
1715
1715
  __name: "switchConfirm",
1716
1716
  props: {
1717
1717
  size: {}
1718
1718
  },
1719
- setup(n, { expose: o }) {
1720
- const p = N(!1), s = N("确认修改"), l = N("确认要修改状态吗?");
1719
+ setup(i, { expose: o }) {
1720
+ const p = W(!1), n = W("确认修改"), l = W("确认要修改状态吗?");
1721
1721
  let t = null, e = null;
1722
- const r = (c) => (c?.title && (s.value = c.title), c?.content && (l.value = c.content), p.value = !0, new Promise((f, k) => {
1723
- t = f, e = k;
1724
- })), d = () => {
1722
+ const r = (c) => (c?.title && (n.value = c.title), c?.content && (l.value = c.content), p.value = !0, new Promise((u, k) => {
1723
+ t = u, e = k;
1724
+ })), s = () => {
1725
1725
  p.value = !1, t?.(!0), t = null, e = null;
1726
1726
  }, m = () => {
1727
1727
  p.value = !1, e?.(new Error("用户取消操作")), t = null, e = null;
1728
1728
  };
1729
1729
  return o({
1730
1730
  open: r
1731
- }), (c, f) => {
1731
+ }), (c, u) => {
1732
1732
  const k = _("el-form");
1733
- return u(), g(a(ae), {
1733
+ return d(), h(a(ae), {
1734
1734
  modelValue: p.value,
1735
- "onUpdate:modelValue": f[0] || (f[0] = (i) => p.value = i),
1736
- title: s.value,
1735
+ "onUpdate:modelValue": u[0] || (u[0] = (f) => p.value = f),
1736
+ title: n.value,
1737
1737
  "close-on-click-modal": !1,
1738
1738
  width: "400px"
1739
1739
  }, {
1740
1740
  footer: y(() => [
1741
- D(k, { size: c.size }, {
1741
+ U(k, { size: c.size }, {
1742
1742
  default: y(() => [
1743
- E("span", Re, [
1744
- D(a(L), { onClick: m }, {
1745
- default: y(() => f[1] || (f[1] = [
1746
- U("取消")
1743
+ E("span", Ie, [
1744
+ U(a(L), { onClick: m }, {
1745
+ default: y(() => u[1] || (u[1] = [
1746
+ D("取消")
1747
1747
  ])),
1748
1748
  _: 1
1749
1749
  }),
1750
- D(a(L), {
1750
+ U(a(L), {
1751
1751
  type: "primary",
1752
- onClick: d
1752
+ onClick: s
1753
1753
  }, {
1754
- default: y(() => f[2] || (f[2] = [
1755
- U("确认")
1754
+ default: y(() => u[2] || (u[2] = [
1755
+ D("确认")
1756
1756
  ])),
1757
1757
  _: 1
1758
1758
  })
@@ -1768,100 +1768,100 @@ const H = M.EDialog, Be = (n) => {
1768
1768
  }, 8, ["modelValue", "title"]);
1769
1769
  };
1770
1770
  }
1771
- }), X = (n, o) => {
1772
- const p = n.__vccOpts || n;
1773
- for (const [s, l] of o)
1774
- p[s] = l;
1771
+ }), X = (i, o) => {
1772
+ const p = i.__vccOpts || i;
1773
+ for (const [n, l] of o)
1774
+ p[n] = l;
1775
1775
  return p;
1776
- }, He = {}, Pe = {
1776
+ }, Pe = {}, Ke = {
1777
1777
  xmlns: "http://www.w3.org/2000/svg",
1778
1778
  viewBox: "0 0 1024 1024"
1779
1779
  };
1780
- function Ke(n, o) {
1781
- return u(), b("svg", Pe, o[0] || (o[0] = [
1780
+ function Ne(i, o) {
1781
+ return d(), b("svg", Ke, o[0] || (o[0] = [
1782
1782
  E("path", {
1783
1783
  fill: "currentColor",
1784
1784
  d: "M771.776 794.88A384 384 0 0 1 128 512h64a320 320 0 0 0 555.712 216.448H654.72a32 32 0 1 1 0-64h149.056a32 32 0 0 1 32 32v148.928a32 32 0 1 1-64 0v-50.56zM276.288 295.616h92.992a32 32 0 0 1 0 64H220.16a32 32 0 0 1-32-32V178.56a32 32 0 0 1 64 0v50.56A384 384 0 0 1 896.128 512h-64a320 320 0 0 0-555.776-216.384z"
1785
1785
  }, null, -1)
1786
1786
  ]));
1787
1787
  }
1788
- const Ne = /* @__PURE__ */ X(He, [["render", Ke]]), We = ["innerHTML"], Je = /* @__PURE__ */ J({
1788
+ const We = /* @__PURE__ */ X(Pe, [["render", Ne]]), Je = ["innerHTML"], qe = /* @__PURE__ */ K({
1789
1789
  __name: "text",
1790
1790
  props: {
1791
1791
  content: {},
1792
1792
  value: {}
1793
1793
  },
1794
- setup(n) {
1795
- const o = n, p = we(() => typeof o.content == "function" ? o.content(o.value) : o.content);
1796
- return (s, l) => typeof p.value == "object" ? (u(), g(W(p.value), { key: 0 })) : (u(), b("div", {
1794
+ setup(i) {
1795
+ const o = i, p = me(() => typeof o.content == "function" ? o.content(o.value) : o.content);
1796
+ return (n, l) => typeof p.value == "object" ? (d(), h(J(p.value), { key: 0 })) : (d(), b("div", {
1797
1797
  key: 1,
1798
1798
  innerHTML: p.value
1799
- }, null, 8, We));
1799
+ }, null, 8, Je));
1800
1800
  }
1801
- }), qe = {}, Qe = {
1801
+ }), Qe = {}, Ge = {
1802
1802
  "data-v-58697b5c": "",
1803
1803
  xmlns: "http://www.w3.org/2000/svg",
1804
1804
  viewBox: "0 0 1024 1024"
1805
1805
  };
1806
- function Ge(n, o) {
1807
- return u(), b("svg", Qe, o[0] || (o[0] = [
1806
+ function Xe(i, o) {
1807
+ return d(), b("svg", Ge, o[0] || (o[0] = [
1808
1808
  E("path", {
1809
1809
  fill: "currentColor",
1810
1810
  d: "M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m23.744 191.488c-52.096 0-92.928 14.784-123.2 44.352-30.976 29.568-45.76 70.4-45.76 122.496h80.256c0-29.568 5.632-52.8 17.6-68.992 13.376-19.712 35.2-28.864 66.176-28.864 23.936 0 42.944 6.336 56.32 19.712 12.672 13.376 19.712 31.68 19.712 54.912 0 17.6-6.336 34.496-19.008 49.984l-8.448 9.856c-45.76 40.832-73.216 70.4-82.368 89.408-9.856 19.008-14.08 42.24-14.08 68.992v9.856h80.96v-9.856c0-16.896 3.52-31.68 10.56-45.76 6.336-12.672 15.488-24.64 28.16-35.2 33.792-29.568 54.208-48.576 60.544-55.616 16.896-22.528 26.048-51.392 26.048-86.592q0-64.416-42.24-101.376c-28.16-25.344-65.472-37.312-111.232-37.312m-12.672 406.208a54.27 54.27 0 0 0-38.72 14.784 49.4 49.4 0 0 0-15.488 38.016c0 15.488 4.928 28.16 15.488 38.016A54.85 54.85 0 0 0 523.072 768c15.488 0 28.16-4.928 38.72-14.784a51.52 51.52 0 0 0 16.192-38.72 51.97 51.97 0 0 0-15.488-38.016 55.94 55.94 0 0 0-39.424-14.784"
1811
1811
  }, null, -1)
1812
1812
  ]));
1813
1813
  }
1814
- const Xe = /* @__PURE__ */ X(qe, [["render", Ge]]), Ye = {}, Ze = {
1814
+ const Ye = /* @__PURE__ */ X(Qe, [["render", Xe]]), Ze = {}, xe = {
1815
1815
  "data-v-58697b5c": "",
1816
1816
  xmlns: "http://www.w3.org/2000/svg",
1817
1817
  viewBox: "0 0 1024 1024"
1818
1818
  };
1819
- function xe(n, o) {
1820
- return u(), b("svg", Ze, o[0] || (o[0] = [
1819
+ function _e(i, o) {
1820
+ return d(), b("svg", xe, o[0] || (o[0] = [
1821
1821
  E("path", {
1822
1822
  fill: "currentColor",
1823
1823
  d: "M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m-38.4 409.6H326.4a38.4 38.4 0 1 0 0 76.8h147.2v147.2a38.4 38.4 0 0 0 76.8 0V550.4h147.2a38.4 38.4 0 0 0 0-76.8H550.4V326.4a38.4 38.4 0 1 0-76.8 0z"
1824
1824
  }, null, -1)
1825
1825
  ]));
1826
1826
  }
1827
- const _e = /* @__PURE__ */ X(Ye, [["render", xe]]), et = {}, tt = {
1827
+ const et = /* @__PURE__ */ X(Ze, [["render", _e]]), tt = {}, ot = {
1828
1828
  "data-v-58697b5c": "",
1829
1829
  xmlns: "http://www.w3.org/2000/svg",
1830
1830
  viewBox: "0 0 1024 1024"
1831
1831
  };
1832
- function ot(n, o) {
1833
- return u(), b("svg", tt, o[0] || (o[0] = [
1832
+ function at(i, o) {
1833
+ return d(), b("svg", ot, o[0] || (o[0] = [
1834
1834
  E("path", {
1835
1835
  fill: "currentColor",
1836
1836
  d: "M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896M288 512a38.4 38.4 0 0 0 38.4 38.4h371.2a38.4 38.4 0 0 0 0-76.8H326.4A38.4 38.4 0 0 0 288 512"
1837
1837
  }, null, -1)
1838
1838
  ]));
1839
1839
  }
1840
- const at = /* @__PURE__ */ X(et, [["render", ot]]), lt = { class: "row flex-center table-header-label inline" }, nt = { class: "table-header-tooltip" }, it = ["innerHTML"], rt = ["onClick"], st = { key: 1 }, dt = ["onClick", "innerHTML"], ut = /* @__PURE__ */ J({
1840
+ const lt = /* @__PURE__ */ X(tt, [["render", at]]), nt = { class: "row flex-center table-header-label inline" }, it = { class: "table-header-tooltip" }, rt = ["innerHTML"], st = ["onClick"], dt = { key: 1 }, ut = ["onClick", "innerHTML"], pt = /* @__PURE__ */ K({
1841
1841
  __name: "tableColumn",
1842
1842
  props: {
1843
1843
  conf: {},
1844
1844
  columnList: {},
1845
1845
  option: {}
1846
1846
  },
1847
- setup(n) {
1848
- const o = M.isFun, p = ke().type;
1849
- return (s, l) => {
1847
+ setup(i) {
1848
+ const o = M.isFun, p = ve().type;
1849
+ return (n, l) => {
1850
1850
  const t = _("el-tooltip");
1851
- return u(!0), b($, null, A(s.columnList, (e) => (u(), b($, {
1851
+ return d(!0), b($, null, A(n.columnList, (e) => (d(), b($, {
1852
1852
  key: e.key
1853
1853
  }, [
1854
- s.conf.table.column.show.list.includes(e.key) ? (u(), b($, { key: 0 }, [
1855
- e.table?.header?.groupKey === void 0 || e.table.header.show ? (u(), g(a(ee), V({
1854
+ n.conf.table.column.show.list.includes(e.key) && a(o)(e.show?.table, n.conf.table.data) ? (d(), b($, { key: 0 }, [
1855
+ e.table?.header?.groupKey === void 0 || e.table.header.show ? (d(), h(a(ee), V({
1856
1856
  key: 0,
1857
1857
  prop: e.key,
1858
1858
  label: e.label,
1859
1859
  ref_for: !0
1860
1860
  }, e.table), {
1861
1861
  header: y(() => [
1862
- C(s.$slots, "table-header-" + e.key, { item: e }, () => [
1863
- E("div", lt, [
1864
- e.table?.header?.tooltip ? (u(), g(t, {
1862
+ C(n.$slots, "table-header-" + e.key, { item: e }, () => [
1863
+ E("div", nt, [
1864
+ e.table?.header?.tooltip ? (d(), h(t, {
1865
1865
  key: 0,
1866
1866
  effect: "dark",
1867
1867
  placement: "top"
@@ -1869,168 +1869,168 @@ const at = /* @__PURE__ */ X(et, [["render", ot]]), lt = { class: "row flex-cent
1869
1869
  content: y(() => [
1870
1870
  E("div", {
1871
1871
  innerHTML: e.table?.header?.tooltip
1872
- }, null, 8, it)
1872
+ }, null, 8, rt)
1873
1873
  ]),
1874
1874
  default: y(() => [
1875
- E("span", nt, [
1876
- D(Xe)
1875
+ E("span", it, [
1876
+ U(Ye)
1877
1877
  ])
1878
1878
  ]),
1879
1879
  _: 2
1880
1880
  }, 1024)) : v("", !0),
1881
- U(" " + O(e.label) + " ", 1),
1882
- e.table?.header?.group !== void 0 ? (u(), b("span", {
1881
+ D(" " + O(e.label) + " ", 1),
1882
+ e.table?.header?.group !== void 0 ? (d(), b("span", {
1883
1883
  key: 1,
1884
1884
  class: "table-header-plus",
1885
- onClick: ve(
1885
+ onClick: Ce(
1886
1886
  () => {
1887
- e.table.header.group = !e.table.header.group, s.columnList.forEach((r) => {
1887
+ e.table.header.group = !e.table.header.group, n.columnList.forEach((r) => {
1888
1888
  r.table?.header?.groupKey === e.key && (r.table.header.show = !e.table.header.group);
1889
1889
  });
1890
1890
  },
1891
1891
  ["stop"]
1892
1892
  )
1893
1893
  }, [
1894
- e.table.header.group ? (u(), g(_e, { key: 0 })) : (u(), g(at, { key: 1 }))
1895
- ], 8, rt)) : v("", !0)
1894
+ e.table.header.group ? (d(), h(et, { key: 0 })) : (d(), h(lt, { key: 1 }))
1895
+ ], 8, st)) : v("", !0)
1896
1896
  ])
1897
1897
  ])
1898
1898
  ]),
1899
1899
  default: y(({ row: r }) => [
1900
- e.children ? (u(), b($, { key: 0 }, [
1901
- l[0] || (l[0] = U("   ")),
1902
- (u(), g(W(a(p)), {
1903
- conf: s.conf,
1900
+ e.children ? (d(), b($, { key: 0 }, [
1901
+ l[0] || (l[0] = D("   ")),
1902
+ (d(), h(J(a(p)), {
1903
+ conf: n.conf,
1904
1904
  columnList: e.children,
1905
- option: s.option
1905
+ option: n.option
1906
1906
  }, Q({ _: 2 }, [
1907
- A(s.$slots, (d, m) => ({
1907
+ A(n.$slots, (s, m) => ({
1908
1908
  name: m,
1909
1909
  fn: y((c) => [
1910
- C(s.$slots, m, V({ ref_for: !0 }, c || {}))
1910
+ C(n.$slots, m, V({ ref_for: !0 }, c || {}))
1911
1911
  ])
1912
1912
  }))
1913
1913
  ]), 1032, ["conf", "columnList", "option"]))
1914
- ], 64)) : (u(), b($, { key: 1 }, [
1915
- s.option.table?.editMode ? (u(), b("div", {
1914
+ ], 64)) : (d(), b($, { key: 1 }, [
1915
+ n.option.table?.editMode ? (d(), b("div", {
1916
1916
  key: 0,
1917
1917
  class: I(["row", ["table-edit-" + e.key]]),
1918
1918
  style: { width: "100%" }
1919
1919
  }, [
1920
- C(s.$slots, "table-edit-left-" + e.key, {
1920
+ C(n.$slots, "table-edit-left-" + e.key, {
1921
1921
  row: r,
1922
1922
  item: e
1923
1923
  }),
1924
- e.type === "input" ? (u(), g(a(x), V({
1924
+ e.type === "input" ? (d(), h(a(x), V({
1925
1925
  key: 0,
1926
1926
  modelValue: r[e.key],
1927
- "onUpdate:modelValue": (d) => r[e.key] = d,
1928
- disabled: s.conf.update.getDisabled(e, !0),
1927
+ "onUpdate:modelValue": (s) => r[e.key] = s,
1928
+ disabled: n.conf.update.getDisabled(e, !0),
1929
1929
  class: "col",
1930
1930
  ref_for: !0
1931
- }, s.conf.update.getBind(e), z(s.conf.update.getOn(e, r))), Q({ _: 2 }, [
1931
+ }, n.conf.update.getBind(e), z(n.conf.update.getOn(e, r))), Q({ _: 2 }, [
1932
1932
  e.options?.input?.prepend ? {
1933
1933
  name: "prepend",
1934
1934
  fn: y(() => [
1935
- U(O(typeof e.options?.input?.prepend == "function" ? e.options?.input?.prepend(r) : e.options?.input?.prepend), 1)
1935
+ D(O(typeof e.options?.input?.prepend == "function" ? e.options?.input?.prepend(r) : e.options?.input?.prepend), 1)
1936
1936
  ]),
1937
1937
  key: "0"
1938
1938
  } : void 0
1939
- ]), 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "select" ? (u(), g(a(G), V({
1939
+ ]), 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "select" ? (d(), h(a(G), V({
1940
1940
  key: 1,
1941
1941
  modelValue: r[e.key],
1942
- "onUpdate:modelValue": (d) => r[e.key] = d,
1943
- disabled: s.conf.update.getDisabled(e, !0),
1942
+ "onUpdate:modelValue": (s) => r[e.key] = s,
1943
+ disabled: n.conf.update.getDisabled(e, !0),
1944
1944
  class: "col",
1945
1945
  ref_for: !0
1946
- }, s.conf.update.getBind(e), z(s.conf.update.getOn(e, r))), {
1946
+ }, n.conf.update.getBind(e), z(n.conf.update.getOn(e, r))), {
1947
1947
  default: y(() => [
1948
- (u(!0), b($, null, A(e.options?.search?.select?.data || e.options?.select?.data, (d) => (u(), g(a(K), {
1949
- key: d.value,
1950
- label: d.label,
1951
- value: d.value
1948
+ (d(!0), b($, null, A(e.options?.search?.select?.data || e.options?.select?.data, (s) => (d(), h(a(N), {
1949
+ key: s.value,
1950
+ label: s.label,
1951
+ value: s.value
1952
1952
  }, null, 8, ["label", "value"]))), 128))
1953
1953
  ]),
1954
1954
  _: 2
1955
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "switch" ? (u(), g(a(Z), V({
1955
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "switch" ? (d(), h(a(Z), V({
1956
1956
  key: 2,
1957
1957
  modelValue: r[e.key],
1958
- "onUpdate:modelValue": (d) => r[e.key] = d,
1959
- disabled: s.conf.update.getDisabled(e, !0),
1958
+ "onUpdate:modelValue": (s) => r[e.key] = s,
1959
+ disabled: n.conf.update.getDisabled(e, !0),
1960
1960
  class: "col",
1961
1961
  ref_for: !0
1962
- }, s.conf.update.getBind(e), z(s.conf.update.getOn(e, r))), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : v("", !0),
1963
- C(s.$slots, "table-edit-right-" + e.key, {
1962
+ }, n.conf.update.getBind(e), z(n.conf.update.getOn(e, r))), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : v("", !0),
1963
+ C(n.$slots, "table-edit-right-" + e.key, {
1964
1964
  row: r,
1965
1965
  item: e
1966
1966
  })
1967
- ], 2)) : (u(), b($, { key: 1 }, [
1968
- s.conf.update.type === a(M).EDialog.Update && a(o)(e.show?.form, s.conf.update.form, a(M).EDialog.Update) && s.option.table?.inlineEdit && s.conf.update.form[s.option.table?.rowKey] === r[s.option.table?.rowKey] && (e.type === "input" || e.type === "select") ? (u(), b($, { key: 0 }, [
1969
- e.type === "input" ? (u(), g(a(x), V({
1967
+ ], 2)) : (d(), b($, { key: 1 }, [
1968
+ n.conf.update.type === a(M).EDialog.Update && a(o)(e.show?.form, n.conf.update.form, a(M).EDialog.Update) && n.option.table?.inlineEdit && n.conf.update.form[n.option.table?.rowKey] === r[n.option.table?.rowKey] && (e.type === "input" || e.type === "select") ? (d(), b($, { key: 0 }, [
1969
+ e.type === "input" ? (d(), h(a(x), V({
1970
1970
  key: 0,
1971
- modelValue: s.conf.update.form[e.key],
1972
- "onUpdate:modelValue": (d) => s.conf.update.form[e.key] = d,
1973
- disabled: s.conf.update.getDisabled(e, !0),
1971
+ modelValue: n.conf.update.form[e.key],
1972
+ "onUpdate:modelValue": (s) => n.conf.update.form[e.key] = s,
1973
+ disabled: n.conf.update.getDisabled(e, !0),
1974
1974
  ref_for: !0
1975
- }, s.conf.update.getBind(e), z(s.conf.update.getOn(e, r)), { style: { width: "100%" } }), Q({ _: 2 }, [
1975
+ }, n.conf.update.getBind(e), z(n.conf.update.getOn(e, r)), { style: { width: "100%" } }), Q({ _: 2 }, [
1976
1976
  e.options?.input?.prepend ? {
1977
1977
  name: "prepend",
1978
1978
  fn: y(() => [
1979
- U(O(typeof e.options?.input?.prepend == "function" ? e.options?.input?.prepend(r) : e.options?.input?.prepend), 1)
1979
+ D(O(typeof e.options?.input?.prepend == "function" ? e.options?.input?.prepend(r) : e.options?.input?.prepend), 1)
1980
1980
  ]),
1981
1981
  key: "0"
1982
1982
  } : void 0
1983
- ]), 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "select" ? (u(), g(a(G), V({
1983
+ ]), 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "select" ? (d(), h(a(G), V({
1984
1984
  key: 1,
1985
- modelValue: s.conf.update.form[e.key],
1986
- "onUpdate:modelValue": (d) => s.conf.update.form[e.key] = d,
1987
- disabled: s.conf.update.getDisabled(e, !0),
1985
+ modelValue: n.conf.update.form[e.key],
1986
+ "onUpdate:modelValue": (s) => n.conf.update.form[e.key] = s,
1987
+ disabled: n.conf.update.getDisabled(e, !0),
1988
1988
  ref_for: !0
1989
- }, s.conf.update.getBind(e), z(s.conf.update.getOn(e, r)), { style: { width: "100%" } }), {
1989
+ }, n.conf.update.getBind(e), z(n.conf.update.getOn(e, r)), { style: { width: "100%" } }), {
1990
1990
  default: y(() => [
1991
- (u(!0), b($, null, A(e.options?.search?.select?.data || e.options?.select?.data, (d) => (u(), g(a(K), {
1992
- key: d.value,
1993
- label: d.label,
1994
- value: d.value
1991
+ (d(!0), b($, null, A(e.options?.search?.select?.data || e.options?.select?.data, (s) => (d(), h(a(N), {
1992
+ key: s.value,
1993
+ label: s.label,
1994
+ value: s.value
1995
1995
  }, null, 8, ["label", "value"]))), 128))
1996
1996
  ]),
1997
1997
  _: 2
1998
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "switch" ? (u(), g(a(Z), V({
1998
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "switch" ? (d(), h(a(Z), V({
1999
1999
  key: 2,
2000
- modelValue: s.conf.update.form[e.key],
2001
- "onUpdate:modelValue": (d) => s.conf.update.form[e.key] = d,
2000
+ modelValue: n.conf.update.form[e.key],
2001
+ "onUpdate:modelValue": (s) => n.conf.update.form[e.key] = s,
2002
2002
  ref_for: !0
2003
- }, s.conf.update.getBind(e), z(s.conf.update.getOn(e, r)), {
2004
- disabled: s.conf.update.getDisabled(e, !0)
2003
+ }, n.conf.update.getBind(e), z(n.conf.update.getOn(e, r)), {
2004
+ disabled: n.conf.update.getDisabled(e, !0)
2005
2005
  }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : v("", !0)
2006
- ], 64)) : C(s.$slots, "table-" + e.key, {
2006
+ ], 64)) : C(n.$slots, "table-" + e.key, {
2007
2007
  key: 1,
2008
2008
  row: r,
2009
2009
  item: e
2010
2010
  }, () => [
2011
- a(j).customComponent[e.type ?? ""]?.table ? (u(), g(W(a(j).customComponent[e.type ?? ""]?.table), V({
2011
+ a(j).customComponent[e.type ?? ""]?.table ? (d(), h(J(a(j).customComponent[e.type ?? ""]?.table), V({
2012
2012
  key: 0,
2013
2013
  modelValue: r[e.key],
2014
- "onUpdate:modelValue": (d) => r[e.key] = d,
2014
+ "onUpdate:modelValue": (s) => r[e.key] = s,
2015
2015
  ref_for: !0
2016
- }, e.options?.[e.type ?? ""], z(e.options?.[e.type ?? ""]?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue"])) : e.type === "switch" ? (u(), b($, { key: 1 }, [
2017
- e.options?.switch?.tableConfig?.change ? (u(), g(a(Z), V({
2016
+ }, e.options?.[e.type ?? ""], z(e.options?.[e.type ?? ""]?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue"])) : e.type === "switch" ? (d(), b($, { key: 1 }, [
2017
+ e.options?.switch?.tableConfig?.change ? (d(), h(a(Z), V({
2018
2018
  key: 0,
2019
2019
  modelValue: r[e.key],
2020
- "onUpdate:modelValue": (d) => r[e.key] = d,
2021
- loading: e.options?.switch?.loadingMap?.[r[s.option.table?.rowKey]]?.loading,
2020
+ "onUpdate:modelValue": (s) => r[e.key] = s,
2021
+ loading: e.options?.switch?.loadingMap?.[r[n.option.table?.rowKey]]?.loading,
2022
2022
  "before-change": () => e.options?.switch?.tableBeforeChange?.(e.key, r),
2023
2023
  ref_for: !0
2024
- }, e.options?.switch), null, 16, ["modelValue", "onUpdate:modelValue", "loading", "before-change"])) : (u(), b("span", st, O(r[e.key] === e.options?.switch?.activeValue ? e.options?.switch?.activeText : e.options?.switch?.inactiveText), 1))
2025
- ], 64)) : (u(), b("span", {
2024
+ }, e.options?.switch), null, 16, ["modelValue", "onUpdate:modelValue", "loading", "before-change"])) : (d(), b("span", dt, O(r[e.key] === e.options?.switch?.activeValue ? e.options?.switch?.activeText : e.options?.switch?.inactiveText), 1))
2025
+ ], 64)) : (d(), b("span", {
2026
2026
  key: 2,
2027
- style: pe({
2027
+ style: ce({
2028
2028
  "--table-text-click-color": e.table?.click?.color
2029
2029
  }),
2030
2030
  class: I({ "table-text-click": e.table?.click?.callback }),
2031
- onClick: (d) => e.table?.click?.callback?.(r),
2031
+ onClick: (s) => e.table?.click?.callback?.(r),
2032
2032
  innerHTML: e.table?.format ? e.table?.format(r) : r[e.key]
2033
- }, null, 14, dt))
2033
+ }, null, 14, ut))
2034
2034
  ])
2035
2035
  ], 64))
2036
2036
  ], 64))
@@ -2044,14 +2044,14 @@ const at = /* @__PURE__ */ X(et, [["render", ot]]), lt = { class: "row flex-cent
2044
2044
  }), ft = {
2045
2045
  class: "row form-item-content",
2046
2046
  style: { width: "100%" }
2047
- }, pt = { class: "col column form-item-content-item" }, ct = { class: "col" }, mt = ["innerHTML"], ht = /* @__PURE__ */ J({
2047
+ }, ct = { class: "col column form-item-content-item" }, mt = { class: "col" }, ht = ["innerHTML"], gt = /* @__PURE__ */ K({
2048
2048
  __name: "formColumn",
2049
2049
  props: {
2050
2050
  conf: {},
2051
2051
  item: {}
2052
2052
  },
2053
- setup(n) {
2054
- return (o, p) => (u(), g(a(te), {
2053
+ setup(i) {
2054
+ return (o, p) => (d(), h(a(te), {
2055
2055
  label: o.item.item.text?.form?.label ?? o.item.item.label,
2056
2056
  prop: o.item.item.key,
2057
2057
  "label-width": o.item.item.text?.form?.label == "" ? 0 : o.item.item.form?.labelWidth || o.conf.option.form?.labelWidth
@@ -2062,88 +2062,88 @@ const at = /* @__PURE__ */ X(et, [["render", ot]]), lt = { class: "row flex-cent
2062
2062
  row: o.conf.update.form,
2063
2063
  item: o.item.item
2064
2064
  }),
2065
- E("div", pt, [
2066
- E("div", ct, [
2065
+ E("div", ct, [
2066
+ E("div", mt, [
2067
2067
  C(o.$slots, "form-" + o.item.item.key, {
2068
2068
  row: o.conf.update.form,
2069
2069
  item: o.item.item
2070
2070
  }, () => [
2071
- o.item.item.type === "input" ? (u(), g(a(x), V({
2071
+ o.item.item.type === "input" ? (d(), h(a(x), V({
2072
2072
  key: 0,
2073
2073
  modelValue: o.conf.update.form[o.item.item.key],
2074
- "onUpdate:modelValue": p[0] || (p[0] = (s) => o.conf.update.form[o.item.item.key] = s)
2074
+ "onUpdate:modelValue": p[0] || (p[0] = (n) => o.conf.update.form[o.item.item.key] = n)
2075
2075
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2076
2076
  disabled: o.conf.update.getDisabled(o.item.item)
2077
2077
  }), Q({ _: 2 }, [
2078
2078
  o.item.item.options?.input?.prepend ? {
2079
2079
  name: "prepend",
2080
2080
  fn: y(() => [
2081
- U(O(typeof o.item.item.options?.input?.prepend == "function" ? o.item.item.options?.input?.prepend(o.conf.update.form) : o.item.item.options?.input?.prepend), 1)
2081
+ D(O(typeof o.item.item.options?.input?.prepend == "function" ? o.item.item.options?.input?.prepend(o.conf.update.form) : o.item.item.options?.input?.prepend), 1)
2082
2082
  ]),
2083
2083
  key: "0"
2084
2084
  } : void 0
2085
- ]), 1040, ["modelValue", "disabled"])) : o.item.item.type === "switch" ? (u(), g(a(Z), V({
2085
+ ]), 1040, ["modelValue", "disabled"])) : o.item.item.type === "switch" ? (d(), h(a(Z), V({
2086
2086
  key: 1,
2087
2087
  modelValue: o.conf.update.form[o.item.item.key],
2088
- "onUpdate:modelValue": p[1] || (p[1] = (s) => o.conf.update.form[o.item.item.key] = s)
2088
+ "onUpdate:modelValue": p[1] || (p[1] = (n) => o.conf.update.form[o.item.item.key] = n)
2089
2089
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2090
2090
  disabled: o.conf.update.getDisabled(o.item.item)
2091
- }), null, 16, ["modelValue", "disabled"])) : o.item.item.type === "select" ? (u(), g(a(G), V({
2091
+ }), null, 16, ["modelValue", "disabled"])) : o.item.item.type === "select" ? (d(), h(a(G), V({
2092
2092
  key: 2,
2093
2093
  modelValue: o.conf.update.form[o.item.item.key],
2094
- "onUpdate:modelValue": p[2] || (p[2] = (s) => o.conf.update.form[o.item.item.key] = s)
2094
+ "onUpdate:modelValue": p[2] || (p[2] = (n) => o.conf.update.form[o.item.item.key] = n)
2095
2095
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2096
2096
  disabled: o.conf.update.getDisabled(o.item.item),
2097
2097
  style: { width: "100%" }
2098
2098
  }), {
2099
2099
  default: y(() => [
2100
- (u(!0), b($, null, A(o.conf.update.getBind(o.item.item).data, (s) => (u(), g(a(K), {
2101
- key: s.value,
2102
- label: s.label,
2103
- value: s.value
2100
+ (d(!0), b($, null, A(o.conf.update.getBind(o.item.item).data, (n) => (d(), h(a(N), {
2101
+ key: n.value,
2102
+ label: n.label,
2103
+ value: n.value
2104
2104
  }, null, 8, ["label", "value"]))), 128))
2105
2105
  ]),
2106
2106
  _: 1
2107
- }, 16, ["modelValue", "disabled"])) : o.item.item.type === "radio" ? (u(), g(a(le), V({
2107
+ }, 16, ["modelValue", "disabled"])) : o.item.item.type === "radio" ? (d(), h(a(le), V({
2108
2108
  key: 3,
2109
2109
  modelValue: o.conf.update.form[o.item.item.key],
2110
- "onUpdate:modelValue": p[3] || (p[3] = (s) => o.conf.update.form[o.item.item.key] = s)
2110
+ "onUpdate:modelValue": p[3] || (p[3] = (n) => o.conf.update.form[o.item.item.key] = n)
2111
2111
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2112
2112
  disabled: o.conf.update.getDisabled(o.item.item),
2113
2113
  style: { width: "100%" }
2114
2114
  }), {
2115
2115
  default: y(() => [
2116
- (u(!0), b($, null, A(o.conf.update.getBind(o.item.item).data, (s) => (u(), g(a(ne), {
2117
- key: s.value,
2118
- label: s.label,
2119
- value: s.value
2116
+ (d(!0), b($, null, A(o.conf.update.getBind(o.item.item).data, (n) => (d(), h(a(ne), {
2117
+ key: n.value,
2118
+ label: n.label,
2119
+ value: n.value
2120
2120
  }, null, 8, ["label", "value"]))), 128))
2121
2121
  ]),
2122
2122
  _: 1
2123
- }, 16, ["modelValue", "disabled"])) : o.item.item.type === "list" ? (u(), g(se, V({
2123
+ }, 16, ["modelValue", "disabled"])) : o.item.item.type === "list" ? (d(), h(se, V({
2124
2124
  key: 4,
2125
2125
  row: o.conf.update.form,
2126
2126
  field: o.item.item.key
2127
2127
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2128
2128
  disabled: o.conf.update.getDisabled(o.item.item),
2129
2129
  style: { width: "100%" }
2130
- }), null, 16, ["row", "field", "disabled"])) : o.item.item.type === "treeSelect" ? (u(), g(a(ue), V({
2130
+ }), null, 16, ["row", "field", "disabled"])) : o.item.item.type === "treeSelect" ? (d(), h(a(pe), V({
2131
2131
  key: 5,
2132
2132
  modelValue: o.conf.update.form[o.item.item.key],
2133
- "onUpdate:modelValue": p[4] || (p[4] = (s) => o.conf.update.form[o.item.item.key] = s)
2133
+ "onUpdate:modelValue": p[4] || (p[4] = (n) => o.conf.update.form[o.item.item.key] = n)
2134
2134
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2135
2135
  disabled: o.conf.update.getDisabled(o.item.item),
2136
2136
  style: { width: "100%" }
2137
- }), null, 16, ["modelValue", "disabled"])) : o.item.item.type === "datetime" ? (u(), g(a(ie), V({
2137
+ }), null, 16, ["modelValue", "disabled"])) : o.item.item.type === "datetime" ? (d(), h(a(ie), V({
2138
2138
  key: 6,
2139
2139
  modelValue: o.conf.update.form[o.item.item.key],
2140
- "onUpdate:modelValue": p[5] || (p[5] = (s) => o.conf.update.form[o.item.item.key] = s)
2140
+ "onUpdate:modelValue": p[5] || (p[5] = (n) => o.conf.update.form[o.item.item.key] = n)
2141
2141
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2142
2142
  disabled: o.conf.update.getDisabled(o.item.item)
2143
- }), null, 16, ["modelValue", "disabled"])) : o.item.item.type && (a(j).customComponent[o.item.item.type] || a(j).customComponent[o.item.item.type]?.form) ? (u(), g(W(a(j).customComponent[o.item.item.type]?.form || a(j).customComponent[o.item.item.type]), V({
2143
+ }), null, 16, ["modelValue", "disabled"])) : o.item.item.type && (a(j).customComponent[o.item.item.type] || a(j).customComponent[o.item.item.type]?.form) ? (d(), h(J(a(j).customComponent[o.item.item.type]?.form || a(j).customComponent[o.item.item.type]), V({
2144
2144
  key: 7,
2145
2145
  modelValue: o.conf.update.form[o.item.item.key],
2146
- "onUpdate:modelValue": p[6] || (p[6] = (s) => o.conf.update.form[o.item.item.key] = s)
2146
+ "onUpdate:modelValue": p[6] || (p[6] = (n) => o.conf.update.form[o.item.item.key] = n)
2147
2147
  }, o.conf.update.getBind(o.item.item), z(o.conf.update.getOn(o.item.item)), {
2148
2148
  disabled: o.conf.update.getDisabled(o.item.item)
2149
2149
  }), null, 16, ["modelValue", "disabled"])) : v("", !0)
@@ -2157,11 +2157,11 @@ const at = /* @__PURE__ */ X(et, [["render", ot]]), lt = { class: "row flex-cent
2157
2157
  row: o.conf.update.form,
2158
2158
  item: o.item.item
2159
2159
  }, () => [
2160
- o.item.item.form?.tipText ? (u(), b("div", {
2160
+ o.item.item.form?.tipText ? (d(), b("div", {
2161
2161
  key: 0,
2162
2162
  class: "form-tip-text",
2163
2163
  innerHTML: typeof o.item.item.form?.tipText == "function" ? o.item.item.form?.tipText(o.conf.update.form, o.conf.update.type) : o.item.item.form?.tipText
2164
- }, null, 8, mt)) : v("", !0)
2164
+ }, null, 8, ht)) : v("", !0)
2165
2165
  ])
2166
2166
  ]),
2167
2167
  C(o.$slots, "form-" + o.item.item.key + "-end", {
@@ -2173,43 +2173,132 @@ const at = /* @__PURE__ */ X(et, [["render", ot]]), lt = { class: "row flex-cent
2173
2173
  _: 3
2174
2174
  }, 8, ["label", "prop", "label-width"]));
2175
2175
  }
2176
- }), gt = {}, yt = {
2176
+ }), yt = {}, bt = {
2177
2177
  xmlns: "http://www.w3.org/2000/svg",
2178
2178
  viewBox: "64 64 896 896"
2179
2179
  };
2180
- function bt(n, o) {
2181
- return u(), b("svg", yt, o[0] || (o[0] = [
2180
+ function wt(i, o) {
2181
+ return d(), b("svg", bt, o[0] || (o[0] = [
2182
2182
  E("path", {
2183
2183
  fill: "currentColor",
2184
2184
  d: "M482.2 508.4L331.3 389c-3-2.4-7.3-.2-7.3 3.6V478H184V184h204v128c0 2.2 1.8 4 4 4h60c2.2 0 4-1.8 4-4V144c0-15.5-12.5-28-28-28H144c-15.5 0-28 12.5-28 28v736c0 15.5 12.5 28 28 28h284c15.5 0 28-12.5 28-28V712c0-2.2-1.8-4-4-4h-60c-2.2 0-4 1.8-4 4v128H184V546h140v85.4c0 3.8 4.4 6 7.3 3.6l150.9-119.4a4.5 4.5 0 000-7.2zM880 116H596c-15.5 0-28 12.5-28 28v168c0 2.2 1.8 4 4 4h60c2.2 0 4-1.8 4-4V184h204v294H700v-85.4c0-3.8-4.3-6-7.3-3.6l-151 119.4a4.52 4.52 0 000 7.1l151 119.5c2.9 2.3 7.3.2 7.3-3.6V546h140v294H636V712c0-2.2-1.8-4-4-4h-60c-2.2 0-4 1.8-4 4v168c0 15.5 12.5 28 28 28h284c15.5 0 28-12.5 28-28V144c0-15.5-12.5-28-28-28z"
2185
2185
  }, null, -1)
2186
2186
  ]));
2187
2187
  }
2188
- const wt = /* @__PURE__ */ X(gt, [["render", bt]]), kt = {}, vt = {
2188
+ const kt = /* @__PURE__ */ X(yt, [["render", wt]]), vt = {}, Ct = {
2189
2189
  xmlns: "http://www.w3.org/2000/svg",
2190
2190
  viewBox: "64 64 896 896"
2191
2191
  };
2192
- function Ct(n, o) {
2193
- return u(), b("svg", vt, o[0] || (o[0] = [
2192
+ function Vt(i, o) {
2193
+ return d(), b("svg", Ct, o[0] || (o[0] = [
2194
2194
  E("path", {
2195
2195
  fill: "currentColor",
2196
2196
  d: "M180 176h-60c-4.4 0-8 3.6-8 8v656c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V184c0-4.4-3.6-8-8-8zm724 0h-60c-4.4 0-8 3.6-8 8v656c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V184c0-4.4-3.6-8-8-8zM785.3 504.3L657.7 403.6a7.23 7.23 0 00-11.7 5.7V476H378v-62.8c0-6-7-9.4-11.7-5.7L238.7 508.3a7.14 7.14 0 000 11.3l127.5 100.8c4.7 3.7 11.7.4 11.7-5.7V548h268v62.8c0 6 7 9.4 11.7 5.7l127.5-100.8c3.8-2.9 3.8-8.5.2-11.4z"
2197
2197
  }, null, -1)
2198
2198
  ]));
2199
2199
  }
2200
- const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2200
+ const zt = /* @__PURE__ */ X(vt, [["render", Vt]]), ue = /* @__PURE__ */ K({
2201
+ __name: "searchField",
2202
+ props: {
2203
+ item: {},
2204
+ conf: {},
2205
+ type: {}
2206
+ },
2207
+ setup(i) {
2208
+ const o = i, p = me({
2209
+ get: () => o.conf.search.form?.[o.item?.key],
2210
+ set: (n) => {
2211
+ o.item?.key !== void 0 && (o.conf.search.form[o.item.key] = n);
2212
+ }
2213
+ });
2214
+ return (n, l) => a(j).customComponent[n.type ?? ""]?.search ? (d(), h(J(a(j).customComponent[n.type ?? ""]?.search), V({
2215
+ key: 0,
2216
+ modelValue: p.value,
2217
+ "onUpdate:modelValue": l[0] || (l[0] = (t) => p.value = t)
2218
+ }, n.item.options?.search?.[n.type ?? ""], z(n.item.options?.search?.[n.type ?? ""]?.on || {})), null, 16, ["modelValue"])) : n.type === "input" ? (d(), h(a(x), V({
2219
+ key: 1,
2220
+ modelValue: p.value,
2221
+ "onUpdate:modelValue": l[1] || (l[1] = (t) => p.value = t),
2222
+ placeholder: n.conf.search.getPlaceholder(n.item),
2223
+ clearable: "",
2224
+ disabled: n.item.disabled?.search
2225
+ }, n.item.options?.search?.input || n.item.options?.input, z(n.item.options?.search?.input?.on || n.item.options?.input?.on || {})), null, 16, ["modelValue", "placeholder", "disabled"])) : n.type === "switch" ? (d(), h(a(G), V({
2226
+ key: 2,
2227
+ modelValue: p.value,
2228
+ "onUpdate:modelValue": l[2] || (l[2] = (t) => p.value = t),
2229
+ placeholder: n.conf.search.getPlaceholder(n.item, a(w).tCurd("placeholderSelect")),
2230
+ clearable: "",
2231
+ disabled: n.item.disabled?.search
2232
+ }, n.item.options?.search?.switch || n.item.options?.switch, z(n.item.options?.search?.switch?.on || n.item.options?.switch?.on || {})), {
2233
+ default: y(() => [
2234
+ (d(), h(a(N), {
2235
+ key: n.item.options?.switch?.activeValue,
2236
+ label: n.item.options?.switch?.activeText,
2237
+ value: n.item.options?.switch?.activeValue
2238
+ }, null, 8, ["label", "value"])),
2239
+ (d(), h(a(N), {
2240
+ key: n.item.options?.switch?.inactiveValue,
2241
+ label: n.item.options?.switch?.inactiveText,
2242
+ value: n.item.options?.switch?.inactiveValue
2243
+ }, null, 8, ["label", "value"]))
2244
+ ]),
2245
+ _: 1
2246
+ }, 16, ["modelValue", "placeholder", "disabled"])) : n.type === "select" ? (d(), h(a(G), V({
2247
+ key: 3,
2248
+ modelValue: p.value,
2249
+ "onUpdate:modelValue": l[3] || (l[3] = (t) => p.value = t),
2250
+ placeholder: n.conf.search.getPlaceholder(n.item, a(w).tCurd("placeholderSelect")),
2251
+ clearable: "",
2252
+ disabled: n.item.disabled?.search
2253
+ }, n.item.options?.search?.select || n.item.options?.select, z(n.item.options?.search?.select?.on || n.item.options?.select?.on || {})), {
2254
+ default: y(() => [
2255
+ (d(!0), b($, null, A(n.item.options?.search?.select?.data || n.item.options?.select?.data || [], (t) => (d(), h(a(N), {
2256
+ key: t.value,
2257
+ label: t.label,
2258
+ value: t.value
2259
+ }, null, 8, ["label", "value"]))), 128))
2260
+ ]),
2261
+ _: 1
2262
+ }, 16, ["modelValue", "placeholder", "disabled"])) : n.type === "radio" ? (d(), h(a(le), V({
2263
+ key: 4,
2264
+ modelValue: p.value,
2265
+ "onUpdate:modelValue": l[4] || (l[4] = (t) => p.value = t),
2266
+ disabled: n.item.disabled?.search
2267
+ }, n.item.options?.search?.radio || n.item.options?.radio, z(n.item.options?.search?.radio?.on || n.item.options?.radio?.on || {})), {
2268
+ default: y(() => [
2269
+ (d(!0), b($, null, A(n.item.options?.radio?.data, (t) => (d(), h(a(ne), {
2270
+ key: t.value,
2271
+ label: t.label,
2272
+ value: t.value
2273
+ }, null, 8, ["label", "value"]))), 128))
2274
+ ]),
2275
+ _: 1
2276
+ }, 16, ["modelValue", "disabled"])) : n.type === "datetime" ? (d(), h(a(ie), V({
2277
+ key: 5,
2278
+ modelValue: p.value,
2279
+ "onUpdate:modelValue": l[5] || (l[5] = (t) => p.value = t),
2280
+ disabled: n.item.disabled?.search
2281
+ }, n.item.options?.search?.datetime || n.item.options?.datetime, z(n.item.options?.search?.datetime?.on || n.item.options?.datetime?.on || {})), null, 16, ["modelValue", "disabled"])) : n.type && a(j).customComponent[n.type] ? (d(), h(J(a(j).customComponent[n.type]), V({
2282
+ key: 6,
2283
+ modelValue: p.value,
2284
+ "onUpdate:modelValue": l[6] || (l[6] = (t) => p.value = t)
2285
+ }, n.item.options?.search?.[n.type] || n.item.options?.[n.type], z(n.item.options?.search?.[n.type]?.on || n.item.options?.[n.type]?.on || {}), {
2286
+ disabled: n.item.disabled?.search
2287
+ }), null, 16, ["modelValue", "disabled"])) : v("", !0);
2288
+ }
2289
+ }), $t = {
2201
2290
  key: 0,
2202
2291
  class: "relative curd-search fit-width"
2203
- }, $t = { class: "mb-10 flex justify-between items-center fit-width" }, Ut = {
2292
+ }, Dt = { class: "mb-10 flex justify-between items-center fit-width" }, Ut = {
2204
2293
  class: "flex items-center",
2205
2294
  style: { gap: "10px" }
2206
- }, Dt = { key: 0 }, Et = { key: 1 }, Ot = { key: 2 }, St = { class: "export-btn" }, Mt = {
2295
+ }, Et = { key: 0 }, Ot = { key: 1 }, St = { key: 2 }, Mt = { class: "export-btn" }, Tt = {
2207
2296
  key: 1,
2208
2297
  class: "export-btn"
2209
- }, Tt = {
2298
+ }, At = {
2210
2299
  class: "flex items-center table-tools-right",
2211
2300
  style: { gap: "10px" }
2212
- }, At = { class: "row justify-end mt-10 mb-10 table-bottom-pagination" }, Ft = { class: "dialog-footer" }, Lt = { key: 0 }, jt = { key: 1 }, Bt = { class: "dialog-footer" }, Rt = /* @__PURE__ */ J({
2301
+ }, Ft = { class: "row justify-end mt-10 mb-10 table-bottom-pagination" }, Lt = { class: "dialog-footer" }, jt = { key: 0 }, Bt = { key: 1 }, Rt = { class: "dialog-footer" }, It = /* @__PURE__ */ K({
2213
2302
  __name: "index",
2214
2303
  props: {
2215
2304
  /**
@@ -2219,163 +2308,93 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2219
2308
  default: {}
2220
2309
  }
2221
2310
  },
2222
- setup(n, { expose: o }) {
2223
- const p = M.EDialog, s = n, l = M.isFun, { conf: t, switchConfirmRef: e, ruleFormRef: r, tableRef: d } = Be(s);
2311
+ setup(i, { expose: o }) {
2312
+ const p = M.EDialog, n = i, l = M.isFun, { conf: t, switchConfirmRef: e, ruleFormRef: r, tableRef: s } = Re(n);
2224
2313
  return o({
2225
2314
  conf: t
2226
2315
  }), (m, c) => {
2227
- const f = _("el-tooltip"), k = Ce("loading");
2228
- return u(), b("div", {
2229
- class: I(["relative cc1-form-box", [n.option.table?.fitHeight ? "col" : "no-min-height"]])
2316
+ const u = _("el-tooltip"), k = Ve("loading");
2317
+ return d(), b("div", {
2318
+ class: I(["relative cc1-form-box", [i.option.table?.fitHeight ? "col" : "no-min-height"]])
2230
2319
  }, [
2231
2320
  E("div", {
2232
- class: I(["row", [n.option.table?.fitHeight ? "absolute fit" : ""]]),
2321
+ class: I(["row", [i.option.table?.fitHeight ? "absolute fit" : ""]]),
2233
2322
  style: { overflow: "hidden" }
2234
2323
  }, [
2235
2324
  C(m.$slots, "box-left"),
2236
2325
  E("div", {
2237
- class: I(["column fit-width no-wrap", [n.option.table?.fitHeight ? "col" : ""]])
2326
+ class: I(["column fit-width no-wrap", [i.option.table?.fitHeight ? "col" : ""]])
2238
2327
  }, [
2239
- n.option.search?.show !== !1 ? (u(), b("div", zt, [
2240
- D(a(q), {
2328
+ i.option.search?.show !== !1 ? (d(), b("div", $t, [
2329
+ U(a(q), {
2241
2330
  model: a(t).search.form,
2242
2331
  inline: "",
2243
- size: n.option.size?.search
2332
+ size: i.option.size?.search
2244
2333
  }, {
2245
2334
  default: y(() => [
2246
2335
  C(m.$slots, "search-start", {
2247
2336
  row: a(t).search.form
2248
2337
  }),
2249
- (u(!0), b($, null, A(a(t).search.column.list, (i) => (u(), b($, {
2250
- key: i.key
2338
+ (d(!0), b($, null, A(a(t).search.column.list, (f) => (d(), b($, {
2339
+ key: f.key
2251
2340
  }, [
2252
- C(m.$slots, "search-" + i.key + "-start", {
2341
+ C(m.$slots, "search-" + f.key + "-start", {
2253
2342
  row: a(t).search.form
2254
2343
  }),
2255
- (typeof i.show?.search == "function" ? i.show?.search(a(t).search.form) : i.show?.search) ? (u(), g(a(te), {
2344
+ (typeof f.show?.search == "function" ? f.show?.search(a(t).search.form) : f.show?.search) ? (d(), h(a(te), {
2256
2345
  key: 0,
2257
- label: i.text?.search?.label ?? i.label
2346
+ label: f.text?.search?.label ?? f.label
2258
2347
  }, {
2259
2348
  default: y(() => [
2260
- C(m.$slots, "search-" + i.key + "-left", {
2349
+ C(m.$slots, "search-" + f.key + "-left", {
2261
2350
  row: a(t).search.form
2262
2351
  }),
2263
- C(m.$slots, "search-" + i.key, {
2352
+ C(m.$slots, "search-" + f.key, {
2264
2353
  row: a(t).search.form
2265
2354
  }, () => [
2266
- a(j).customComponent[i.type ?? ""]?.search ? (u(), g(W(a(j).customComponent[i.type ?? ""]?.search), V({
2355
+ f.options?.search?.type ? (d(), h(ue, {
2267
2356
  key: 0,
2268
- modelValue: a(t).search.form[i.key],
2269
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2270
- ref_for: !0
2271
- }, i.options?.search?.[i.type ?? ""], z(i.options?.search?.[i.type ?? ""]?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue"])) : i.type === "input" ? (u(), g(a(x), V({
2357
+ item: f,
2358
+ conf: a(t),
2359
+ type: f.options.search.type
2360
+ }, null, 8, ["item", "conf", "type"])) : (d(), h(ue, {
2272
2361
  key: 1,
2273
- modelValue: a(t).search.form[i.key],
2274
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2275
- placeholder: a(t).search.getPlaceholder(i),
2276
- clearable: "",
2277
- disabled: i.disabled?.search,
2278
- ref_for: !0
2279
- }, i.options?.search?.input || i.options?.input, z(i.options?.search?.input?.on || i.options?.input?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : i.type === "switch" ? (u(), g(a(G), V({
2280
- key: 2,
2281
- modelValue: a(t).search.form[i.key],
2282
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2283
- placeholder: a(t).search.getPlaceholder(i, a(w).tCurd("placeholderSelect")),
2284
- clearable: "",
2285
- disabled: i.disabled?.search,
2286
- ref_for: !0
2287
- }, i.options?.search?.switch || i.options?.switch, z(i.options?.search?.switch?.on || i.options?.switch?.on || {})), {
2288
- default: y(() => [
2289
- (u(), g(a(K), {
2290
- key: i.options?.switch?.activeValue,
2291
- label: i.options?.switch?.activeText,
2292
- value: i.options?.switch?.activeValue
2293
- }, null, 8, ["label", "value"])),
2294
- (u(), g(a(K), {
2295
- key: i.options?.switch?.inactiveValue,
2296
- label: i.options?.switch?.inactiveText,
2297
- value: i.options?.switch?.inactiveValue
2298
- }, null, 8, ["label", "value"]))
2299
- ]),
2300
- _: 2
2301
- }, 1040, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : i.type === "select" ? (u(), g(a(G), V({
2302
- key: 3,
2303
- modelValue: a(t).search.form[i.key],
2304
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2305
- placeholder: a(t).search.getPlaceholder(i, a(w).tCurd("placeholderSelect")),
2306
- clearable: "",
2307
- disabled: i.disabled?.search,
2308
- ref_for: !0
2309
- }, i.options?.search?.select || i.options?.select, z(i.options?.search?.select?.on || i.options?.select?.on || {})), {
2310
- default: y(() => [
2311
- (u(!0), b($, null, A(i.options?.select?.data, (h) => (u(), g(a(K), {
2312
- key: h.value,
2313
- label: h.label,
2314
- value: h.value
2315
- }, null, 8, ["label", "value"]))), 128))
2316
- ]),
2317
- _: 2
2318
- }, 1040, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : i.type === "radio" ? (u(), g(a(le), V({
2319
- key: 4,
2320
- modelValue: a(t).search.form[i.key],
2321
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2322
- disabled: i.disabled?.search,
2323
- ref_for: !0
2324
- }, i.options?.search?.radio || i.options?.radio, z(i.options?.search?.radio?.on || i.options?.radio?.on || {})), {
2325
- default: y(() => [
2326
- (u(!0), b($, null, A(i.options?.radio?.data, (h) => (u(), g(a(ne), {
2327
- key: h.value,
2328
- label: h.label,
2329
- value: h.value
2330
- }, null, 8, ["label", "value"]))), 128))
2331
- ]),
2332
- _: 2
2333
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : i.type === "datetime" ? (u(), g(a(ie), V({
2334
- key: 5,
2335
- modelValue: a(t).search.form[i.key],
2336
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2337
- disabled: i.disabled?.search,
2338
- ref_for: !0
2339
- }, i.options?.search?.datetime || i.options?.datetime, z(i.options?.search?.datetime?.on || i.options?.datetime?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : i.type && a(j).customComponent[i.type] ? (u(), g(W(a(j).customComponent[i.type]), V({
2340
- key: 6,
2341
- modelValue: a(t).search.form[i.key],
2342
- "onUpdate:modelValue": (h) => a(t).search.form[i.key] = h,
2343
- ref_for: !0
2344
- }, i.options?.search?.[i.type] || i.options?.[i.type], z(i.options?.search?.[i.type]?.on || i.options?.[i.type]?.on || {}), {
2345
- disabled: i.disabled?.search
2346
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : v("", !0)
2362
+ item: f,
2363
+ conf: a(t),
2364
+ type: f.type
2365
+ }, null, 8, ["item", "conf", "type"]))
2347
2366
  ]),
2348
- C(m.$slots, "search-" + i.key + "-right", {
2367
+ C(m.$slots, "search-" + f.key + "-right", {
2349
2368
  row: a(t).search.form
2350
2369
  })
2351
2370
  ]),
2352
2371
  _: 2
2353
2372
  }, 1032, ["label"])) : v("", !0),
2354
- C(m.$slots, "search-" + i.key + "-end", {
2373
+ C(m.$slots, "search-" + f.key + "-end", {
2355
2374
  row: a(t).search.form
2356
2375
  })
2357
2376
  ], 64))), 128)),
2358
2377
  C(m.$slots, "search-center", {
2359
2378
  row: a(t).search.form
2360
2379
  }),
2361
- n.option.tools?.search || n.option.tools?.reset ? (u(), g(a(te), { key: 0 }, {
2380
+ i.option.tools?.search || i.option.tools?.reset ? (d(), h(a(te), { key: 0 }, {
2362
2381
  default: y(() => [
2363
- n.option.tools?.search ? (u(), g(a(L), {
2382
+ i.option.tools?.search ? (d(), h(a(L), {
2364
2383
  key: 0,
2365
2384
  type: "primary",
2366
2385
  onClick: a(t).search.submit
2367
2386
  }, {
2368
2387
  default: y(() => [
2369
- U(O(a(w).tCurd("search")), 1)
2388
+ D(O(a(w).tCurd("search")), 1)
2370
2389
  ]),
2371
2390
  _: 1
2372
2391
  }, 8, ["onClick"])) : v("", !0),
2373
- n.option.tools?.reset ? (u(), g(a(L), {
2392
+ i.option.tools?.reset ? (d(), h(a(L), {
2374
2393
  key: 1,
2375
2394
  onClick: a(t).search.reset
2376
2395
  }, {
2377
2396
  default: y(() => [
2378
- U(O(a(w).tCurd("reset")), 1)
2397
+ D(O(a(w).tCurd("reset")), 1)
2379
2398
  ]),
2380
2399
  _: 1
2381
2400
  }, 8, ["onClick"])) : v("", !0)
@@ -2389,78 +2408,78 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2389
2408
  _: 3
2390
2409
  }, 8, ["model", "size"])
2391
2410
  ])) : v("", !0),
2392
- E("div", $t, [
2411
+ E("div", Dt, [
2393
2412
  E("div", Ut, [
2394
- a(l)(n.option.tools?.add) ? (u(), b("div", Dt, [
2395
- D(a(L), {
2413
+ a(l)(i.option.tools?.add) ? (d(), b("div", Et, [
2414
+ U(a(L), {
2396
2415
  type: "primary",
2397
- onClick: c[0] || (c[0] = (i) => a(t).update.open(a(p).Add)),
2398
- size: n.option.size?.search
2416
+ onClick: c[0] || (c[0] = (f) => a(t).update.open(a(p).Add)),
2417
+ size: i.option.size?.search
2399
2418
  }, {
2400
2419
  default: y(() => [
2401
- U(O(a(w).tCurd("add")), 1)
2420
+ D(O(a(w).tCurd("add")), 1)
2402
2421
  ]),
2403
2422
  _: 1
2404
2423
  }, 8, ["size"])
2405
2424
  ])) : v("", !0),
2406
- n.option.table?.selectable && a(l)(n.option.tools?.delete) ? (u(), b("div", Et, [
2407
- D(a(L), {
2425
+ i.option.table?.selectable && a(l)(i.option.tools?.delete) ? (d(), b("div", Ot, [
2426
+ U(a(L), {
2408
2427
  type: "danger",
2409
- onClick: c[1] || (c[1] = (i) => a(t).remove.open(a(t).table.selection.list)),
2410
- size: n.option.size?.search
2428
+ onClick: c[1] || (c[1] = (f) => a(t).remove.open(a(t).table.selection.list)),
2429
+ size: i.option.size?.search
2411
2430
  }, {
2412
2431
  default: y(() => [
2413
- U(O(a(w).tCurd("delete")), 1)
2432
+ D(O(a(w).tCurd("delete")), 1)
2414
2433
  ]),
2415
2434
  _: 1
2416
2435
  }, 8, ["size"])
2417
2436
  ])) : v("", !0),
2418
- n.option.tools?.expand ? (u(), b("div", Ot, [
2419
- D(a(L), {
2437
+ i.option.tools?.expand ? (d(), b("div", St, [
2438
+ U(a(L), {
2420
2439
  type: "warning",
2421
- onClick: c[2] || (c[2] = (i) => a(t).table.expand.all()),
2422
- size: n.option.size?.search
2440
+ onClick: c[2] || (c[2] = (f) => a(t).table.expand.all()),
2441
+ size: i.option.size?.search
2423
2442
  }, {
2424
2443
  default: y(() => [
2425
- U(O(a(w).tCurd("expandCollapse")), 1)
2444
+ D(O(a(w).tCurd("expandCollapse")), 1)
2426
2445
  ]),
2427
2446
  _: 1
2428
2447
  }, 8, ["size"])
2429
2448
  ])) : v("", !0),
2430
- n.option.tools?.export?.show ? (u(), b($, { key: 3 }, [
2431
- n.option.tools?.export?.dropdown?.show ? (u(), g(a(he), {
2449
+ i.option.tools?.export?.show ? (d(), b($, { key: 3 }, [
2450
+ i.option.tools?.export?.dropdown?.show ? (d(), h(a(ye), {
2432
2451
  key: 0,
2433
2452
  onCommand: a(t).export.click
2434
2453
  }, {
2435
2454
  dropdown: y(() => [
2436
- D(a(ge), {
2437
- size: n.option.size?.search
2455
+ U(a(be), {
2456
+ size: i.option.size?.search
2438
2457
  }, {
2439
2458
  default: y(() => [
2440
- n.option.tools?.export?.dropdown?.select && (n.option.table?.selectable || a(l)(n.option.tools?.delete)) ? (u(), g(a(oe), {
2459
+ i.option.tools?.export?.dropdown?.select && (i.option.table?.selectable || a(l)(i.option.tools?.delete)) ? (d(), h(a(oe), {
2441
2460
  key: 0,
2442
2461
  command: "select"
2443
2462
  }, {
2444
2463
  default: y(() => [
2445
- U(O(a(w).tCurd("exportSelect")), 1)
2464
+ D(O(a(w).tCurd("exportSelect")), 1)
2446
2465
  ]),
2447
2466
  _: 1
2448
2467
  })) : v("", !0),
2449
- n.option.tools?.export?.dropdown?.page ? (u(), g(a(oe), {
2468
+ i.option.tools?.export?.dropdown?.page ? (d(), h(a(oe), {
2450
2469
  key: 1,
2451
2470
  command: "page"
2452
2471
  }, {
2453
2472
  default: y(() => [
2454
- U(O(a(w).tCurd("exportPage")), 1)
2473
+ D(O(a(w).tCurd("exportPage")), 1)
2455
2474
  ]),
2456
2475
  _: 1
2457
2476
  })) : v("", !0),
2458
- n.option.tools?.export?.dropdown?.all ? (u(), g(a(oe), {
2477
+ i.option.tools?.export?.dropdown?.all ? (d(), h(a(oe), {
2459
2478
  key: 2,
2460
2479
  command: "all"
2461
2480
  }, {
2462
2481
  default: y(() => [
2463
- U(O(a(w).tCurd("exportAll")), 1)
2482
+ D(O(a(w).tCurd("exportAll")), 1)
2464
2483
  ]),
2465
2484
  _: 1
2466
2485
  })) : v("", !0)
@@ -2469,29 +2488,29 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2469
2488
  }, 8, ["size"])
2470
2489
  ]),
2471
2490
  default: y(() => [
2472
- E("div", St, [
2473
- D(a(L), {
2491
+ E("div", Mt, [
2492
+ U(a(L), {
2474
2493
  type: "warning",
2475
2494
  loading: a(t).export.loading,
2476
- size: n.option.size?.search
2495
+ size: i.option.size?.search
2477
2496
  }, {
2478
2497
  default: y(() => [
2479
- U(O(a(w).tCurd("export")), 1)
2498
+ D(O(a(w).tCurd("export")), 1)
2480
2499
  ]),
2481
2500
  _: 1
2482
2501
  }, 8, ["loading", "size"])
2483
2502
  ])
2484
2503
  ]),
2485
2504
  _: 1
2486
- }, 8, ["onCommand"])) : (u(), b("div", Mt, [
2487
- D(a(L), {
2505
+ }, 8, ["onCommand"])) : (d(), b("div", Tt, [
2506
+ U(a(L), {
2488
2507
  type: "warning",
2489
2508
  loading: a(t).export.loading,
2490
- size: n.option.size?.search,
2491
- onClick: c[3] || (c[3] = (i) => a(t).export.run.start("all"))
2509
+ size: i.option.size?.search,
2510
+ onClick: c[3] || (c[3] = (f) => a(t).export.run.start("all"))
2492
2511
  }, {
2493
2512
  default: y(() => [
2494
- U(O(a(w).tCurd("export")), 1)
2513
+ D(O(a(w).tCurd("export")), 1)
2495
2514
  ]),
2496
2515
  _: 1
2497
2516
  }, 8, ["loading", "size"])
@@ -2499,24 +2518,24 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2499
2518
  ], 64)) : v("", !0),
2500
2519
  C(m.$slots, "tools-left")
2501
2520
  ]),
2502
- E("div", Tt, [
2521
+ E("div", At, [
2503
2522
  C(m.$slots, "tools-right"),
2504
- a(t).page.showTools ? (u(), g(a(de), V({
2523
+ a(t).page.showTools ? (d(), h(a(de), V({
2505
2524
  key: 0,
2506
2525
  "current-page": a(t).page.num,
2507
- "onUpdate:currentPage": c[4] || (c[4] = (i) => a(t).page.num = i),
2526
+ "onUpdate:currentPage": c[4] || (c[4] = (f) => a(t).page.num = f),
2508
2527
  "page-size": a(t).page.size,
2509
- "onUpdate:pageSize": c[5] || (c[5] = (i) => a(t).page.size = i),
2528
+ "onUpdate:pageSize": c[5] || (c[5] = (f) => a(t).page.size = f),
2510
2529
  background: "",
2511
2530
  "page-sizes": a(t).page.sizeList,
2512
2531
  "pager-count": a(t).page.pagerCount,
2513
2532
  layout: a(t).page.layout,
2514
2533
  total: a(t).page.total,
2515
- size: n.option.size?.table,
2534
+ size: i.option.size?.table,
2516
2535
  onSizeChange: a(t).table.getList,
2517
2536
  onCurrentChange: a(t).table.getList
2518
- }, n.option.page?.pagination || {}, z(n.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "size", "onSizeChange", "onCurrentChange"])) : v("", !0),
2519
- n.option.tools?.expandColumn === void 0 || n.option.tools?.expandColumn ? (u(), g(f, {
2537
+ }, i.option.page?.pagination || {}, z(i.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "size", "onSizeChange", "onCurrentChange"])) : v("", !0),
2538
+ i.option.tools?.expandColumn === void 0 || i.option.tools?.expandColumn ? (d(), h(u, {
2520
2539
  key: 1,
2521
2540
  effect: "dark",
2522
2541
  content: a(t).table.header.group.expand ? a(w).tCurd("mergeColumn") : a(w).tCurd("expandColumn"),
@@ -2524,43 +2543,43 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2524
2543
  }, {
2525
2544
  default: y(() => [
2526
2545
  E("div", {
2527
- class: I(["refresh-btn", [n.option.size?.search]]),
2546
+ class: I(["refresh-btn", [i.option.size?.search]]),
2528
2547
  onClick: c[6] || (c[6] = //@ts-ignore
2529
- (...i) => a(t).table.header.group.toggleExpandAll && a(t).table.header.group.toggleExpandAll(...i))
2548
+ (...f) => a(t).table.header.group.toggleExpandAll && a(t).table.header.group.toggleExpandAll(...f))
2530
2549
  }, [
2531
- a(t).table.header.group.expand ? (u(), g(wt, { key: 0 })) : (u(), g(Vt, { key: 1 }))
2550
+ a(t).table.header.group.expand ? (d(), h(kt, { key: 0 })) : (d(), h(zt, { key: 1 }))
2532
2551
  ], 2)
2533
2552
  ]),
2534
2553
  _: 1
2535
2554
  }, 8, ["content"])) : v("", !0),
2536
- n.option.tools?.refresh === void 0 || n.option.tools?.refresh ? (u(), b("div", {
2555
+ i.option.tools?.refresh === void 0 || i.option.tools?.refresh ? (d(), b("div", {
2537
2556
  key: 2,
2538
- class: I(["refresh-btn", [n.option.size?.search]]),
2557
+ class: I(["refresh-btn", [i.option.size?.search]]),
2539
2558
  onClick: c[7] || (c[7] = //@ts-ignore
2540
- (...i) => a(t).table.getList && a(t).table.getList(...i))
2559
+ (...f) => a(t).table.getList && a(t).table.getList(...f))
2541
2560
  }, [
2542
- D(Ne)
2561
+ U(We)
2543
2562
  ], 2)) : v("", !0)
2544
2563
  ])
2545
2564
  ]),
2546
2565
  E("div", {
2547
- class: I(["fit-width relative form-box", [n.option.table?.fitHeight ? "col " : "", n.option.table?.editMode ? "edit-mode" : ""]])
2566
+ class: I(["fit-width relative form-box", [i.option.table?.fitHeight ? "col " : "", i.option.table?.editMode ? "edit-mode" : ""]])
2548
2567
  }, [
2549
2568
  E("div", {
2550
- class: I(["column form-box-content", [n.option.table?.fitHeight ? "absolute fit" : ""]])
2569
+ class: I(["column form-box-content", [i.option.table?.fitHeight ? "absolute fit" : ""]])
2551
2570
  }, [
2552
- Ve((u(), g(a(ye), V({
2571
+ ze((d(), h(a(we), V({
2553
2572
  ref_key: "tableRef",
2554
- ref: d,
2573
+ ref: s,
2555
2574
  data: a(t).table.data,
2556
- border: n.option.table?.border === void 0 ? !0 : n.option.table?.border,
2575
+ border: i.option.table?.border === void 0 ? !0 : i.option.table?.border,
2557
2576
  onSelectionChange: a(t).table.selection.change,
2558
2577
  onSortChange: a(t).table.sort.change,
2559
2578
  "expand-row-keys": a(t).table.expand.rowKeys,
2560
2579
  onExpandChange: a(t).table.expand.change
2561
- }, n.option.table, z(n.option.table?.on || {})), {
2580
+ }, i.option.table, z(i.option.table?.on || {})), {
2562
2581
  default: y(() => [
2563
- (typeof n.option.table?.selectable == "object" ? n.option.table?.selectable?.show : n.option.table?.selectable) || a(l)(n.option.tools?.delete) || n.option.tools?.export?.show && n.option.tools?.export?.select ? (u(), g(a(ee), V({
2582
+ (typeof i.option.table?.selectable == "object" ? i.option.table?.selectable?.show : i.option.table?.selectable) || a(l)(i.option.tools?.delete) || i.option.tools?.export?.show && i.option.tools?.export?.select ? (d(), h(a(ee), V({
2564
2583
  key: 0,
2565
2584
  type: "selection",
2566
2585
  width: "40",
@@ -2568,8 +2587,8 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2568
2587
  fixed: "left",
2569
2588
  "show-overflow-tooltip": !1,
2570
2589
  className: "cc1-form-selectable-column"
2571
- }, typeof n.option.table?.selectable == "object" ? n.option.table?.selectable : {}, z(typeof n.option.table?.selectable == "object" ? n.option.table?.selectable?.on || {} : {})), null, 16)) : v("", !0),
2572
- (typeof n.option.table?.index == "object" ? n.option.table?.index?.show : n.option.table?.index) ? (u(), g(a(ee), V({
2590
+ }, typeof i.option.table?.selectable == "object" ? i.option.table?.selectable : {}, z(typeof i.option.table?.selectable == "object" ? i.option.table?.selectable?.on || {} : {})), null, 16)) : v("", !0),
2591
+ (typeof i.option.table?.index == "object" ? i.option.table?.index?.show : i.option.table?.index) ? (d(), h(a(ee), V({
2573
2592
  key: 1,
2574
2593
  type: "index",
2575
2594
  fixed: "left",
@@ -2578,106 +2597,106 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2578
2597
  label: "#",
2579
2598
  "show-overflow-tooltip": !1,
2580
2599
  className: "cc1-form-index-column"
2581
- }, typeof n.option.table?.index == "object" ? n.option.table?.index : {}, z(typeof n.option.table?.index == "object" ? n.option.table?.index?.on || {} : {})), null, 16)) : v("", !0),
2582
- D(ut, {
2600
+ }, typeof i.option.table?.index == "object" ? i.option.table?.index : {}, z(typeof i.option.table?.index == "object" ? i.option.table?.index?.on || {} : {})), null, 16)) : v("", !0),
2601
+ U(pt, {
2583
2602
  conf: a(t),
2584
2603
  columnList: a(t).table.column.list,
2585
- option: n.option
2604
+ option: i.option
2586
2605
  }, Q({ _: 2 }, [
2587
- A(m.$slots, (i, h) => ({
2588
- name: h,
2606
+ A(m.$slots, (f, g) => ({
2607
+ name: g,
2589
2608
  fn: y((S) => [
2590
- C(m.$slots, h, ze($e(S || {})))
2609
+ C(m.$slots, g, $e(De(S || {})))
2591
2610
  ])
2592
2611
  }))
2593
2612
  ]), 1032, ["conf", "columnList", "option"]),
2594
- a(l)(n.option.table?.add) || a(l)(n.option.table?.update) || a(l)(n.option.table?.delete) || a(l)(n.option.table?.view) || m.$slots["table-op-left"] || m.$slots["table-op-right"] ? (u(), g(a(ee), V({
2613
+ a(l)(i.option.table?.add) || a(l)(i.option.table?.update) || a(l)(i.option.table?.delete) || a(l)(i.option.table?.view) || m.$slots["table-op-left"] || m.$slots["table-op-right"] ? (d(), h(a(ee), V({
2595
2614
  key: 2,
2596
2615
  width: "auto",
2597
2616
  "max-width": "200",
2598
2617
  align: "center",
2599
2618
  fixed: "right"
2600
- }, n.option.table?.operate, { "show-overflow-tooltip": !1 }), {
2619
+ }, i.option.table?.operate, { "show-overflow-tooltip": !1 }), {
2601
2620
  header: y(() => [
2602
2621
  C(m.$slots, "table-header-op", {}, () => [
2603
- U(O(a(w).tCurd("operation")), 1)
2622
+ D(O(a(w).tCurd("operation")), 1)
2604
2623
  ])
2605
2624
  ]),
2606
- default: y(({ row: i }) => [
2607
- D(a(q), {
2608
- size: n.option.size?.table
2625
+ default: y(({ row: f }) => [
2626
+ U(a(q), {
2627
+ size: i.option.size?.table
2609
2628
  }, {
2610
2629
  default: y(() => [
2611
- C(m.$slots, "table-op-left", { row: i }),
2612
- a(t).update.type === a(p).Update && n.option.table?.inlineEdit && a(t).update.form[s.option.table?.rowKey] === i[s.option.table?.rowKey] ? (u(), b($, { key: 0 }, [
2613
- D(a(L), {
2630
+ C(m.$slots, "table-op-left", { row: f }),
2631
+ a(t).update.type === a(p).Update && i.option.table?.inlineEdit && a(t).update.form[n.option.table?.rowKey] === f[n.option.table?.rowKey] ? (d(), b($, { key: 0 }, [
2632
+ U(a(L), {
2614
2633
  link: "",
2615
2634
  type: "info",
2616
2635
  onClick: a(t).update.close
2617
2636
  }, {
2618
2637
  default: y(() => [
2619
- U(O(a(w).tCurd("cancel")), 1)
2638
+ D(O(a(w).tCurd("cancel")), 1)
2620
2639
  ]),
2621
2640
  _: 1
2622
2641
  }, 8, ["onClick"]),
2623
- D(a(L), {
2642
+ U(a(L), {
2624
2643
  link: "",
2625
2644
  type: "primary",
2626
2645
  onClick: a(t).update.submit,
2627
2646
  loading: a(t).update.loading
2628
2647
  }, {
2629
2648
  default: y(() => [
2630
- U(O(a(w).tCurd("confirm")), 1)
2649
+ D(O(a(w).tCurd("confirm")), 1)
2631
2650
  ]),
2632
2651
  _: 1
2633
2652
  }, 8, ["onClick", "loading"]),
2634
- C(m.$slots, "table-op-edit-right", { row: i })
2635
- ], 64)) : (u(), b($, { key: 1 }, [
2636
- a(l)(n.option.table?.add, i) ? (u(), g(a(L), {
2653
+ C(m.$slots, "table-op-edit-right", { row: f })
2654
+ ], 64)) : (d(), b($, { key: 1 }, [
2655
+ a(l)(i.option.table?.add, f) ? (d(), h(a(L), {
2637
2656
  key: 0,
2638
2657
  link: "",
2639
2658
  type: "primary",
2640
- onClick: (h) => a(t).update.open(a(p).Add, i)
2659
+ onClick: (g) => a(t).update.open(a(p).Add, f)
2641
2660
  }, {
2642
2661
  default: y(() => [
2643
- U(O(a(w).tCurd("add")), 1)
2662
+ D(O(a(w).tCurd("add")), 1)
2644
2663
  ]),
2645
2664
  _: 2
2646
2665
  }, 1032, ["onClick"])) : v("", !0),
2647
- a(l)(n.option.table?.view, i) ? (u(), g(a(L), {
2666
+ a(l)(i.option.table?.view, f) ? (d(), h(a(L), {
2648
2667
  key: 1,
2649
2668
  link: "",
2650
2669
  type: "primary",
2651
- onClick: (h) => a(t).update.open(a(p).View, i)
2670
+ onClick: (g) => a(t).update.open(a(p).View, f)
2652
2671
  }, {
2653
2672
  default: y(() => [
2654
- U(O(a(w).tCurd("view")), 1)
2673
+ D(O(a(w).tCurd("view")), 1)
2655
2674
  ]),
2656
2675
  _: 2
2657
2676
  }, 1032, ["onClick"])) : v("", !0),
2658
- a(l)(n.option.table?.update, i) ? (u(), g(a(L), {
2677
+ a(l)(i.option.table?.update, f) ? (d(), h(a(L), {
2659
2678
  key: 2,
2660
2679
  link: "",
2661
2680
  type: "warning",
2662
- onClick: (h) => a(t).update.open(a(p).Update, i)
2681
+ onClick: (g) => a(t).update.open(a(p).Update, f)
2663
2682
  }, {
2664
2683
  default: y(() => [
2665
- U(O(a(w).tCurd("edit")), 1)
2684
+ D(O(a(w).tCurd("edit")), 1)
2666
2685
  ]),
2667
2686
  _: 2
2668
2687
  }, 1032, ["onClick"])) : v("", !0),
2669
- a(l)(n.option.table?.delete, i) ? (u(), g(a(L), {
2688
+ a(l)(i.option.table?.delete, f) ? (d(), h(a(L), {
2670
2689
  key: 3,
2671
2690
  link: "",
2672
2691
  type: "danger",
2673
- onClick: (h) => a(t).remove.open([i])
2692
+ onClick: (g) => a(t).remove.open([f])
2674
2693
  }, {
2675
2694
  default: y(() => [
2676
- U(O(a(w).tCurd("delete")), 1)
2695
+ D(O(a(w).tCurd("delete")), 1)
2677
2696
  ]),
2678
2697
  _: 2
2679
2698
  }, 1032, ["onClick"])) : v("", !0),
2680
- C(m.$slots, "table-op-right", { row: i })
2699
+ C(m.$slots, "table-op-right", { row: f })
2681
2700
  ], 64))
2682
2701
  ]),
2683
2702
  _: 2
@@ -2692,54 +2711,54 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2692
2711
  ])
2693
2712
  ], 2)
2694
2713
  ], 2),
2695
- E("div", At, [
2696
- (n.option.page?.show === void 0 || n.option.page?.show) && !a(t).page.showTools ? (u(), g(a(de), V({
2714
+ E("div", Ft, [
2715
+ (i.option.page?.show === void 0 || i.option.page?.show) && !a(t).page.showTools ? (d(), h(a(de), V({
2697
2716
  key: 0,
2698
2717
  "current-page": a(t).page.num,
2699
- "onUpdate:currentPage": c[8] || (c[8] = (i) => a(t).page.num = i),
2718
+ "onUpdate:currentPage": c[8] || (c[8] = (f) => a(t).page.num = f),
2700
2719
  "page-size": a(t).page.size,
2701
- "onUpdate:pageSize": c[9] || (c[9] = (i) => a(t).page.size = i),
2720
+ "onUpdate:pageSize": c[9] || (c[9] = (f) => a(t).page.size = f),
2702
2721
  background: "",
2703
2722
  "page-sizes": a(t).page.sizeList,
2704
2723
  "pager-count": a(t).page.pagerCount,
2705
2724
  layout: a(t).page.layout,
2706
2725
  total: a(t).page.total,
2707
- size: n.option.size?.table,
2726
+ size: i.option.size?.table,
2708
2727
  onSizeChange: a(t).table.getList,
2709
2728
  onCurrentChange: a(t).table.getList
2710
- }, n.option.page?.pagination || {}, z(n.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "size", "onSizeChange", "onCurrentChange"])) : v("", !0)
2729
+ }, i.option.page?.pagination || {}, z(i.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "size", "onSizeChange", "onCurrentChange"])) : v("", !0)
2711
2730
  ])
2712
2731
  ], 2),
2713
2732
  C(m.$slots, "box-right")
2714
2733
  ], 2),
2715
- D(a(ae), V({
2734
+ U(a(ae), V({
2716
2735
  modelValue: a(t).update.show,
2717
- "onUpdate:modelValue": c[10] || (c[10] = (i) => a(t).update.show = i),
2736
+ "onUpdate:modelValue": c[10] || (c[10] = (f) => a(t).update.show = f),
2718
2737
  title: a(t).update.title,
2719
2738
  "before-close": a(t).update.close
2720
- }, n.option.dialog), {
2739
+ }, i.option.dialog), {
2721
2740
  footer: y(() => [
2722
- E("span", Ft, [
2723
- D(a(q), {
2724
- size: n.option.size?.form
2741
+ E("span", Lt, [
2742
+ U(a(q), {
2743
+ size: i.option.size?.form
2725
2744
  }, {
2726
2745
  default: y(() => [
2727
- D(a(L), {
2746
+ U(a(L), {
2728
2747
  onClick: a(t).update.close
2729
2748
  }, {
2730
2749
  default: y(() => [
2731
- U(O(a(w).tCurd("close")), 1)
2750
+ D(O(a(w).tCurd("close")), 1)
2732
2751
  ]),
2733
2752
  _: 1
2734
2753
  }, 8, ["onClick"]),
2735
- a(t).update.type !== a(p).View ? (u(), g(a(L), {
2754
+ a(t).update.type !== a(p).View ? (d(), h(a(L), {
2736
2755
  key: 0,
2737
2756
  type: "primary",
2738
2757
  onClick: a(t).update.submit,
2739
2758
  loading: a(t).update.loading
2740
2759
  }, {
2741
2760
  default: y(() => [
2742
- U(O(a(w).tCurd("submit")), 1)
2761
+ D(O(a(w).tCurd("submit")), 1)
2743
2762
  ]),
2744
2763
  _: 1
2745
2764
  }, 8, ["onClick", "loading"])) : v("", !0)
@@ -2749,40 +2768,40 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2749
2768
  ])
2750
2769
  ]),
2751
2770
  default: y(() => [
2752
- D(a(q), {
2771
+ U(a(q), {
2753
2772
  ref_key: "ruleFormRef",
2754
2773
  ref: r,
2755
2774
  model: a(t).update.form,
2756
2775
  rules: a(t).update.rules,
2757
- size: n.option.size?.form,
2776
+ size: i.option.size?.form,
2758
2777
  class: "update-dialog-form"
2759
2778
  }, {
2760
2779
  default: y(() => [
2761
- a(t).update.showContent ? (u(!0), b($, { key: 0 }, A(a(t).update.formColumn, (i) => (u(), b($, null, [
2780
+ a(t).update.showContent ? (d(!0), b($, { key: 0 }, A(a(t).update.formColumn, (f) => (d(), b($, null, [
2762
2781
  a(l)(
2763
2782
  (() => {
2764
- const h = [], S = (B) => {
2765
- B?.item?.children ? S(B.item.children) : h.push(...B.map((F) => F.item?.show?.form));
2783
+ const g = [], S = (B) => {
2784
+ B?.item?.children ? S(B.item.children) : g.push(...B.map((F) => F.item?.show?.form));
2766
2785
  };
2767
- return S(i), h;
2786
+ return S(f), g;
2768
2787
  })(),
2769
2788
  a(t).update.form,
2770
2789
  a(t).update.type
2771
- ) ? (u(), b("div", {
2790
+ ) ? (d(), b("div", {
2772
2791
  key: 0,
2773
2792
  class: I(["row curd-row", {
2774
- stripe: n.option.form?.stripe === void 0 ? !0 : n.option.form?.stripe
2793
+ stripe: i.option.form?.stripe === void 0 ? !0 : i.option.form?.stripe
2775
2794
  }])
2776
2795
  }, [
2777
2796
  C(m.$slots, "form-start", {
2778
2797
  row: a(t).update.form
2779
2798
  }),
2780
- (u(!0), b($, null, A(i, (h) => (u(), b($, null, [
2781
- a(l)(h.item.show?.form, a(t).update.form, a(t).update.type) ? (u(), b("div", {
2799
+ (d(!0), b($, null, A(f, (g) => (d(), b($, null, [
2800
+ a(l)(g.item.show?.form, a(t).update.form, a(t).update.type) ? (d(), b("div", {
2782
2801
  key: 0,
2783
- class: I([h.item.form.span > 0 ? `col-${a(t).getColumnSpan(h, i)}` : "col", `form-item-col-${h.item.key}`])
2802
+ class: I([g.item.form.span > 0 ? `col-${a(t).getColumnSpan(g, f)}` : "col", `form-item-col-${g.item.key}`])
2784
2803
  }, [
2785
- (u(!0), b($, null, A(h.item.children ? h.children : [h], (S) => (u(), g(ht, {
2804
+ (d(!0), b($, null, A(g.item.children ? g.children : [g], (S) => (d(), h(gt, {
2786
2805
  key: S.item.key,
2787
2806
  conf: a(t),
2788
2807
  item: S
@@ -2807,33 +2826,33 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2807
2826
  ]),
2808
2827
  _: 3
2809
2828
  }, 16, ["modelValue", "title", "before-close"]),
2810
- D(a(ae), {
2829
+ U(a(ae), {
2811
2830
  modelValue: a(t).remove.show,
2812
- "onUpdate:modelValue": c[11] || (c[11] = (i) => a(t).remove.show = i),
2831
+ "onUpdate:modelValue": c[11] || (c[11] = (f) => a(t).remove.show = f),
2813
2832
  title: a(t).remove.title,
2814
2833
  "close-on-click-modal": !1
2815
2834
  }, {
2816
2835
  footer: y(() => [
2817
- E("span", Bt, [
2818
- D(a(q), {
2819
- size: n.option.size?.form
2836
+ E("span", Rt, [
2837
+ U(a(q), {
2838
+ size: i.option.size?.form
2820
2839
  }, {
2821
2840
  default: y(() => [
2822
- D(a(L), {
2841
+ U(a(L), {
2823
2842
  onClick: a(t).remove.close
2824
2843
  }, {
2825
2844
  default: y(() => [
2826
- U(O(a(w).tCurd("close")), 1)
2845
+ D(O(a(w).tCurd("close")), 1)
2827
2846
  ]),
2828
2847
  _: 1
2829
2848
  }, 8, ["onClick"]),
2830
- D(a(L), {
2849
+ U(a(L), {
2831
2850
  type: "danger",
2832
2851
  onClick: a(t).remove.submit,
2833
2852
  loading: a(t).remove.loading
2834
2853
  }, {
2835
2854
  default: y(() => [
2836
- U(O(a(w).tCurd("confirmDelete")), 1)
2855
+ D(O(a(w).tCurd("confirmDelete")), 1)
2837
2856
  ]),
2838
2857
  _: 1
2839
2858
  }, 8, ["onClick", "loading"])
@@ -2843,25 +2862,25 @@ const Vt = /* @__PURE__ */ X(kt, [["render", Ct]]), zt = {
2843
2862
  ])
2844
2863
  ]),
2845
2864
  default: y(() => [
2846
- n.option.dialog?.delete?.content ? (u(), b("div", Lt, [
2847
- D(Je, {
2848
- content: n.option.dialog?.delete?.content,
2865
+ i.option.dialog?.delete?.content ? (d(), b("div", jt, [
2866
+ U(qe, {
2867
+ content: i.option.dialog?.delete?.content,
2849
2868
  value: a(t).remove.items
2850
2869
  }, null, 8, ["content", "value"])
2851
- ])) : (u(), b("div", jt, O(a(w).tCurd("confirmDeleteMessage", a(t).remove.items.length)), 1))
2870
+ ])) : (d(), b("div", Bt, O(a(w).tCurd("confirmDeleteMessage", a(t).remove.items.length)), 1))
2852
2871
  ]),
2853
2872
  _: 1
2854
2873
  }, 8, ["modelValue", "title"]),
2855
- D(Ie, {
2874
+ U(He, {
2856
2875
  ref_key: "switchConfirmRef",
2857
2876
  ref: e,
2858
- size: n.option.size?.form
2877
+ size: i.option.size?.form
2859
2878
  }, null, 8, ["size"])
2860
2879
  ], 2);
2861
2880
  };
2862
2881
  }
2863
2882
  });
2864
- class Nt {
2883
+ class Wt {
2865
2884
  /**
2866
2885
  * 通过远程 URL 下载文件,自动创建临时 `<a>` 标签触发浏览器下载
2867
2886
  *
@@ -2869,8 +2888,8 @@ class Nt {
2869
2888
  * @param name - 下载后的文件名,默认 `'download.png'`
2870
2889
  */
2871
2890
  static async download(o, p = "download.png") {
2872
- const s = document.createElement("a");
2873
- s.style.display = "none", s.href = o, s.setAttribute("download", p), typeof s.download > "u" && s.setAttribute("target", "_blank"), document.body.appendChild(s), s.click(), document.body.removeChild(s), window.URL.revokeObjectURL(o);
2891
+ const n = document.createElement("a");
2892
+ n.style.display = "none", n.href = o, n.setAttribute("download", p), typeof n.download > "u" && n.setAttribute("target", "_blank"), document.body.appendChild(n), n.click(), document.body.removeChild(n), window.URL.revokeObjectURL(o);
2874
2893
  }
2875
2894
  /**
2876
2895
  * 将json对象或者json数组导出为json文件保存
@@ -2878,7 +2897,7 @@ class Nt {
2878
2897
  * @param name
2879
2898
  */
2880
2899
  static exportJSONFile = (o, p) => {
2881
- const s = new Blob([JSON.stringify(o)], { type: "application/json" }), l = URL.createObjectURL(s), t = document.createElement("a");
2900
+ const n = new Blob([JSON.stringify(o)], { type: "application/json" }), l = URL.createObjectURL(n), t = document.createElement("a");
2882
2901
  t.href = l, t.download = `${p || "config"}.json`, t.click();
2883
2902
  };
2884
2903
  /**
@@ -2886,46 +2905,46 @@ class Nt {
2886
2905
  * @param param
2887
2906
  * @returns
2888
2907
  */
2889
- static importFile = async (o) => new Promise((p, s) => {
2908
+ static importFile = async (o) => new Promise((p, n) => {
2890
2909
  const l = document.createElement("input");
2891
2910
  l.type = "file";
2892
2911
  const t = o?.accept || ".json";
2893
2912
  l.accept = t, l.style.display = "none", l.onchange = (e) => {
2894
2913
  const r = e.target.files[0];
2895
2914
  if (!r) {
2896
- M.fail("未选择文件"), s("未选择文件");
2915
+ M.fail("未选择文件"), n("未选择文件");
2897
2916
  return;
2898
2917
  }
2899
- const d = new FileReader();
2900
- d.onload = async (m) => {
2918
+ const s = new FileReader();
2919
+ s.onload = async (m) => {
2901
2920
  const c = t == ".json" ? JSON.parse(m.target.result) : m.target.result;
2902
2921
  p(c);
2903
- }, d.onerror = () => {
2904
- M.fail("文件读取失败"), s("文件读取失败");
2905
- }, d.readAsText(r), document.body.removeChild(l);
2922
+ }, s.onerror = () => {
2923
+ M.fail("文件读取失败"), n("文件读取失败");
2924
+ }, s.readAsText(r), document.body.removeChild(l);
2906
2925
  }, document.body.appendChild(l), l.click();
2907
2926
  });
2908
2927
  }
2909
- const It = (n, o) => {
2910
- if (n.component("TCurd", Rt), n.component("TFormList", se), n.component("TColumn", Le), o?.customComponent) {
2928
+ const Ht = (i, o) => {
2929
+ if (i.component("TCurd", It), i.component("TFormList", se), i.component("TColumn", je), o?.customComponent) {
2911
2930
  j.customComponent = o.customComponent;
2912
2931
  for (const p in o.customComponent)
2913
- n.component(p, o.customComponent[p]);
2932
+ i.component(p, o.customComponent[p]);
2914
2933
  }
2915
- }, Wt = {
2916
- install: It
2934
+ }, Jt = {
2935
+ install: Ht
2917
2936
  };
2918
2937
  export {
2919
2938
  P as ArrUtil,
2920
- je as ExcelUtil,
2921
- Le as TColumn,
2922
- Rt as TCurd,
2923
- Nt as TFile,
2939
+ Be as ExcelUtil,
2940
+ je as TColumn,
2941
+ It as TCurd,
2942
+ Wt as TFile,
2924
2943
  j as TForm,
2925
2944
  T as TFormConfig,
2926
2945
  w as TFormI18n,
2927
2946
  se as TFormList,
2928
2947
  M as TSys,
2929
- Wt as default,
2930
- It as install
2948
+ Jt as default,
2949
+ Ht as install
2931
2950
  };