cc1-form 1.2.2 → 1.2.3

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 K, ElFormItem as G, ElInput as Z, ElSwitch as X, ElSelect as W, ElOption as N, ElRadioGroup as re, ElRadio as se, ElTreeSelect as de, ElDatePicker as ae, ElDialog as ee, ElButton as A, ElTableColumn as te, ElDropdown as he, ElDropdownMenu as ge, ElDropdownItem as _, ElPagination as ie, ElTable as ye } from "element-plus";
1
+ import { ElMessage as ce, ElLoading as me, ElForm as K, ElFormItem as G, ElInput as Z, ElSwitch as X, ElSelect as W, ElOption as N, ElRadioGroup as re, ElRadio as se, ElTreeSelect as de, ElDatePicker as ae, ElDialog as ee, ElButton as M, ElTableColumn as te, ElDropdown as he, ElDropdownMenu as ge, ElDropdownItem as _, ElPagination as ie, ElTable as ye } from "element-plus";
2
2
  import "vue-router";
3
- import { defineComponent as J, reactive as le, onMounted as ue, resolveComponent as Y, createElementBlock as b, createCommentVNode as k, openBlock as f, renderSlot as C, createVNode as z, withCtx as m, createTextVNode as $, Fragment as S, renderList as T, createBlock as h, normalizeClass as j, normalizeStyle as fe, ref as H, unref as o, createElementVNode as F, mergeProps as v, toHandlers as D, resolveDynamicComponent as q, toDisplayString as O, getCurrentInstance as be, createSlots as oe, resolveDirective as we, withDirectives as ke, normalizeProps as Ce, guardReactiveProps as ve } from "vue";
3
+ import { defineComponent as J, reactive as le, onMounted as ue, resolveComponent as Y, createElementBlock as y, createCommentVNode as k, openBlock as u, renderSlot as C, createVNode as z, withCtx as m, createTextVNode as $, Fragment as S, renderList as A, createBlock as h, normalizeClass as j, normalizeStyle as fe, ref as H, unref as o, createElementVNode as F, mergeProps as v, toHandlers as D, resolveDynamicComponent as q, toDisplayString as O, getCurrentInstance as be, createSlots as oe, resolveDirective as we, withDirectives as ke, normalizeProps as Ce, guardReactiveProps as ve } from "vue";
4
4
  class U {
5
5
  /**
6
6
  * Vue Router 实例,需在应用初始化时赋值
@@ -26,13 +26,13 @@ class U {
26
26
  * @param data 数据
27
27
  * @returns 是否显示
28
28
  */
29
- static isFun = (a, ...u) => Array.isArray(a) ? a.some((t) => typeof t == "function" ? t(...u) : t) : typeof a == "function" ? a(...u) : a;
29
+ static isFun = (a, ...f) => Array.isArray(a) ? a.some((t) => typeof t == "function" ? t(...f) : t) : typeof a == "function" ? a(...f) : a;
30
30
  /**
31
31
  * 获取路由参数,自动获取query、params中的参数, 哪个有就返回哪个
32
32
  */
33
33
  static getRouterParams = () => {
34
- const a = this.router.currentRoute.value.query || {}, u = this.router.currentRoute.value.params || {};
35
- return Object.keys(a).length ? a : Object.keys(u).length ? u : {};
34
+ const a = this.router.currentRoute.value.query || {}, f = this.router.currentRoute.value.params || {};
35
+ return Object.keys(a).length ? a : Object.keys(f).length ? f : {};
36
36
  };
37
37
  /**
38
38
  * 模块赋值
@@ -45,8 +45,8 @@ class U {
45
45
  static loadModule = async (a) => {
46
46
  if (!U.moduleObj[a])
47
47
  throw new Error(`模块${a}未加载,请赋值如:TSys.moduleObj = { ${a}: ()=>import('${a}') }`);
48
- const u = await U.moduleObj[a]();
49
- return u.default ?? u;
48
+ const f = await U.moduleObj[a]();
49
+ return f.default ?? f;
50
50
  };
51
51
  /**
52
52
  * 提示信息对象管理
@@ -62,14 +62,14 @@ class U {
62
62
  * @param type 消息类型
63
63
  * @param options 其他选项
64
64
  */
65
- static showMessage(a, u, t = {}) {
65
+ static showMessage(a, f, t = {}) {
66
66
  const r = Date.now();
67
67
  if (!this.tipMessages[a] || r - this.tipMessages[a] > this.tipMessagesGap) {
68
68
  this.tipMessages[a] = r;
69
69
  const l = Object.assign(
70
70
  {
71
71
  message: a,
72
- type: u
72
+ type: f
73
73
  },
74
74
  t
75
75
  );
@@ -83,16 +83,16 @@ class U {
83
83
  * @param content
84
84
  * @param options
85
85
  */
86
- static fail = (a, u = {}) => {
87
- this.showMessage(a, "error", u);
86
+ static fail = (a, f = {}) => {
87
+ this.showMessage(a, "error", f);
88
88
  };
89
89
  /**
90
90
  * 成功提示
91
91
  * @param content
92
92
  * @param options
93
93
  */
94
- static success = (a, u = {}) => {
95
- this.showMessage(a, "success", u);
94
+ static success = (a, f = {}) => {
95
+ this.showMessage(a, "success", f);
96
96
  };
97
97
  static loadingObj = null;
98
98
  static loadingTimer = null;
@@ -101,11 +101,11 @@ class U {
101
101
  * @param show
102
102
  * @param text
103
103
  */
104
- static loading = (a = !0, u = "Loading...") => {
104
+ static loading = (a = !0, f = "Loading...") => {
105
105
  Timer.un(this.loadingTimer), this.loadingTimer = Timer.once(() => {
106
106
  a ? this.loadingObj = me.service({
107
107
  lock: !0,
108
- text: u,
108
+ text: f,
109
109
  background: "rgba(0, 0, 0, 0.3)"
110
110
  }) : this.loadingObj && (this.loadingObj.close(), this.loadingObj = null);
111
111
  }, 50);
@@ -115,8 +115,8 @@ class U {
115
115
  * @param url 地址
116
116
  * @param isCenter 是否居中
117
117
  */
118
- static openUrl = (a, u = !0) => {
119
- if (u) {
118
+ static openUrl = (a, f = !0) => {
119
+ if (f) {
120
120
  let t = screen.width / 2 - 500, r = screen.height / 2 - 800 / 2 - 30;
121
121
  window.open(
122
122
  a,
@@ -131,7 +131,7 @@ class U {
131
131
  * @param param
132
132
  * @returns
133
133
  */
134
- static getImgPic = (a) => new Promise(async (u, t) => {
134
+ static getImgPic = (a) => new Promise(async (f, t) => {
135
135
  let r = document.getElementById(a.id);
136
136
  const l = await U.loadModule("html2canvas");
137
137
  try {
@@ -147,7 +147,7 @@ class U {
147
147
  backgroundColor: "#ffffff00"
148
148
  }).then(function(e) {
149
149
  let s = e.toDataURL("image/png");
150
- u(s);
150
+ f(s);
151
151
  });
152
152
  } catch (e) {
153
153
  t(e);
@@ -459,6 +459,7 @@ class E {
459
459
  inactiveValue: !1,
460
460
  // inactiveText: TFormI18n.tCurd('switchOff'),
461
461
  tableConfig: {
462
+ change: !0,
462
463
  confirm: !0,
463
464
  loadList: !0
464
465
  }
@@ -528,8 +529,8 @@ class L {
528
529
  * @param field - 字段的 key 值
529
530
  * @returns 该字段对应类型的 options 配置,如 select 类型返回 `options.select`
530
531
  */
531
- static findOptions = (a, u) => {
532
- const t = a.column.find((l) => l.key === u), r = (l) => l.replace(/-([a-z])/g, (e, s) => s.toUpperCase());
532
+ static findOptions = (a, f) => {
533
+ const t = a.column.find((l) => l.key === f), r = (l) => l.replace(/-([a-z])/g, (e, s) => s.toUpperCase());
533
534
  if (t)
534
535
  return t.options[r(t.type)];
535
536
  };
@@ -549,8 +550,8 @@ class L {
549
550
  }))
550
551
  )
551
552
  */
552
- static setOptionsData = (a, u, t) => {
553
- const r = L.findOptions(a, u);
553
+ static setOptionsData = (a, f, t) => {
554
+ const r = L.findOptions(a, f);
554
555
  r && (r.data = t);
555
556
  };
556
557
  static form = {
@@ -562,9 +563,9 @@ class L {
562
563
  * @param treeData 树形数据
563
564
  * @param option 组件配置
564
565
  */
565
- parentId: (a, u, t, r) => {
566
+ parentId: (a, f, t, r) => {
566
567
  const l = E.config.table.rowKey;
567
- a ? u.type === U.EDialog.Add ? (u.form.parentId = a[l], u.form.sort = a.children.length + 1) : u.form.parentId = a.parentId.substring(a.parentId.lastIndexOf(",") + 1) : (u.form.parentId = "0", u.form.sort = t.length + 1), L.setOptionsData(r, "parentId", [{ [l]: "0", title: "根", children: t }]);
568
+ a ? f.type === U.EDialog.Add ? (f.form.parentId = a[l], f.form.sort = a.children.length + 1) : f.form.parentId = a.parentId.substring(a.parentId.lastIndexOf(",") + 1) : (f.form.parentId = "0", f.form.sort = t.length + 1), L.setOptionsData(r, "parentId", [{ [l]: "0", title: "根", children: t }]);
568
569
  }
569
570
  }
570
571
  };
@@ -602,21 +603,21 @@ const Ve = {
602
603
  confirmModify: "确认修改",
603
604
  confirmSwitchMessage: "确认要修改吗?"
604
605
  };
605
- class y {
606
+ class b {
606
607
  /** 解析国际化值:函数则执行并返回字符串,字符串则替换 `{key}` 占位符 */
607
- static t(a, ...u) {
608
+ static t(a, ...f) {
608
609
  if (typeof a == "function")
609
- return a(...u);
610
+ return a(...f);
610
611
  a = String(a);
611
612
  let t = 0;
612
- return a.replace(/{([^}]+)}/g, (r, l) => t < u.length ? String(u[t++]) : `{${l}}`);
613
+ return a.replace(/{([^}]+)}/g, (r, l) => t < f.length ? String(f[t++]) : `{${l}}`);
613
614
  }
614
615
  static setI18n = (a) => {
615
- y.curd = ObjectUtil.deepMerge(y.curd, a);
616
+ b.curd = ObjectUtil.deepMerge(b.curd, a);
616
617
  };
617
618
  /** 解析curd国际化值 */
618
- static tCurd(a, ...u) {
619
- return this.t(this.curd[a], ...u);
619
+ static tCurd(a, ...f) {
620
+ return this.t(this.curd[a], ...f);
620
621
  }
621
622
  /** curd表单 */
622
623
  static curd = Ve;
@@ -631,10 +632,10 @@ class P {
631
632
  * @param field 字段名
632
633
  * @param row 行数据
633
634
  */
634
- static setId = (a, u, t) => {
635
- u[a] || (u[a] = []);
635
+ static setId = (a, f, t) => {
636
+ f[a] || (f[a] = []);
636
637
  const r = E.config.table.rowKey;
637
- u[a].forEach((l) => {
638
+ f[a].forEach((l) => {
638
639
  t.forEach((e) => {
639
640
  let s = e.default ?? "";
640
641
  e.type === "number" && (s = e.default ?? 0), e.type === "boolean" && (s = e.default ?? !1), e.type === "time" && (s = e.default ?? /* @__PURE__ */ new Date()), l[e.value] === void 0 && (l[e.value] = s);
@@ -648,19 +649,19 @@ class P {
648
649
  * @param itemFields 元素字段-如:[{label:'',value:''}]
649
650
  * @param callback 回调函数
650
651
  */
651
- static add = (a, u, t, r) => {
652
+ static add = (a, f, t, r) => {
652
653
  const l = JSONUtil.cp(t);
653
- P.setId(a, u, t);
654
+ P.setId(a, f, t);
654
655
  const e = E.config.table.rowKey;
655
- u[a].push(
656
+ f[a].push(
656
657
  l.reduce(
657
- (s, p) => {
658
- let c = p.default ?? "";
659
- return p.type === "number" && (c = p.default ?? 0), p.type === "boolean" && (c = p.default ?? !1), p.type === "time" && (c = p.default ?? /* @__PURE__ */ new Date()), s[p.value] = c, s;
658
+ (s, c) => {
659
+ let p = c.default ?? "";
660
+ return c.type === "number" && (p = c.default ?? 0), c.type === "boolean" && (p = c.default ?? !1), c.type === "time" && (p = c.default ?? /* @__PURE__ */ new Date()), s[c.value] = p, s;
660
661
  },
661
662
  { [e]: P.getIdFun() }
662
663
  )
663
- ), r?.(u);
664
+ ), r?.(f);
664
665
  };
665
666
  /**
666
667
  * 删除数组元素
@@ -669,9 +670,9 @@ class P {
669
670
  * @param item 元素-如:{_id:''}
670
671
  * @param callback 回调函数
671
672
  */
672
- static remove = (a, u, t, r) => {
673
+ static remove = (a, f, t, r) => {
673
674
  const l = E.config.table.rowKey;
674
- u[a] = u[a].filter((e) => e[l] !== t[l]), r?.(u);
675
+ f[a] = f[a].filter((e) => e[l] !== t[l]), r?.(f);
675
676
  };
676
677
  /**
677
678
  * 获取没有id的数据
@@ -679,10 +680,10 @@ class P {
679
680
  * @param childernField 子级字段-如:list、children
680
681
  * @returns 没有id的数据
681
682
  */
682
- static getNoIdData = (a, u) => {
683
+ static getNoIdData = (a, f) => {
683
684
  const t = JSONUtil.cp(a), r = E.config.table.rowKey;
684
685
  return t.forEach((l) => {
685
- l[r] && delete l[r], u && l[u] && P.getNoIdData(l[u], u);
686
+ l[r] && delete l[r], f && l[f] && P.getNoIdData(l[f], f);
686
687
  }), t;
687
688
  };
688
689
  }
@@ -732,7 +733,7 @@ const ze = {
732
733
  },
733
734
  emits: ["change"],
734
735
  setup(i, { emit: a }) {
735
- const u = i, t = le({
736
+ const f = i, t = le({
736
737
  show: !1,
737
738
  add: (l, e, s) => {
738
739
  P.add(l, e, s, () => {
@@ -746,18 +747,18 @@ const ze = {
746
747
  }
747
748
  });
748
749
  ue(() => {
749
- P.setId(u.field, u.row, u.itemFields), t.show = !0;
750
+ P.setId(f.field, f.row, f.itemFields), t.show = !0;
750
751
  });
751
752
  const r = a;
752
753
  return (l, e) => {
753
- const s = Y("el-button"), p = Y("el-input");
754
- return t.show ? (f(), b("div", ze, [
754
+ const s = Y("el-button"), c = Y("el-input");
755
+ return t.show ? (u(), y("div", ze, [
755
756
  C(l.$slots, "list-start", { row: i.row }),
756
- i.addBottom ? k("", !0) : (f(), b("div", De, [
757
+ i.addBottom ? k("", !0) : (u(), y("div", De, [
757
758
  z(s, {
758
759
  link: "",
759
760
  type: "primary",
760
- onClick: e[0] || (e[0] = (c) => t.add(i.field, i.row, i.itemFields))
761
+ onClick: e[0] || (e[0] = (p) => t.add(i.field, i.row, i.itemFields))
761
762
  }, {
762
763
  default: m(() => e[3] || (e[3] = [
763
764
  $("添加")
@@ -765,27 +766,27 @@ const ze = {
765
766
  _: 1
766
767
  })
767
768
  ])),
768
- (f(!0), b(S, null, T(i.row[i.field], (c) => (f(), b("div", $e, [
769
+ (u(!0), y(S, null, A(i.row[i.field], (p) => (u(), y("div", $e, [
769
770
  C(l.$slots, "item-start", {
770
- item: c,
771
+ item: p,
771
772
  row: i.row
772
773
  }),
773
- (f(!0), b(S, null, T(i.itemFields, (g) => (f(), h(p, {
774
- modelValue: c[g.value],
775
- "onUpdate:modelValue": (n) => c[g.value] = n,
774
+ (u(!0), y(S, null, A(i.itemFields, (g) => (u(), h(c, {
775
+ modelValue: p[g.value],
776
+ "onUpdate:modelValue": (n) => p[g.value] = n,
776
777
  style: fe({ width: i.inputWidth }),
777
778
  class: j(i.inputClass),
778
779
  placeholder: g[i.label] || g[i.value],
779
780
  onChange: e[1] || (e[1] = (n) => r("change"))
780
781
  }, null, 8, ["modelValue", "onUpdate:modelValue", "style", "class", "placeholder"]))), 256)),
781
782
  C(l.$slots, "item-end", {
782
- item: c,
783
+ item: p,
783
784
  row: i.row
784
785
  }),
785
786
  z(s, {
786
787
  link: "",
787
788
  type: "danger",
788
- onClick: (g) => t.remove(i.field, i.row, c)
789
+ onClick: (g) => t.remove(i.field, i.row, p)
789
790
  }, {
790
791
  default: m(() => e[4] || (e[4] = [
791
792
  $("删除")
@@ -793,11 +794,11 @@ const ze = {
793
794
  _: 2
794
795
  }, 1032, ["onClick"])
795
796
  ]))), 256)),
796
- i.addBottom ? (f(), b("div", Se, [
797
+ i.addBottom ? (u(), y("div", Se, [
797
798
  z(s, {
798
799
  link: "",
799
800
  type: "primary",
800
- onClick: e[2] || (e[2] = (c) => t.add(i.field, i.row, i.itemFields))
801
+ onClick: e[2] || (e[2] = (p) => t.add(i.field, i.row, i.itemFields))
801
802
  }, {
802
803
  default: m(() => e[5] || (e[5] = [
803
804
  $("添加")
@@ -812,7 +813,7 @@ const ze = {
812
813
  }), Ue = {
813
814
  class: "row form-item-content",
814
815
  style: { width: "100%" }
815
- }, Oe = { class: "col" }, Ee = { class: "col" }, Fe = ["innerHTML"], Me = /* @__PURE__ */ J({
816
+ }, Oe = { class: "col" }, Ee = { class: "col" }, Fe = ["innerHTML"], Te = /* @__PURE__ */ J({
816
817
  __name: "column",
817
818
  props: {
818
819
  /**
@@ -829,7 +830,7 @@ const ze = {
829
830
  }
830
831
  },
831
832
  setup(i, { expose: a }) {
832
- const u = U.isFun, t = U.EDialog, r = H(), l = i, e = le({
833
+ const f = U.isFun, t = U.EDialog, r = H(), l = i, e = le({
833
834
  rules: {},
834
835
  show: !0,
835
836
  form: {},
@@ -839,9 +840,9 @@ const ze = {
839
840
  getDisabled: (s) => e.type === t.View ? s.disabled?.view === void 0 ? !0 : s.disabled?.view : s.disabled?.[e.type === t.Add ? "create" : "update"],
840
841
  getBind: (s) => s.options?.[e.type === t.Add ? "formAdd" : "formUpdate"]?.[s.type] || s.options?.[s.type] || {},
841
842
  getOn: (s) => s.options?.[e.type === t.Add ? "formAdd" : "formUpdate"]?.[s.type]?.on || s.options?.[s.type]?.on || {},
842
- getColumnSpan: (s, p) => {
843
+ getColumnSpan: (s, c) => {
843
844
  if (s.item.form?.spanCol) {
844
- const c = l.option.form?.maxSpan || 12, g = l.option.form?.defaultSpan || c / 2, d = p.filter((V) => !U.isFun(V.item.show?.form, e.form, e.type)).reduce((V, w) => V + (w.item.form?.span || g), 0);
845
+ const p = l.option.form?.maxSpan || 12, g = l.option.form?.defaultSpan || p / 2, d = c.filter((V) => !U.isFun(V.item.show?.form, e.form, e.type)).reduce((V, w) => V + (w.item.form?.span || g), 0);
845
846
  return (s.item.form?.span || g) + d;
846
847
  }
847
848
  return s.item.form?.span;
@@ -849,22 +850,22 @@ const ze = {
849
850
  initColumnForm: () => {
850
851
  const s = l.option;
851
852
  e.formColumn = [], e.rules = {}, e.formDefault = {};
852
- const p = [], c = l.option.form?.maxSpan || 12, g = l.option.form?.defaultSpan || c / 2;
853
+ const c = [], p = l.option.form?.maxSpan || 12, g = l.option.form?.defaultSpan || p / 2;
853
854
  let n = [];
854
855
  const d = (w) => {
855
856
  if (w.children) {
856
- w.children.forEach((M) => {
857
- d(M);
857
+ w.children.forEach((T) => {
858
+ d(T);
858
859
  });
859
860
  return;
860
861
  }
861
862
  if (e.formDefault[w.key] = w.value, w.isForm && (typeof w.show?.form != "boolean" || w.show?.form)) {
862
863
  w.form = w.form || { span: g }, w.form.span = w.form.span ?? g;
863
- const M = w.form.span, B = n.reduce((Q, x) => Q + x.span, M), I = n.length;
864
- if (n.push({ item: w, span: M }), (I === 1 && n[0].span === 0 || B >= c || M === 0 && I > 1) && (p.push(n), n = []), w.rules) {
864
+ const T = w.form.span, B = n.reduce((Q, x) => Q + x.span, T), I = n.length;
865
+ if (n.push({ item: w, span: T }), (I === 1 && n[0].span === 0 || B >= p || T === 0 && I > 1) && (c.push(n), n = []), w.rules) {
865
866
  const Q = {
866
- input: y.tCurd("placeholderInput"),
867
- select: y.tCurd("placeholderSelect")
867
+ input: b.tCurd("placeholderInput"),
868
+ select: b.tCurd("placeholderSelect")
868
869
  }, x = (Q[w.type] || Q.input) + w.label;
869
870
  e.rules[w.key] = typeof w.rules == "boolean" ? [
870
871
  {
@@ -875,30 +876,30 @@ const ze = {
875
876
  ] : w.rules;
876
877
  }
877
878
  }
878
- }, V = (w, M) => {
879
- w.isForm = M, Array.isArray(w.children) && w.children.forEach((B) => V(B, M));
879
+ }, V = (w, T) => {
880
+ w.isForm = T, Array.isArray(w.children) && w.children.forEach((B) => V(B, T));
880
881
  };
881
882
  s.column.forEach((w) => {
882
883
  V(w, !0), d(w);
883
- }), n.length > 0 && p.push(n), e.formColumn = p, e.form = JSONUtil.cp(e.formDefault);
884
+ }), n.length > 0 && c.push(n), e.formColumn = c, e.form = JSONUtil.cp(e.formDefault);
884
885
  }
885
886
  });
886
887
  return e.initColumnForm(), a({
887
888
  ref: r,
888
889
  conf: e
889
- }), (s, p) => (f(), h(o(K), {
890
+ }), (s, c) => (u(), h(o(K), {
890
891
  ref_key: "ruleFormRef",
891
892
  ref: r,
892
893
  model: e.form,
893
894
  rules: e.rules
894
895
  }, {
895
896
  default: m(() => [
896
- e.show ? (f(!0), b(S, { key: 0 }, T(e.formColumn, (c, g) => (f(), b(S, { key: g }, [
897
- o(u)(
898
- c.map((n) => n.item?.show?.form),
897
+ e.show ? (u(!0), y(S, { key: 0 }, A(e.formColumn, (p, g) => (u(), y(S, { key: g }, [
898
+ o(f)(
899
+ p.map((n) => n.item?.show?.form),
899
900
  e.form,
900
901
  e.type
901
- ) ? (f(), b("div", {
902
+ ) ? (u(), y("div", {
902
903
  key: 0,
903
904
  class: j(["row curd-row", {
904
905
  stripe: i.option.form?.stripe === void 0 ? !0 : i.option.form?.stripe
@@ -907,12 +908,12 @@ const ze = {
907
908
  C(s.$slots, "form-start", {
908
909
  row: e.form
909
910
  }),
910
- (f(!0), b(S, null, T(c, (n) => (f(), b(S, {
911
+ (u(!0), y(S, null, A(p, (n) => (u(), y(S, {
911
912
  key: n.item.key
912
913
  }, [
913
- o(u)(n.item.show?.form, e.form, e.type) ? (f(), b("div", {
914
+ o(f)(n.item.show?.form, e.form, e.type) ? (u(), y("div", {
914
915
  key: 0,
915
- class: j([n.item.form.span > 0 ? `col-${e.getColumnSpan(n, c)}` : "col", `form-item-col-${n.item.key}`])
916
+ class: j([n.item.form.span > 0 ? `col-${e.getColumnSpan(n, p)}` : "col", `form-item-col-${n.item.key}`])
916
917
  }, [
917
918
  z(o(G), {
918
919
  class: j({
@@ -934,21 +935,21 @@ const ze = {
934
935
  row: e.form,
935
936
  item: n.item
936
937
  }, () => [
937
- n.item.type === "input" ? (f(), h(o(Z), v({
938
+ n.item.type === "input" ? (u(), h(o(Z), v({
938
939
  key: 0,
939
940
  modelValue: e.form[n.item.key],
940
941
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
941
942
  ref_for: !0
942
943
  }, e.getBind(n.item), D(e.getOn(n.item)), {
943
944
  disabled: e.getDisabled(n.item)
944
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "switch" ? (f(), h(o(X), v({
945
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "switch" ? (u(), h(o(X), v({
945
946
  key: 1,
946
947
  modelValue: e.form[n.item.key],
947
948
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
948
949
  ref_for: !0
949
950
  }, e.getBind(n.item), D(e.getOn(n.item)), {
950
951
  disabled: e.getDisabled(n.item)
951
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "select" ? (f(), h(o(W), v({
952
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "select" ? (u(), h(o(W), v({
952
953
  key: 2,
953
954
  modelValue: e.form[n.item.key],
954
955
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
@@ -958,14 +959,14 @@ const ze = {
958
959
  style: { width: "100%" }
959
960
  }), {
960
961
  default: m(() => [
961
- (f(!0), b(S, null, T(n.item.options?.select?.data, (d) => (f(), h(o(N), {
962
+ (u(!0), y(S, null, A(n.item.options?.select?.data, (d) => (u(), h(o(N), {
962
963
  key: d.value,
963
964
  label: d.label,
964
965
  value: d.value
965
966
  }, null, 8, ["label", "value"]))), 128))
966
967
  ]),
967
968
  _: 2
968
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "radio" ? (f(), h(o(re), v({
969
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "radio" ? (u(), h(o(re), v({
969
970
  key: 3,
970
971
  modelValue: e.form[n.item.key],
971
972
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
@@ -975,14 +976,14 @@ const ze = {
975
976
  style: { width: "100%" }
976
977
  }), {
977
978
  default: m(() => [
978
- (f(!0), b(S, null, T(n.item.options?.radio?.data, (d) => (f(), h(o(se), {
979
+ (u(!0), y(S, null, A(n.item.options?.radio?.data, (d) => (u(), h(o(se), {
979
980
  key: d.value,
980
981
  label: d.label,
981
982
  value: d.value
982
983
  }, null, 8, ["label", "value"]))), 128))
983
984
  ]),
984
985
  _: 2
985
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "list" ? (f(), h(ne, v({
986
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "list" ? (u(), h(ne, v({
986
987
  key: 4,
987
988
  row: e.form,
988
989
  field: n.item.key,
@@ -990,7 +991,7 @@ const ze = {
990
991
  }, e.getBind(n.item), D(e.getOn(n.item)), {
991
992
  disabled: e.getDisabled(n.item),
992
993
  style: { width: "100%" }
993
- }), null, 16, ["row", "field", "disabled"])) : n.item.type === "treeSelect" ? (f(), h(o(de), v({
994
+ }), null, 16, ["row", "field", "disabled"])) : n.item.type === "treeSelect" ? (u(), h(o(de), v({
994
995
  key: 5,
995
996
  modelValue: e.form[n.item.key],
996
997
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
@@ -998,14 +999,14 @@ const ze = {
998
999
  }, e.getBind(n.item), D(e.getOn(n.item)), {
999
1000
  disabled: e.getDisabled(n.item),
1000
1001
  style: { width: "100%" }
1001
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "datetime" ? (f(), h(o(ae), v({
1002
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type === "datetime" ? (u(), h(o(ae), v({
1002
1003
  key: 6,
1003
1004
  modelValue: e.form[n.item.key],
1004
1005
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
1005
1006
  ref_for: !0
1006
1007
  }, e.getBind(n.item), D(e.getOn(n.item)), {
1007
1008
  disabled: e.getDisabled(n.item)
1008
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type && (o(L).customComponent[n.item.type] || o(L).customComponent[n.item.type]?.form) ? (f(), h(q(o(L).customComponent[n.item.type]?.form || o(L).customComponent[n.item.type]), v({
1009
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.item.type && (o(L).customComponent[n.item.type] || o(L).customComponent[n.item.type]?.form) ? (u(), h(q(o(L).customComponent[n.item.type]?.form || o(L).customComponent[n.item.type]), v({
1009
1010
  key: 7,
1010
1011
  modelValue: e.form[n.item.key],
1011
1012
  "onUpdate:modelValue": (d) => e.form[n.item.key] = d,
@@ -1023,7 +1024,7 @@ const ze = {
1023
1024
  row: e.form,
1024
1025
  item: n.item
1025
1026
  }, () => [
1026
- n.item.form?.tipText ? (f(), b("div", {
1027
+ n.item.form?.tipText ? (u(), y("div", {
1027
1028
  key: 0,
1028
1029
  class: "form-tip-text",
1029
1030
  innerHTML: typeof n.item.form?.tipText == "function" ? n.item.form?.tipText(e.form, e.type) : n.item.form?.tipText
@@ -1050,7 +1051,7 @@ const ze = {
1050
1051
  }, 8, ["model", "rules"]));
1051
1052
  }
1052
1053
  });
1053
- class Ae {
1054
+ class Me {
1054
1055
  /**
1055
1056
  * 导出数据为 Excel 文件(.xlsx),自动触发浏览器下载
1056
1057
  *
@@ -1058,19 +1059,19 @@ class Ae {
1058
1059
  * @param columns - 列配置数组,需包含 `key`(数据字段)和 `label`(Excel 表头)
1059
1060
  * @param fileName - 文件名(不含扩展名),支持字符串或返回字符串的函数;默认生成「导出数据_日期_时间戳」
1060
1061
  */
1061
- static exportToExcel = async (a, u, t) => {
1062
+ static exportToExcel = async (a, f, t) => {
1062
1063
  if (!a || a.length === 0) return;
1063
- const r = await U.loadModule("xlsx"), l = a.map((p) => {
1064
- const c = {};
1065
- return u.forEach((g) => {
1066
- c[g.label] = p[g.key];
1067
- }), c;
1064
+ const r = await U.loadModule("xlsx"), l = a.map((c) => {
1065
+ const p = {};
1066
+ return f.forEach((g) => {
1067
+ p[g.label] = c[g.key];
1068
+ }), p;
1068
1069
  }), e = r.utils.json_to_sheet(l), s = r.utils.book_new();
1069
1070
  r.utils.book_append_sheet(s, e, "Sheet1"), t ? typeof t == "function" && (t = t()) : t = `导出数据_${(/* @__PURE__ */ new Date()).Format("yyyy-MM-dd")}_${(/* @__PURE__ */ new Date()).getTime()}`, r.writeFile(s, `${t}.xlsx`);
1070
1071
  };
1071
1072
  }
1072
- const R = U.EDialog, Te = (i) => {
1073
- const a = H(), u = H(), t = le({
1073
+ const R = U.EDialog, Ae = (i) => {
1074
+ const a = H(), f = H(), t = le({
1074
1075
  option: i.option,
1075
1076
  /** 查询区域相关配置对象 */
1076
1077
  search: {
@@ -1084,7 +1085,7 @@ const R = U.EDialog, Te = (i) => {
1084
1085
  /** 搜索表单默认值 */
1085
1086
  formDefault: {},
1086
1087
  /** 获取占位符 */
1087
- getPlaceholder: (r, l = y.tCurd("placeholderInput")) => r.text?.search?.placeholder === void 0 ? `${l}${r.label}` : r.text?.search?.placeholder,
1088
+ getPlaceholder: (r, l = b.tCurd("placeholderInput")) => r.text?.search?.placeholder === void 0 ? `${l}${r.label}` : r.text?.search?.placeholder,
1088
1089
  /** 组装实际要搜索的数据对象 */
1089
1090
  getFormData: () => {
1090
1091
  let r = {};
@@ -1194,13 +1195,13 @@ const R = U.EDialog, Te = (i) => {
1194
1195
  const e = await r({
1195
1196
  ...t.page.getQuery(),
1196
1197
  ...l
1197
- }), s = E.config.field.result, p = e.data || { [s.list]: e };
1198
- let c = (Array.isArray(p[s.list]), p[s.list]);
1199
- const g = t.update.formColumn.flat(), n = JSONUtil.cp(c).map((d) => (Object.keys(d).forEach((w) => {
1200
- const M = g.find((B) => B.item.key === w);
1201
- M && ["select", "radio"].includes(M.item.type) && (M.item.table.format || (M.item.table.format = (B) => M.item.options[M.item.type].data?.find((I) => I.value == B[w])?.label || B[w]));
1198
+ }), s = E.config.field.result, c = e.data || { [s.list]: e };
1199
+ let p = (Array.isArray(c[s.list]), c[s.list]);
1200
+ const g = t.update.formColumn.flat(), n = JSONUtil.cp(p).map((d) => (Object.keys(d).forEach((w) => {
1201
+ const T = g.find((B) => B.item.key === w);
1202
+ T && ["select", "radio"].includes(T.item.type) && (T.item.table.format || (T.item.table.format = (B) => T.item.options[T.item.type].data?.find((I) => I.value == B[w])?.label || B[w]));
1202
1203
  }), d));
1203
- t.table.data = i.option.data ? await i.option.data(n, c) : n, t.page.total = p[s.total] || 0;
1204
+ t.table.data = i.option.data ? await i.option.data(n, p) : n, t.page.total = c[s.total] || 0;
1204
1205
  } catch (l) {
1205
1206
  console.error(l);
1206
1207
  } finally {
@@ -1244,8 +1245,8 @@ const R = U.EDialog, Te = (i) => {
1244
1245
  const s = JSONUtil.cp({
1245
1246
  data: l,
1246
1247
  columns: e
1247
- }), p = i.option.tools?.export || {};
1248
- p.before && p.before(s), Ae.exportToExcel(s.data, s.columns, p.fileName);
1248
+ }), c = i.option.tools?.export || {};
1249
+ c.before && c.before(s), Me.exportToExcel(s.data, s.columns, c.fileName);
1249
1250
  },
1250
1251
  /** 获取当前选中项进行导出 */
1251
1252
  select: async () => {
@@ -1259,7 +1260,7 @@ const R = U.EDialog, Te = (i) => {
1259
1260
  return;
1260
1261
  }
1261
1262
  if (t.table.selection.list.length === 0)
1262
- throw U.fail(y.tCurd("selectDataToExport")), new Error(y.tCurd("selectDataToExport"));
1263
+ throw U.fail(b.tCurd("selectDataToExport")), new Error(b.tCurd("selectDataToExport"));
1263
1264
  return t.table.selection.list;
1264
1265
  } catch (r) {
1265
1266
  console.error(r);
@@ -1278,7 +1279,7 @@ const R = U.EDialog, Te = (i) => {
1278
1279
  return;
1279
1280
  }
1280
1281
  if (t.table.data.length === 0)
1281
- throw U.fail(y.tCurd("noData")), new Error(y.tCurd("noData"));
1282
+ throw U.fail(b.tCurd("noData")), new Error(b.tCurd("noData"));
1282
1283
  return t.table.data;
1283
1284
  } catch (r) {
1284
1285
  console.error(r);
@@ -1380,7 +1381,7 @@ const R = U.EDialog, Te = (i) => {
1380
1381
  try {
1381
1382
  t.update.type = r, await t.initApiData("update");
1382
1383
  const e = r === R.Add;
1383
- t.update.edit.data = l, t.update.title = y.tCurd(e ? "add" : r === R.View ? "view" : "edit"), t.update.form = JSONUtil.cp(e ? t.update.formDefault : l), await i.option.form?.openBefore?.(t.update.form, t.update), (!i.option.table?.inlineEdit || e) && (t.update.show = !0, t.update.showContent = !0), i.option.form?.openAfter?.(t.update.form, t.update);
1384
+ t.update.edit.data = l, t.update.title = b.tCurd(e ? "add" : r === R.View ? "view" : "edit"), t.update.form = JSONUtil.cp(e ? t.update.formDefault : l), await i.option.form?.openBefore?.(t.update.form, t.update), (!i.option.table?.inlineEdit || e) && (t.update.show = !0, t.update.showContent = !0), i.option.form?.openAfter?.(t.update.form, t.update);
1384
1385
  } catch (e) {
1385
1386
  console.error(e);
1386
1387
  } finally {
@@ -1391,8 +1392,8 @@ const R = U.EDialog, Te = (i) => {
1391
1392
  /** 提交增改表单操作 */
1392
1393
  submit: () => {
1393
1394
  FunUtil.throttle(async () => {
1394
- await u.value?.validate(async (s, p) => new Promise((c, g) => {
1395
- s || (U.fail(y.tCurd("checkFormData")), g(!1)), c();
1395
+ await f.value?.validate(async (s, c) => new Promise((p, g) => {
1396
+ s || (U.fail(b.tCurd("checkFormData")), g(!1)), p();
1396
1397
  })), t.update.loading = !0;
1397
1398
  const r = t.update.type === R.Add ? i.option.api.create : i.option.api.update;
1398
1399
  try {
@@ -1406,8 +1407,8 @@ const R = U.EDialog, Te = (i) => {
1406
1407
  const e = new Set(i.option.column.filter((s) => s.type === "datetime").map((s) => s.key));
1407
1408
  Object.keys(l).forEach((s) => {
1408
1409
  if (e.has(s) && l[s] != null) {
1409
- const p = new Date(l[s]).getTime();
1410
- isNaN(p) || (l[s] = p);
1410
+ const c = new Date(l[s]).getTime();
1411
+ isNaN(c) || (l[s] = c);
1411
1412
  }
1412
1413
  });
1413
1414
  try {
@@ -1432,7 +1433,7 @@ const R = U.EDialog, Te = (i) => {
1432
1433
  /** 删除操作弹窗与数据对象 */
1433
1434
  remove: {
1434
1435
  /** 删除弹窗标题 */
1435
- title: y.tCurd("confirmDelete"),
1436
+ title: b.tCurd("confirmDelete"),
1436
1437
  /** 删除弹窗显示控制 */
1437
1438
  show: !1,
1438
1439
  /** 待删除数据项集合 */
@@ -1446,7 +1447,7 @@ const R = U.EDialog, Te = (i) => {
1446
1447
  /** 打开删除弹窗并设置待删除项 */
1447
1448
  open: (r) => {
1448
1449
  if (r.length === 0) {
1449
- U.fail(y.tCurd("selectDataToDelete"));
1450
+ U.fail(b.tCurd("selectDataToDelete"));
1450
1451
  return;
1451
1452
  }
1452
1453
  t.remove.items = r, t.remove.show = !0;
@@ -1461,7 +1462,7 @@ const R = U.EDialog, Te = (i) => {
1461
1462
  await r({
1462
1463
  [i.option.table?.rowKey]: t.remove.items.map((l) => l[i.option.table?.rowKey]),
1463
1464
  items: t.remove.items
1464
- }), U.success(y.tCurd("operationSuccess")), t.table.data.length <= 1 && t.page.num > 1 && (t.page.num -= 1), t.remove.close(), await t.table.getList();
1465
+ }), U.success(b.tCurd("operationSuccess")), t.table.data.length <= 1 && t.page.num > 1 && (t.page.num -= 1), t.remove.close(), await t.table.getList();
1465
1466
  } catch (l) {
1466
1467
  console.error(l);
1467
1468
  } finally {
@@ -1480,22 +1481,22 @@ const R = U.EDialog, Te = (i) => {
1480
1481
  initApiData: async (r) => {
1481
1482
  const l = [], e = (s) => {
1482
1483
  if (s.children && s.children.length) {
1483
- s.children.forEach((p) => e(p));
1484
+ s.children.forEach((c) => e(c));
1484
1485
  return;
1485
1486
  }
1486
1487
  if (s.options?.[s.type]?.dataApi && s.options?.[s.type]?.dataApiConfig?.[r]) {
1487
1488
  if (t.apiDataMap[s.key] && s.options?.[s.type]?.dataApiConfig?.once) return;
1488
- const p = (async () => {
1489
+ const c = (async () => {
1489
1490
  try {
1490
- let c = await s.options?.[s.type]?.dataApi?.(t.update.form, r);
1491
- if (c) {
1491
+ let p = await s.options?.[s.type]?.dataApi?.(t.update.form, r);
1492
+ if (p) {
1492
1493
  const g = s.options?.[s.type]?.dataPath;
1493
- !Array.isArray(c) && g && (c = ObjectUtil.getPathValue(c, g)), s.options[s.type].data = c, s.options.search[s.type].data = c, s.options.formAdd[s.type].data = c, s.options.formUpdate[s.type].data = c, t.apiDataMap[s.key] = c;
1494
+ !Array.isArray(p) && g && (p = ObjectUtil.getPathValue(p, g)), s.options[s.type].data = p, s.options.search[s.type].data = p, s.options.formAdd[s.type].data = p, s.options.formUpdate[s.type].data = p, t.apiDataMap[s.key] = p;
1494
1495
  }
1495
1496
  } catch {
1496
1497
  }
1497
1498
  })();
1498
- l.push(p);
1499
+ l.push(c);
1499
1500
  }
1500
1501
  };
1501
1502
  return i.option.column.forEach((s) => {
@@ -1505,7 +1506,7 @@ const R = U.EDialog, Te = (i) => {
1505
1506
  /** 初始化curd配置(option默认值合并等) */
1506
1507
  initCurdConfig: () => {
1507
1508
  const r = JSONUtil.cp(E.config);
1508
- r.table.emptyText = y.tCurd("noData"), i.option.size = i.option.size || {}, r.table.size = i.option.size.table || r.size.table, r.form.size = i.option.size.form || r.size.form, r.size.search = i.option.size.search || r.size.search;
1509
+ r.table.emptyText = b.tCurd("noData"), i.option.size = i.option.size || {}, r.table.size = i.option.size.table || r.size.table, r.form.size = i.option.size.form || r.size.form, r.size.search = i.option.size.search || r.size.search;
1509
1510
  const l = ObjectUtil.deepMerge(r, i.option || {});
1510
1511
  Object.keys(l).forEach((e) => {
1511
1512
  i.option[e] = l[e];
@@ -1521,8 +1522,8 @@ const R = U.EDialog, Te = (i) => {
1521
1522
  r.options = ObjectUtil.deepMerge(
1522
1523
  {
1523
1524
  switch: {
1524
- activeText: y.tCurd("switchOn"),
1525
- inactiveText: y.tCurd("switchOff")
1525
+ activeText: b.tCurd("switchOn"),
1526
+ inactiveText: b.tCurd("switchOff")
1526
1527
  }
1527
1528
  },
1528
1529
  r.options
@@ -1531,35 +1532,39 @@ const R = U.EDialog, Te = (i) => {
1531
1532
  for (const s in r) {
1532
1533
  if (s === "table") {
1533
1534
  if (e.table = ObjectUtil.deepMerge(r.table, e.table || {}), e.children) {
1534
- e.children.forEach((c) => {
1535
- l(c);
1535
+ e.children.forEach((p) => {
1536
+ l(p);
1536
1537
  });
1537
1538
  return;
1538
1539
  }
1539
1540
  } else s === "type" ? e.type = e.type || r.type : e[s] = ObjectUtil.deepMerge(r[s], e[s] || {});
1540
- e.options = e.options || {}, e.options[e.type] = e.options[e.type] || {}, e.options[e.type].size = i.option.size.form, ["search", "formAdd", "formUpdate"].forEach((c) => {
1541
- e.options[c] = e.options[c] || JSONUtil.cp(e.options), e.options[c][e.type] = e.options[c][e.type] || {}, e.options[c][e.type].size = c === "search" ? i.option.size.search : i.option.size.form;
1541
+ e.options = e.options || {}, e.options[e.type] = e.options[e.type] || {}, e.options[e.type].size = i.option.size.form, ["search", "formAdd", "formUpdate"].forEach((p) => {
1542
+ e.options[p] = e.options[p] || JSONUtil.cp(e.options), e.options[p][e.type] = e.options[p][e.type] || {}, e.options[p][e.type].size = p === "search" ? i.option.size.search : i.option.size.form;
1542
1543
  }), e.table = ObjectUtil.deepMerge(e.table, e.options[e.type].table || {});
1543
1544
  }
1544
- e.type === "switch" && (e.options.switch.tableBeforeChange = async (s, p) => {
1545
- const c = e.options?.switch;
1545
+ e.type === "switch" && (e.options.switch.tableBeforeChange = async (s, c) => {
1546
+ const p = e.options?.switch;
1546
1547
  try {
1547
- c.tableConfig?.confirm && await a.value?.open({
1548
- title: y.tCurd("confirmModify"),
1549
- content: y.tCurd("confirmSwitchMessage")
1548
+ p.tableConfig?.confirm && await a.value?.open({
1549
+ title: b.tCurd("confirmModify"),
1550
+ content: b.tCurd("confirmSwitchMessage")
1550
1551
  });
1551
1552
  try {
1552
1553
  if (!i.option.api.update) return;
1553
- const g = p[i.option.table?.rowKey];
1554
- c.loadingMap || (c.loadingMap = {}), c.loadingMap[g] || (c.loadingMap[g] = { loading: !1 }), c.loadingMap[g].loading = !0;
1555
- const n = p[s] === c.activeValue ? c.inactiveValue : c.activeValue;
1556
- return await i.option.api.update({
1557
- ...p,
1558
- [s]: n,
1559
- final(d, V, w) {
1560
- c.loadingMap[g].loading = !1;
1561
- }
1562
- }), U.success(y.tCurd("operationSuccess")), c.tableConfig?.loadList && (t.table.loading = !0, t.table.getList(), t.table.loading = !1), !0;
1554
+ const g = c[i.option.table?.rowKey];
1555
+ p.loadingMap || (p.loadingMap = {}), p.loadingMap[g] || (p.loadingMap[g] = { loading: !1 }), p.loadingMap[g].loading = !0;
1556
+ const n = c[s] === p.activeValue ? p.inactiveValue : p.activeValue, d = p.tableConfig?.api ? p.tableConfig.api : i.option.api.update;
1557
+ try {
1558
+ await d({
1559
+ ...c,
1560
+ [s]: n
1561
+ });
1562
+ } catch {
1563
+ return !1;
1564
+ } finally {
1565
+ p.loadingMap[g].loading = !1;
1566
+ }
1567
+ return U.success(b.tCurd("operationSuccess")), p.tableConfig?.loadList && (t.table.loading = !0, t.table.getList(), t.table.loading = !1), !0;
1563
1568
  } catch (g) {
1564
1569
  return console.error(g), !1;
1565
1570
  } finally {
@@ -1574,8 +1579,8 @@ const R = U.EDialog, Te = (i) => {
1574
1579
  },
1575
1580
  getColumnSpan: (r, l) => {
1576
1581
  if (r.item.form?.spanCol) {
1577
- const e = E.config.form.defaultSpan, p = l.filter((c) => !U.isFun(c.item.show?.form, t.update.form, t.update.type)).reduce((c, g) => c + (g.item.form?.span || e), 0);
1578
- return (r.item?.form.span || e) + p;
1582
+ const e = E.config.form.defaultSpan, c = l.filter((p) => !U.isFun(p.item.show?.form, t.update.form, t.update.type)).reduce((p, g) => p + (g.item.form?.span || e), 0);
1583
+ return (r.item?.form.span || e) + c;
1579
1584
  }
1580
1585
  return r.item.form.span;
1581
1586
  },
@@ -1587,22 +1592,22 @@ const R = U.EDialog, Te = (i) => {
1587
1592
  listSource: []
1588
1593
  };
1589
1594
  const l = [], e = i.option.form?.maxSpan || 12, s = i.option.form?.defaultSpan || e / 2;
1590
- let p = [];
1591
- const c = (d) => {
1595
+ let c = [];
1596
+ const p = (d) => {
1592
1597
  if (d.children) {
1593
1598
  t.table.column.show.list.push(d.key), d.children.forEach((V) => {
1594
- c(V);
1599
+ p(V);
1595
1600
  });
1596
1601
  return;
1597
1602
  }
1598
1603
  if (t.update.formDefault[d.key] = d.value, d.table.table && (d.show.table && t.table.column.show.list.push(d.key), d.table.table && t.table.column.show.listSource.push(d.key)), !(d.isForm && typeof d.show?.form == "boolean") || d.show?.form) {
1599
1604
  d.form = d.form || { span: s }, d.form.span = d.form.span ?? s;
1600
- let V = d.form.span, w = p.reduce((B, I) => B + I.span, V);
1601
- const M = p.length;
1602
- if (p.push({ item: d, span: V }), (M === 1 && p[0].span === 0 || w >= e || V === 0 && M > 1) && (l.push(p), p = []), d.rules) {
1605
+ let V = d.form.span, w = c.reduce((B, I) => B + I.span, V);
1606
+ const T = c.length;
1607
+ if (c.push({ item: d, span: V }), (T === 1 && c[0].span === 0 || w >= e || V === 0 && T > 1) && (l.push(c), c = []), d.rules) {
1603
1608
  const B = {
1604
- input: y.tCurd("placeholderInput"),
1605
- select: y.tCurd("placeholderSelect")
1609
+ input: b.tCurd("placeholderInput"),
1610
+ select: b.tCurd("placeholderSelect")
1606
1611
  }, I = (B[d.type] || B.input) + d.label;
1607
1612
  t.update.rules[d.key] = typeof d.rules == "boolean" ? [
1608
1613
  {
@@ -1617,10 +1622,10 @@ const R = U.EDialog, Te = (i) => {
1617
1622
  d.isForm = V, Array.isArray(d.children) && d.children.forEach((w) => g(w, V));
1618
1623
  };
1619
1624
  r.column.forEach((d) => {
1620
- d.isForm = !0, g(d, !0), c(d);
1625
+ d.isForm = !0, g(d, !0), p(d);
1621
1626
  }), i.option.table?.column?.forEach((d) => {
1622
- g(d, !1), c(d);
1623
- }), t.search.column.list = r.column.concat(r.table?.column || []), t.table.column.list = t.search.column.list.filter((d) => d.table?.table), t.search.column.list.sort((d, V) => d.sort?.search - V.sort?.search), t.table.column.list.sort((d, V) => d.sort?.table - V.sort?.table), p.length > 0 && l.push(p), t.update.formColumn = l;
1627
+ g(d, !1), p(d);
1628
+ }), t.search.column.list = r.column.concat(r.table?.column || []), t.table.column.list = t.search.column.list.filter((d) => d.table?.table), t.search.column.list.sort((d, V) => d.sort?.search - V.sort?.search), t.table.column.list.sort((d, V) => d.sort?.table - V.sort?.table), c.length > 0 && l.push(c), t.update.formColumn = l;
1624
1629
  const n = i.option.search?.formDefault;
1625
1630
  n && Object.keys(n).forEach((d) => {
1626
1631
  t.search.formDefault[d] = n[d];
@@ -1631,29 +1636,29 @@ const R = U.EDialog, Te = (i) => {
1631
1636
  });
1632
1637
  return t.init(), ue(() => {
1633
1638
  i.option.init !== !1 && t.table.getList();
1634
- }), { conf: t, switchConfirmRef: a, ruleFormRef: u };
1639
+ }), { conf: t, switchConfirmRef: a, ruleFormRef: f };
1635
1640
  }, Le = { class: "dialog-footer" }, Be = /* @__PURE__ */ J({
1636
1641
  __name: "switchConfirm",
1637
1642
  props: {
1638
1643
  size: {}
1639
1644
  },
1640
1645
  setup(i, { expose: a }) {
1641
- const u = H(!1), t = H("确认修改"), r = H("确认要修改状态吗?");
1646
+ const f = H(!1), t = H("确认修改"), r = H("确认要修改状态吗?");
1642
1647
  let l = null, e = null;
1643
- const s = (g) => (g?.title && (t.value = g.title), g?.content && (r.value = g.content), u.value = !0, new Promise((n, d) => {
1648
+ const s = (g) => (g?.title && (t.value = g.title), g?.content && (r.value = g.content), f.value = !0, new Promise((n, d) => {
1644
1649
  l = n, e = d;
1645
- })), p = () => {
1646
- u.value = !1, l?.(!0), l = null, e = null;
1647
- }, c = () => {
1648
- u.value = !1, e?.(new Error("用户取消操作")), l = null, e = null;
1650
+ })), c = () => {
1651
+ f.value = !1, l?.(!0), l = null, e = null;
1652
+ }, p = () => {
1653
+ f.value = !1, e?.(new Error("用户取消操作")), l = null, e = null;
1649
1654
  };
1650
1655
  return a({
1651
1656
  open: s
1652
1657
  }), (g, n) => {
1653
1658
  const d = Y("el-form");
1654
- return f(), h(o(ee), {
1655
- modelValue: u.value,
1656
- "onUpdate:modelValue": n[0] || (n[0] = (V) => u.value = V),
1659
+ return u(), h(o(ee), {
1660
+ modelValue: f.value,
1661
+ "onUpdate:modelValue": n[0] || (n[0] = (V) => f.value = V),
1657
1662
  title: t.value,
1658
1663
  "close-on-click-modal": !1,
1659
1664
  width: "400px"
@@ -1662,15 +1667,15 @@ const R = U.EDialog, Te = (i) => {
1662
1667
  z(d, { size: g.size }, {
1663
1668
  default: m(() => [
1664
1669
  F("span", Le, [
1665
- z(o(A), { onClick: c }, {
1670
+ z(o(M), { onClick: p }, {
1666
1671
  default: m(() => n[1] || (n[1] = [
1667
1672
  $("取消")
1668
1673
  ])),
1669
1674
  _: 1
1670
1675
  }),
1671
- z(o(A), {
1676
+ z(o(M), {
1672
1677
  type: "primary",
1673
- onClick: p
1678
+ onClick: c
1674
1679
  }, {
1675
1680
  default: m(() => n[2] || (n[2] = [
1676
1681
  $("确认")
@@ -1690,16 +1695,16 @@ const R = U.EDialog, Te = (i) => {
1690
1695
  };
1691
1696
  }
1692
1697
  }), pe = (i, a) => {
1693
- const u = i.__vccOpts || i;
1698
+ const f = i.__vccOpts || i;
1694
1699
  for (const [t, r] of a)
1695
- u[t] = r;
1696
- return u;
1700
+ f[t] = r;
1701
+ return f;
1697
1702
  }, je = {}, Ie = {
1698
1703
  xmlns: "http://www.w3.org/2000/svg",
1699
1704
  viewBox: "0 0 1024 1024"
1700
1705
  };
1701
1706
  function Re(i, a) {
1702
- return f(), b("svg", Ie, a[0] || (a[0] = [
1707
+ return u(), y("svg", Ie, a[0] || (a[0] = [
1703
1708
  F("path", {
1704
1709
  fill: "currentColor",
1705
1710
  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"
@@ -1712,14 +1717,14 @@ const Pe = /* @__PURE__ */ pe(je, [["render", Re]]), Ke = {}, Ne = {
1712
1717
  viewBox: "0 0 1024 1024"
1713
1718
  };
1714
1719
  function He(i, a) {
1715
- return f(), b("svg", Ne, a[0] || (a[0] = [
1720
+ return u(), y("svg", Ne, a[0] || (a[0] = [
1716
1721
  F("path", {
1717
1722
  fill: "currentColor",
1718
1723
  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"
1719
1724
  }, null, -1)
1720
1725
  ]));
1721
1726
  }
1722
- const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-center table-header-label inline" }, qe = { class: "table-header-tooltip" }, Qe = ["onClick", "innerHTML"], Ge = /* @__PURE__ */ J({
1727
+ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-center table-header-label inline" }, qe = { class: "table-header-tooltip" }, Qe = { key: 1 }, Ge = ["onClick", "innerHTML"], Xe = /* @__PURE__ */ J({
1723
1728
  __name: "tableColumn",
1724
1729
  props: {
1725
1730
  conf: {},
@@ -1727,13 +1732,13 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1727
1732
  option: {}
1728
1733
  },
1729
1734
  setup(i) {
1730
- const a = U.isFun, u = be().type;
1735
+ const a = U.isFun, f = be().type;
1731
1736
  return (t, r) => {
1732
1737
  const l = Y("el-tooltip");
1733
- return f(!0), b(S, null, T(t.columnList, (e) => (f(), b(S, {
1738
+ return u(!0), y(S, null, A(t.columnList, (e) => (u(), y(S, {
1734
1739
  key: e.key
1735
1740
  }, [
1736
- t.conf.table.column.show.list.includes(e.key) ? (f(), h(o(te), v({
1741
+ t.conf.table.column.show.list.includes(e.key) ? (u(), h(o(te), v({
1737
1742
  key: 0,
1738
1743
  prop: e.key,
1739
1744
  label: e.label,
@@ -1742,7 +1747,7 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1742
1747
  header: m(() => [
1743
1748
  C(t.$slots, "table-header-" + e.key, { item: e }, () => [
1744
1749
  F("div", We, [
1745
- e.table?.tooltip ? (f(), h(l, {
1750
+ e.table?.tooltip ? (u(), h(l, {
1746
1751
  key: 0,
1747
1752
  effect: "dark",
1748
1753
  content: e.table?.tooltip,
@@ -1760,47 +1765,47 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1760
1765
  ])
1761
1766
  ]),
1762
1767
  default: m(({ row: s }) => [
1763
- e.children ? (f(), b(S, { key: 0 }, [
1768
+ e.children ? (u(), y(S, { key: 0 }, [
1764
1769
  r[0] || (r[0] = $("   ")),
1765
- (f(), h(q(o(u)), {
1770
+ (u(), h(q(o(f)), {
1766
1771
  conf: t.conf,
1767
1772
  columnList: e.children,
1768
1773
  option: t.option
1769
1774
  }, oe({ _: 2 }, [
1770
- T(t.$slots, (p, c) => ({
1771
- name: c,
1775
+ A(t.$slots, (c, p) => ({
1776
+ name: p,
1772
1777
  fn: m((g) => [
1773
- C(t.$slots, c, v({ ref_for: !0 }, g || {}))
1778
+ C(t.$slots, p, v({ ref_for: !0 }, g || {}))
1774
1779
  ])
1775
1780
  }))
1776
1781
  ]), 1032, ["conf", "columnList", "option"]))
1777
- ], 64)) : (f(), b(S, { key: 1 }, [
1778
- t.conf.update.type === o(U).EDialog.Update && o(a)(e.show?.form, t.conf.update.form, o(U).EDialog.Update) && t.option.table?.inlineEdit && t.conf.update.form[t.option.table?.rowKey] === s[t.option.table?.rowKey] && (e.type === "input" || e.type === "select") ? (f(), b(S, { key: 0 }, [
1779
- e.type === "input" ? (f(), h(o(Z), v({
1782
+ ], 64)) : (u(), y(S, { key: 1 }, [
1783
+ t.conf.update.type === o(U).EDialog.Update && o(a)(e.show?.form, t.conf.update.form, o(U).EDialog.Update) && t.option.table?.inlineEdit && t.conf.update.form[t.option.table?.rowKey] === s[t.option.table?.rowKey] && (e.type === "input" || e.type === "select") ? (u(), y(S, { key: 0 }, [
1784
+ e.type === "input" ? (u(), h(o(Z), v({
1780
1785
  key: 0,
1781
1786
  modelValue: t.conf.update.form[e.key],
1782
- "onUpdate:modelValue": (p) => t.conf.update.form[e.key] = p,
1787
+ "onUpdate:modelValue": (c) => t.conf.update.form[e.key] = c,
1783
1788
  disabled: t.conf.update.getDisabled(e),
1784
1789
  ref_for: !0
1785
- }, t.conf.update.getBind(e), D(t.conf.update.getOn(e)), { style: { width: "100%" } }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "select" ? (f(), h(o(W), v({
1790
+ }, t.conf.update.getBind(e), D(t.conf.update.getOn(e)), { style: { width: "100%" } }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "select" ? (u(), h(o(W), v({
1786
1791
  key: 1,
1787
1792
  modelValue: t.conf.update.form[e.key],
1788
- "onUpdate:modelValue": (p) => t.conf.update.form[e.key] = p,
1793
+ "onUpdate:modelValue": (c) => t.conf.update.form[e.key] = c,
1789
1794
  disabled: t.conf.update.getDisabled(e),
1790
1795
  ref_for: !0
1791
1796
  }, t.conf.update.getBind(e), D(t.conf.update.getOn(e)), { style: { width: "100%" } }), {
1792
1797
  default: m(() => [
1793
- (f(!0), b(S, null, T(e.options?.search?.select?.data || e.options?.select?.data, (p) => (f(), h(o(N), {
1794
- key: p.value,
1795
- label: p.label,
1796
- value: p.value
1798
+ (u(!0), y(S, null, A(e.options?.search?.select?.data || e.options?.select?.data, (c) => (u(), h(o(N), {
1799
+ key: c.value,
1800
+ label: c.label,
1801
+ value: c.value
1797
1802
  }, null, 8, ["label", "value"]))), 128))
1798
1803
  ]),
1799
1804
  _: 2
1800
- }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "switch" ? (f(), h(o(X), v({
1805
+ }, 1040, ["modelValue", "onUpdate:modelValue", "disabled"])) : e.type === "switch" ? (u(), h(o(X), v({
1801
1806
  key: 2,
1802
1807
  modelValue: t.conf.update.form[e.key],
1803
- "onUpdate:modelValue": (p) => t.conf.update.form[e.key] = p,
1808
+ "onUpdate:modelValue": (c) => t.conf.update.form[e.key] = c,
1804
1809
  ref_for: !0
1805
1810
  }, t.conf.update.getBind(e), D(t.conf.update.getOn(e)), {
1806
1811
  disabled: t.conf.update.getDisabled(e)
@@ -1810,27 +1815,29 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1810
1815
  row: s,
1811
1816
  item: e
1812
1817
  }, () => [
1813
- o(L).customComponent[e.type ?? ""]?.table ? (f(), h(q(o(L).customComponent[e.type ?? ""]?.table), v({
1818
+ o(L).customComponent[e.type ?? ""]?.table ? (u(), h(q(o(L).customComponent[e.type ?? ""]?.table), v({
1814
1819
  key: 0,
1815
1820
  modelValue: s[e.key],
1816
- "onUpdate:modelValue": (p) => s[e.key] = p,
1817
- ref_for: !0
1818
- }, e.options?.[e.type ?? ""], D(e.options?.[e.type ?? ""]?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue"])) : e.type === "switch" ? (f(), h(o(X), v({
1819
- key: 1,
1820
- modelValue: s[e.key],
1821
- "onUpdate:modelValue": (p) => s[e.key] = p,
1822
- loading: e.options?.switch?.loadingMap?.[s[t.option.table?.rowKey]]?.loading,
1823
- "before-change": () => e.options?.switch?.tableBeforeChange?.(e.key, s),
1821
+ "onUpdate:modelValue": (c) => s[e.key] = c,
1824
1822
  ref_for: !0
1825
- }, e.options?.switch), null, 16, ["modelValue", "onUpdate:modelValue", "loading", "before-change"])) : (f(), b("span", {
1823
+ }, e.options?.[e.type ?? ""], D(e.options?.[e.type ?? ""]?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue"])) : e.type === "switch" ? (u(), y(S, { key: 1 }, [
1824
+ e.options?.switch?.tableConfig?.change ? (u(), h(o(X), v({
1825
+ key: 0,
1826
+ modelValue: s[e.key],
1827
+ "onUpdate:modelValue": (c) => s[e.key] = c,
1828
+ loading: e.options?.switch?.loadingMap?.[s[t.option.table?.rowKey]]?.loading,
1829
+ "before-change": () => e.options?.switch?.tableBeforeChange?.(e.key, s),
1830
+ ref_for: !0
1831
+ }, e.options?.switch), null, 16, ["modelValue", "onUpdate:modelValue", "loading", "before-change"])) : (u(), y("span", Qe, O(s[e.key] === e.options?.switch?.activeValue ? e.options?.switch?.activeText : e.options?.switch?.inactiveText), 1))
1832
+ ], 64)) : (u(), y("span", {
1826
1833
  key: 2,
1827
1834
  style: fe({
1828
1835
  "--table-text-click-color": e.table?.click?.color
1829
1836
  }),
1830
1837
  class: j({ "table-text-click": e.table?.click?.callback }),
1831
- onClick: (p) => e.table?.click?.callback?.(s),
1838
+ onClick: (c) => e.table?.click?.callback?.(s),
1832
1839
  innerHTML: e.table?.format ? e.table?.format(s) : s[e.key]
1833
- }, null, 14, Qe))
1840
+ }, null, 14, Ge))
1834
1841
  ])
1835
1842
  ], 64))
1836
1843
  ]),
@@ -1839,17 +1846,17 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1839
1846
  ], 64))), 128);
1840
1847
  };
1841
1848
  }
1842
- }), Xe = {
1849
+ }), Ye = {
1843
1850
  class: "row form-item-content",
1844
1851
  style: { width: "100%" }
1845
- }, Ye = { class: "col column form-item-content-item" }, Ze = { class: "col" }, xe = ["innerHTML"], _e = /* @__PURE__ */ J({
1852
+ }, Ze = { class: "col column form-item-content-item" }, xe = { class: "col" }, _e = ["innerHTML"], et = /* @__PURE__ */ J({
1846
1853
  __name: "formColumn",
1847
1854
  props: {
1848
1855
  conf: {},
1849
1856
  item: {}
1850
1857
  },
1851
1858
  setup(i) {
1852
- return (a, u) => (f(), h(o(G), {
1859
+ return (a, f) => (u(), h(o(G), {
1853
1860
  class: j({
1854
1861
  "hide-label": typeof a.item.item.text?.form?.label == "boolean" ? !a.item.item.text?.form?.label : !1
1855
1862
  }),
@@ -1858,85 +1865,85 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1858
1865
  "label-width": a.item.item.form?.labelWidth || a.conf.option.form?.labelWidth
1859
1866
  }, {
1860
1867
  default: m(() => [
1861
- F("div", Xe, [
1868
+ F("div", Ye, [
1862
1869
  C(a.$slots, "form-" + a.item.item.key + "-start", {
1863
1870
  row: a.conf.update.form,
1864
1871
  item: a.item.item
1865
1872
  }),
1866
- F("div", Ye, [
1867
- F("div", Ze, [
1873
+ F("div", Ze, [
1874
+ F("div", xe, [
1868
1875
  C(a.$slots, "form-" + a.item.item.key, {
1869
1876
  row: a.conf.update.form,
1870
1877
  item: a.item.item
1871
1878
  }, () => [
1872
- a.item.item.type === "input" ? (f(), h(o(Z), v({
1879
+ a.item.item.type === "input" ? (u(), h(o(Z), v({
1873
1880
  key: 0,
1874
1881
  modelValue: a.conf.update.form[a.item.item.key],
1875
- "onUpdate:modelValue": u[0] || (u[0] = (t) => a.conf.update.form[a.item.item.key] = t)
1882
+ "onUpdate:modelValue": f[0] || (f[0] = (t) => a.conf.update.form[a.item.item.key] = t)
1876
1883
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1877
1884
  disabled: a.conf.update.getDisabled(a.item.item)
1878
- }), null, 16, ["modelValue", "disabled"])) : a.item.item.type === "switch" ? (f(), h(o(X), v({
1885
+ }), null, 16, ["modelValue", "disabled"])) : a.item.item.type === "switch" ? (u(), h(o(X), v({
1879
1886
  key: 1,
1880
1887
  modelValue: a.conf.update.form[a.item.item.key],
1881
- "onUpdate:modelValue": u[1] || (u[1] = (t) => a.conf.update.form[a.item.item.key] = t)
1888
+ "onUpdate:modelValue": f[1] || (f[1] = (t) => a.conf.update.form[a.item.item.key] = t)
1882
1889
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1883
1890
  disabled: a.conf.update.getDisabled(a.item.item)
1884
- }), null, 16, ["modelValue", "disabled"])) : a.item.item.type === "select" ? (f(), h(o(W), v({
1891
+ }), null, 16, ["modelValue", "disabled"])) : a.item.item.type === "select" ? (u(), h(o(W), v({
1885
1892
  key: 2,
1886
1893
  modelValue: a.conf.update.form[a.item.item.key],
1887
- "onUpdate:modelValue": u[2] || (u[2] = (t) => a.conf.update.form[a.item.item.key] = t)
1894
+ "onUpdate:modelValue": f[2] || (f[2] = (t) => a.conf.update.form[a.item.item.key] = t)
1888
1895
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1889
1896
  disabled: a.conf.update.getDisabled(a.item.item),
1890
1897
  style: { width: "100%" }
1891
1898
  }), {
1892
1899
  default: m(() => [
1893
- (f(!0), b(S, null, T(a.conf.update.getBind(a.item.item).data, (t) => (f(), h(o(N), {
1900
+ (u(!0), y(S, null, A(a.conf.update.getBind(a.item.item).data, (t) => (u(), h(o(N), {
1894
1901
  key: t.value,
1895
1902
  label: t.label,
1896
1903
  value: t.value
1897
1904
  }, null, 8, ["label", "value"]))), 128))
1898
1905
  ]),
1899
1906
  _: 1
1900
- }, 16, ["modelValue", "disabled"])) : a.item.item.type === "radio" ? (f(), h(o(re), v({
1907
+ }, 16, ["modelValue", "disabled"])) : a.item.item.type === "radio" ? (u(), h(o(re), v({
1901
1908
  key: 3,
1902
1909
  modelValue: a.conf.update.form[a.item.item.key],
1903
- "onUpdate:modelValue": u[3] || (u[3] = (t) => a.conf.update.form[a.item.item.key] = t)
1910
+ "onUpdate:modelValue": f[3] || (f[3] = (t) => a.conf.update.form[a.item.item.key] = t)
1904
1911
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1905
1912
  disabled: a.conf.update.getDisabled(a.item.item),
1906
1913
  style: { width: "100%" }
1907
1914
  }), {
1908
1915
  default: m(() => [
1909
- (f(!0), b(S, null, T(a.conf.update.getBind(a.item.item).data, (t) => (f(), h(o(se), {
1916
+ (u(!0), y(S, null, A(a.conf.update.getBind(a.item.item).data, (t) => (u(), h(o(se), {
1910
1917
  key: t.value,
1911
1918
  label: t.label,
1912
1919
  value: t.value
1913
1920
  }, null, 8, ["label", "value"]))), 128))
1914
1921
  ]),
1915
1922
  _: 1
1916
- }, 16, ["modelValue", "disabled"])) : a.item.item.type === "list" ? (f(), h(ne, v({
1923
+ }, 16, ["modelValue", "disabled"])) : a.item.item.type === "list" ? (u(), h(ne, v({
1917
1924
  key: 4,
1918
1925
  row: a.conf.update.form,
1919
1926
  field: a.item.item.key
1920
1927
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1921
1928
  disabled: a.conf.update.getDisabled(a.item.item),
1922
1929
  style: { width: "100%" }
1923
- }), null, 16, ["row", "field", "disabled"])) : a.item.item.type === "treeSelect" ? (f(), h(o(de), v({
1930
+ }), null, 16, ["row", "field", "disabled"])) : a.item.item.type === "treeSelect" ? (u(), h(o(de), v({
1924
1931
  key: 5,
1925
1932
  modelValue: a.conf.update.form[a.item.item.key],
1926
- "onUpdate:modelValue": u[4] || (u[4] = (t) => a.conf.update.form[a.item.item.key] = t)
1933
+ "onUpdate:modelValue": f[4] || (f[4] = (t) => a.conf.update.form[a.item.item.key] = t)
1927
1934
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1928
1935
  disabled: a.conf.update.getDisabled(a.item.item),
1929
1936
  style: { width: "100%" }
1930
- }), null, 16, ["modelValue", "disabled"])) : a.item.item.type === "datetime" ? (f(), h(o(ae), v({
1937
+ }), null, 16, ["modelValue", "disabled"])) : a.item.item.type === "datetime" ? (u(), h(o(ae), v({
1931
1938
  key: 6,
1932
1939
  modelValue: a.conf.update.form[a.item.item.key],
1933
- "onUpdate:modelValue": u[5] || (u[5] = (t) => a.conf.update.form[a.item.item.key] = t)
1940
+ "onUpdate:modelValue": f[5] || (f[5] = (t) => a.conf.update.form[a.item.item.key] = t)
1934
1941
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1935
1942
  disabled: a.conf.update.getDisabled(a.item.item)
1936
- }), null, 16, ["modelValue", "disabled"])) : a.item.item.type && (o(L).customComponent[a.item.item.type] || o(L).customComponent[a.item.item.type]?.form) ? (f(), h(q(o(L).customComponent[a.item.item.type]?.form || o(L).customComponent[a.item.item.type]), v({
1943
+ }), null, 16, ["modelValue", "disabled"])) : a.item.item.type && (o(L).customComponent[a.item.item.type] || o(L).customComponent[a.item.item.type]?.form) ? (u(), h(q(o(L).customComponent[a.item.item.type]?.form || o(L).customComponent[a.item.item.type]), v({
1937
1944
  key: 7,
1938
1945
  modelValue: a.conf.update.form[a.item.item.key],
1939
- "onUpdate:modelValue": u[6] || (u[6] = (t) => a.conf.update.form[a.item.item.key] = t)
1946
+ "onUpdate:modelValue": f[6] || (f[6] = (t) => a.conf.update.form[a.item.item.key] = t)
1940
1947
  }, a.conf.update.getBind(a.item.item), D(a.conf.update.getOn(a.item.item)), {
1941
1948
  disabled: a.conf.update.getDisabled(a.item.item)
1942
1949
  }), null, 16, ["modelValue", "disabled"])) : k("", !0)
@@ -1950,11 +1957,11 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1950
1957
  row: a.conf.update.form,
1951
1958
  item: a.item.item
1952
1959
  }, () => [
1953
- a.item.item.form?.tipText ? (f(), b("div", {
1960
+ a.item.item.form?.tipText ? (u(), y("div", {
1954
1961
  key: 0,
1955
1962
  class: "form-tip-text",
1956
1963
  innerHTML: typeof a.item.item.form?.tipText == "function" ? a.item.item.form?.tipText(a.conf.update.form, a.conf.update.type) : a.item.item.form?.tipText
1957
- }, null, 8, xe)) : k("", !0)
1964
+ }, null, 8, _e)) : k("", !0)
1958
1965
  ])
1959
1966
  ]),
1960
1967
  C(a.$slots, "form-" + a.item.item.key + "-end", {
@@ -1966,19 +1973,19 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1966
1973
  _: 3
1967
1974
  }, 8, ["class", "label", "prop", "label-width"]));
1968
1975
  }
1969
- }), et = {
1976
+ }), tt = {
1970
1977
  key: 0,
1971
1978
  class: "relative curd-search fit-width"
1972
- }, tt = { class: "mb-10 flex justify-between items-center fit-width" }, ot = {
1979
+ }, ot = { class: "mb-10 flex justify-between items-center fit-width" }, at = {
1973
1980
  class: "flex items-center",
1974
1981
  style: { gap: "10px" }
1975
- }, at = { key: 0 }, lt = { key: 1 }, nt = { key: 2 }, it = { class: "export-btn" }, rt = {
1982
+ }, lt = { key: 0 }, nt = { key: 1 }, it = { key: 2 }, rt = { class: "export-btn" }, st = {
1976
1983
  key: 1,
1977
1984
  class: "export-btn"
1978
- }, st = {
1985
+ }, dt = {
1979
1986
  class: "flex items-center table-tools-right",
1980
1987
  style: { gap: "10px" }
1981
- }, dt = { class: "row justify-end mt-10 mb-10 table-bottom-pagination" }, ut = { class: "dialog-footer" }, ft = { class: "dialog-footer" }, pt = /* @__PURE__ */ J({
1988
+ }, ut = { class: "row justify-end mt-10 mb-10 table-bottom-pagination" }, ft = { class: "dialog-footer" }, pt = { class: "dialog-footer" }, ct = /* @__PURE__ */ J({
1982
1989
  __name: "index",
1983
1990
  props: {
1984
1991
  /**
@@ -1989,36 +1996,36 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
1989
1996
  }
1990
1997
  },
1991
1998
  setup(i, { expose: a }) {
1992
- const u = U.EDialog, t = i, r = U.isFun, { conf: l, switchConfirmRef: e, ruleFormRef: s } = Te(t);
1999
+ const f = U.EDialog, t = i, r = U.isFun, { conf: l, switchConfirmRef: e, ruleFormRef: s } = Ae(t);
1993
2000
  return a({
1994
2001
  conf: l
1995
- }), (p, c) => {
2002
+ }), (c, p) => {
1996
2003
  const g = we("loading");
1997
- return f(), b("div", {
2004
+ return u(), y("div", {
1998
2005
  class: j(["relative cc1-form-box", [i.option.table?.fitHeight ? "col" : "no-min-height"]])
1999
2006
  }, [
2000
2007
  F("div", {
2001
2008
  class: j(["row", [i.option.table?.fitHeight ? "absolute fit" : ""]]),
2002
2009
  style: { overflow: "hidden" }
2003
2010
  }, [
2004
- C(p.$slots, "box-left"),
2011
+ C(c.$slots, "box-left"),
2005
2012
  F("div", {
2006
2013
  class: j(["column fit-width no-wrap", [i.option.table?.fitHeight ? "col" : ""]])
2007
2014
  }, [
2008
- i.option.search?.show !== !1 ? (f(), b("div", et, [
2015
+ i.option.search?.show !== !1 ? (u(), y("div", tt, [
2009
2016
  z(o(K), {
2010
2017
  model: o(l).search.form,
2011
2018
  inline: "",
2012
2019
  size: i.option.size?.search
2013
2020
  }, {
2014
2021
  default: m(() => [
2015
- C(p.$slots, "search-start", {
2022
+ C(c.$slots, "search-start", {
2016
2023
  row: o(l).search.form
2017
2024
  }),
2018
- (f(!0), b(S, null, T(o(l).search.column.list, (n) => (f(), b(S, {
2025
+ (u(!0), y(S, null, A(o(l).search.column.list, (n) => (u(), y(S, {
2019
2026
  key: n.key
2020
2027
  }, [
2021
- (typeof n.show?.search == "function" ? n.show?.search(o(l).search.form) : n.show?.search) ? (f(), h(o(G), {
2028
+ (typeof n.show?.search == "function" ? n.show?.search(o(l).search.form) : n.show?.search) ? (u(), h(o(G), {
2022
2029
  key: 0,
2023
2030
  label: typeof n.text?.search?.label == "string" ? n.text?.search?.label : n.label,
2024
2031
  class: j({
@@ -2026,10 +2033,10 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2026
2033
  })
2027
2034
  }, {
2028
2035
  default: m(() => [
2029
- C(p.$slots, "search-" + n.key, {
2036
+ C(c.$slots, "search-" + n.key, {
2030
2037
  row: o(l).search.form
2031
2038
  }, () => [
2032
- n.type === "input" ? (f(), h(o(Z), v({
2039
+ n.type === "input" ? (u(), h(o(Z), v({
2033
2040
  key: 0,
2034
2041
  modelValue: o(l).search.form[n.key],
2035
2042
  "onUpdate:modelValue": (d) => o(l).search.form[n.key] = d,
@@ -2037,52 +2044,52 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2037
2044
  clearable: "",
2038
2045
  disabled: n.disabled?.search,
2039
2046
  ref_for: !0
2040
- }, n.options?.search?.input || n.options?.input, D(n.options?.search?.input?.on || n.options?.input?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : n.type === "switch" ? (f(), h(o(W), v({
2047
+ }, n.options?.search?.input || n.options?.input, D(n.options?.search?.input?.on || n.options?.input?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : n.type === "switch" ? (u(), h(o(W), v({
2041
2048
  key: 1,
2042
2049
  modelValue: o(l).search.form[n.key],
2043
2050
  "onUpdate:modelValue": (d) => o(l).search.form[n.key] = d,
2044
- placeholder: o(l).search.getPlaceholder(n, o(y).tCurd("placeholderSelect")),
2051
+ placeholder: o(l).search.getPlaceholder(n, o(b).tCurd("placeholderSelect")),
2045
2052
  clearable: "",
2046
2053
  disabled: n.disabled?.search,
2047
2054
  ref_for: !0
2048
2055
  }, n.options?.search?.switch || n.options?.switch, D(n.options?.search?.switch?.on || n.options?.switch?.on || {})), {
2049
2056
  default: m(() => [
2050
- (f(), h(o(N), {
2057
+ (u(), h(o(N), {
2051
2058
  key: n.options?.switch?.activeValue,
2052
2059
  label: n.options?.switch?.activeLabel,
2053
2060
  value: n.options?.switch?.activeValue
2054
2061
  }, null, 8, ["label", "value"])),
2055
- (f(), h(o(N), {
2062
+ (u(), h(o(N), {
2056
2063
  key: n.options?.switch?.inactiveValue,
2057
2064
  label: n.options?.switch?.inactiveLabel,
2058
2065
  value: n.options?.switch?.inactiveValue
2059
2066
  }, null, 8, ["label", "value"]))
2060
2067
  ]),
2061
2068
  _: 2
2062
- }, 1040, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : n.type === "select" ? (f(), h(o(W), v({
2069
+ }, 1040, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : n.type === "select" ? (u(), h(o(W), v({
2063
2070
  key: 2,
2064
2071
  modelValue: o(l).search.form[n.key],
2065
2072
  "onUpdate:modelValue": (d) => o(l).search.form[n.key] = d,
2066
- placeholder: o(l).search.getPlaceholder(n, o(y).tCurd("placeholderSelect")),
2073
+ placeholder: o(l).search.getPlaceholder(n, o(b).tCurd("placeholderSelect")),
2067
2074
  clearable: "",
2068
2075
  disabled: n.disabled?.search,
2069
2076
  ref_for: !0
2070
2077
  }, n.options?.search?.select || n.options?.select, D(n.options?.search?.select?.on || n.options?.select?.on || {})), {
2071
2078
  default: m(() => [
2072
- (f(!0), b(S, null, T(n.options?.select?.data, (d) => (f(), h(o(N), {
2079
+ (u(!0), y(S, null, A(n.options?.select?.data, (d) => (u(), h(o(N), {
2073
2080
  key: d.value,
2074
2081
  label: d.label,
2075
2082
  value: d.value
2076
2083
  }, null, 8, ["label", "value"]))), 128))
2077
2084
  ]),
2078
2085
  _: 2
2079
- }, 1040, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : n.type === "datetime" ? (f(), h(o(ae), v({
2086
+ }, 1040, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : n.type === "datetime" ? (u(), h(o(ae), v({
2080
2087
  key: 3,
2081
2088
  modelValue: o(l).search.form[n.key],
2082
2089
  "onUpdate:modelValue": (d) => o(l).search.form[n.key] = d,
2083
2090
  disabled: n.disabled?.search,
2084
2091
  ref_for: !0
2085
- }, n.options?.search?.datetime || n.options?.datetime, D(n.options?.search?.datetime?.on || n.options?.datetime?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.type && o(L).customComponent[n.type] ? (f(), h(q(o(L).customComponent[n.type]), v({
2092
+ }, n.options?.search?.datetime || n.options?.datetime, D(n.options?.search?.datetime?.on || n.options?.datetime?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : n.type && o(L).customComponent[n.type] ? (u(), h(q(o(L).customComponent[n.type]), v({
2086
2093
  key: 4,
2087
2094
  modelValue: o(l).search.form[n.key],
2088
2095
  "onUpdate:modelValue": (d) => o(l).search.form[n.key] = d,
@@ -2091,87 +2098,87 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2091
2098
  disabled: n.disabled?.search
2092
2099
  }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : k("", !0)
2093
2100
  ]),
2094
- C(p.$slots, "search-" + n.key + "-right", {
2101
+ C(c.$slots, "search-" + n.key + "-right", {
2095
2102
  row: o(l).search.form
2096
2103
  })
2097
2104
  ]),
2098
2105
  _: 2
2099
2106
  }, 1032, ["label", "class"])) : k("", !0)
2100
2107
  ], 64))), 128)),
2101
- C(p.$slots, "search-center", {
2108
+ C(c.$slots, "search-center", {
2102
2109
  row: o(l).search.form
2103
2110
  }),
2104
- i.option.tools?.search || i.option.tools?.reset ? (f(), h(o(G), { key: 0 }, {
2111
+ i.option.tools?.search || i.option.tools?.reset ? (u(), h(o(G), { key: 0 }, {
2105
2112
  default: m(() => [
2106
- i.option.tools?.search ? (f(), h(o(A), {
2113
+ i.option.tools?.search ? (u(), h(o(M), {
2107
2114
  key: 0,
2108
2115
  type: "primary",
2109
2116
  onClick: o(l).search.submit
2110
2117
  }, {
2111
2118
  default: m(() => [
2112
- $(O(o(y).tCurd("search")), 1)
2119
+ $(O(o(b).tCurd("search")), 1)
2113
2120
  ]),
2114
2121
  _: 1
2115
2122
  }, 8, ["onClick"])) : k("", !0),
2116
- i.option.tools?.reset ? (f(), h(o(A), {
2123
+ i.option.tools?.reset ? (u(), h(o(M), {
2117
2124
  key: 1,
2118
2125
  onClick: o(l).search.reset
2119
2126
  }, {
2120
2127
  default: m(() => [
2121
- $(O(o(y).tCurd("reset")), 1)
2128
+ $(O(o(b).tCurd("reset")), 1)
2122
2129
  ]),
2123
2130
  _: 1
2124
2131
  }, 8, ["onClick"])) : k("", !0)
2125
2132
  ]),
2126
2133
  _: 1
2127
2134
  })) : k("", !0),
2128
- C(p.$slots, "search-end", {
2135
+ C(c.$slots, "search-end", {
2129
2136
  row: o(l).search.form
2130
2137
  })
2131
2138
  ]),
2132
2139
  _: 3
2133
2140
  }, 8, ["model", "size"])
2134
2141
  ])) : k("", !0),
2135
- F("div", tt, [
2136
- F("div", ot, [
2137
- o(r)(i.option.tools?.add) ? (f(), b("div", at, [
2138
- z(o(A), {
2142
+ F("div", ot, [
2143
+ F("div", at, [
2144
+ o(r)(i.option.tools?.add) ? (u(), y("div", lt, [
2145
+ z(o(M), {
2139
2146
  type: "primary",
2140
- onClick: c[0] || (c[0] = (n) => o(l).update.open(o(u).Add)),
2147
+ onClick: p[0] || (p[0] = (n) => o(l).update.open(o(f).Add)),
2141
2148
  size: i.option.size?.search
2142
2149
  }, {
2143
2150
  default: m(() => [
2144
- $(O(o(y).tCurd("add")), 1)
2151
+ $(O(o(b).tCurd("add")), 1)
2145
2152
  ]),
2146
2153
  _: 1
2147
2154
  }, 8, ["size"])
2148
2155
  ])) : k("", !0),
2149
- i.option.table?.selectable && o(r)(i.option.tools?.delete) ? (f(), b("div", lt, [
2150
- z(o(A), {
2156
+ i.option.table?.selectable && o(r)(i.option.tools?.delete) ? (u(), y("div", nt, [
2157
+ z(o(M), {
2151
2158
  type: "danger",
2152
- onClick: c[1] || (c[1] = (n) => o(l).remove.open(o(l).table.selection.list)),
2159
+ onClick: p[1] || (p[1] = (n) => o(l).remove.open(o(l).table.selection.list)),
2153
2160
  size: i.option.size?.search
2154
2161
  }, {
2155
2162
  default: m(() => [
2156
- $(O(o(y).tCurd("delete")), 1)
2163
+ $(O(o(b).tCurd("delete")), 1)
2157
2164
  ]),
2158
2165
  _: 1
2159
2166
  }, 8, ["size"])
2160
2167
  ])) : k("", !0),
2161
- i.option.tools?.expand ? (f(), b("div", nt, [
2162
- z(o(A), {
2168
+ i.option.tools?.expand ? (u(), y("div", it, [
2169
+ z(o(M), {
2163
2170
  type: "warning",
2164
- onClick: c[2] || (c[2] = (n) => o(l).table.expand.all()),
2171
+ onClick: p[2] || (p[2] = (n) => o(l).table.expand.all()),
2165
2172
  size: i.option.size?.search
2166
2173
  }, {
2167
2174
  default: m(() => [
2168
- $(O(o(y).tCurd("expandCollapse")), 1)
2175
+ $(O(o(b).tCurd("expandCollapse")), 1)
2169
2176
  ]),
2170
2177
  _: 1
2171
2178
  }, 8, ["size"])
2172
2179
  ])) : k("", !0),
2173
- i.option.tools?.export?.show ? (f(), b(S, { key: 3 }, [
2174
- i.option.tools?.export?.dropdown?.show ? (f(), h(o(he), {
2180
+ i.option.tools?.export?.show ? (u(), y(S, { key: 3 }, [
2181
+ i.option.tools?.export?.dropdown?.show ? (u(), h(o(he), {
2175
2182
  key: 0,
2176
2183
  onCommand: o(l).export.click
2177
2184
  }, {
@@ -2180,30 +2187,30 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2180
2187
  size: i.option.size?.search
2181
2188
  }, {
2182
2189
  default: m(() => [
2183
- i.option.tools?.export?.dropdown?.select && (i.option.table?.selectable || o(r)(i.option.tools?.delete)) ? (f(), h(o(_), {
2190
+ i.option.tools?.export?.dropdown?.select && (i.option.table?.selectable || o(r)(i.option.tools?.delete)) ? (u(), h(o(_), {
2184
2191
  key: 0,
2185
2192
  command: "select"
2186
2193
  }, {
2187
2194
  default: m(() => [
2188
- $(O(o(y).tCurd("exportSelect")), 1)
2195
+ $(O(o(b).tCurd("exportSelect")), 1)
2189
2196
  ]),
2190
2197
  _: 1
2191
2198
  })) : k("", !0),
2192
- i.option.tools?.export?.dropdown?.page ? (f(), h(o(_), {
2199
+ i.option.tools?.export?.dropdown?.page ? (u(), h(o(_), {
2193
2200
  key: 1,
2194
2201
  command: "page"
2195
2202
  }, {
2196
2203
  default: m(() => [
2197
- $(O(o(y).tCurd("exportPage")), 1)
2204
+ $(O(o(b).tCurd("exportPage")), 1)
2198
2205
  ]),
2199
2206
  _: 1
2200
2207
  })) : k("", !0),
2201
- i.option.tools?.export?.dropdown?.all ? (f(), h(o(_), {
2208
+ i.option.tools?.export?.dropdown?.all ? (u(), h(o(_), {
2202
2209
  key: 2,
2203
2210
  command: "all"
2204
2211
  }, {
2205
2212
  default: m(() => [
2206
- $(O(o(y).tCurd("exportAll")), 1)
2213
+ $(O(o(b).tCurd("exportAll")), 1)
2207
2214
  ]),
2208
2215
  _: 1
2209
2216
  })) : k("", !0)
@@ -2212,44 +2219,44 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2212
2219
  }, 8, ["size"])
2213
2220
  ]),
2214
2221
  default: m(() => [
2215
- F("div", it, [
2216
- z(o(A), {
2222
+ F("div", rt, [
2223
+ z(o(M), {
2217
2224
  type: "warning",
2218
2225
  loading: o(l).export.loading,
2219
2226
  size: i.option.size?.search
2220
2227
  }, {
2221
2228
  default: m(() => [
2222
- $(O(o(y).tCurd("export")), 1)
2229
+ $(O(o(b).tCurd("export")), 1)
2223
2230
  ]),
2224
2231
  _: 1
2225
2232
  }, 8, ["loading", "size"])
2226
2233
  ])
2227
2234
  ]),
2228
2235
  _: 1
2229
- }, 8, ["onCommand"])) : (f(), b("div", rt, [
2230
- z(o(A), {
2236
+ }, 8, ["onCommand"])) : (u(), y("div", st, [
2237
+ z(o(M), {
2231
2238
  type: "warning",
2232
2239
  loading: o(l).export.loading,
2233
2240
  size: i.option.size?.search,
2234
- onClick: c[3] || (c[3] = (n) => o(l).export.run.start("all"))
2241
+ onClick: p[3] || (p[3] = (n) => o(l).export.run.start("all"))
2235
2242
  }, {
2236
2243
  default: m(() => [
2237
- $(O(o(y).tCurd("export")), 1)
2244
+ $(O(o(b).tCurd("export")), 1)
2238
2245
  ]),
2239
2246
  _: 1
2240
2247
  }, 8, ["loading", "size"])
2241
2248
  ]))
2242
2249
  ], 64)) : k("", !0),
2243
- C(p.$slots, "tools-left")
2250
+ C(c.$slots, "tools-left")
2244
2251
  ]),
2245
- F("div", st, [
2246
- C(p.$slots, "tools-right"),
2247
- o(l).page.showTools ? (f(), h(o(ie), v({
2252
+ F("div", dt, [
2253
+ C(c.$slots, "tools-right"),
2254
+ o(l).page.showTools ? (u(), h(o(ie), v({
2248
2255
  key: 0,
2249
2256
  "current-page": o(l).page.num,
2250
- "onUpdate:currentPage": c[4] || (c[4] = (n) => o(l).page.num = n),
2257
+ "onUpdate:currentPage": p[4] || (p[4] = (n) => o(l).page.num = n),
2251
2258
  "page-size": o(l).page.size,
2252
- "onUpdate:pageSize": c[5] || (c[5] = (n) => o(l).page.size = n),
2259
+ "onUpdate:pageSize": p[5] || (p[5] = (n) => o(l).page.size = n),
2253
2260
  background: "",
2254
2261
  "page-sizes": o(l).page.sizeList,
2255
2262
  "pager-count": o(l).page.pagerCount,
@@ -2259,10 +2266,10 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2259
2266
  onSizeChange: o(l).table.getList,
2260
2267
  onCurrentChange: o(l).table.getList
2261
2268
  }, i.option.page?.pagination || {}, D(i.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "size", "onSizeChange", "onCurrentChange"])) : k("", !0),
2262
- i.option.tools?.refresh === void 0 || i.option.tools?.refresh ? (f(), b("div", {
2269
+ i.option.tools?.refresh === void 0 || i.option.tools?.refresh ? (u(), y("div", {
2263
2270
  key: 1,
2264
2271
  class: j(["refresh-btn", [i.option.size?.search]]),
2265
- onClick: c[6] || (c[6] = //@ts-ignore
2272
+ onClick: p[6] || (p[6] = //@ts-ignore
2266
2273
  (...n) => o(l).table.getList && o(l).table.getList(...n))
2267
2274
  }, [
2268
2275
  z(Pe)
@@ -2275,7 +2282,7 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2275
2282
  F("div", {
2276
2283
  class: j(["column form-box-content", [i.option.table?.fitHeight ? "absolute fit" : ""]])
2277
2284
  }, [
2278
- ke((f(), h(o(ye), v({
2285
+ ke((u(), h(o(ye), v({
2279
2286
  data: o(l).table.data,
2280
2287
  border: i.option.table?.border === void 0 ? !0 : i.option.table?.border,
2281
2288
  onSelectionChange: o(l).table.selection.change,
@@ -2284,7 +2291,7 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2284
2291
  onExpandChange: o(l).table.expand.change
2285
2292
  }, i.option.table, D(i.option.table?.on || {})), {
2286
2293
  default: m(() => [
2287
- (typeof i.option.table?.selectable == "object" ? i.option.table?.selectable?.show : i.option.table?.selectable) || o(r)(i.option.tools?.delete) || i.option.tools?.export?.show && i.option.tools?.export?.select ? (f(), h(o(te), v({
2294
+ (typeof i.option.table?.selectable == "object" ? i.option.table?.selectable?.show : i.option.table?.selectable) || o(r)(i.option.tools?.delete) || i.option.tools?.export?.show && i.option.tools?.export?.select ? (u(), h(o(te), v({
2288
2295
  key: 0,
2289
2296
  type: "selection",
2290
2297
  width: "40",
@@ -2293,27 +2300,27 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2293
2300
  "show-overflow-tooltip": !1,
2294
2301
  className: "cc1-form-selectable-column"
2295
2302
  }, typeof i.option.table?.selectable == "object" ? i.option.table?.selectable : {}, D(typeof i.option.table?.selectable == "object" ? i.option.table?.selectable?.on || {} : {})), null, 16)) : k("", !0),
2296
- z(Ge, {
2303
+ z(Xe, {
2297
2304
  conf: o(l),
2298
2305
  columnList: o(l).table.column.list,
2299
2306
  option: i.option
2300
2307
  }, oe({ _: 2 }, [
2301
- T(p.$slots, (n, d) => ({
2308
+ A(c.$slots, (n, d) => ({
2302
2309
  name: d,
2303
2310
  fn: m((V) => [
2304
- C(p.$slots, d, Ce(ve(V || {})))
2311
+ C(c.$slots, d, Ce(ve(V || {})))
2305
2312
  ])
2306
2313
  }))
2307
2314
  ]), 1032, ["conf", "columnList", "option"]),
2308
- o(r)(i.option.table?.add) || o(r)(i.option.table?.update) || o(r)(i.option.table?.delete) || o(r)(i.option.table?.view) || p.$slots["table-op-left"] || p.$slots["table-op-right"] ? (f(), h(o(te), v({
2315
+ o(r)(i.option.table?.add) || o(r)(i.option.table?.update) || o(r)(i.option.table?.delete) || o(r)(i.option.table?.view) || c.$slots["table-op-left"] || c.$slots["table-op-right"] ? (u(), h(o(te), v({
2309
2316
  key: 1,
2310
- width: o(l).table.op.width(o(r)(i.option.table?.add), o(r)(i.option.table?.update), o(r)(i.option.table?.delete), o(r)(i.option.table?.view), p.$slots["table-op-left"], p.$slots["table-op-right"]),
2317
+ width: o(l).table.op.width(o(r)(i.option.table?.add), o(r)(i.option.table?.update), o(r)(i.option.table?.delete), o(r)(i.option.table?.view), c.$slots["table-op-left"], c.$slots["table-op-right"]),
2311
2318
  align: "center",
2312
2319
  fixed: "right"
2313
2320
  }, i.option.table?.operate), {
2314
2321
  header: m(() => [
2315
- C(p.$slots, "table-header-op", {}, () => [
2316
- $(O(o(y).tCurd("operation")), 1)
2322
+ C(c.$slots, "table-header-op", {}, () => [
2323
+ $(O(o(b).tCurd("operation")), 1)
2317
2324
  ])
2318
2325
  ]),
2319
2326
  default: m(({ row: n }) => [
@@ -2321,76 +2328,76 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2321
2328
  size: i.option.size?.table
2322
2329
  }, {
2323
2330
  default: m(() => [
2324
- C(p.$slots, "table-op-left", { row: n }),
2325
- o(l).update.type === o(u).Update && i.option.table?.inlineEdit && o(l).update.form[t.option.table?.rowKey] === n[t.option.table?.rowKey] ? (f(), b(S, { key: 0 }, [
2326
- z(o(A), {
2331
+ C(c.$slots, "table-op-left", { row: n }),
2332
+ o(l).update.type === o(f).Update && i.option.table?.inlineEdit && o(l).update.form[t.option.table?.rowKey] === n[t.option.table?.rowKey] ? (u(), y(S, { key: 0 }, [
2333
+ z(o(M), {
2327
2334
  link: "",
2328
2335
  type: "info",
2329
2336
  onClick: o(l).update.close
2330
2337
  }, {
2331
2338
  default: m(() => [
2332
- $(O(o(y).tCurd("cancel")), 1)
2339
+ $(O(o(b).tCurd("cancel")), 1)
2333
2340
  ]),
2334
2341
  _: 1
2335
2342
  }, 8, ["onClick"]),
2336
- z(o(A), {
2343
+ z(o(M), {
2337
2344
  link: "",
2338
2345
  type: "primary",
2339
2346
  onClick: o(l).update.submit,
2340
2347
  loading: o(l).update.loading
2341
2348
  }, {
2342
2349
  default: m(() => [
2343
- $(O(o(y).tCurd("confirm")), 1)
2350
+ $(O(o(b).tCurd("confirm")), 1)
2344
2351
  ]),
2345
2352
  _: 1
2346
2353
  }, 8, ["onClick", "loading"]),
2347
- C(p.$slots, "table-op-edit-right", { row: n })
2348
- ], 64)) : (f(), b(S, { key: 1 }, [
2349
- o(r)(i.option.table?.add, n) ? (f(), h(o(A), {
2354
+ C(c.$slots, "table-op-edit-right", { row: n })
2355
+ ], 64)) : (u(), y(S, { key: 1 }, [
2356
+ o(r)(i.option.table?.add, n) ? (u(), h(o(M), {
2350
2357
  key: 0,
2351
2358
  link: "",
2352
2359
  type: "primary",
2353
- onClick: (d) => o(l).update.open(o(u).Add, n)
2360
+ onClick: (d) => o(l).update.open(o(f).Add, n)
2354
2361
  }, {
2355
2362
  default: m(() => [
2356
- $(O(o(y).tCurd("add")), 1)
2363
+ $(O(o(b).tCurd("add")), 1)
2357
2364
  ]),
2358
2365
  _: 2
2359
2366
  }, 1032, ["onClick"])) : k("", !0),
2360
- o(r)(i.option.table?.view, n) ? (f(), h(o(A), {
2367
+ o(r)(i.option.table?.view, n) ? (u(), h(o(M), {
2361
2368
  key: 1,
2362
2369
  link: "",
2363
2370
  type: "primary",
2364
- onClick: (d) => o(l).update.open(o(u).View, n)
2371
+ onClick: (d) => o(l).update.open(o(f).View, n)
2365
2372
  }, {
2366
2373
  default: m(() => [
2367
- $(O(o(y).tCurd("view")), 1)
2374
+ $(O(o(b).tCurd("view")), 1)
2368
2375
  ]),
2369
2376
  _: 2
2370
2377
  }, 1032, ["onClick"])) : k("", !0),
2371
- o(r)(i.option.table?.update, n) ? (f(), h(o(A), {
2378
+ o(r)(i.option.table?.update, n) ? (u(), h(o(M), {
2372
2379
  key: 2,
2373
2380
  link: "",
2374
2381
  type: "warning",
2375
- onClick: (d) => o(l).update.open(o(u).Update, n)
2382
+ onClick: (d) => o(l).update.open(o(f).Update, n)
2376
2383
  }, {
2377
2384
  default: m(() => [
2378
- $(O(o(y).tCurd("edit")), 1)
2385
+ $(O(o(b).tCurd("edit")), 1)
2379
2386
  ]),
2380
2387
  _: 2
2381
2388
  }, 1032, ["onClick"])) : k("", !0),
2382
- o(r)(i.option.table?.delete, n) ? (f(), h(o(A), {
2389
+ o(r)(i.option.table?.delete, n) ? (u(), h(o(M), {
2383
2390
  key: 3,
2384
2391
  link: "",
2385
2392
  type: "danger",
2386
2393
  onClick: (d) => o(l).remove.open([n])
2387
2394
  }, {
2388
2395
  default: m(() => [
2389
- $(O(o(y).tCurd("delete")), 1)
2396
+ $(O(o(b).tCurd("delete")), 1)
2390
2397
  ]),
2391
2398
  _: 2
2392
2399
  }, 1032, ["onClick"])) : k("", !0),
2393
- C(p.$slots, "table-op-right", { row: n })
2400
+ C(c.$slots, "table-op-right", { row: n })
2394
2401
  ], 64))
2395
2402
  ]),
2396
2403
  _: 2
@@ -2405,13 +2412,13 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2405
2412
  ])
2406
2413
  ], 2)
2407
2414
  ], 2),
2408
- F("div", dt, [
2409
- (i.option.page?.show === void 0 || i.option.page?.show) && !o(l).page.showTools ? (f(), h(o(ie), v({
2415
+ F("div", ut, [
2416
+ (i.option.page?.show === void 0 || i.option.page?.show) && !o(l).page.showTools ? (u(), h(o(ie), v({
2410
2417
  key: 0,
2411
2418
  "current-page": o(l).page.num,
2412
- "onUpdate:currentPage": c[7] || (c[7] = (n) => o(l).page.num = n),
2419
+ "onUpdate:currentPage": p[7] || (p[7] = (n) => o(l).page.num = n),
2413
2420
  "page-size": o(l).page.size,
2414
- "onUpdate:pageSize": c[8] || (c[8] = (n) => o(l).page.size = n),
2421
+ "onUpdate:pageSize": p[8] || (p[8] = (n) => o(l).page.size = n),
2415
2422
  background: "",
2416
2423
  "page-sizes": o(l).page.sizeList,
2417
2424
  "pager-count": o(l).page.pagerCount,
@@ -2423,36 +2430,36 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2423
2430
  }, i.option.page?.pagination || {}, D(i.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "size", "onSizeChange", "onCurrentChange"])) : k("", !0)
2424
2431
  ])
2425
2432
  ], 2),
2426
- C(p.$slots, "box-right")
2433
+ C(c.$slots, "box-right")
2427
2434
  ], 2),
2428
2435
  z(o(ee), v({
2429
2436
  modelValue: o(l).update.show,
2430
- "onUpdate:modelValue": c[9] || (c[9] = (n) => o(l).update.show = n),
2437
+ "onUpdate:modelValue": p[9] || (p[9] = (n) => o(l).update.show = n),
2431
2438
  title: o(l).update.title,
2432
2439
  "before-close": o(l).update.close
2433
2440
  }, i.option.dialog), {
2434
2441
  footer: m(() => [
2435
- F("span", ut, [
2442
+ F("span", ft, [
2436
2443
  z(o(K), {
2437
2444
  size: i.option.size?.form
2438
2445
  }, {
2439
2446
  default: m(() => [
2440
- z(o(A), {
2447
+ z(o(M), {
2441
2448
  onClick: o(l).update.close
2442
2449
  }, {
2443
2450
  default: m(() => [
2444
- $(O(o(y).tCurd("close")), 1)
2451
+ $(O(o(b).tCurd("close")), 1)
2445
2452
  ]),
2446
2453
  _: 1
2447
2454
  }, 8, ["onClick"]),
2448
- o(l).update.type !== o(u).View ? (f(), h(o(A), {
2455
+ o(l).update.type !== o(f).View ? (u(), h(o(M), {
2449
2456
  key: 0,
2450
2457
  type: "primary",
2451
2458
  onClick: o(l).update.submit,
2452
2459
  loading: o(l).update.loading
2453
2460
  }, {
2454
2461
  default: m(() => [
2455
- $(O(o(y).tCurd("submit")), 1)
2462
+ $(O(o(b).tCurd("submit")), 1)
2456
2463
  ]),
2457
2464
  _: 1
2458
2465
  }, 8, ["onClick", "loading"])) : k("", !0)
@@ -2470,45 +2477,45 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2470
2477
  size: i.option.size?.form
2471
2478
  }, {
2472
2479
  default: m(() => [
2473
- o(l).update.showContent ? (f(!0), b(S, { key: 0 }, T(o(l).update.formColumn, (n) => (f(), b(S, null, [
2480
+ o(l).update.showContent ? (u(!0), y(S, { key: 0 }, A(o(l).update.formColumn, (n) => (u(), y(S, null, [
2474
2481
  o(r)(
2475
2482
  (() => {
2476
2483
  const d = [], V = (w) => {
2477
- w?.item?.children ? V(w.item.children) : d.push(...w.map((M) => M.item?.show?.form));
2484
+ w?.item?.children ? V(w.item.children) : d.push(...w.map((T) => T.item?.show?.form));
2478
2485
  };
2479
2486
  return V(n), d;
2480
2487
  })(),
2481
2488
  o(l).update.form,
2482
2489
  o(l).update.type
2483
- ) ? (f(), b("div", {
2490
+ ) ? (u(), y("div", {
2484
2491
  key: 0,
2485
2492
  class: j(["row curd-row", {
2486
2493
  stripe: i.option.form?.stripe === void 0 ? !0 : i.option.form?.stripe
2487
2494
  }])
2488
2495
  }, [
2489
- C(p.$slots, "form-start", {
2496
+ C(c.$slots, "form-start", {
2490
2497
  row: o(l).update.form
2491
2498
  }),
2492
- (f(!0), b(S, null, T(n, (d) => (f(), b(S, null, [
2493
- o(r)(d.item.show?.form, o(l).update.form, o(l).update.type) ? (f(), b("div", {
2499
+ (u(!0), y(S, null, A(n, (d) => (u(), y(S, null, [
2500
+ o(r)(d.item.show?.form, o(l).update.form, o(l).update.type) ? (u(), y("div", {
2494
2501
  key: 0,
2495
2502
  class: j([d.item.form.span > 0 ? `col-${o(l).getColumnSpan(d, n)}` : "col", `form-item-col-${d.item.key}`])
2496
2503
  }, [
2497
- (f(!0), b(S, null, T(d.item.children ? d.children : [d], (V) => (f(), h(_e, {
2504
+ (u(!0), y(S, null, A(d.item.children ? d.children : [d], (V) => (u(), h(et, {
2498
2505
  key: V.item.key,
2499
2506
  conf: o(l),
2500
2507
  item: V
2501
2508
  }, oe({ _: 2 }, [
2502
- T(p.$slots, (w, M) => ({
2503
- name: M,
2509
+ A(c.$slots, (w, T) => ({
2510
+ name: T,
2504
2511
  fn: m((B) => [
2505
- C(p.$slots, M, v({ ref_for: !0 }, B || {}))
2512
+ C(c.$slots, T, v({ ref_for: !0 }, B || {}))
2506
2513
  ])
2507
2514
  }))
2508
2515
  ]), 1032, ["conf", "item"]))), 128))
2509
2516
  ], 2)) : k("", !0)
2510
2517
  ], 64))), 256)),
2511
- C(p.$slots, "form-end", {
2518
+ C(c.$slots, "form-end", {
2512
2519
  row: o(l).update.form
2513
2520
  })
2514
2521
  ], 2)) : k("", !0)
@@ -2521,31 +2528,31 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2521
2528
  }, 16, ["modelValue", "title", "before-close"]),
2522
2529
  z(o(ee), {
2523
2530
  modelValue: o(l).remove.show,
2524
- "onUpdate:modelValue": c[10] || (c[10] = (n) => o(l).remove.show = n),
2531
+ "onUpdate:modelValue": p[10] || (p[10] = (n) => o(l).remove.show = n),
2525
2532
  title: o(l).remove.title,
2526
2533
  "close-on-click-modal": !1
2527
2534
  }, {
2528
2535
  footer: m(() => [
2529
- F("span", ft, [
2536
+ F("span", pt, [
2530
2537
  z(o(K), {
2531
2538
  size: i.option.size?.form
2532
2539
  }, {
2533
2540
  default: m(() => [
2534
- z(o(A), {
2541
+ z(o(M), {
2535
2542
  onClick: o(l).remove.close
2536
2543
  }, {
2537
2544
  default: m(() => [
2538
- $(O(o(y).tCurd("close")), 1)
2545
+ $(O(o(b).tCurd("close")), 1)
2539
2546
  ]),
2540
2547
  _: 1
2541
2548
  }, 8, ["onClick"]),
2542
- z(o(A), {
2549
+ z(o(M), {
2543
2550
  type: "danger",
2544
2551
  onClick: o(l).remove.submit,
2545
2552
  loading: o(l).remove.loading
2546
2553
  }, {
2547
2554
  default: m(() => [
2548
- $(O(o(y).tCurd("confirmDelete")), 1)
2555
+ $(O(o(b).tCurd("confirmDelete")), 1)
2549
2556
  ]),
2550
2557
  _: 1
2551
2558
  }, 8, ["onClick", "loading"])
@@ -2555,7 +2562,7 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2555
2562
  ])
2556
2563
  ]),
2557
2564
  default: m(() => [
2558
- F("div", null, O(o(y).tCurd("confirmDeleteMessage", o(l).remove.items.length)), 1)
2565
+ F("div", null, O(o(b).tCurd("confirmDeleteMessage", o(l).remove.items.length)), 1)
2559
2566
  ]),
2560
2567
  _: 1
2561
2568
  }, 8, ["modelValue", "title"]),
@@ -2568,32 +2575,32 @@ const Je = /* @__PURE__ */ pe(Ke, [["render", He]]), We = { class: "row flex-cen
2568
2575
  };
2569
2576
  }
2570
2577
  });
2571
- class yt {
2578
+ class bt {
2572
2579
  /**
2573
2580
  * 通过远程 URL 下载文件,自动创建临时 `<a>` 标签触发浏览器下载
2574
2581
  *
2575
2582
  * @param href - 文件的远程地址
2576
2583
  * @param name - 下载后的文件名,默认 `'download.png'`
2577
2584
  */
2578
- static async download(a, u = "download.png") {
2585
+ static async download(a, f = "download.png") {
2579
2586
  const t = document.createElement("a");
2580
- t.style.display = "none", t.href = a, t.setAttribute("download", u), typeof t.download > "u" && t.setAttribute("target", "_blank"), document.body.appendChild(t), t.click(), document.body.removeChild(t), window.URL.revokeObjectURL(a);
2587
+ t.style.display = "none", t.href = a, t.setAttribute("download", f), typeof t.download > "u" && t.setAttribute("target", "_blank"), document.body.appendChild(t), t.click(), document.body.removeChild(t), window.URL.revokeObjectURL(a);
2581
2588
  }
2582
2589
  /**
2583
2590
  * 将json对象或者json数组导出为json文件保存
2584
2591
  * @param data
2585
2592
  * @param name
2586
2593
  */
2587
- static exportJSONFile = (a, u) => {
2594
+ static exportJSONFile = (a, f) => {
2588
2595
  const t = new Blob([JSON.stringify(a)], { type: "application/json" }), r = URL.createObjectURL(t), l = document.createElement("a");
2589
- l.href = r, l.download = `${u || "config"}.json`, l.click();
2596
+ l.href = r, l.download = `${f || "config"}.json`, l.click();
2590
2597
  };
2591
2598
  /**
2592
2599
  * 导入文件内容,默认为json
2593
2600
  * @param param
2594
2601
  * @returns
2595
2602
  */
2596
- static importFile = async (a) => new Promise((u, t) => {
2603
+ static importFile = async (a) => new Promise((f, t) => {
2597
2604
  const r = document.createElement("input");
2598
2605
  r.type = "file";
2599
2606
  const l = a?.accept || ".json";
@@ -2603,36 +2610,36 @@ class yt {
2603
2610
  U.fail("未选择文件"), t("未选择文件");
2604
2611
  return;
2605
2612
  }
2606
- const p = new FileReader();
2607
- p.onload = async (c) => {
2608
- const g = l == ".json" ? JSON.parse(c.target.result) : c.target.result;
2609
- u(g);
2610
- }, p.onerror = () => {
2613
+ const c = new FileReader();
2614
+ c.onload = async (p) => {
2615
+ const g = l == ".json" ? JSON.parse(p.target.result) : p.target.result;
2616
+ f(g);
2617
+ }, c.onerror = () => {
2611
2618
  U.fail("文件读取失败"), t("文件读取失败");
2612
- }, p.readAsText(s), document.body.removeChild(r);
2619
+ }, c.readAsText(s), document.body.removeChild(r);
2613
2620
  }, document.body.appendChild(r), r.click();
2614
2621
  });
2615
2622
  }
2616
- const ct = (i, a) => {
2617
- if (i.component("TCurd", pt), i.component("TFormList", ne), i.component("TColumn", Me), a?.customComponent) {
2623
+ const mt = (i, a) => {
2624
+ if (i.component("TCurd", ct), i.component("TFormList", ne), i.component("TColumn", Te), a?.customComponent) {
2618
2625
  L.customComponent = a.customComponent;
2619
- for (const u in a.customComponent)
2620
- i.component(u, a.customComponent[u]);
2626
+ for (const f in a.customComponent)
2627
+ i.component(f, a.customComponent[f]);
2621
2628
  }
2622
- }, bt = {
2623
- install: ct
2629
+ }, wt = {
2630
+ install: mt
2624
2631
  };
2625
2632
  export {
2626
2633
  P as ArrUtil,
2627
- Ae as ExcelUtil,
2628
- Me as TColumn,
2629
- pt as TCurd,
2630
- yt as TFile,
2634
+ Me as ExcelUtil,
2635
+ Te as TColumn,
2636
+ ct as TCurd,
2637
+ bt as TFile,
2631
2638
  L as TForm,
2632
2639
  E as TFormConfig,
2633
- y as TFormI18n,
2640
+ b as TFormI18n,
2634
2641
  ne as TFormList,
2635
2642
  U as TSys,
2636
- bt as default,
2637
- ct as install
2643
+ wt as default,
2644
+ mt as install
2638
2645
  };