cc1-form 1.1.29 → 1.1.31

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,7 +1,7 @@
1
1
  import { ElMessage as de, ElLoading as ue, ElForm as Q, ElFormItem as W, ElInput as q, ElSwitch as ee, ElSelect as H, ElOption as N, ElTreeSelect as ae, ElDatePicker as te, ElDialog as Y, ElButton as M, ElTableColumn as Z, ElRadioGroup as ce, ElRadio as fe, ElDropdown as pe, ElDropdownMenu as me, ElDropdownItem as X, ElTable as he, ElPagination as be } from "element-plus";
2
2
  import "vue-router";
3
- import { defineComponent as J, reactive as oe, onMounted as ne, resolveComponent as x, createElementBlock as g, createCommentVNode as C, openBlock as c, renderSlot as k, createElementVNode as O, createVNode as E, withCtx as h, createTextVNode as V, Fragment as $, renderList as I, createBlock as b, normalizeClass as A, normalizeStyle as ie, ref as B, nextTick as ye, unref as l, mergeProps as v, toHandlers as F, resolveDynamicComponent as G, toDisplayString as S, getCurrentInstance as ge, createSlots as _, withKeys as we, resolveDirective as ke, withDirectives as Ce, normalizeProps as ve, guardReactiveProps as Ve } from "vue";
4
- class D {
3
+ import { defineComponent as J, reactive as oe, onMounted as ne, resolveComponent as x, createElementBlock as g, createCommentVNode as C, openBlock as c, renderSlot as k, createElementVNode as O, createVNode as D, withCtx as h, createTextVNode as E, Fragment as S, renderList as I, createBlock as b, normalizeClass as A, normalizeStyle as ie, ref as B, nextTick as ye, unref as l, mergeProps as v, toHandlers as F, resolveDynamicComponent as G, toDisplayString as U, getCurrentInstance as ge, createSlots as _, withKeys as we, resolveDirective as ke, withDirectives as Ce, normalizeProps as ve, guardReactiveProps as Ve } from "vue";
4
+ class $ {
5
5
  /**
6
6
  * Vue Router 实例,需在应用初始化时赋值
7
7
  */
@@ -43,9 +43,9 @@ class D {
43
43
  * @param module
44
44
  */
45
45
  static loadModule = async (o) => {
46
- if (!D.moduleObj[o])
46
+ if (!$.moduleObj[o])
47
47
  throw new Error(`模块${o}未加载,请赋值如:TSys.moduleObj = { ${o}: ()=>import('${o}') }`);
48
- const s = await D.moduleObj[o]();
48
+ const s = await $.moduleObj[o]();
49
49
  return s.default ?? s;
50
50
  };
51
51
  /**
@@ -133,7 +133,7 @@ class D {
133
133
  */
134
134
  static getImgPic = (o) => new Promise(async (s, e) => {
135
135
  let n = document.getElementById(o.id);
136
- const t = await D.loadModule("html2canvas");
136
+ const t = await $.loadModule("html2canvas");
137
137
  try {
138
138
  t(n, {
139
139
  logging: !1,
@@ -154,16 +154,9 @@ class D {
154
154
  }
155
155
  });
156
156
  }
157
- class U {
157
+ class V {
158
158
  /**
159
159
  * 全局配置对象
160
- *
161
- * - `tableRowKey` — 数据行的主键字段名,默认 `'_id'`,影响删除、编辑时的主键识别
162
- * - `page.num` — 分页请求中「页码」的参数名,默认 `'num'`
163
- * - `page.size` — 分页请求中「每页条数」的参数名,默认 `'size'`
164
- * - `result.list` — API 返回数据中「列表」的字段名,默认 `'list'`
165
- * - `result.total` — API 返回数据中「总条数」的字段名,默认 `'total'`
166
- * - `table.click.color` — 表格中可点击文本的颜色,默认 `'#409EFF'`
167
160
  */
168
161
  static config = {
169
162
  /** 全局分页字段 */
@@ -184,6 +177,17 @@ class U {
184
177
  width: "980px",
185
178
  closeOnClickModal: !1
186
179
  },
180
+ /** 全局分页配置 */
181
+ pagination: {
182
+ /** 分页布局 默认'total, sizes, prev, pager, next, jumper' */
183
+ layout: "total, sizes, prev, pager, next, jumper",
184
+ /** 每页条数列表 默认[10, 20, 50, 100] */
185
+ pageSizes: [10, 20, 50, 100],
186
+ /** 每页条数 默认10 */
187
+ size: 10,
188
+ /** 分页器计数 默认7 */
189
+ pagerCount: 7
190
+ },
187
191
  /** 工具栏配置 */
188
192
  tools: {
189
193
  /**
@@ -462,10 +466,10 @@ class U {
462
466
  * @param config - 需要覆盖的配置项(深度 Partial)
463
467
  */
464
468
  static setConfig = (o) => {
465
- U.config = ObjectUtil.deepMerge(U.config, o);
469
+ V.config = ObjectUtil.deepMerge(V.config, o);
466
470
  };
467
471
  }
468
- class z {
472
+ class T {
469
473
  /**
470
474
  * 自定义组件映射表,key 为组件名(同时作为 column.type 值),value 为 Vue 组件定义
471
475
  *
@@ -504,7 +508,7 @@ class z {
504
508
  )
505
509
  */
506
510
  static setOptionsData = (o, s, e) => {
507
- const n = z.findOptions(o, s);
511
+ const n = T.findOptions(o, s);
508
512
  n && (n.data = e);
509
513
  };
510
514
  static form = {
@@ -517,8 +521,8 @@ class z {
517
521
  * @param option 组件配置
518
522
  */
519
523
  parentId: (o, s, e, n) => {
520
- const t = U.config.table.rowKey;
521
- o ? s.type === D.EDialog.Insert ? (s.form.parentId = o[t], s.form.sort = o.children.length + 1) : s.form.parentId = o.parentId.substring(o.parentId.lastIndexOf(",") + 1) : (s.form.parentId = "0", s.form.sort = e.length + 1), z.setOptionsData(n, "parentId", [{ [t]: "0", title: "根", children: e }]);
524
+ const t = V.config.table.rowKey;
525
+ o ? s.type === $.EDialog.Insert ? (s.form.parentId = o[t], s.form.sort = o.children.length + 1) : s.form.parentId = o.parentId.substring(o.parentId.lastIndexOf(",") + 1) : (s.form.parentId = "0", s.form.sort = e.length + 1), T.setOptionsData(n, "parentId", [{ [t]: "0", title: "根", children: e }]);
522
526
  }
523
527
  }
524
528
  };
@@ -535,7 +539,7 @@ class R {
535
539
  */
536
540
  static setId = (o, s, e) => {
537
541
  s[o] || (s[o] = []);
538
- const n = U.config.table.rowKey;
542
+ const n = V.config.table.rowKey;
539
543
  s[o].forEach((t) => {
540
544
  e.forEach((a) => {
541
545
  let d = a.default ?? "";
@@ -553,7 +557,7 @@ class R {
553
557
  static add = (o, s, e, n) => {
554
558
  const t = JSONUtil.cp(e);
555
559
  R.setId(o, s, e);
556
- const a = U.config.table.rowKey;
560
+ const a = V.config.table.rowKey;
557
561
  s[o].push(
558
562
  t.reduce(
559
563
  (d, p) => {
@@ -572,7 +576,7 @@ class R {
572
576
  * @param callback 回调函数
573
577
  */
574
578
  static remove = (o, s, e, n) => {
575
- const t = U.config.table.rowKey;
579
+ const t = V.config.table.rowKey;
576
580
  s[o] = s[o].filter((a) => a[t] !== e[t]), n?.(s);
577
581
  };
578
582
  /**
@@ -582,7 +586,7 @@ class R {
582
586
  * @returns 没有id的数据
583
587
  */
584
588
  static getNoIdData = (o, s) => {
585
- const e = JSONUtil.cp(o), n = U.config.table.rowKey;
589
+ const e = JSONUtil.cp(o), n = V.config.table.rowKey;
586
590
  return e.forEach((t) => {
587
591
  t[n] && delete t[n], s && t[s] && R.getNoIdData(t[s], s);
588
592
  }), e;
@@ -653,23 +657,23 @@ const Ee = {
653
657
  return e.show ? (c(), g("div", Ee, [
654
658
  k(t.$slots, "list-start", { row: r.row }),
655
659
  O("div", null, [
656
- E(d, {
660
+ D(d, {
657
661
  link: "",
658
662
  type: "primary",
659
663
  onClick: a[0] || (a[0] = (m) => e.add(r.field, r.row, r.itemFields))
660
664
  }, {
661
665
  default: h(() => a[2] || (a[2] = [
662
- V("添加")
666
+ E("添加")
663
667
  ])),
664
668
  _: 1
665
669
  })
666
670
  ]),
667
- (c(!0), g($, null, I(r.row[r.field], (m) => (c(), g("div", De, [
671
+ (c(!0), g(S, null, I(r.row[r.field], (m) => (c(), g("div", De, [
668
672
  k(t.$slots, "item-start", {
669
673
  item: m,
670
674
  row: r.row
671
675
  }),
672
- (c(!0), g($, null, I(r.itemFields, (u) => (c(), b(p, {
676
+ (c(!0), g(S, null, I(r.itemFields, (u) => (c(), b(p, {
673
677
  modelValue: m[u.value],
674
678
  "onUpdate:modelValue": (i) => m[u.value] = i,
675
679
  style: ie({ width: r.inputWidth }),
@@ -681,13 +685,13 @@ const Ee = {
681
685
  item: m,
682
686
  row: r.row
683
687
  }),
684
- E(d, {
688
+ D(d, {
685
689
  link: "",
686
690
  type: "danger",
687
691
  onClick: (u) => e.remove(r.field, r.row, m)
688
692
  }, {
689
693
  default: h(() => a[3] || (a[3] = [
690
- V("删除")
694
+ E("删除")
691
695
  ])),
692
696
  _: 2
693
697
  }, 1032, ["onClick"])
@@ -713,7 +717,7 @@ const Ee = {
713
717
  }
714
718
  },
715
719
  setup(r, { expose: o }) {
716
- const s = D.isFun, e = D.EDialog, n = B(), t = r, a = oe({
720
+ const s = $.isFun, e = $.EDialog, n = B(), t = r, a = oe({
717
721
  rules: {},
718
722
  show: !0,
719
723
  form: {},
@@ -729,8 +733,8 @@ const Ee = {
729
733
  if (a.formDefault[w.key] = w.value, w.isForm) {
730
734
  w.form = w.form || { span: u }, w.form.span = w.form.span ?? u;
731
735
  let L = w.form.span, j = i.reduce((P, se) => P + se.span, L);
732
- const T = i.length;
733
- i.push({ item: w, span: L }), (T === 1 && i[0].span === 0 || j >= m || L === 0 && T > 1) && (p.push(i), i = []), w.rules && (a.rules[w.key] = w.rules);
736
+ const z = i.length;
737
+ i.push({ item: w, span: L }), (z === 1 && i[0].span === 0 || j >= m || L === 0 && z > 1) && (p.push(i), i = []), w.rules && (a.rules[w.key] = w.rules);
734
738
  }
735
739
  };
736
740
  d.column.forEach((w) => {
@@ -751,16 +755,16 @@ const Ee = {
751
755
  rules: a.rules
752
756
  }, {
753
757
  default: h(() => [
754
- a.show ? (c(!0), g($, { key: 0 }, I(a.formColumn, (m) => (c(), g("div", $e, [
758
+ a.show ? (c(!0), g(S, { key: 0 }, I(a.formColumn, (m) => (c(), g("div", $e, [
755
759
  k(d.$slots, "form-start", {
756
760
  row: a.form
757
761
  }),
758
- (c(!0), g($, null, I(m, (u) => (c(), g($, null, [
762
+ (c(!0), g(S, null, I(m, (u) => (c(), g(S, null, [
759
763
  l(s)(u.item.show?.form, a.form) ?? !0 ? (c(), g("div", {
760
764
  key: 0,
761
765
  class: A(u.item.form.span > 0 ? `col-${u.item.form.span}` : "col")
762
766
  }, [
763
- E(l(W), {
767
+ D(l(W), {
764
768
  label: u.item.label,
765
769
  prop: u.item.key,
766
770
  "label-width": u.item.form?.labelWidth || "100px"
@@ -798,7 +802,7 @@ const Ee = {
798
802
  style: { width: "100%" }
799
803
  }), {
800
804
  default: h(() => [
801
- (c(!0), g($, null, I(u.item.options?.select?.data, (i) => (c(), b(l(N), {
805
+ (c(!0), g(S, null, I(u.item.options?.select?.data, (i) => (c(), b(l(N), {
802
806
  key: i.value,
803
807
  label: i.label,
804
808
  value: i.value
@@ -828,7 +832,7 @@ const Ee = {
828
832
  ref_for: !0
829
833
  }, u.item.options?.datetime, F(u.item.options?.datetime?.on || {}), {
830
834
  disabled: a.getDisabled(u.item)
831
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type && l(z).customComponent[u.item.type] ? (c(), b(G(l(z).customComponent[u.item.type]), v({
835
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : u.item.type && l(T).customComponent[u.item.type] ? (c(), b(G(l(T).customComponent[u.item.type]), v({
832
836
  key: 6,
833
837
  modelValue: a.form[u.item.key],
834
838
  "onUpdate:modelValue": (i) => a.form[u.item.key] = i,
@@ -917,7 +921,7 @@ class Oe {
917
921
  */
918
922
  static exportToExcel = async (o, s, e) => {
919
923
  if (!o || o.length === 0) return;
920
- const n = await D.loadModule("xlsx"), t = o.map((p) => {
924
+ const n = await $.loadModule("xlsx"), t = o.map((p) => {
921
925
  const m = {};
922
926
  return s.forEach((u) => {
923
927
  m[u.label] = p[u.key];
@@ -926,7 +930,7 @@ class Oe {
926
930
  n.utils.book_append_sheet(d, a, "Sheet1"), e ? typeof e == "function" && (e = e()) : e = `导出数据_${(/* @__PURE__ */ new Date()).Format("yyyy-MM-dd")}_${(/* @__PURE__ */ new Date()).getTime()}`, n.writeFile(d, `${e}.xlsx`);
927
931
  };
928
932
  }
929
- const K = D.EDialog, Fe = (r) => {
933
+ const K = $.EDialog, Fe = (r) => {
930
934
  const o = B(), s = B(), e = oe({
931
935
  /** 查询区域相关配置对象 */
932
936
  search: {
@@ -964,16 +968,18 @@ const K = D.EDialog, Fe = (r) => {
964
968
  },
965
969
  /** 分页区域相关配置对象 */
966
970
  page: {
967
- /** 当前每页条数 */
968
- size: r.option.page?.size || 10,
969
- /** 支持切换的每页条数选项 */
970
- sizeList: r.option.page?.sizeList || [10, 20, 50, 100],
971
971
  /** 当前页码 */
972
972
  num: 1,
973
973
  /** 总条数 */
974
974
  total: 0,
975
975
  /** 分页控件的布局方式 */
976
- layout: r.option.page?.layout || "total, sizes, prev, pager, next, jumper"
976
+ layout: r.option.page?.layout || V.config.pagination.layout,
977
+ /** 当前每页条数 */
978
+ size: r.option.page?.size || V.config.pagination.size,
979
+ /** 支持切换的每页条数选项 */
980
+ sizeList: r.option.page?.sizeList || V.config.pagination.pageSizes,
981
+ /** 分页器计数 */
982
+ pagerCount: r.option.page?.pagerCount || V.config.pagination.pagerCount
977
983
  },
978
984
  /** 表格区域相关配置对象 */
979
985
  table: {
@@ -1031,22 +1037,22 @@ const K = D.EDialog, Fe = (r) => {
1031
1037
  await e.initApiData("init");
1032
1038
  let t = {};
1033
1039
  if (e.table.sort.prop) {
1034
- const { props: f, order: w } = U.config.table.sort;
1040
+ const { props: f, order: w } = V.config.table.sort;
1035
1041
  t = {
1036
1042
  [f.field]: e.table.sort.prop,
1037
1043
  [w.field]: e.table.sort.order
1038
1044
  };
1039
1045
  }
1040
1046
  const a = await n({
1041
- [U.config.page.size]: e.page.size,
1042
- [U.config.page.num]: e.page.num,
1047
+ [V.config.page.size]: e.page.size,
1048
+ [V.config.page.num]: e.page.num,
1043
1049
  ...e.search.getFormData(),
1044
1050
  ...t
1045
- }), d = U.config.result, p = a.data || { [d.list]: a };
1051
+ }), d = V.config.result, p = a.data || { [d.list]: a };
1046
1052
  let m = (Array.isArray(p[d.list]), p[d.list]);
1047
1053
  const u = e.update.formColumn.flat(), i = JSONUtil.cp(m).map((f) => (Object.keys(f).forEach((L) => {
1048
- const j = u.find((T) => T.item.key === L);
1049
- j && ["select", "radio"].includes(j.item.type) && (j.item.table.format || (j.item.table.format = (T) => j.item.options[j.item.type].data?.find((P) => P.value == T[L])?.label || T[L]));
1054
+ const j = u.find((z) => z.item.key === L);
1055
+ j && ["select", "radio"].includes(j.item.type) && (j.item.table.format || (j.item.table.format = (z) => j.item.options[j.item.type].data?.find((P) => P.value == z[L])?.label || z[L]));
1050
1056
  }), f));
1051
1057
  e.table.data = r.option.data ? await r.option.data(i, m) : i, e.page.total = p[d.total] || 0;
1052
1058
  } catch (t) {
@@ -1072,8 +1078,8 @@ const K = D.EDialog, Fe = (r) => {
1072
1078
  order: "",
1073
1079
  /** 排序变更回调 */
1074
1080
  change: (n) => {
1075
- U.config.table.sort.resetPage && (e.page.num = 1);
1076
- const t = U.config.table.sort;
1081
+ V.config.table.sort.resetPage && (e.page.num = 1);
1082
+ const t = V.config.table.sort;
1077
1083
  if (t.change) {
1078
1084
  t.change(n, e);
1079
1085
  return;
@@ -1098,13 +1104,13 @@ const K = D.EDialog, Fe = (r) => {
1098
1104
  /** 获取当前选中项进行导出 */
1099
1105
  select: () => {
1100
1106
  if (e.table.selection.list.length === 0)
1101
- throw D.fail(y.tCurd("selectDataToExport")), new Error(y.tCurd("selectDataToExport"));
1107
+ throw $.fail(y.tCurd("selectDataToExport")), new Error(y.tCurd("selectDataToExport"));
1102
1108
  return e.table.selection.list;
1103
1109
  },
1104
1110
  /** 导出当前页的数据 */
1105
1111
  page: () => {
1106
1112
  if (e.table.data.length === 0)
1107
- throw D.fail(y.tCurd("noData")), new Error(y.tCurd("noData"));
1113
+ throw $.fail(y.tCurd("noData")), new Error(y.tCurd("noData"));
1108
1114
  return e.table.data;
1109
1115
  },
1110
1116
  /** 导出所有数据 */
@@ -1113,17 +1119,17 @@ const K = D.EDialog, Fe = (r) => {
1113
1119
  try {
1114
1120
  if (r.option.tools?.export?.all) {
1115
1121
  await r.option.tools?.export?.all({
1116
- [U.config.page.size]: e.page.size,
1117
- [U.config.page.num]: e.page.num,
1122
+ [V.config.page.size]: e.page.size,
1123
+ [V.config.page.num]: e.page.num,
1118
1124
  ...e.search.getFormData()
1119
1125
  });
1120
1126
  return;
1121
1127
  }
1122
1128
  const n = r.option.api.list, t = await n({
1123
- [U.config.page.size]: 999999,
1124
- [U.config.page.num]: 1
1129
+ [V.config.page.size]: 999999,
1130
+ [V.config.page.num]: 1
1125
1131
  });
1126
- return (t.data || { [U.config.result.list]: t })[U.config.result.list];
1132
+ return (t.data || { [V.config.result.list]: t })[V.config.result.list];
1127
1133
  } catch (n) {
1128
1134
  console.error(n);
1129
1135
  } finally {
@@ -1180,7 +1186,7 @@ const K = D.EDialog, Fe = (r) => {
1180
1186
  /** 打开增改弹窗 */
1181
1187
  open: (n, t) => {
1182
1188
  e.update.showContent || FunUtil.throttle(async () => {
1183
- D.loading(!0);
1189
+ $.loading(!0);
1184
1190
  try {
1185
1191
  await e.initApiData("update");
1186
1192
  const a = n === K.Insert;
@@ -1192,7 +1198,7 @@ const K = D.EDialog, Fe = (r) => {
1192
1198
  } catch (a) {
1193
1199
  console.error(a);
1194
1200
  } finally {
1195
- D.loading(!1);
1201
+ $.loading(!1);
1196
1202
  }
1197
1203
  });
1198
1204
  },
@@ -1200,7 +1206,7 @@ const K = D.EDialog, Fe = (r) => {
1200
1206
  submit: () => {
1201
1207
  FunUtil.throttle(async () => {
1202
1208
  await s.value?.validate(async (d, p) => new Promise((m, u) => {
1203
- d || (D.fail(y.tCurd("checkFormData")), u(!1)), m();
1209
+ d || ($.fail(y.tCurd("checkFormData")), u(!1)), m();
1204
1210
  })), e.update.loading = !0;
1205
1211
  const n = e.update.type === K.Insert ? r.option.api.create : r.option.api.update;
1206
1212
  let t = JSONUtil.cp(e.update.form);
@@ -1256,7 +1262,7 @@ const K = D.EDialog, Fe = (r) => {
1256
1262
  delete t.children;
1257
1263
  try {
1258
1264
  if (!n) return;
1259
- await n({ ...t }), e.inlineEdit.close(), await e.table.getList(), D.success(y.tCurd("operationSuccess"));
1265
+ await n({ ...t }), e.inlineEdit.close(), await e.table.getList(), $.success(y.tCurd("operationSuccess"));
1260
1266
  } catch (a) {
1261
1267
  console.error(a);
1262
1268
  } finally {
@@ -1282,7 +1288,7 @@ const K = D.EDialog, Fe = (r) => {
1282
1288
  /** 打开删除弹窗并设置待删除项 */
1283
1289
  open: (n) => {
1284
1290
  if (n.length === 0) {
1285
- D.fail(y.tCurd("selectDataToDelete"));
1291
+ $.fail(y.tCurd("selectDataToDelete"));
1286
1292
  return;
1287
1293
  }
1288
1294
  e.remove.items = n, e.remove.show = !0;
@@ -1297,7 +1303,7 @@ const K = D.EDialog, Fe = (r) => {
1297
1303
  await n({
1298
1304
  [r.option.table?.rowKey]: e.remove.items.map((t) => t[r.option.table?.rowKey]),
1299
1305
  items: e.remove.items
1300
- }), D.success(y.tCurd("operationSuccess")), e.table.data.length <= 1 && e.page.num > 1 && (e.page.num -= 1), e.remove.close(), await e.table.getList();
1306
+ }), $.success(y.tCurd("operationSuccess")), e.table.data.length <= 1 && e.page.num > 1 && (e.page.num -= 1), e.remove.close(), await e.table.getList();
1301
1307
  } catch (t) {
1302
1308
  console.error(t);
1303
1309
  } finally {
@@ -1340,7 +1346,7 @@ const K = D.EDialog, Fe = (r) => {
1340
1346
  },
1341
1347
  /** 初始化curd配置(option默认值合并等) */
1342
1348
  initCurdConfig: () => {
1343
- const n = JSONUtil.cp(U.config);
1349
+ const n = JSONUtil.cp(V.config);
1344
1350
  n.table.emptyText = y.tCurd("noData");
1345
1351
  const t = ObjectUtil.deepMerge(n, r.option || {});
1346
1352
  Object.keys(t).forEach((a) => {
@@ -1353,7 +1359,7 @@ const K = D.EDialog, Fe = (r) => {
1353
1359
  * @returns
1354
1360
  */
1355
1361
  initColumnOptions: () => {
1356
- let n = JSONUtil.cp(U.config.columnConfig);
1362
+ let n = JSONUtil.cp(V.config.columnConfig);
1357
1363
  n.options = ObjectUtil.deepMerge(n.options, {
1358
1364
  switch: {
1359
1365
  activeLabel: y.tCurd("switchOn"),
@@ -1381,7 +1387,7 @@ const K = D.EDialog, Fe = (r) => {
1381
1387
  final(u, i, f) {
1382
1388
  e.table.loading = !1;
1383
1389
  }
1384
- }), e.table.loading = !1, D.success(y.tCurd("operationSuccess")), e.table.getList(), !0) : void 0;
1390
+ }), e.table.loading = !1, $.success(y.tCurd("operationSuccess")), e.table.getList(), !0) : void 0;
1385
1391
  } catch (u) {
1386
1392
  return console.error(u), !1;
1387
1393
  } finally {
@@ -1396,7 +1402,7 @@ const K = D.EDialog, Fe = (r) => {
1396
1402
  },
1397
1403
  getColumnSpan: (n, t) => {
1398
1404
  if (n.item.form?.spanCol) {
1399
- const a = U.config.form.defaultSpan, p = t.filter((m) => !D.isFun(m.item.show?.form, e.update.form, e.update.type)).reduce((m, u) => m + (u.item.form?.span || a), 0);
1405
+ const a = V.config.form.defaultSpan, p = t.filter((m) => !$.isFun(m.item.show?.form, e.update.form, e.update.type)).reduce((m, u) => m + (u.item.form?.span || a), 0);
1400
1406
  return (n.item?.form.span || a) + p;
1401
1407
  }
1402
1408
  return n.item.form.span;
@@ -1419,13 +1425,13 @@ const K = D.EDialog, Fe = (r) => {
1419
1425
  }
1420
1426
  if (e.update.formDefault[f.key] = f.value, f.table.table && (f.show.table && e.table.column.show.list.push(f.key), f.table.table && e.table.column.show.listSource.push(f.key)), !(f.isForm && typeof f.show?.form == "boolean") || f.show?.form) {
1421
1427
  f.form = f.form || { span: d }, f.form.span = f.form.span ?? d;
1422
- let w = f.form.span, L = p.reduce((T, P) => T + P.span, w);
1428
+ let w = f.form.span, L = p.reduce((z, P) => z + P.span, w);
1423
1429
  const j = p.length;
1424
1430
  if (p.push({ item: f, span: w }), (j === 1 && p[0].span === 0 || L >= a || w === 0 && j > 1) && (t.push(p), p = []), f.rules) {
1425
- const T = {
1431
+ const z = {
1426
1432
  input: y.tCurd("placeholderInput"),
1427
1433
  select: y.tCurd("placeholderSelect")
1428
- }, P = (T[f.type] || T.input) + f.label;
1434
+ }, P = (z[f.type] || z.input) + f.label;
1429
1435
  e.update.rules[f.key] = typeof f.rules == "boolean" ? [
1430
1436
  {
1431
1437
  required: !0,
@@ -1477,25 +1483,25 @@ const K = D.EDialog, Fe = (r) => {
1477
1483
  }, {
1478
1484
  footer: h(() => [
1479
1485
  O("span", Me, [
1480
- E(l(M), { onClick: m }, {
1486
+ D(l(M), { onClick: m }, {
1481
1487
  default: h(() => i[1] || (i[1] = [
1482
- V("取消")
1488
+ E("取消")
1483
1489
  ])),
1484
1490
  _: 1
1485
1491
  }),
1486
- E(l(M), {
1492
+ D(l(M), {
1487
1493
  type: "primary",
1488
1494
  onClick: p
1489
1495
  }, {
1490
1496
  default: h(() => i[2] || (i[2] = [
1491
- V("确认")
1497
+ E("确认")
1492
1498
  ])),
1493
1499
  _: 1
1494
1500
  })
1495
1501
  ])
1496
1502
  ]),
1497
1503
  default: h(() => [
1498
- O("div", null, S(n.value), 1)
1504
+ O("div", null, U(n.value), 1)
1499
1505
  ]),
1500
1506
  _: 1
1501
1507
  }, 8, ["modelValue", "title"]));
@@ -1509,7 +1515,7 @@ const K = D.EDialog, Fe = (r) => {
1509
1515
  xmlns: "http://www.w3.org/2000/svg",
1510
1516
  viewBox: "0 0 1024 1024"
1511
1517
  };
1512
- function Te(r, o) {
1518
+ function ze(r, o) {
1513
1519
  return c(), g("svg", je, o[0] || (o[0] = [
1514
1520
  O("path", {
1515
1521
  fill: "currentColor",
@@ -1517,7 +1523,7 @@ function Te(r, o) {
1517
1523
  }, null, -1)
1518
1524
  ]));
1519
1525
  }
1520
- const ze = /* @__PURE__ */ re(Le, [["render", Te]]), Re = {}, Pe = {
1526
+ const Te = /* @__PURE__ */ re(Le, [["render", ze]]), Re = {}, Pe = {
1521
1527
  "data-v-58697b5c": "",
1522
1528
  xmlns: "http://www.w3.org/2000/svg",
1523
1529
  viewBox: "0 0 1024 1024"
@@ -1538,10 +1544,10 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1538
1544
  option: {}
1539
1545
  },
1540
1546
  setup(r) {
1541
- const o = D.isFun, s = ge().type;
1547
+ const o = $.isFun, s = ge().type;
1542
1548
  return (e, n) => {
1543
1549
  const t = x("el-tooltip");
1544
- return c(!0), g($, null, I(e.columnList, (a) => (c(), g($, {
1550
+ return c(!0), g(S, null, I(e.columnList, (a) => (c(), g(S, {
1545
1551
  key: a.key
1546
1552
  }, [
1547
1553
  e.conf.table.column.show.list.includes(a.key) ? (c(), b(l(Z), v({
@@ -1561,18 +1567,18 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1561
1567
  }, {
1562
1568
  default: h(() => [
1563
1569
  O("span", Be, [
1564
- E(Ke)
1570
+ D(Ke)
1565
1571
  ])
1566
1572
  ]),
1567
1573
  _: 2
1568
1574
  }, 1032, ["content"])) : C("", !0),
1569
- V(" " + S(a.label), 1)
1575
+ E(" " + U(a.label), 1)
1570
1576
  ])
1571
1577
  ])
1572
1578
  ]),
1573
1579
  default: h(({ row: d }) => [
1574
- a.children ? (c(), g($, { key: 0 }, [
1575
- n[0] || (n[0] = V("   ")),
1580
+ a.children ? (c(), g(S, { key: 0 }, [
1581
+ n[0] || (n[0] = E("   ")),
1576
1582
  (c(), b(G(l(s)), {
1577
1583
  conf: e.conf,
1578
1584
  columnList: a.children,
@@ -1585,8 +1591,8 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1585
1591
  ])
1586
1592
  }))
1587
1593
  ]), 1032, ["conf", "columnList", "option"]))
1588
- ], 64)) : (c(), g($, { key: 1 }, [
1589
- l(o)(a.show?.form, e.conf.inlineEdit.form, l(D).EDialog.Update) && e.option.table?.inlineEdit && e.conf.inlineEdit.row === d && (a.type === "input" || a.type === "select") ? (c(), g($, { key: 0 }, [
1594
+ ], 64)) : (c(), g(S, { key: 1 }, [
1595
+ l(o)(a.show?.form, e.conf.inlineEdit.form, l($).EDialog.Update) && e.option.table?.inlineEdit && e.conf.inlineEdit.row === d && (a.type === "input" || a.type === "select") ? (c(), g(S, { key: 0 }, [
1590
1596
  a.type === "input" ? (c(), b(l(q), v({
1591
1597
  key: 0,
1592
1598
  modelValue: e.conf.inlineEdit.form[a.key],
@@ -1606,7 +1612,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1606
1612
  style: { width: "100%" }
1607
1613
  }), {
1608
1614
  default: h(() => [
1609
- (c(!0), g($, null, I(a.options?.select?.data, (p) => (c(), b(l(N), {
1615
+ (c(!0), g(S, null, I(a.options?.select?.data, (p) => (c(), b(l(N), {
1610
1616
  key: p.value,
1611
1617
  label: p.label,
1612
1618
  value: p.value
@@ -1693,7 +1699,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1693
1699
  style: { width: "100%" }
1694
1700
  }), {
1695
1701
  default: h(() => [
1696
- (c(!0), g($, null, I(o.item.item.options?.select?.data, (e) => (c(), b(l(N), {
1702
+ (c(!0), g(S, null, I(o.item.item.options?.select?.data, (e) => (c(), b(l(N), {
1697
1703
  key: e.value,
1698
1704
  label: e.label,
1699
1705
  value: e.value
@@ -1709,7 +1715,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1709
1715
  style: { width: "100%" }
1710
1716
  }), {
1711
1717
  default: h(() => [
1712
- (c(!0), g($, null, I(o.item.item.options?.radio?.data, (e) => (c(), b(l(fe), {
1718
+ (c(!0), g(S, null, I(o.item.item.options?.radio?.data, (e) => (c(), b(l(fe), {
1713
1719
  key: e.value,
1714
1720
  label: e.label,
1715
1721
  value: e.value
@@ -1736,7 +1742,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1736
1742
  "onUpdate:modelValue": s[5] || (s[5] = (e) => o.conf.update.form[o.item.item.key] = e)
1737
1743
  }, o.item.item.options?.datetime, F(o.item.item.options?.datetime?.on || {}), {
1738
1744
  disabled: o.conf.update.getDisabled(o.item.item)
1739
- }), null, 16, ["modelValue", "disabled"])) : o.item.item.type && l(z).customComponent[o.item.item.type] ? (c(), b(G(l(z).customComponent[o.item.item.type]), v({
1745
+ }), null, 16, ["modelValue", "disabled"])) : o.item.item.type && l(T).customComponent[o.item.item.type] ? (c(), b(G(l(T).customComponent[o.item.item.type]), v({
1740
1746
  key: 7,
1741
1747
  modelValue: o.conf.update.form[o.item.item.key],
1742
1748
  "onUpdate:modelValue": s[6] || (s[6] = (e) => o.conf.update.form[o.item.item.key] = e)
@@ -1792,7 +1798,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1792
1798
  }
1793
1799
  },
1794
1800
  setup(r, { expose: o }) {
1795
- const s = D.EDialog, e = r, n = D.isFun, { conf: t, switchConfirmRef: a, ruleFormRef: d } = Fe(e);
1801
+ const s = $.EDialog, e = r, n = $.isFun, { conf: t, switchConfirmRef: a, ruleFormRef: d } = Fe(e);
1796
1802
  return o({
1797
1803
  conf: t
1798
1804
  }), (p, m) => {
@@ -1802,7 +1808,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1802
1808
  k(p.$slots, "box-left"),
1803
1809
  O("div", xe, [
1804
1810
  r.option.search?.show !== !1 ? (c(), g("div", _e, [
1805
- E(l(Q), {
1811
+ D(l(Q), {
1806
1812
  model: l(t).search.form,
1807
1813
  inline: ""
1808
1814
  }, {
@@ -1810,7 +1816,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1810
1816
  k(p.$slots, "search-start", {
1811
1817
  row: l(t).search.form
1812
1818
  }),
1813
- (c(!0), g($, null, I(l(t).search.column.list, (i) => (c(), g($, {
1819
+ (c(!0), g(S, null, I(l(t).search.column.list, (i) => (c(), g(S, {
1814
1820
  key: i.key
1815
1821
  }, [
1816
1822
  (typeof i.show?.search == "function" ? i.show?.search(l(t).search.form) : i.show?.search) ? (c(), b(l(W), {
@@ -1832,7 +1838,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1832
1838
  clearable: "",
1833
1839
  disabled: i.disabled?.search,
1834
1840
  ref_for: !0
1835
- }, i.options?.input, F(i.options?.input?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : i.type === "switch" ? (c(), b(l(H), v({
1841
+ }, i.options?.search?.input || i.options?.input, F(i.options?.search?.input?.on || i.options?.input?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "placeholder", "disabled"])) : i.type === "switch" ? (c(), b(l(H), v({
1836
1842
  key: 1,
1837
1843
  modelValue: l(t).search.form[i.key],
1838
1844
  "onUpdate:modelValue": (f) => l(t).search.form[i.key] = f,
@@ -1840,7 +1846,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1840
1846
  clearable: "",
1841
1847
  disabled: i.disabled?.search,
1842
1848
  ref_for: !0
1843
- }, i.options?.switch, F(i.options?.switch?.on || {})), {
1849
+ }, i.options?.search?.switch || i.options?.switch, F(i.options?.search?.switch?.on || i.options?.switch?.on || {})), {
1844
1850
  default: h(() => [
1845
1851
  (c(), b(l(N), {
1846
1852
  key: i.options?.switch?.activeValue,
@@ -1862,9 +1868,9 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1862
1868
  clearable: "",
1863
1869
  disabled: i.disabled?.search,
1864
1870
  ref_for: !0
1865
- }, i.options?.select, F(i.options?.select?.on || {})), {
1871
+ }, i.options?.search?.select || i.options?.select, F(i.options?.search?.select?.on || i.options?.select?.on || {})), {
1866
1872
  default: h(() => [
1867
- (c(!0), g($, null, I(i.options?.select?.data, (f) => (c(), b(l(N), {
1873
+ (c(!0), g(S, null, I(i.options?.select?.data, (f) => (c(), b(l(N), {
1868
1874
  key: f.value,
1869
1875
  label: f.label,
1870
1876
  value: f.value
@@ -1875,15 +1881,14 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1875
1881
  key: 3,
1876
1882
  modelValue: l(t).search.form[i.key],
1877
1883
  "onUpdate:modelValue": (f) => l(t).search.form[i.key] = f,
1884
+ disabled: i.disabled?.search,
1878
1885
  ref_for: !0
1879
- }, i.options?.datetime, F(i.options?.datetime?.on || {}), {
1880
- disabled: i.disabled?.search
1881
- }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : i.type && l(z).customComponent[i.type] ? (c(), b(G(l(z).customComponent[i.type]), v({
1886
+ }, i.options?.search?.datetime || i.options?.datetime, F(i.options?.search?.datetime?.on || i.options?.datetime?.on || {})), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : i.type && l(T).customComponent[i.type] ? (c(), b(G(l(T).customComponent[i.type]), v({
1882
1887
  key: 4,
1883
1888
  modelValue: l(t).search.form[i.key],
1884
1889
  "onUpdate:modelValue": (f) => l(t).search.form[i.key] = f,
1885
1890
  ref_for: !0
1886
- }, i.options?.[i.type], F(i.options?.[i.type]?.on || {}), {
1891
+ }, i.options?.search?.[i.type] || i.options?.[i.type], F(i.options?.search?.[i.type]?.on || i.options?.[i.type]?.on || {}), {
1887
1892
  disabled: i.disabled?.search
1888
1893
  }), null, 16, ["modelValue", "onUpdate:modelValue", "disabled"])) : C("", !0)
1889
1894
  ]),
@@ -1905,7 +1910,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1905
1910
  onClick: l(t).search.submit
1906
1911
  }, {
1907
1912
  default: h(() => [
1908
- V(S(l(y).tCurd("search")), 1)
1913
+ E(U(l(y).tCurd("search")), 1)
1909
1914
  ]),
1910
1915
  _: 1
1911
1916
  }, 8, ["onClick"])) : C("", !0),
@@ -1914,7 +1919,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1914
1919
  onClick: l(t).search.reset
1915
1920
  }, {
1916
1921
  default: h(() => [
1917
- V(S(l(y).tCurd("reset")), 1)
1922
+ E(U(l(y).tCurd("reset")), 1)
1918
1923
  ]),
1919
1924
  _: 1
1920
1925
  }, 8, ["onClick"])) : C("", !0)
@@ -1931,34 +1936,34 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1931
1936
  O("div", et, [
1932
1937
  O("div", tt, [
1933
1938
  l(n)(r.option.tools?.add) ? (c(), g("div", ot, [
1934
- E(l(M), {
1939
+ D(l(M), {
1935
1940
  type: "primary",
1936
1941
  onClick: m[0] || (m[0] = (i) => l(t).update.open(l(s).Insert))
1937
1942
  }, {
1938
1943
  default: h(() => [
1939
- V(S(l(y).tCurd("add")), 1)
1944
+ E(U(l(y).tCurd("add")), 1)
1940
1945
  ]),
1941
1946
  _: 1
1942
1947
  })
1943
1948
  ])) : C("", !0),
1944
1949
  r.option.table?.selectable && l(n)(r.option.tools?.delete) ? (c(), g("div", lt, [
1945
- E(l(M), {
1950
+ D(l(M), {
1946
1951
  type: "danger",
1947
1952
  onClick: m[1] || (m[1] = (i) => l(t).remove.open(l(t).table.selection.list))
1948
1953
  }, {
1949
1954
  default: h(() => [
1950
- V(S(l(y).tCurd("delete")), 1)
1955
+ E(U(l(y).tCurd("delete")), 1)
1951
1956
  ]),
1952
1957
  _: 1
1953
1958
  })
1954
1959
  ])) : C("", !0),
1955
1960
  r.option.tools?.expand ? (c(), g("div", at, [
1956
- E(l(M), {
1961
+ D(l(M), {
1957
1962
  type: "warning",
1958
1963
  onClick: m[2] || (m[2] = (i) => l(t).table.expand.all())
1959
1964
  }, {
1960
1965
  default: h(() => [
1961
- V(S(l(y).tCurd("expandCollapse")), 1)
1966
+ E(U(l(y).tCurd("expandCollapse")), 1)
1962
1967
  ]),
1963
1968
  _: 1
1964
1969
  })
@@ -1968,26 +1973,26 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1968
1973
  onCommand: l(t).export.click
1969
1974
  }, {
1970
1975
  dropdown: h(() => [
1971
- E(l(me), null, {
1976
+ D(l(me), null, {
1972
1977
  default: h(() => [
1973
1978
  r.option.table?.selectable ? (c(), b(l(X), {
1974
1979
  key: 0,
1975
1980
  command: "select"
1976
1981
  }, {
1977
1982
  default: h(() => [
1978
- V(S(l(y).tCurd("exportSelect")), 1)
1983
+ E(U(l(y).tCurd("exportSelect")), 1)
1979
1984
  ]),
1980
1985
  _: 1
1981
1986
  })) : C("", !0),
1982
- E(l(X), { command: "page" }, {
1987
+ D(l(X), { command: "page" }, {
1983
1988
  default: h(() => [
1984
- V(S(l(y).tCurd("exportPage")), 1)
1989
+ E(U(l(y).tCurd("exportPage")), 1)
1985
1990
  ]),
1986
1991
  _: 1
1987
1992
  }),
1988
- E(l(X), { command: "all" }, {
1993
+ D(l(X), { command: "all" }, {
1989
1994
  default: h(() => [
1990
- V(S(l(y).tCurd("exportAll")), 1)
1995
+ E(U(l(y).tCurd("exportAll")), 1)
1991
1996
  ]),
1992
1997
  _: 1
1993
1998
  })
@@ -1997,12 +2002,12 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
1997
2002
  ]),
1998
2003
  default: h(() => [
1999
2004
  O("div", nt, [
2000
- E(l(M), {
2005
+ D(l(M), {
2001
2006
  type: "warning",
2002
2007
  loading: l(t).export.loading
2003
2008
  }, {
2004
2009
  default: h(() => [
2005
- V(S(l(y).tCurd("export")), 1)
2010
+ E(U(l(y).tCurd("export")), 1)
2006
2011
  ]),
2007
2012
  _: 1
2008
2013
  }, 8, ["loading"])
@@ -2020,7 +2025,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2020
2025
  onClick: m[3] || (m[3] = //@ts-ignore
2021
2026
  (...i) => l(t).table.getList && l(t).table.getList(...i))
2022
2027
  }, [
2023
- E(ze)
2028
+ D(Te)
2024
2029
  ])) : C("", !0)
2025
2030
  ])
2026
2031
  ]),
@@ -2044,7 +2049,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2044
2049
  fixed: "left",
2045
2050
  "show-overflow-tooltip": !1
2046
2051
  }, null, 8, ["selectable"])) : C("", !0),
2047
- E(He, {
2052
+ D(He, {
2048
2053
  conf: l(t),
2049
2054
  columnList: l(t).table.column.list,
2050
2055
  option: r.option
@@ -2064,35 +2069,35 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2064
2069
  }, r.option.table?.operate), {
2065
2070
  header: h(() => [
2066
2071
  k(p.$slots, "table-header-op", {}, () => [
2067
- V(S(l(y).tCurd("operation")), 1)
2072
+ E(U(l(y).tCurd("operation")), 1)
2068
2073
  ])
2069
2074
  ]),
2070
2075
  default: h(({ row: i }) => [
2071
2076
  k(p.$slots, "table-op-left", { row: i }),
2072
- r.option.table?.inlineEdit && l(t).inlineEdit.row === i ? (c(), g($, { key: 0 }, [
2073
- E(l(M), {
2077
+ r.option.table?.inlineEdit && l(t).inlineEdit.row === i ? (c(), g(S, { key: 0 }, [
2078
+ D(l(M), {
2074
2079
  link: "",
2075
2080
  type: "info",
2076
2081
  onClick: l(t).inlineEdit.close
2077
2082
  }, {
2078
2083
  default: h(() => [
2079
- V(S(l(y).tCurd("cancel")), 1)
2084
+ E(U(l(y).tCurd("cancel")), 1)
2080
2085
  ]),
2081
2086
  _: 1
2082
2087
  }, 8, ["onClick"]),
2083
- E(l(M), {
2088
+ D(l(M), {
2084
2089
  link: "",
2085
2090
  type: "primary",
2086
2091
  onClick: l(t).inlineEdit.submit,
2087
2092
  loading: l(t).inlineEdit.loading
2088
2093
  }, {
2089
2094
  default: h(() => [
2090
- V(S(l(y).tCurd("confirm")), 1)
2095
+ E(U(l(y).tCurd("confirm")), 1)
2091
2096
  ]),
2092
2097
  _: 1
2093
2098
  }, 8, ["onClick", "loading"]),
2094
2099
  k(p.$slots, "table-op-edit-right", { row: i })
2095
- ], 64)) : (c(), g($, { key: 1 }, [
2100
+ ], 64)) : (c(), g(S, { key: 1 }, [
2096
2101
  l(n)(r.option.table?.add, i) ? (c(), b(l(M), {
2097
2102
  key: 0,
2098
2103
  link: "",
@@ -2100,7 +2105,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2100
2105
  onClick: (f) => l(t).update.open(l(s).Insert, i)
2101
2106
  }, {
2102
2107
  default: h(() => [
2103
- V(S(l(y).tCurd("add")), 1)
2108
+ E(U(l(y).tCurd("add")), 1)
2104
2109
  ]),
2105
2110
  _: 2
2106
2111
  }, 1032, ["onClick"])) : C("", !0),
@@ -2111,7 +2116,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2111
2116
  onClick: (f) => l(t).update.open(l(s).View, i)
2112
2117
  }, {
2113
2118
  default: h(() => [
2114
- V(S(l(y).tCurd("view")), 1)
2119
+ E(U(l(y).tCurd("view")), 1)
2115
2120
  ]),
2116
2121
  _: 2
2117
2122
  }, 1032, ["onClick"])) : C("", !0),
@@ -2122,7 +2127,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2122
2127
  onClick: (f) => l(t).update.open(l(s).Update, i)
2123
2128
  }, {
2124
2129
  default: h(() => [
2125
- V(S(l(y).tCurd("edit")), 1)
2130
+ E(U(l(y).tCurd("edit")), 1)
2126
2131
  ]),
2127
2132
  _: 2
2128
2133
  }, 1032, ["onClick"])) : C("", !0),
@@ -2133,7 +2138,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2133
2138
  onClick: (f) => l(t).remove.open([i])
2134
2139
  }, {
2135
2140
  default: h(() => [
2136
- V(S(l(y).tCurd("delete")), 1)
2141
+ E(U(l(y).tCurd("delete")), 1)
2137
2142
  ]),
2138
2143
  _: 2
2139
2144
  }, 1032, ["onClick"])) : C("", !0),
@@ -2150,7 +2155,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2150
2155
  ])
2151
2156
  ]),
2152
2157
  O("div", dt, [
2153
- r.option.page?.show === void 0 || r.option.page?.show ? (c(), b(l(be), {
2158
+ r.option.page?.show === void 0 || r.option.page?.show ? (c(), b(l(be), v({
2154
2159
  key: 0,
2155
2160
  "current-page": l(t).page.num,
2156
2161
  "onUpdate:currentPage": m[4] || (m[4] = (i) => l(t).page.num = i),
@@ -2158,17 +2163,17 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2158
2163
  "onUpdate:pageSize": m[5] || (m[5] = (i) => l(t).page.size = i),
2159
2164
  background: "",
2160
2165
  "page-sizes": l(t).page.sizeList,
2161
- "pager-count": 7,
2166
+ "pager-count": l(t).page.pagerCount,
2162
2167
  layout: l(t).page.layout,
2163
2168
  total: l(t).page.total,
2164
2169
  onSizeChange: l(t).table.getList,
2165
2170
  onCurrentChange: l(t).table.getList
2166
- }, null, 8, ["current-page", "page-size", "page-sizes", "layout", "total", "onSizeChange", "onCurrentChange"])) : C("", !0)
2171
+ }, r.option.page?.pagination || {}, F(r.option.page?.pagination?.on || {})), null, 16, ["current-page", "page-size", "page-sizes", "pager-count", "layout", "total", "onSizeChange", "onCurrentChange"])) : C("", !0)
2167
2172
  ])
2168
2173
  ]),
2169
2174
  k(p.$slots, "box-right")
2170
2175
  ]),
2171
- E(l(Y), v({
2176
+ D(l(Y), v({
2172
2177
  modelValue: l(t).update.show,
2173
2178
  "onUpdate:modelValue": m[6] || (m[6] = (i) => l(t).update.show = i),
2174
2179
  title: l(t).update.title,
@@ -2176,11 +2181,11 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2176
2181
  }, r.option.dialog), {
2177
2182
  footer: h(() => [
2178
2183
  O("span", ut, [
2179
- E(l(M), {
2184
+ D(l(M), {
2180
2185
  onClick: l(t).update.close
2181
2186
  }, {
2182
2187
  default: h(() => [
2183
- V(S(l(y).tCurd("close")), 1)
2188
+ E(U(l(y).tCurd("close")), 1)
2184
2189
  ]),
2185
2190
  _: 1
2186
2191
  }, 8, ["onClick"]),
@@ -2191,21 +2196,21 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2191
2196
  loading: l(t).update.loading
2192
2197
  }, {
2193
2198
  default: h(() => [
2194
- V(S(l(y).tCurd("submit")), 1)
2199
+ E(U(l(y).tCurd("submit")), 1)
2195
2200
  ]),
2196
2201
  _: 1
2197
2202
  }, 8, ["onClick", "loading"])) : C("", !0)
2198
2203
  ])
2199
2204
  ]),
2200
2205
  default: h(() => [
2201
- E(l(Q), {
2206
+ D(l(Q), {
2202
2207
  ref_key: "ruleFormRef",
2203
2208
  ref: d,
2204
2209
  model: l(t).update.form,
2205
2210
  rules: l(t).update.rules
2206
2211
  }, {
2207
2212
  default: h(() => [
2208
- l(t).update.showContent ? (c(!0), g($, { key: 0 }, I(l(t).update.formColumn, (i) => (c(), g($, null, [
2213
+ l(t).update.showContent ? (c(!0), g(S, { key: 0 }, I(l(t).update.formColumn, (i) => (c(), g(S, null, [
2209
2214
  l(n)(
2210
2215
  (() => {
2211
2216
  const f = [], w = (L) => {
@@ -2224,20 +2229,20 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2224
2229
  k(p.$slots, "form-start", {
2225
2230
  row: l(t).update.form
2226
2231
  }),
2227
- (c(!0), g($, null, I(i, (f) => (c(), g($, null, [
2232
+ (c(!0), g(S, null, I(i, (f) => (c(), g(S, null, [
2228
2233
  l(n)(f.item.show?.form, l(t).update.form, l(t).update.type) ? (c(), g("div", {
2229
2234
  key: 0,
2230
2235
  class: A([f.item.form.span > 0 ? `col-${l(t).getColumnSpan(f, i)}` : "col", `form-item-col-${f.item.key}`])
2231
2236
  }, [
2232
- (c(!0), g($, null, I(f.item.children ? f.children : [f], (w) => (c(), b(Qe, {
2237
+ (c(!0), g(S, null, I(f.item.children ? f.children : [f], (w) => (c(), b(Qe, {
2233
2238
  key: w.item.key,
2234
2239
  conf: l(t),
2235
2240
  item: w
2236
2241
  }, _({ _: 2 }, [
2237
2242
  I(p.$slots, (L, j) => ({
2238
2243
  name: j,
2239
- fn: h((T) => [
2240
- k(p.$slots, j, v({ ref_for: !0 }, T || {}))
2244
+ fn: h((z) => [
2245
+ k(p.$slots, j, v({ ref_for: !0 }, z || {}))
2241
2246
  ])
2242
2247
  }))
2243
2248
  ]), 1032, ["conf", "item"]))), 128))
@@ -2254,7 +2259,7 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2254
2259
  ]),
2255
2260
  _: 3
2256
2261
  }, 16, ["modelValue", "title", "before-close"]),
2257
- E(l(Y), {
2262
+ D(l(Y), {
2258
2263
  modelValue: l(t).remove.show,
2259
2264
  "onUpdate:modelValue": m[7] || (m[7] = (i) => l(t).remove.show = i),
2260
2265
  title: l(t).remove.title,
@@ -2262,32 +2267,32 @@ const Ke = /* @__PURE__ */ re(Re, [["render", Ae]]), Ne = { class: "row flex-cen
2262
2267
  }, {
2263
2268
  footer: h(() => [
2264
2269
  O("span", ct, [
2265
- E(l(M), {
2270
+ D(l(M), {
2266
2271
  onClick: l(t).remove.close
2267
2272
  }, {
2268
2273
  default: h(() => [
2269
- V(S(l(y).tCurd("close")), 1)
2274
+ E(U(l(y).tCurd("close")), 1)
2270
2275
  ]),
2271
2276
  _: 1
2272
2277
  }, 8, ["onClick"]),
2273
- E(l(M), {
2278
+ D(l(M), {
2274
2279
  type: "danger",
2275
2280
  onClick: l(t).remove.submit,
2276
2281
  loading: l(t).remove.loading
2277
2282
  }, {
2278
2283
  default: h(() => [
2279
- V(S(l(y).tCurd("confirmDelete")), 1)
2284
+ E(U(l(y).tCurd("confirmDelete")), 1)
2280
2285
  ]),
2281
2286
  _: 1
2282
2287
  }, 8, ["onClick", "loading"])
2283
2288
  ])
2284
2289
  ]),
2285
2290
  default: h(() => [
2286
- O("div", null, S(l(y).tCurd("confirmDeleteMessage", l(t).remove.items.length)), 1)
2291
+ O("div", null, U(l(y).tCurd("confirmDeleteMessage", l(t).remove.items.length)), 1)
2287
2292
  ]),
2288
2293
  _: 1
2289
2294
  }, 8, ["modelValue", "title"]),
2290
- E(Ie, {
2295
+ D(Ie, {
2291
2296
  ref_key: "switchConfirmRef",
2292
2297
  ref: a
2293
2298
  }, null, 512)
@@ -2327,7 +2332,7 @@ class yt {
2327
2332
  n.accept = t, n.style.display = "none", n.onchange = (a) => {
2328
2333
  const d = a.target.files[0];
2329
2334
  if (!d) {
2330
- D.fail("未选择文件"), e("未选择文件");
2335
+ $.fail("未选择文件"), e("未选择文件");
2331
2336
  return;
2332
2337
  }
2333
2338
  const p = new FileReader();
@@ -2335,14 +2340,14 @@ class yt {
2335
2340
  const u = t == ".json" ? JSON.parse(m.target.result) : m.target.result;
2336
2341
  s(u);
2337
2342
  }, p.onerror = () => {
2338
- D.fail("文件读取失败"), e("文件读取失败");
2343
+ $.fail("文件读取失败"), e("文件读取失败");
2339
2344
  }, p.readAsText(d), document.body.removeChild(n);
2340
2345
  }, document.body.appendChild(n), n.click();
2341
2346
  });
2342
2347
  }
2343
2348
  const pt = (r, o) => {
2344
2349
  if (r.component("TCurd", ft), r.component("TFormList", le), r.component("TColumn", Se), o?.customComponent) {
2345
- z.customComponent = o.customComponent;
2350
+ T.customComponent = o.customComponent;
2346
2351
  for (const s in o.customComponent)
2347
2352
  r.component(s, o.customComponent[s]);
2348
2353
  }
@@ -2355,11 +2360,11 @@ export {
2355
2360
  Se as TColumn,
2356
2361
  ft as TCurd,
2357
2362
  yt as TFile,
2358
- z as TForm,
2359
- U as TFormConfig,
2363
+ T as TForm,
2364
+ V as TFormConfig,
2360
2365
  y as TFormI18n,
2361
2366
  le as TFormList,
2362
- D as TSys,
2367
+ $ as TSys,
2363
2368
  gt as default,
2364
2369
  pt as install
2365
2370
  };