@xmszm/core 0.0.4 → 0.0.5

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/index.mjs CHANGED
@@ -1,15 +1,15 @@
1
- var lt = Object.defineProperty;
2
- var nt = (e, l, t) => l in e ? lt(e, l, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[l] = t;
3
- var de = (e, l, t) => nt(e, typeof l != "symbol" ? l + "" : l, t);
4
- import { unref as y, useCssVars as at, ref as P, watchEffect as Fe, resolveComponent as X, createElementBlock as ne, openBlock as B, createVNode as f, createElementVNode as _e, withCtx as v, Fragment as ue, renderList as he, createBlock as K, createTextVNode as Z, toDisplayString as pe, defineComponent as j, getCurrentInstance as re, computed as Y, watch as te, onMounted as ke, renderSlot as be, isProxy as ut, normalizeStyle as ve, mergeProps as I, isVNode as le, withDirectives as rt, resolveDirective as ot, isRef as it, mergeModels as xe, useModel as Le, reactive as st, onUnmounted as ft, createCommentVNode as ct, resolveDynamicComponent as dt, h as ye } from "vue";
5
- import { useThemeVars as yt, NDataTable as gt, NTooltip as mt, NButton as z, NCheckboxGroup as ht, NSpace as V, NCheckbox as pt, NSwitch as bt, NDivider as xt, NProgress as wt, NUpload as _t, NUploadDragger as Ct, NIcon as Ve, NText as Ot, NInputNumber as At, NInput as Ue, NRadioGroup as Dt, NRadio as Nt, NDatePicker as Pe, NTimePicker as St, NSelect as It, NEllipsis as Mt, NFormItem as Ft, NForm as Ut, useDialog as Ce, createDiscreteApi as Pt, NPopconfirm as Rt, NPopover as qt, NSpin as Et, NImage as $t } from "naive-ui";
6
- import { Funnel as Tt, ArchiveOutline as Bt, RefreshOutline as Yt, SearchOutline as kt, Code as vt, ChevronDown as Lt, ChevronUp as Vt } from "@vicons/ionicons5";
7
- import { useRoute as ze, useRouter as zt } from "vue-router";
8
- import L from "dayjs";
9
- import { uniqueId as Re } from "lodash-es";
10
- import { initRouteMeta as tn } from "./plugin/vite/initRouteMeta.mjs";
1
+ var ut = Object.defineProperty;
2
+ var rt = (e, l, t) => l in e ? ut(e, l, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[l] = t;
3
+ var de = (e, l, t) => rt(e, typeof l != "symbol" ? l + "" : l, t);
4
+ import { unref as c, useCssVars as ot, ref as P, watchEffect as Ue, createElementBlock as le, openBlock as B, createVNode as f, createElementVNode as Ae, withCtx as L, Fragment as ae, renderList as he, createBlock as K, createTextVNode as X, toDisplayString as pe, defineComponent as j, getCurrentInstance as ue, computed as Y, watch as ee, onMounted as Le, renderSlot as be, isProxy as it, normalizeStyle as ke, mergeProps as M, isVNode as te, withDirectives as st, resolveDirective as ft, isRef as ct, mergeModels as xe, useModel as Ve, reactive as dt, onUnmounted as yt, createCommentVNode as gt, resolveDynamicComponent as mt, h as ye } from "vue";
5
+ import { useThemeVars as ht, NCheckboxGroup as we, NCheckbox as Oe, NEllipsis as ze, NButton as z, NDataTable as pt, NEmpty as bt, NTooltip as xt, NSpace as k, NUpload as We, NSwitch as wt, NDivider as Ot, NProgress as Ct, NUploadDragger as At, NIcon as He, NText as _t, NInputNumber as Dt, NInput as Pe, NRadioGroup as Nt, NRadio as St, NDatePicker as Re, NTimePicker as It, NSelect as Mt, NFormItem as Ft, NForm as Ut, useDialog as _e, createDiscreteApi as Pt, NPopconfirm as Rt, NPopover as qt, NSpin as Et, NImage as $t } from "naive-ui";
6
+ import { Funnel as Tt, ArchiveOutline as Bt, RefreshOutline as Yt, SearchOutline as vt, Code as Lt, ChevronDown as kt, ChevronUp as Vt } from "@vicons/ionicons5";
7
+ import { useRoute as Ke, useRouter as zt } from "vue-router";
8
+ import V from "dayjs";
9
+ import { uniqueId as qe } from "lodash-es";
10
+ import { initRouteMeta as ln } from "./plugin/vite/initRouteMeta.mjs";
11
11
  const $ = "name", T = "id";
12
- function We(e, { labelField: l = $, valueField: t = T } = {}) {
12
+ function je(e, { labelField: l = $, valueField: t = T } = {}) {
13
13
  return Object.keys(e).reduce((a, u) => {
14
14
  const i = Wt(e[u], u), n = {
15
15
  ...i
@@ -19,15 +19,15 @@ function We(e, { labelField: l = $, valueField: t = T } = {}) {
19
19
  }
20
20
  function Wt(e, l) {
21
21
  const t = {
22
- [$]: y(e),
22
+ [$]: c(e),
23
23
  [T]: Number.isNaN(Number(l)) ? l : Number(l)
24
24
  };
25
- return typeof y(e) == "object" ? {
26
- ...y(e),
25
+ return typeof c(e) == "object" ? {
26
+ ...c(e),
27
27
  [T]: Number.isNaN(Number(l)) ? l : Number(l)
28
28
  } : t;
29
29
  }
30
- const qe = {
30
+ const Ee = {
31
31
  style: {
32
32
  cursor: "pointer"
33
33
  },
@@ -48,7 +48,7 @@ const qe = {
48
48
  backgroundColor: "--n-color"
49
49
  }
50
50
  }
51
- }, oe = (e, l) => {
51
+ }, re = (e, l) => {
52
52
  const t = e.__vccOpts || e;
53
53
  for (const [a, u] of l)
54
54
  t[a] = u;
@@ -80,21 +80,21 @@ const qe = {
80
80
  },
81
81
  emits: ["submit"],
82
82
  setup(e, { emit: l }) {
83
- var w, p;
84
- at((_) => ({
85
- e0ecc754: y(u).infoColor
83
+ var w, b;
84
+ ot((O) => ({
85
+ v56ebba65: c(u).infoColor
86
86
  }));
87
- const t = e, a = l, u = yt(), i = P([]);
88
- Fe(() => {
87
+ const t = e, a = l, u = ht(), i = P([]);
88
+ Ue(() => {
89
89
  i.value = t.selectItem;
90
90
  });
91
- const n = P([]), d = [
91
+ const n = P([]), y = [
92
92
  {
93
93
  key: "all",
94
94
  label: "全选",
95
95
  onCheck: () => {
96
- var _;
97
- return i.value = (_ = t.filterItem) == null ? void 0 : _.map((h) => h.key);
96
+ var O;
97
+ return i.value = (O = t.filterItem) == null ? void 0 : O.map((m) => m.key);
98
98
  },
99
99
  unCheck: () => i.value = []
100
100
  },
@@ -111,82 +111,79 @@ const qe = {
111
111
  unCheck: () => i.value = t.selectItem
112
112
  }
113
113
  ];
114
- Fe(() => {
115
- n.value = d.filter(
116
- (_) => t.filterButtonKey.includes(_.key)
114
+ Ue(() => {
115
+ n.value = y.filter(
116
+ (O) => t.filterButtonKey.includes(O.key)
117
117
  ), console.log(t.filterButtonKey);
118
118
  });
119
119
  function o() {
120
120
  a("submit", i.value);
121
121
  }
122
122
  const s = P(
123
- ((w = t.filterItem) == null ? void 0 : w.length) === ((p = t.selectItem) == null ? void 0 : p.length) ? ["all"] : []
123
+ ((w = t.filterItem) == null ? void 0 : w.length) === ((b = t.selectItem) == null ? void 0 : b.length) ? ["all"] : []
124
124
  );
125
- function g(_, h) {
126
- var M, N, r, A;
127
- console.log(_), console.log(h), h.actionType === "uncheck" ? ((N = (M = n.value) == null ? void 0 : M.find((m) => (m == null ? void 0 : m.key) === h.value)) == null || N.unCheck(), s.value = []) : ((A = (r = n.value) == null ? void 0 : r.find((m) => (m == null ? void 0 : m.key) === h.value)) == null || A.onCheck(), s.value = [h.value]);
125
+ function g(O, m) {
126
+ var N, S, r, _;
127
+ console.log(O), console.log(m), m.actionType === "uncheck" ? ((S = (N = n.value) == null ? void 0 : N.find((h) => (h == null ? void 0 : h.key) === m.value)) == null || S.unCheck(), s.value = []) : ((_ = (r = n.value) == null ? void 0 : r.find((h) => (h == null ? void 0 : h.key) === m.value)) == null || _.onCheck(), s.value = [m.value]);
128
128
  }
129
- return (_, h) => {
130
- const M = X("n-ellipsis"), N = X("n-checkbox"), r = X("n-checkbox-group"), A = X("n-button");
131
- return B(), ne("div", Ht, [
132
- f(r, {
133
- value: i.value,
134
- "onUpdate:value": h[0] || (h[0] = (m) => i.value = m),
135
- class: "filter-main"
129
+ return (O, m) => (B(), le("div", Ht, [
130
+ f(c(we), {
131
+ value: i.value,
132
+ "onUpdate:value": m[0] || (m[0] = (N) => i.value = N),
133
+ class: "filter-main"
134
+ }, {
135
+ default: L(() => [
136
+ (B(!0), le(ae, null, he(e.filterItem, (N) => (B(), K(c(Oe), {
137
+ key: N.key,
138
+ value: N.key,
139
+ class: "filter-item"
140
+ }, {
141
+ default: L(() => [
142
+ f(c(ze), { style: { "max-width": "100px" } }, {
143
+ default: L(() => [
144
+ X(pe(N.title), 1)
145
+ ]),
146
+ _: 2
147
+ }, 1024)
148
+ ]),
149
+ _: 2
150
+ }, 1032, ["value"]))), 128))
151
+ ]),
152
+ _: 1
153
+ }, 8, ["value"]),
154
+ Ae("div", Kt, [
155
+ f(c(we), {
156
+ type: t.type,
157
+ value: s.value,
158
+ "onUpdate:value": g
136
159
  }, {
137
- default: v(() => [
138
- (B(!0), ne(ue, null, he(e.filterItem, (m) => (B(), K(N, {
139
- key: m.key,
140
- value: m.key,
141
- class: "filter-item"
160
+ default: L(() => [
161
+ (B(!0), le(ae, null, he(n.value, (N) => (B(), K(c(Oe), {
162
+ key: N.key,
163
+ value: N.key
142
164
  }, {
143
- default: v(() => [
144
- f(M, { style: { "max-width": "100px" } }, {
145
- default: v(() => [
146
- Z(pe(m.title), 1)
147
- ]),
148
- _: 2
149
- }, 1024)
165
+ default: L(() => [
166
+ X(pe(N.label), 1)
150
167
  ]),
151
168
  _: 2
152
169
  }, 1032, ["value"]))), 128))
153
170
  ]),
154
171
  _: 1
155
- }, 8, ["value"]),
156
- _e("div", Kt, [
157
- f(r, {
158
- type: t.type,
159
- value: s.value,
160
- "onUpdate:value": g
161
- }, {
162
- default: v(() => [
163
- (B(!0), ne(ue, null, he(n.value, (m) => (B(), K(N, {
164
- key: m.key,
165
- value: m.key
166
- }, {
167
- default: v(() => [
168
- Z(pe(m.label), 1)
169
- ]),
170
- _: 2
171
- }, 1032, ["value"]))), 128))
172
- ]),
173
- _: 1
174
- }, 8, ["type", "value"]),
175
- f(A, {
176
- class: "submit-btn",
177
- type: t.type,
178
- onClick: o
179
- }, {
180
- default: v(() => [...h[1] || (h[1] = [
181
- Z(" 保存 ", -1)
182
- ])]),
183
- _: 1
184
- }, 8, ["type"])
185
- ])
186
- ]);
187
- };
172
+ }, 8, ["type", "value"]),
173
+ f(c(z), {
174
+ class: "submit-btn",
175
+ type: t.type,
176
+ onClick: o
177
+ }, {
178
+ default: L(() => [...m[1] || (m[1] = [
179
+ X(" 保存 ", -1)
180
+ ])]),
181
+ _: 1
182
+ }, 8, ["type"])
183
+ ])
184
+ ]));
188
185
  }
189
- }, Gt = /* @__PURE__ */ oe(jt, [["__scopeId", "data-v-2aba8b9e"]]), q = {
186
+ }, Gt = /* @__PURE__ */ re(jt, [["__scopeId", "data-v-ffb0cfbf"]]), q = {
190
187
  // API 基础地址
191
188
  baseURL: "",
192
189
  // 权限检查函数
@@ -236,13 +233,13 @@ function Xt() {
236
233
  function Zt() {
237
234
  return { ...q.dialog };
238
235
  }
239
- function He(e) {
236
+ function Ge(e) {
240
237
  q.dialog.instance = e;
241
238
  }
242
239
  function el() {
243
240
  return q.dialog.instance;
244
241
  }
245
- function we(e) {
242
+ function Ce(e) {
246
243
  return q.hasPermission ? q.hasPermission(e) : (console.warn("hasPermission 未配置,默认返回 true。请使用 setupConfig 配置权限检查函数。"), !0);
247
244
  }
248
245
  const tl = {
@@ -250,7 +247,7 @@ const tl = {
250
247
  const t = l.value;
251
248
  if (!t)
252
249
  return;
253
- (Array.isArray(t) ? t : [t]).some((i) => we(i)) || (e.style.display = "none", e._originalDisplay = e.style.display || "");
250
+ (Array.isArray(t) ? t : [t]).some((i) => Ce(i)) || (e.style.display = "none", e._originalDisplay = e.style.display || "");
254
251
  },
255
252
  updated(e, l) {
256
253
  const t = l.value;
@@ -258,16 +255,16 @@ const tl = {
258
255
  e._originalDisplay !== void 0 ? e.style.display = e._originalDisplay || "" : e.style.display = "";
259
256
  return;
260
257
  }
261
- (Array.isArray(t) ? t : [t]).some((i) => we(i)) ? e._originalDisplay !== void 0 ? e.style.display = e._originalDisplay || "" : e.style.display = "" : e.style.display = "none";
258
+ (Array.isArray(t) ? t : [t]).some((i) => Ce(i)) ? e._originalDisplay !== void 0 ? e.style.display = e._originalDisplay || "" : e.style.display = "" : e.style.display = "none";
262
259
  },
263
260
  unmounted(e) {
264
261
  delete e._originalDisplay;
265
262
  }
266
263
  };
267
- let Ke = null;
268
- function ee(e) {
264
+ let Je = null;
265
+ function Z(e) {
269
266
  var l;
270
- e && (Ke = e, (l = e._context.directives) != null && l.corePermission || e.directive("corePermission", tl));
267
+ e && (Je = e, (l = e._context.directives) != null && l.corePermission || e.directive("corePermission", tl));
271
268
  }
272
269
  function Yl() {
273
270
  var e;
@@ -276,15 +273,15 @@ function Yl() {
276
273
  if (!l) return !1;
277
274
  const { getCurrentInstance: t } = l, a = t == null ? void 0 : t();
278
275
  if ((e = a == null ? void 0 : a.appContext) != null && e.app)
279
- return ee(a.appContext.app), !0;
276
+ return Z(a.appContext.app), !0;
280
277
  } catch {
281
278
  }
282
279
  return !1;
283
280
  }
284
281
  function ll() {
285
- return Ke;
282
+ return Je;
286
283
  }
287
- const Ee = "filter_key", nl = /* @__PURE__ */ j({
284
+ const $e = "filter_key", nl = /* @__PURE__ */ j({
288
285
  __name: "DataTable",
289
286
  props: {
290
287
  data: {
@@ -340,82 +337,82 @@ const Ee = "filter_key", nl = /* @__PURE__ */ j({
340
337
  emit: t
341
338
  }) {
342
339
  var x;
343
- const a = re();
344
- (x = a == null ? void 0 : a.appContext) != null && x.app && ee(a.appContext.app);
345
- const u = e, i = ze(), n = t, d = () => {
340
+ const a = ue();
341
+ (x = a == null ? void 0 : a.appContext) != null && x.app && Z(a.appContext.app);
342
+ const u = e, i = Ke(), n = t, y = () => {
346
343
  try {
347
344
  return (i == null ? void 0 : i.fullPath) || (i == null ? void 0 : i.path) || "";
348
345
  } catch {
349
346
  return "";
350
347
  }
351
348
  }, o = Y(() => (console.log("table -data", u.data), u.data));
352
- function s(b) {
353
- window.localStorage.setItem(Ee, JSON.stringify(b));
349
+ function s(p) {
350
+ window.localStorage.setItem($e, JSON.stringify(p));
354
351
  }
355
352
  function g() {
356
- return JSON.parse(window.localStorage.getItem(Ee) || "{}") || {};
353
+ return JSON.parse(window.localStorage.getItem($e) || "{}") || {};
357
354
  }
358
- const w = P(g()), p = P([]), _ = P(0);
359
- function h(b) {
355
+ const w = P(g()), b = P([]), O = P(0);
356
+ function m(p) {
360
357
  if (u.summaryColumns)
361
- return [u.selectColumns, ...y(u.columns || []), u.oprColumns].reduce((c, C) => {
358
+ return [u.selectColumns, ...c(u.columns || []), u.oprColumns].reduce((d, C) => {
362
359
  var U, E;
363
- return C != null && C.key ? c[C.key] = ((E = (U = u.summaryColumns) == null ? void 0 : U.call(u, b)) == null ? void 0 : E[C.key]) || {
360
+ return C != null && C.key ? d[C.key] = ((E = (U = u.summaryColumns) == null ? void 0 : U.call(u, p)) == null ? void 0 : E[C.key]) || {
364
361
  value: null
365
- } : c[Re("table")] = {
362
+ } : d[qe("table")] = {
366
363
  value: null
367
- }, c;
364
+ }, d;
368
365
  }, {});
369
366
  }
370
- const M = P([]);
371
- te(() => y(u.columns), () => {
372
- N();
367
+ const N = P([]);
368
+ ee(() => c(u.columns), () => {
369
+ S();
373
370
  }, {
374
371
  immediate: !0
375
- }), te(() => u.oprColumns, (b) => {
376
- console.log("oprColumns", b);
372
+ }), ee(() => u.oprColumns, (p) => {
373
+ console.log("oprColumns", p);
377
374
  });
378
- function N() {
375
+ function S() {
379
376
  var E;
380
- const b = y(u.columns || []), c = d();
381
- p.value = c && ((E = w.value) == null ? void 0 : E[c]) || (b == null ? void 0 : b.map((R, D) => (R == null ? void 0 : R.key) || String(L().valueOf() + D)));
382
- const C = u.isFilter ? b.filter((R) => {
377
+ const p = c(u.columns || []), d = y();
378
+ b.value = d && ((E = w.value) == null ? void 0 : E[d]) || (p == null ? void 0 : p.map((R, D) => (R == null ? void 0 : R.key) || String(V().valueOf() + D)));
379
+ const C = u.isFilter ? p.filter((R) => {
383
380
  var D;
384
- return (D = p.value) == null ? void 0 : D.includes(R.key);
385
- }) : [...b];
381
+ return (D = b.value) == null ? void 0 : D.includes(R.key);
382
+ }) : [...p];
386
383
  u.selectColumns && C.unshift({
387
384
  key: "selectKey",
388
385
  ...u.selectColumns
389
386
  }), u.oprColumns && C.push(u.oprColumns);
390
387
  let U = 0;
391
- M.value = C.reduce((R, D) => {
388
+ N.value = C.reduce((R, D) => {
392
389
  var G;
393
390
  if (D != null && D.display && console.log("display", D == null ? void 0 : D.display), !((D == null ? void 0 : D.display) ?? !0)) return R;
394
391
  const F = {
395
392
  align: "center",
396
393
  width: 120,
397
394
  ...D,
398
- key: (D == null ? void 0 : D.key) || Re("table"),
399
- ellipsis: D != null && D.ellipsis || u.isEllipsis ? D != null && D.ellipsisProp ? D == null ? void 0 : D.ellipsisProp(qe) : qe : !1,
395
+ key: (D == null ? void 0 : D.key) || qe("table"),
396
+ ellipsis: D != null && D.ellipsis || u.isEllipsis ? D != null && D.ellipsisProp ? D == null ? void 0 : D.ellipsisProp(Ee) : Ee : !1,
400
397
  "ellipsis-component": "ellipsis",
401
398
  title: () => {
402
- const k = (D == null ? void 0 : D.label) || (D == null ? void 0 : D.title) || "";
399
+ const v = (D == null ? void 0 : D.label) || (D == null ? void 0 : D.title) || "";
403
400
  return f("div", {
404
401
  style: {
405
402
  width: "100%",
406
403
  whiteSpace: "pre-wrap"
407
404
  }
408
- }, [typeof k == "string" ? k : k == null ? void 0 : k()]);
405
+ }, [typeof v == "string" ? v : v == null ? void 0 : v()]);
409
406
  }
410
407
  };
411
408
  return D != null && D.sorter && (F.renderSorterIcon = ({
412
- order: k
409
+ order: v
413
410
  }) => {
414
411
  const {
415
412
  Icon: ie,
416
413
  title: se
417
- } = me[k];
418
- return f(mt, null, {
414
+ } = me[v];
415
+ return f(xt, null, {
419
416
  trigger: () => ie,
420
417
  default: () => se
421
418
  });
@@ -423,21 +420,21 @@ const Ee = "filter_key", nl = /* @__PURE__ */ j({
423
420
  multiple: 1,
424
421
  fn: D.sorter
425
422
  }), U += F != null && F.width ? Number.parseInt(String(F == null ? void 0 : F.width)) : (typeof (F == null ? void 0 : F.title) == "string" ? ((G = F == null ? void 0 : F.title) == null ? void 0 : G.length) * 30 : 0) || 0, R.push(F), R;
426
- }, []), _.value = U, console.log("计算");
423
+ }, []), O.value = U, console.log("计算");
427
424
  }
428
425
  function r() {
429
426
  return f(z, {
430
427
  type: "info",
431
- onClick: () => A()
428
+ onClick: () => _()
432
429
  }, {
433
430
  default: () => "筛选字段",
434
431
  icon: () => f(Tt, null, null)
435
432
  });
436
433
  }
437
- function A() {
434
+ function _() {
438
435
  const {
439
- cancel: b
440
- } = Je({
436
+ cancel: p
437
+ } = Ze({
441
438
  title: "筛选字段",
442
439
  read: !0,
443
440
  options: [{
@@ -448,12 +445,12 @@ const Ee = "filter_key", nl = /* @__PURE__ */ j({
448
445
  margin: "0",
449
446
  padding: 0
450
447
  },
451
- filterItem: y(u.columns || []),
452
- selectItem: p.value,
448
+ filterItem: c(u.columns || []),
449
+ selectItem: b.value,
453
450
  defaultItem: u.defaultColumns,
454
- onSubmit: (c) => {
455
- const C = d();
456
- C && (w.value[C] = c, s(w.value)), N(), b();
451
+ onSubmit: (d) => {
452
+ const C = y();
453
+ C && (w.value[C] = d, s(w.value)), S(), p();
457
454
  }
458
455
  }, null)
459
456
  }]
@@ -464,58 +461,55 @@ const Ee = "filter_key", nl = /* @__PURE__ */ j({
464
461
  }
465
462
  });
466
463
  }
467
- function m(b) {
468
- if (console.log("onSorter", b), !b) return;
469
- Oe(b).forEach((C) => {
464
+ function h(p) {
465
+ if (console.log("onSorter", p), !p) return;
466
+ De(p).forEach((C) => {
470
467
  var U, E, R;
471
468
  console.log("v", C), C != null && C.sorter && ((R = (U = C == null ? void 0 : C.sorter) == null ? void 0 : U.fn) == null || R.call(U, (D, F, G) => {
472
- var k;
473
- (k = me[C.order]) == null || k.fn(D, G), F.fetchData();
469
+ var v;
470
+ (v = me[C.order]) == null || v.fn(D, G), F.fetchData();
474
471
  }, {
475
472
  field: C == null ? void 0 : C.columnKey,
476
473
  value: (E = me[C == null ? void 0 : C.order]) == null ? void 0 : E.value,
477
- isClick: !ut(C)
474
+ isClick: !it(C)
478
475
  }));
479
476
  }), n("sorted");
480
477
  }
481
478
  return l({
482
- filterHandle: A,
479
+ filterHandle: _,
483
480
  filterButton: r,
484
- initColumns: N
485
- }), ke(() => {
486
- }), (b, c) => {
487
- const C = X("n-empty");
488
- return B(), K(y(gt), {
489
- data: o.value,
490
- columns: M.value,
491
- "scroll-x": _.value,
492
- "single-column": u.singleColumn,
493
- summary: u.summaryColumns ? h : void 0,
494
- "summary-placement": "bottom",
495
- pagination: u.pagination,
496
- "row-props": () => ({
497
- style: {
498
- height: "60px"
499
- }
500
- }),
501
- "flex-height": "",
502
- remote: "",
503
- "virtual-scroll": !!(u.virtual ?? u.data.length > 1e3),
481
+ initColumns: S
482
+ }), Le(() => {
483
+ }), (p, d) => (B(), K(c(pt), {
484
+ data: o.value,
485
+ columns: N.value,
486
+ "scroll-x": O.value,
487
+ "single-column": u.singleColumn,
488
+ summary: u.summaryColumns ? m : void 0,
489
+ "summary-placement": "bottom",
490
+ pagination: u.pagination,
491
+ "row-props": () => ({
504
492
  style: {
505
- flex: "1"
506
- },
507
- "onUpdate:sorter": m
508
- }, {
509
- empty: v(() => [be(b.$slots, "empty", {}, () => [f(C, null, {
510
- default: v(() => [Z(pe(e.emptyText), 1)]),
511
- _: 1
512
- })], !0)]),
513
- _: 3
514
- }, 8, ["data", "columns", "scroll-x", "single-column", "summary", "pagination", "virtual-scroll"]);
515
- };
493
+ height: "60px"
494
+ }
495
+ }),
496
+ "flex-height": "",
497
+ remote: "",
498
+ "virtual-scroll": !!(u.virtual ?? u.data.length > 1e3),
499
+ style: {
500
+ flex: "1"
501
+ },
502
+ "onUpdate:sorter": h
503
+ }, {
504
+ empty: L(() => [be(p.$slots, "empty", {}, () => [f(c(bt), null, {
505
+ default: L(() => [X(pe(e.emptyText), 1)]),
506
+ _: 1
507
+ })], !0)]),
508
+ _: 3
509
+ }, 8, ["data", "columns", "scroll-x", "single-column", "summary", "pagination", "virtual-scroll"]));
516
510
  }
517
- }), al = /* @__PURE__ */ oe(nl, [["__scopeId", "data-v-9de17e68"]]);
518
- function kl(e) {
511
+ }), al = /* @__PURE__ */ re(nl, [["__scopeId", "data-v-057650fc"]]);
512
+ function vl(e) {
519
513
  Jt({ uploadMethod: e });
520
514
  }
521
515
  function ul(...e) {
@@ -581,24 +575,24 @@ const rl = "/admin/file", ol = {
581
575
  emit: l
582
576
  }) {
583
577
  const t = e, a = l, u = P([]);
584
- te(() => t.value, (o) => {
578
+ ee(() => t.value, (o) => {
585
579
  console.log("props.value", o), u.value = t.max === 1 ? o ? typeof o != "string" ? o != null && o.length ? [{
586
- id: L().valueOf(),
587
- name: `img${L().valueOf()}`,
580
+ id: V().valueOf(),
581
+ name: `img${V().valueOf()}`,
588
582
  url: W(o[0]),
589
583
  thumbnailUrl: W(o[0]),
590
584
  fullPath: o[0],
591
585
  status: "finished"
592
586
  }] : [] : [{
593
- id: L().valueOf(),
594
- name: `img${L().valueOf()}`,
587
+ id: V().valueOf(),
588
+ name: `img${V().valueOf()}`,
595
589
  url: W(o),
596
590
  fullPath: o,
597
591
  thumbnailUrl: W(o),
598
592
  status: "finished"
599
593
  }] : [] : (o == null ? void 0 : o.map((s, g) => ({
600
- id: L().valueOf() + g,
601
- name: `img${L().valueOf()}`,
594
+ id: V().valueOf() + g,
595
+ name: `img${V().valueOf()}`,
602
596
  url: W(s),
603
597
  fullPath: s,
604
598
  thumbnailUrl: W(s),
@@ -615,85 +609,82 @@ const rl = "/admin/file", ol = {
615
609
  onFinish: s,
616
610
  onError: g,
617
611
  onProgress: w
618
- }, p) {
619
- const _ = new FormData();
620
- o.status === "pending" && (_.append("file", o.file), t.formData && Object.keys(t.formData).length && Object.keys(t.formData).forEach((h) => {
621
- _.append(h, t.formData[h]);
612
+ }, b) {
613
+ const O = new FormData();
614
+ o.status === "pending" && (O.append("file", o.file), t.formData && Object.keys(t.formData).length && Object.keys(t.formData).forEach((m) => {
615
+ O.append(m, t.formData[m]);
622
616
  }), ul({
623
617
  url: rl,
624
- data: _,
618
+ data: O,
625
619
  method: "post",
626
620
  onUploadProgress: ({
627
- percent: h
621
+ percent: m
628
622
  }) => w({
629
- percent: h
623
+ percent: m
630
624
  })
631
- }).then((h) => {
625
+ }).then((m) => {
632
626
  const {
633
- url: M
634
- } = h.data;
635
- o.url = W(M), o.fullPath = M, o.thumbnailUrl = W(M), s(), d();
627
+ url: N
628
+ } = m.data;
629
+ o.url = W(N), o.fullPath = N, o.thumbnailUrl = W(N), s(), y();
636
630
  }).catch(() => {
637
631
  o = null, g();
638
632
  }).finally(() => {
639
633
  }));
640
634
  }
641
- function d() {
635
+ function y() {
642
636
  console.log("onSubmit", u.value);
643
637
  const o = u.value.reduce((s, g) => (g.status === "finished" && (g != null && g.fullPath) && s.push(g.fullPath), s), []);
644
638
  t.max === 1 && o.length === 1 ? a("update:value", o[0]) : o.length ? a("update:value", o) : a("update:value", t.max === 1 ? null : []);
645
639
  }
646
- return (o, s) => {
647
- const g = X("n-upload"), w = X("n-space");
648
- return B(), K(w, {
649
- align: "end",
650
- "wrap-item": !1
651
- }, {
652
- default: v(() => [f(g, {
653
- "file-list": u.value,
654
- "onUpdate:fileList": s[0] || (s[0] = (p) => u.value = p),
655
- accept: ".jpeg,.jpg,.png",
656
- "list-type": "image-card",
657
- "custom-request": i,
658
- max: t.read ? Array.isArray(t.value) ? t.value.length : 1 : t.max,
659
- "show-retry-button": !1,
660
- "show-remove-button": !t.read,
661
- class: "upload-box",
662
- style: ve({
663
- ...t.size ? {
664
- "--image-w": `${t.size}px`,
665
- "--image-h": `${t.size}px`
666
- } : {
667
- "--image-w": `${t.width}px`,
668
- "--image-h": `${t.height}px`
669
- },
670
- "--image-mode": t.mode
671
- }),
672
- onFinish: s[1] || (s[1] = () => {
673
- d(), a("complete");
674
- }),
675
- onRemove: s[2] || (s[2] = (p, _) => (u.value.splice(_, 1), d(), !1))
676
- }, null, 8, ["file-list", "max", "show-remove-button", "style"])]),
677
- _: 1
678
- });
679
- };
640
+ return (o, s) => (B(), K(c(k), {
641
+ align: "end",
642
+ "wrap-item": !1
643
+ }, {
644
+ default: L(() => [f(c(We), {
645
+ "file-list": u.value,
646
+ "onUpdate:fileList": s[0] || (s[0] = (g) => u.value = g),
647
+ accept: ".jpeg,.jpg,.png",
648
+ "list-type": "image-card",
649
+ "custom-request": i,
650
+ max: t.read ? Array.isArray(t.value) ? t.value.length : 1 : t.max,
651
+ "show-retry-button": !1,
652
+ "show-remove-button": !t.read,
653
+ class: "upload-box",
654
+ style: ke({
655
+ ...t.size ? {
656
+ "--image-w": `${t.size}px`,
657
+ "--image-h": `${t.size}px`
658
+ } : {
659
+ "--image-w": `${t.width}px`,
660
+ "--image-h": `${t.height}px`
661
+ },
662
+ "--image-mode": t.mode
663
+ }),
664
+ onFinish: s[1] || (s[1] = () => {
665
+ y(), a("complete");
666
+ }),
667
+ onRemove: s[2] || (s[2] = (g, w) => (u.value.splice(w, 1), y(), !1))
668
+ }, null, 8, ["file-list", "max", "show-remove-button", "style"])]),
669
+ _: 1
670
+ }));
680
671
  }
681
- }, il = /* @__PURE__ */ oe(ol, [["__scopeId", "data-v-54e2cc87"]]);
682
- function $e(e = [], l = $, t = T) {
683
- return y(e).reduce((a, u) => (a[u[t]] = {
672
+ }, il = /* @__PURE__ */ re(ol, [["__scopeId", "data-v-29718977"]]);
673
+ function Te(e = [], l = $, t = T) {
674
+ return c(e).reduce((a, u) => (a[u[t]] = {
684
675
  ...u,
685
676
  [l]: u[l],
686
677
  [t]: u[t]
687
678
  }, a), {});
688
679
  }
689
- function Oe(e) {
680
+ function De(e) {
690
681
  return Array.isArray(e) ? e : [e];
691
682
  }
692
- function Te(e, l = "YYYY-MM-DD", t = { emptyText: "" }) {
693
- return e ? L(Number.isNaN(Number(e)) ? e : Number(e)).format(l) : (t == null ? void 0 : t.emptyText) || "";
683
+ function Be(e, l = "YYYY-MM-DD", t = { emptyText: "" }) {
684
+ return e ? V(Number.isNaN(Number(e)) ? e : Number(e)).format(l) : (t == null ? void 0 : t.emptyText) || "";
694
685
  }
695
686
  function sl(e) {
696
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
687
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !te(e);
697
688
  }
698
689
  const fl = {
699
690
  input: ({
@@ -705,16 +696,16 @@ const fl = {
705
696
  read: i
706
697
  }, {
707
698
  _value: n,
708
- _isRead: d
699
+ _isRead: y
709
700
  }) => {
710
- const o = y(n), s = y(d);
711
- return i ?? s ? f(Mt, a, {
701
+ const o = c(n), s = c(y);
702
+ return i ?? s ? f(ze, a, {
712
703
  default: () => [u ? u == null ? void 0 : u(o[l], o) : o[l]]
713
- }) : f(Ue, I({
704
+ }) : f(Pe, M({
714
705
  value: o[l],
715
706
  "onUpdate:value": (g) => o[l] = g,
716
707
  clearable: !0,
717
- placeholder: `请输入${y(e)}`
708
+ placeholder: `请输入${c(e)}`
718
709
  }, t), {
719
710
  ...(t == null ? void 0 : t.slots) || {}
720
711
  });
@@ -728,22 +719,22 @@ const fl = {
728
719
  format: i = null,
729
720
  read: n
730
721
  }, {
731
- _value: d,
722
+ _value: y,
732
723
  _isRead: o
733
724
  }) => {
734
- var p, _;
735
- const s = y(d), g = y(o), w = Array.isArray(a) ? a : typeof a == "function" ? a(s[l]) : [];
736
- return n ?? g ? f("div", null, [i ? i == null ? void 0 : i(s[l], w) : ((_ = (p = $e(w, (t == null ? void 0 : t.labelField) || $, (t == null ? void 0 : t.valueField) || T)) == null ? void 0 : p[s[l]]) == null ? void 0 : _[(t == null ? void 0 : t.labelField) || $]) || s[l]]) : f(It, I({
725
+ var b, O;
726
+ const s = c(y), g = c(o), w = Array.isArray(a) ? a : typeof a == "function" ? a(s[l]) : [];
727
+ return n ?? g ? f("div", null, [i ? i == null ? void 0 : i(s[l], w) : ((O = (b = Te(w, (t == null ? void 0 : t.labelField) || $, (t == null ? void 0 : t.valueField) || T)) == null ? void 0 : b[s[l]]) == null ? void 0 : O[(t == null ? void 0 : t.labelField) || $]) || s[l]]) : f(Mt, M({
737
728
  value: s[l],
738
- "onUpdate:value": (h) => s[l] = h,
729
+ "onUpdate:value": (m) => s[l] = m,
739
730
  options: w,
740
- loading: y(u),
731
+ loading: c(u),
741
732
  clearable: !0,
742
733
  filterable: !0,
743
734
  "fallback-option": () => (t != null && t.asyncFallback || (s[l] = null), !1),
744
735
  labelField: (t == null ? void 0 : t.labelField) || $,
745
736
  valueField: (t == null ? void 0 : t.valueField) || T,
746
- placeholder: `请选择${y(e)}`,
737
+ placeholder: `请选择${c(e)}`,
747
738
  style: "width:100%",
748
739
  "max-tag-count": "responsive"
749
740
  }, t), {
@@ -759,18 +750,18 @@ const fl = {
759
750
  format: i,
760
751
  read: n
761
752
  }, {
762
- _value: d,
753
+ _value: y,
763
754
  _isRead: o
764
755
  }) => {
765
- const s = y(d), g = y(o);
766
- return n ?? g ? f("div", null, [i ? i == null ? void 0 : i(s[l]) : Te(s[l], a)]) : f(Pe, I({
756
+ const s = c(y), g = c(o);
757
+ return n ?? g ? f("div", null, [i ? i == null ? void 0 : i(s[l]) : Be(s[l], a)]) : f(Re, M({
767
758
  "formatted-value": s[l],
768
759
  "onUpdate:formatted-value": (w) => {
769
760
  s[l] = w;
770
761
  },
771
762
  type: u,
772
763
  clearable: !0,
773
- placeholder: `请选择${y(e)}`,
764
+ placeholder: `请选择${c(e)}`,
774
765
  "update-value-on-close": !["year"].includes(t == null ? void 0 : t.type),
775
766
  style: "width:100%"
776
767
  }, t), {
@@ -786,10 +777,10 @@ const fl = {
786
777
  read: i
787
778
  }, {
788
779
  _value: n,
789
- _isRead: d
780
+ _isRead: y
790
781
  }) => {
791
- const o = y(n), s = y(d);
792
- return i ?? s ? f("div", null, [a ? a == null ? void 0 : a(o[l]) : Te(o[l], u)]) : f(St, I({
782
+ const o = c(n), s = c(y);
783
+ return i ?? s ? f("div", null, [a ? a == null ? void 0 : a(o[l]) : Be(o[l], u)]) : f(It, M({
793
784
  "formatted-value": o[l],
794
785
  "onUpdate:value": (g, w) => {
795
786
  console.log("v", w), o[l] = w;
@@ -797,7 +788,7 @@ const fl = {
797
788
  clearable: !0,
798
789
  format: "HH:mm:ss",
799
790
  style: "width:100%",
800
- placeholder: `请选择${y(e)}`
791
+ placeholder: `请选择${c(e)}`
801
792
  }, t), {
802
793
  ...(t == null ? void 0 : t.slots) || {}
803
794
  });
@@ -812,17 +803,17 @@ const fl = {
812
803
  _isRead: i
813
804
  }) => {
814
805
  var g, w;
815
- const n = y(u), d = y(i), o = {
806
+ const n = c(u), y = c(i), o = {
816
807
  date: "YYYY-MM-DD",
817
808
  datetime: "YYYY-MM-DD HH:mm:ss",
818
809
  time: "HH:mm:ss",
819
810
  datetimerange: "YYYY-MM-DD HH:mm:ss",
820
811
  daterange: "YYYY-MM-DD"
821
812
  }, s = l != null && l.format ? (w = (g = l == null ? void 0 : l.format) == null ? void 0 : g.replace("yyyy", "YYYY")) == null ? void 0 : w.replace("dd", "DD") : o[(l == null ? void 0 : l.type) || t];
822
- return console.log("formatStr type", t), console.log("formatStr", s), a ?? d ? f("div", null, [Array.isArray(e) ? `${n == null ? void 0 : n[e == null ? void 0 : e[0]]} - ${n == null ? void 0 : n[e == null ? void 0 : e[1]]}` : n == null ? void 0 : n[e]]) : f(Pe, I({
823
- "formatted-value": Array.isArray(e) ? n != null && n[e == null ? void 0 : e[0]] && (n != null && n[e == null ? void 0 : e[1]]) ? [L(n == null ? void 0 : n[e == null ? void 0 : e[0]]).format(s), L(n == null ? void 0 : n[e == null ? void 0 : e[1]]).format(s)] : null : (n == null ? void 0 : n[e]) || null,
824
- "onUpdate:formatted-value": (p) => {
825
- console.log(p), p && ![o.datetime, o.datetimerange].includes(s) && (p = p.map((_, h) => L(_, s)[h ? "endOf" : "startOf"]("day").format(s))), Array.isArray(e) ? (n[e == null ? void 0 : e[0]] = p == null ? void 0 : p[0], n[e == null ? void 0 : e[1]] = p == null ? void 0 : p[1]) : n[e] = p;
813
+ return console.log("formatStr type", t), console.log("formatStr", s), a ?? y ? f("div", null, [Array.isArray(e) ? `${n == null ? void 0 : n[e == null ? void 0 : e[0]]} - ${n == null ? void 0 : n[e == null ? void 0 : e[1]]}` : n == null ? void 0 : n[e]]) : f(Re, M({
814
+ "formatted-value": Array.isArray(e) ? n != null && n[e == null ? void 0 : e[0]] && (n != null && n[e == null ? void 0 : e[1]]) ? [V(n == null ? void 0 : n[e == null ? void 0 : e[0]]).format(s), V(n == null ? void 0 : n[e == null ? void 0 : e[1]]).format(s)] : null : (n == null ? void 0 : n[e]) || null,
815
+ "onUpdate:formatted-value": (b) => {
816
+ console.log(b), b && ![o.datetime, o.datetimerange].includes(s) && (b = b.map((O, m) => V(O, s)[m ? "endOf" : "startOf"]("day").format(s))), Array.isArray(e) ? (n[e == null ? void 0 : e[0]] = b == null ? void 0 : b[0], n[e == null ? void 0 : e[1]] = b == null ? void 0 : b[1]) : n[e] = b;
826
817
  },
827
818
  "update-value-on-close": !["year", "month"].includes(l == null ? void 0 : l.type),
828
819
  type: t,
@@ -841,30 +832,30 @@ const fl = {
841
832
  }, {
842
833
  _value: i,
843
834
  _isRead: n,
844
- labelField: d,
835
+ labelField: y,
845
836
  valueField: o
846
837
  }) => {
847
- var w, p;
848
- const s = y(i), g = y(n);
849
- return u ?? g ? f("div", null, [(p = (w = $e(Array.isArray(l) ? l : [], (t == null ? void 0 : t.labelField) || d || $, (t == null ? void 0 : t.valueField) || o || T)) == null ? void 0 : w[s[e]]) == null ? void 0 : p[(t == null ? void 0 : t.labelField) || d || $]]) : f(Dt, I({
838
+ var w, b;
839
+ const s = c(i), g = c(n);
840
+ return u ?? g ? f("div", null, [(b = (w = Te(Array.isArray(l) ? l : [], (t == null ? void 0 : t.labelField) || y || $, (t == null ? void 0 : t.valueField) || o || T)) == null ? void 0 : w[s[e]]) == null ? void 0 : b[(t == null ? void 0 : t.labelField) || y || $]]) : f(Nt, M({
850
841
  style: {
851
842
  width: "100%"
852
843
  },
853
844
  value: s[e],
854
- "onUpdate:value": (_) => s[e] = _
845
+ "onUpdate:value": (O) => s[e] = O
855
846
  }, t), {
856
847
  ...(t == null ? void 0 : t.slots) || {},
857
- default: () => f(V, I({
848
+ default: () => f(k, M({
858
849
  "item-wrap": !1
859
850
  }, (t == null ? void 0 : t.radioProps) || {}), {
860
851
  default: () => {
861
- var _;
862
- return [(_ = Array.isArray(l) ? l : []) == null ? void 0 : _.map((h) => f(Nt, {
863
- key: h.value,
864
- value: h == null ? void 0 : h[(t == null ? void 0 : t.valueField) || o || T],
852
+ var O;
853
+ return [(O = Array.isArray(l) ? l : []) == null ? void 0 : O.map((m) => f(St, {
854
+ key: m.value,
855
+ value: m == null ? void 0 : m[(t == null ? void 0 : t.valueField) || o || T],
865
856
  class: "items-center"
866
857
  }, {
867
- default: () => [f("div", (a == null ? void 0 : a(h)) || {}, [h == null ? void 0 : h[(t == null ? void 0 : t.labelField) || d || $]])]
858
+ default: () => [f("div", (a == null ? void 0 : a(m)) || {}, [m == null ? void 0 : m[(t == null ? void 0 : t.labelField) || y || $]])]
868
859
  }))];
869
860
  }
870
861
  })
@@ -879,14 +870,14 @@ const fl = {
879
870
  _value: u,
880
871
  _isRead: i
881
872
  }) => {
882
- const n = y(u), d = y(i);
883
- return a ?? d ? f("div", null, [n[l]]) : f(Ue, I({
873
+ const n = c(u), y = c(i);
874
+ return a ?? y ? f("div", null, [n[l]]) : f(Pe, M({
884
875
  value: n[l],
885
876
  "onUpdate:value": (o) => n[l] = o,
886
877
  clearable: !0,
887
878
  style: "width:100%",
888
879
  "allow-input": (o) => !o || /^\d$/.test(o) || o.length <= 11,
889
- placeholder: `请输入${y(e)}`
880
+ placeholder: `请输入${c(e)}`
890
881
  }, t), {
891
882
  ...t == null ? void 0 : t.slots
892
883
  });
@@ -900,8 +891,8 @@ const fl = {
900
891
  _value: u,
901
892
  _isRead: i
902
893
  }) => {
903
- const n = y(u), d = y(i);
904
- return a ?? d ? f("div", null, [n[l]]) : f(At, I({
894
+ const n = c(u), y = c(i);
895
+ return a ?? y ? f("div", null, [n[l]]) : f(Dt, M({
905
896
  value: typeof n[l] == "string" && n[l] ? Number(n[l]) : n[l],
906
897
  "onUpdate:value": (o) => {
907
898
  n[l] = o;
@@ -909,7 +900,7 @@ const fl = {
909
900
  showButton: !1,
910
901
  clearable: !0,
911
902
  style: "width:100%",
912
- placeholder: `请输入${y(e)}`,
903
+ placeholder: `请输入${c(e)}`,
913
904
  min: 0
914
905
  }, t), {
915
906
  ...(t == null ? void 0 : t.slots) || {}
@@ -921,26 +912,26 @@ const fl = {
921
912
  }, {
922
913
  _value: t
923
914
  }) => {
924
- const a = y(t);
925
- return f(_t, I({
915
+ const a = c(t);
916
+ return f(We, M({
926
917
  multiple: !0,
927
918
  max: 1,
928
919
  accept: ".xls,.xlsx",
929
920
  "file-list": a[e],
930
921
  "onUpdate:file-list": (u) => a[e] = u
931
922
  }, l), {
932
- default: () => [f(Ct, null, {
923
+ default: () => [f(At, null, {
933
924
  default: () => [f("div", {
934
925
  style: "margin-bottom: 12px"
935
- }, [f(Ve, {
926
+ }, [f(He, {
936
927
  size: "48",
937
928
  depth: 3
938
929
  }, {
939
930
  default: () => [f(Bt, null, null)]
940
- })]), f(Ot, {
931
+ })]), f(_t, {
941
932
  style: "font-size: 16px"
942
933
  }, {
943
- default: () => [Z("点击或者拖动文件到该区域来上传")]
934
+ default: () => [X("点击或者拖动文件到该区域来上传")]
944
935
  })]
945
936
  })]
946
937
  });
@@ -954,12 +945,12 @@ const fl = {
954
945
  pageState: i
955
946
  }, {
956
947
  _value: n,
957
- _isRead: d
948
+ _isRead: y
958
949
  }) => {
959
- var p;
960
- const o = y(n);
950
+ var b;
951
+ const o = c(n);
961
952
  console.log(l), console.log(i);
962
- const s = (p = i == null ? void 0 : i.data) != null && p.length ? i.data : o[e], g = Array.isArray(a) ? a : typeof a == "function" ? a(o[e]) : [], w = {
953
+ const s = (b = i == null ? void 0 : i.data) != null && b.length ? i.data : o[e], g = Array.isArray(a) ? a : typeof a == "function" ? a(o[e]) : [], w = {
963
954
  data: s,
964
955
  columns: g,
965
956
  maxHeight: 200,
@@ -977,12 +968,12 @@ const fl = {
977
968
  }, {
978
969
  _value: t
979
970
  }) => {
980
- const a = y(t);
981
- return f(wt, I({
971
+ const a = c(t);
972
+ return f(Ct, M({
982
973
  percentage: a[e]
983
974
  }, l), null);
984
975
  },
985
- line: () => f(xt, null, null),
976
+ line: () => f(Ot, null, null),
986
977
  image: ({
987
978
  key: e,
988
979
  props: l,
@@ -991,10 +982,10 @@ const fl = {
991
982
  _isRead: a,
992
983
  _value: u
993
984
  }) => {
994
- const i = y(u), n = y(a);
995
- return f(il, I({
985
+ const i = c(u), n = c(a);
986
+ return f(il, M({
996
987
  value: i[e],
997
- "onUpdate:value": (d) => i[e] = d,
988
+ "onUpdate:value": (y) => i[e] = y,
998
989
  max: 1
999
990
  }, l, {
1000
991
  read: t ?? n
@@ -1007,8 +998,8 @@ const fl = {
1007
998
  }, {
1008
999
  _value: a
1009
1000
  }) => {
1010
- const u = y(a);
1011
- return f(z, I({
1001
+ const u = c(a);
1002
+ return f(z, M({
1012
1003
  type: "info"
1013
1004
  }, l, {
1014
1005
  onClick: () => l != null && l.onClick ? l == null ? void 0 : l.onClick(u) : e == null ? void 0 : e(u)
@@ -1024,10 +1015,10 @@ const fl = {
1024
1015
  _isRead: a,
1025
1016
  _value: u
1026
1017
  }) => {
1027
- const i = y(u), n = y(a);
1028
- return t ?? n ? f("div", null, [i[e] ? "是" : "否"]) : f(bt, I({
1018
+ const i = c(u), n = c(a);
1019
+ return t ?? n ? f("div", null, [i[e] ? "是" : "否"]) : f(wt, M({
1029
1020
  value: i[e],
1030
- "onUpdate:value": (d) => i[e] = d
1021
+ "onUpdate:value": (y) => i[e] = y
1031
1022
  }, l), {
1032
1023
  ...(l == null ? void 0 : l.slots) || {}
1033
1024
  });
@@ -1041,29 +1032,29 @@ const fl = {
1041
1032
  _value: u,
1042
1033
  _isRead: i,
1043
1034
  labelField: n,
1044
- valueField: d
1035
+ valueField: y
1045
1036
  }) => {
1046
- var g, w, p;
1047
- const o = y(u), s = y(i);
1048
- return a ?? s ? f("div", null, [(p = (w = (g = Array.isArray(l) ? l : []) == null ? void 0 : g.filter((_) => {
1049
- var h;
1050
- return (h = o[e]) == null ? void 0 : h.includes(_[(t == null ? void 0 : t.valueField) || d || T]);
1051
- })) == null ? void 0 : w.map((_) => _[(t == null ? void 0 : t.labelField) || n || $])) == null ? void 0 : p.join("、")]) : f(ht, I({
1037
+ var g, w, b;
1038
+ const o = c(u), s = c(i);
1039
+ return a ?? s ? f("div", null, [(b = (w = (g = Array.isArray(l) ? l : []) == null ? void 0 : g.filter((O) => {
1040
+ var m;
1041
+ return (m = o[e]) == null ? void 0 : m.includes(O[(t == null ? void 0 : t.valueField) || y || T]);
1042
+ })) == null ? void 0 : w.map((O) => O[(t == null ? void 0 : t.labelField) || n || $])) == null ? void 0 : b.join("、")]) : f(we, M({
1052
1043
  value: o[e],
1053
- "onUpdate:value": (_) => o[e] = _,
1044
+ "onUpdate:value": (O) => o[e] = O,
1054
1045
  style: {
1055
1046
  width: "100%"
1056
1047
  }
1057
1048
  }, t), {
1058
1049
  ...(t == null ? void 0 : t.slots) || {},
1059
- default: () => f(V, (t == null ? void 0 : t.checkBoxProps) || {}, {
1050
+ default: () => f(k, (t == null ? void 0 : t.checkBoxProps) || {}, {
1060
1051
  default: () => {
1061
- var _;
1062
- return [(_ = Array.isArray(l) ? l : []) == null ? void 0 : _.map((h) => f(pt, {
1063
- key: h == null ? void 0 : h[(t == null ? void 0 : t.valueField) || d || T],
1064
- value: h == null ? void 0 : h[(t == null ? void 0 : t.valueField) || d || T]
1052
+ var O;
1053
+ return [(O = Array.isArray(l) ? l : []) == null ? void 0 : O.map((m) => f(Oe, {
1054
+ key: m == null ? void 0 : m[(t == null ? void 0 : t.valueField) || y || T],
1055
+ value: m == null ? void 0 : m[(t == null ? void 0 : t.valueField) || y || T]
1065
1056
  }, {
1066
- default: () => [h == null ? void 0 : h[(t == null ? void 0 : t.labelField) || n || $]]
1057
+ default: () => [m == null ? void 0 : m[(t == null ? void 0 : t.labelField) || n || $]]
1067
1058
  }))];
1068
1059
  }
1069
1060
  })
@@ -1075,7 +1066,7 @@ const fl = {
1075
1066
  options: t
1076
1067
  }, {
1077
1068
  _value: a
1078
- }) => (y(a), f("div", null, [Z("FilterSelect 组件需要外部提供")]))
1069
+ }) => (c(a), f("div", null, [X("FilterSelect 组件需要外部提供")]))
1079
1070
  };
1080
1071
  let J = {};
1081
1072
  class cl {
@@ -1131,12 +1122,12 @@ class cl {
1131
1122
  this.initSetup(l);
1132
1123
  }
1133
1124
  }
1134
- const Ae = new cl(), je = (e = []) => Ae.getOptions(e);
1135
- function vl() {
1136
- return Ae.getAllOptions();
1125
+ const oe = new cl(), Ll = (e) => oe.init(e), Qe = (e = []) => oe.getOptions(e);
1126
+ function kl() {
1127
+ return oe.getAllOptions();
1137
1128
  }
1138
- function Ll(e, l) {
1139
- return Ae.setupExtendOptions(e, l);
1129
+ function Vl(e, l) {
1130
+ return oe.setupExtendOptions(e, l);
1140
1131
  }
1141
1132
  const dl = ["xlink:href", "fill"], yl = /* @__PURE__ */ j({
1142
1133
  __name: "SvgIcon",
@@ -1152,76 +1143,76 @@ const dl = ["xlink:href", "fill"], yl = /* @__PURE__ */ j({
1152
1143
  },
1153
1144
  setup(e) {
1154
1145
  const l = e, t = Y(() => `#svg-${l.name}`);
1155
- return (a, u) => (B(), ne("svg", I({ class: "svg-icon" }, a.$attrs, {
1146
+ return (a, u) => (B(), le("svg", M({ class: "svg-icon" }, a.$attrs, {
1156
1147
  style: { color: e.color },
1157
1148
  "aria-hidden": ""
1158
1149
  }), [
1159
- _e("use", {
1150
+ Ae("use", {
1160
1151
  "xlink:href": t.value,
1161
1152
  fill: e.color
1162
1153
  }, null, 8, dl)
1163
1154
  ], 16));
1164
1155
  }
1165
- }), gl = /* @__PURE__ */ oe(yl, [["__scopeId", "data-v-9dbe5f10"]]);
1156
+ }), gl = /* @__PURE__ */ re(yl, [["__scopeId", "data-v-9dbe5f10"]]);
1166
1157
  function ml(e) {
1167
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
1158
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !te(e);
1168
1159
  }
1169
1160
  const hl = /* @__PURE__ */ j((e, {
1170
1161
  emit: l
1171
1162
  }) => {
1172
- var N;
1173
- const t = re();
1174
- if ((N = t == null ? void 0 : t.appContext) != null && N.app)
1175
- ee(t.appContext.app);
1163
+ var S;
1164
+ const t = ue();
1165
+ if ((S = t == null ? void 0 : t.appContext) != null && S.app)
1166
+ Z(t.appContext.app);
1176
1167
  else {
1177
1168
  const r = ll();
1178
- r && ee(r);
1169
+ r && Z(r);
1179
1170
  }
1180
1171
  const a = P(e.value || {}), u = Y(() => e.read || !1);
1181
1172
  let i = e.formRef;
1182
- te(() => e.formRef, (r) => i = r);
1173
+ ee(() => e.formRef, (r) => i = r);
1183
1174
  const n = Y(() => e.option || []);
1184
- function d(r) {
1185
- return r.reduce((A, m) => {
1186
- A.push((m == null ? void 0 : m.way) ?? "input");
1187
- const x = [m == null ? void 0 : m.default, m == null ? void 0 : m.suffix, m == null ? void 0 : m.prefix].reduce((b, c) => {
1175
+ function y(r) {
1176
+ return r.reduce((_, h) => {
1177
+ _.push((h == null ? void 0 : h.way) ?? "input");
1178
+ const x = [h == null ? void 0 : h.default, h == null ? void 0 : h.suffix, h == null ? void 0 : h.prefix].reduce((p, d) => {
1188
1179
  var C;
1189
- return Array.isArray(c) ? b = b.concat(c) : c && ((C = Object.keys(c)) != null && C.length) && b.push(c), b;
1180
+ return Array.isArray(d) ? p = p.concat(d) : d && ((C = Object.keys(d)) != null && C.length) && p.push(d), p;
1190
1181
  }, []);
1191
- return console.log(x), x.length && x.forEach((b) => A.push((b == null ? void 0 : b.way) ?? "input")), A;
1182
+ return console.log(x), x.length && x.forEach((p) => _.push((p == null ? void 0 : p.way) ?? "input")), _;
1192
1183
  }, []);
1193
1184
  }
1194
- const o = Y(() => [...new Set(d(e.option || []))]), s = je(o.value);
1195
- console.log(e.option), console.log("defaultOption", s, o.value), te(() => a.value, (r) => {
1185
+ const o = Y(() => [...new Set(y(e.option || []))]), s = Qe(o.value);
1186
+ console.log(e.option), console.log("defaultOption", s, o.value), ee(() => a.value, (r) => {
1196
1187
  l("update:value", r);
1197
1188
  }, {
1198
1189
  immediate: !0
1199
1190
  });
1200
- function g(r, A) {
1201
- let m = {};
1191
+ function g(r, _) {
1192
+ let h = {};
1202
1193
  const x = typeof r;
1203
- let b = null;
1194
+ let p = null;
1204
1195
  try {
1205
- return r ? x === "string" || x === "object" ? b = r : x === "function" && (b = r(y(a), {
1196
+ return r ? x === "string" || x === "object" ? p = r : x === "function" && (p = r(c(a), {
1206
1197
  formRef: i,
1207
1198
  resetForm: () => {
1208
- var c;
1209
- return (c = i == null ? void 0 : i.value) == null ? void 0 : c.restoreValidation();
1199
+ var d;
1200
+ return (d = i == null ? void 0 : i.value) == null ? void 0 : d.restoreValidation();
1210
1201
  },
1211
1202
  close: () => {
1212
- var c;
1213
- return (c = e.cancel) == null ? void 0 : c.call(e);
1203
+ var d;
1204
+ return (d = e.cancel) == null ? void 0 : d.call(e);
1214
1205
  },
1215
1206
  setValue: w
1216
- })) : b = r, typeof b == "object" && !Array.isArray(b) ? Object.keys(b).forEach((c) => {
1217
- const C = b[c];
1218
- it(C) ? m[c] = y(C) : m[c] = C;
1219
- }) : m = b, m;
1207
+ })) : p = r, typeof p == "object" && !Array.isArray(p) ? Object.keys(p).forEach((d) => {
1208
+ const C = p[d];
1209
+ ct(C) ? h[d] = c(C) : h[d] = C;
1210
+ }) : h = p, h;
1220
1211
  } catch {
1221
1212
  return {};
1222
1213
  }
1223
1214
  }
1224
- te(() => e.value, (r) => {
1215
+ ee(() => e.value, (r) => {
1225
1216
  console.log(r), a.value = r || {};
1226
1217
  }, {
1227
1218
  immediate: !0
@@ -1229,8 +1220,8 @@ const hl = /* @__PURE__ */ j((e, {
1229
1220
  function w(r) {
1230
1221
  a.value = r;
1231
1222
  }
1232
- function p(r) {
1233
- return f(V, I({
1223
+ function b(r) {
1224
+ return f(k, M({
1234
1225
  "wrap-item": !1,
1235
1226
  wrap: !!(r != null && r.isWrap),
1236
1227
  align: "center",
@@ -1238,39 +1229,39 @@ const hl = /* @__PURE__ */ j((e, {
1238
1229
  width: "100%"
1239
1230
  }
1240
1231
  }, (r == null ? void 0 : r.contentProps) || {}), {
1241
- default: () => [_(r == null ? void 0 : r.prefix), _((r == null ? void 0 : r.default) || r), _(r == null ? void 0 : r.suffix)]
1232
+ default: () => [O(r == null ? void 0 : r.prefix), O((r == null ? void 0 : r.default) || r), O(r == null ? void 0 : r.suffix)]
1242
1233
  });
1243
1234
  }
1244
- function _(r) {
1235
+ function O(r) {
1245
1236
  if (!r) return;
1246
- let A = r;
1247
- return typeof r == "function" && (A = g(r)), A = g(A), le(A) ? (console.log("??? isVNode"), A) : typeof A == "string" ? (console.log("??? string"), A) : Array.isArray(A) ? (console.log("???"), f(ue, null, [A.map((m, x) => f(M, {
1248
- item: m,
1237
+ let _ = r;
1238
+ return typeof r == "function" && (_ = g(r)), _ = g(_), te(_) ? (console.log("??? isVNode"), _) : typeof _ == "string" ? (console.log("??? string"), _) : Array.isArray(_) ? (console.log("???"), f(ae, null, [_.map((h, x) => f(N, {
1239
+ item: h,
1249
1240
  index: x
1250
- }, null))])) : typeof A == "object" ? (console.log("??? object"), A.props = g((A == null ? void 0 : A.props) ?? {}), y(Y(() => {
1251
- var m;
1252
- return (m = s == null ? void 0 : s[(A == null ? void 0 : A.way) || "input"]) == null ? void 0 : m.call(s, h(A), {
1253
- _value: A != null && A.queryType ? y(a)[A == null ? void 0 : A.queryType] : y(a),
1254
- _formRef: y(i),
1255
- _isRead: y(u),
1241
+ }, null))])) : typeof _ == "object" ? (console.log("??? object"), _.props = g((_ == null ? void 0 : _.props) ?? {}), c(Y(() => {
1242
+ var h;
1243
+ return (h = s == null ? void 0 : s[(_ == null ? void 0 : _.way) || "input"]) == null ? void 0 : h.call(s, m(_), {
1244
+ _value: _ != null && _.queryType ? c(a)[_ == null ? void 0 : _.queryType] : c(a),
1245
+ _formRef: c(i),
1246
+ _isRead: c(u),
1256
1247
  labelField: $,
1257
1248
  valueField: T
1258
1249
  });
1259
1250
  }))) : null;
1260
1251
  }
1261
- function h(r) {
1262
- return y(r.enum) && (r.options = We(y(r.enum))), r;
1252
+ function m(r) {
1253
+ return c(r.enum) && (r.options = je(c(r.enum))), r;
1263
1254
  }
1264
- function M({
1255
+ function N({
1265
1256
  item: r,
1266
- index: A
1257
+ index: _
1267
1258
  }) {
1268
- var m, x, b, c, C, U;
1269
- return r.formItemProps = g(r == null ? void 0 : r.formItemProps), r.formItemProps || (r.formItemProps = {}), !((m = r.formItemProps) != null && m.labelWidth) && ((x = e.formProps) != null && x.labelWidth) && (r.formItemProps.labelWidth = (b = e.formProps) == null ? void 0 : b.labelWidth), rt(f(Ft, I({
1270
- key: A,
1259
+ var h, x, p, d, C, U;
1260
+ return r.formItemProps = g(r == null ? void 0 : r.formItemProps), r.formItemProps || (r.formItemProps = {}), !((h = r.formItemProps) != null && h.labelWidth) && ((x = e.formProps) != null && x.labelWidth) && (r.formItemProps.labelWidth = (p = e.formProps) == null ? void 0 : p.labelWidth), st(f(Ft, M({
1261
+ key: _,
1271
1262
  showLabel: !(r != null && r.noLabel)
1272
1263
  }, r == null ? void 0 : r.formItemProps, {
1273
- labelWidth: ((c = r == null ? void 0 : r.formItemProps) == null ? void 0 : c.labelWidth) || "auto",
1264
+ labelWidth: ((d = r == null ? void 0 : r.formItemProps) == null ? void 0 : d.labelWidth) || "auto",
1274
1265
  feedback: g((C = r == null ? void 0 : r.formItemProps) == null ? void 0 : C.feedback),
1275
1266
  style: {
1276
1267
  padding: "0 15px",
@@ -1280,26 +1271,26 @@ const hl = /* @__PURE__ */ j((e, {
1280
1271
  },
1281
1272
  path: String(r.key)
1282
1273
  }), {
1283
- default: () => p(r),
1274
+ default: () => b(r),
1284
1275
  label: () => {
1285
1276
  var E, R;
1286
1277
  return f("div", {
1287
1278
  class: r != null && r.labelClass || r != null && r.labelSuffix ? ` ${r == null ? void 0 : r.labelClass} flex items-center gap-col-9px` : ""
1288
- }, [r != null && r.labelSuffix ? typeof (r == null ? void 0 : r.labelSuffix) == "string" ? f(Ve, {
1279
+ }, [r != null && r.labelSuffix ? typeof (r == null ? void 0 : r.labelSuffix) == "string" ? f(He, {
1289
1280
  class: "wh-20px c-inherit",
1290
1281
  ...r == null ? void 0 : r.labelSuffixProps
1291
1282
  }, {
1292
1283
  default: () => [f(gl, {
1293
1284
  name: r == null ? void 0 : r.labelSuffix
1294
1285
  }, null)]
1295
- }) : (E = r == null ? void 0 : r.labelSuffix) == null ? void 0 : E.call(r) : f(ue, null, null), `${y(typeof (r == null ? void 0 : r[e.labelField || "label"]) == "function" ? (R = r == null ? void 0 : r[e.labelField || "label"]) == null ? void 0 : R.call(r) : r == null ? void 0 : r[e.labelField || "label"]) || ""} ${u.value || r.read, " "}
1286
+ }) : (E = r == null ? void 0 : r.labelSuffix) == null ? void 0 : E.call(r) : f(ae, null, null), `${c(typeof (r == null ? void 0 : r[e.labelField || "label"]) == "function" ? (R = r == null ? void 0 : r[e.labelField || "label"]) == null ? void 0 : R.call(r) : r == null ? void 0 : r[e.labelField || "label"]) || ""} ${u.value || r.read, " "}
1296
1287
  `]);
1297
1288
  }
1298
- }), [[ot("corePermission"), r == null ? void 0 : r.permission]]);
1289
+ }), [[ft("corePermission"), r == null ? void 0 : r.permission]]);
1299
1290
  }
1300
1291
  return () => {
1301
1292
  let r;
1302
- return f(V, {
1293
+ return f(k, {
1303
1294
  "wrap-item": !1,
1304
1295
  size: [0, 8],
1305
1296
  style: {
@@ -1309,13 +1300,13 @@ const hl = /* @__PURE__ */ j((e, {
1309
1300
  ...e.style
1310
1301
  }
1311
1302
  }, ml(r = n.value.map(({
1312
- isRender: A = !0,
1313
- ...m
1314
- }, x) => (typeof y(A) != "boolean" ? A != null && A(y(a)) : y(A)) ? m != null && m.render ? m == null ? void 0 : m.render(y(a), x, {
1303
+ isRender: _ = !0,
1304
+ ...h
1305
+ }, x) => (typeof c(_) != "boolean" ? _ != null && _(c(a)) : c(_)) ? h != null && h.render ? h == null ? void 0 : h.render(c(a), x, {
1315
1306
  setValue: w,
1316
- value: y(a)
1317
- }) : f(M, {
1318
- item: m,
1307
+ value: c(a)
1308
+ }) : f(N, {
1309
+ item: h,
1319
1310
  index: x
1320
1311
  }, null) : null)) ? r : {
1321
1312
  default: () => [r]
@@ -1374,31 +1365,31 @@ function bl({
1374
1365
  n != null && n.required && (u[String(g)] = {
1375
1366
  key: g,
1376
1367
  type: "any",
1377
- required: n != null && n.required ? typeof (n == null ? void 0 : n.required) == "function" ? n == null ? void 0 : n.required(y(l), { ...a }) : n == null ? void 0 : n.required : !1,
1368
+ required: n != null && n.required ? typeof (n == null ? void 0 : n.required) == "function" ? n == null ? void 0 : n.required(c(l), { ...a }) : n == null ? void 0 : n.required : !1,
1378
1369
  message: (n == null ? void 0 : n.message) || `请选择${n == null ? void 0 : n[t]}`,
1379
1370
  fields: i
1380
1371
  });
1381
1372
  });
1382
- const d = n != null && n.rule ? typeof (n == null ? void 0 : n.rule) != "function" ? n == null ? void 0 : n.rule : n == null ? void 0 : n.rule(y(l), { ...a }) : i ? {
1373
+ const y = n != null && n.rule ? typeof (n == null ? void 0 : n.rule) != "function" ? n == null ? void 0 : n.rule : n == null ? void 0 : n.rule(c(l), { ...a }) : i ? {
1383
1374
  key: n == null ? void 0 : n.key,
1384
1375
  type: "any",
1385
- required: n != null && n.required ? typeof (n == null ? void 0 : n.required) == "function" ? n == null ? void 0 : n.required(y(l), { ...a }) : n == null ? void 0 : n.required : !1,
1376
+ required: n != null && n.required ? typeof (n == null ? void 0 : n.required) == "function" ? n == null ? void 0 : n.required(c(l), { ...a }) : n == null ? void 0 : n.required : !1,
1386
1377
  message: (n == null ? void 0 : n.message) || `请${(o = n == null ? void 0 : n.options) != null && o.length ? "选择" : "输入"}${n == null ? void 0 : n[t]}`,
1387
1378
  fields: i
1388
1379
  } : {
1389
1380
  key: n == null ? void 0 : n.key,
1390
1381
  type: "any",
1391
- required: n != null && n.required ? typeof (n == null ? void 0 : n.required) == "function" ? n == null ? void 0 : n.required(y(l), { ...a }) : n == null ? void 0 : n.required : !1,
1382
+ required: n != null && n.required ? typeof (n == null ? void 0 : n.required) == "function" ? n == null ? void 0 : n.required(c(l), { ...a }) : n == null ? void 0 : n.required : !1,
1392
1383
  message: (n == null ? void 0 : n.message) || `请${(s = n == null ? void 0 : n.options) != null && s.length ? "选择" : "输入"}${n == null ? void 0 : n[t]}`,
1393
1384
  ...Array.isArray(n == null ? void 0 : n.key) ? {
1394
- validator: (g) => (console.log(g), !(n == null ? void 0 : n.key.every((p) => y(l)[p])) && (n != null && n.required) ? new Error(g == null ? void 0 : g.message) : !0)
1385
+ validator: (g) => (console.log(g), !(n == null ? void 0 : n.key.every((b) => c(l)[b])) && (n != null && n.required) ? new Error(g == null ? void 0 : g.message) : !0)
1395
1386
  } : {}
1396
1387
  };
1397
- return d != null && d.required && (u[String(n == null ? void 0 : n.key)] = d), u;
1388
+ return y != null && y.required && (u[String(n == null ? void 0 : n.key)] = y), u;
1398
1389
  }, {})) || {}
1399
1390
  );
1400
1391
  }
1401
- const Ge = /* @__PURE__ */ j({
1392
+ const Xe = /* @__PURE__ */ j({
1402
1393
  __name: "DataForm",
1403
1394
  props: /* @__PURE__ */ xe({
1404
1395
  value: {},
@@ -1421,9 +1412,9 @@ const Ge = /* @__PURE__ */ j({
1421
1412
  emits: ["update:value"],
1422
1413
  setup(e, { expose: l }) {
1423
1414
  var o;
1424
- const t = re();
1425
- (o = t == null ? void 0 : t.appContext) != null && o.app && ee(t.appContext.app);
1426
- const a = e, u = Y(() => a.options), i = P(), n = Le(e, "value"), d = Y(() => y(
1415
+ const t = ue();
1416
+ (o = t == null ? void 0 : t.appContext) != null && o.app && Z(t.appContext.app);
1417
+ const a = e, u = Y(() => a.options), i = P(), n = Ve(e, "value"), y = Y(() => c(
1427
1418
  u.value ? bl({
1428
1419
  options: u.value,
1429
1420
  model: n,
@@ -1431,44 +1422,44 @@ const Ge = /* @__PURE__ */ j({
1431
1422
  formOpr: { formRef: i }
1432
1423
  }) : {}
1433
1424
  ));
1434
- return console.log(d.value), l({
1425
+ return console.log(y.value), l({
1435
1426
  formRef: i,
1436
- getRule: () => d.value,
1427
+ getRule: () => y.value,
1437
1428
  valid: (s = []) => (console.log("?? valid", s), new Promise((g, w) => {
1438
- var _;
1439
- const p = Oe(s);
1440
- (_ = i.value) == null || _.validate((h) => {
1441
- if (h) return w(h);
1429
+ var O;
1430
+ const b = De(s);
1431
+ (O = i.value) == null || O.validate((m) => {
1432
+ if (m) return w(m);
1442
1433
  g();
1443
- }, (h) => p.length ? p.includes(h == null ? void 0 : h.key) : !0);
1434
+ }, (m) => b.length ? b.includes(m == null ? void 0 : m.key) : !0);
1444
1435
  })),
1445
1436
  confirm: (s) => new Promise((g, w) => {
1446
- var p;
1447
- (p = i.value) == null || p.validate((_) => {
1448
- if (_) return w(_);
1449
- s && s(y(n)), g(y(n));
1437
+ var b;
1438
+ (b = i.value) == null || b.validate((O) => {
1439
+ if (O) return w(O);
1440
+ s && s(c(n)), g(c(n));
1450
1441
  });
1451
1442
  })
1452
- }), (s, g) => (B(), K(y(Ut), I({
1443
+ }), (s, g) => (B(), K(c(Ut), M({
1453
1444
  ref_key: "formRef",
1454
1445
  ref: i,
1455
1446
  model: n.value,
1456
- rules: a.read ? {} : d.value,
1447
+ rules: a.read ? {} : y.value,
1457
1448
  "label-placement": "left",
1458
1449
  "label-width": "100px",
1459
1450
  "require-mark-placement": "right-hanging",
1460
1451
  class: a.dialog ? a.read ? "core-dialog-content" : "core-dialog-main" : "",
1461
1452
  style: { minHeight: a.isNo ? "unset" : null }
1462
1453
  }, a.formProps), {
1463
- default: v(() => [
1464
- f(y(hl), {
1454
+ default: L(() => [
1455
+ f(c(hl), {
1465
1456
  value: n.value,
1466
1457
  "onUpdate:value": g[0] || (g[0] = (w) => n.value = w),
1467
1458
  "form-ref": i.value,
1468
1459
  option: a.options,
1469
1460
  "label-field": a.labelField,
1470
1461
  read: a.read,
1471
- style: ve(a.contentStyle),
1462
+ style: ke(a.contentStyle),
1472
1463
  "form-props": a.formProps
1473
1464
  }, null, 8, ["value", "form-ref", "option", "label-field", "read", "style", "form-props"])
1474
1465
  ]),
@@ -1477,7 +1468,7 @@ const Ge = /* @__PURE__ */ j({
1477
1468
  }
1478
1469
  });
1479
1470
  function xl(e) {
1480
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
1471
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !te(e);
1481
1472
  }
1482
1473
  let H = null, ge = null;
1483
1474
  function wl() {
@@ -1485,7 +1476,7 @@ function wl() {
1485
1476
  if (typeof $dialog < "u" && $dialog)
1486
1477
  return H = $dialog, H;
1487
1478
  try {
1488
- const e = Ce();
1479
+ const e = _e();
1489
1480
  if (e)
1490
1481
  return H = e, H;
1491
1482
  } catch {
@@ -1500,7 +1491,7 @@ function wl() {
1500
1491
  }
1501
1492
  return H = ge.dialog, H;
1502
1493
  }
1503
- function Je({
1494
+ function Ze({
1504
1495
  title: e = "",
1505
1496
  noTitle: l = !1,
1506
1497
  titleFull: t = null,
@@ -1508,16 +1499,16 @@ function Je({
1508
1499
  mode: u = "add",
1509
1500
  modeEnum: i = {},
1510
1501
  labelField: n = "label",
1511
- isNo: d = !0,
1502
+ isNo: y = !0,
1512
1503
  formProps: o = {},
1513
1504
  interfaceFn: s = null,
1514
1505
  interfaceFnCancel: g = null,
1515
1506
  valueData: w,
1516
- read: p,
1517
- isRead: _,
1518
- action: h = null,
1519
- contentStyle: M = {},
1520
- actionProps: N = {}
1507
+ read: b,
1508
+ isRead: O,
1509
+ action: m = null,
1510
+ contentStyle: N = {},
1511
+ actionProps: S = {}
1521
1512
  } = {
1522
1513
  title: "自定义弹窗",
1523
1514
  noTitle: !1,
@@ -1527,8 +1518,8 @@ function Je({
1527
1518
  isRead: !1,
1528
1519
  valueData: {}
1529
1520
  }, r = null) {
1530
- var De;
1531
- const A = wl(), m = {
1521
+ var Ne;
1522
+ const _ = wl(), h = {
1532
1523
  none: {
1533
1524
  sub: "",
1534
1525
  read: !1
@@ -1566,7 +1557,7 @@ function Je({
1566
1557
  read: !1
1567
1558
  },
1568
1559
  ...i
1569
- }, x = P(), b = st([]), c = P({
1560
+ }, x = P(), p = dt([]), d = P({
1570
1561
  ...w
1571
1562
  }), C = {
1572
1563
  justify: "end",
@@ -1583,136 +1574,136 @@ function Je({
1583
1574
  ghost: !0
1584
1575
  },
1585
1576
  onClick: ({
1586
- cancel: S
1577
+ cancel: I
1587
1578
  }) => {
1588
- g ? g(y(c), {
1589
- close: S
1590
- }) : S();
1579
+ g ? g(c(d), {
1580
+ close: I
1581
+ }) : I();
1591
1582
  }
1592
1583
  }, {
1593
1584
  label: "确定",
1594
1585
  valid: !0,
1595
1586
  onClick: async ({
1596
- cancel: S,
1597
- hideLoading: O
1598
- }) => s ? await s(y(c), {
1599
- close: S,
1600
- hideLoading: O
1601
- }) : S()
1587
+ cancel: I,
1588
+ hideLoading: A
1589
+ }) => s ? await s(c(d), {
1590
+ close: I,
1591
+ hideLoading: A
1592
+ }) : I()
1602
1593
  }];
1603
- (Array.isArray(h) ? h : E).forEach((S, O) => {
1604
- b[O] = !1;
1594
+ (Array.isArray(m) ? m : E).forEach((I, A) => {
1595
+ p[A] = !1;
1605
1596
  });
1606
1597
  const R = typeof t == "function" ? () => {
1607
- var S;
1608
- return t(((S = m[u]) == null ? void 0 : S.sub) || "");
1598
+ var I;
1599
+ return t(((I = h[u]) == null ? void 0 : I.sub) || "");
1609
1600
  } : t, D = P();
1610
1601
  function F() {
1611
- var S;
1612
- console.log("取消", c.value), (S = D.value) == null || S.destroy();
1602
+ var I;
1603
+ console.log("取消", d.value), (I = D.value) == null || I.destroy();
1613
1604
  }
1614
- async function G(S = []) {
1615
- var O;
1616
- console.log("开启验证"), await ((O = x.value) == null ? void 0 : O.valid());
1605
+ async function G(I = []) {
1606
+ var A;
1607
+ console.log("开启验证"), await ((A = x.value) == null ? void 0 : A.valid());
1617
1608
  }
1618
- async function k(S) {
1619
- return S && S();
1609
+ async function v(I) {
1610
+ return I && I();
1620
1611
  }
1621
- const ie = p ?? _ ? null : typeof h == "function" ? () => h({
1612
+ const ie = b ?? O ? null : typeof m == "function" ? () => m({
1622
1613
  formRef: x,
1623
- data: y(c),
1614
+ data: c(d),
1624
1615
  d: D.value,
1625
1616
  close: F
1626
1617
  }) : () => {
1627
- let S;
1628
- return f(V, I(C, N, {
1618
+ let I;
1619
+ return f(k, M(C, S, {
1629
1620
  style: {
1630
1621
  ...C == null ? void 0 : C.style,
1631
- ...(N == null ? void 0 : N.style) || {}
1622
+ ...(S == null ? void 0 : S.style) || {}
1632
1623
  }
1633
- }), xl(S = (Array.isArray(h) ? h : E).map((O, fe) => {
1634
- var Ne;
1635
- return O != null && O.render ? (Ne = O == null ? void 0 : O.render) == null ? void 0 : Ne.call(O) : f(z, I({
1624
+ }), xl(I = (Array.isArray(m) ? m : E).map((A, fe) => {
1625
+ var Se;
1626
+ return A != null && A.render ? (Se = A == null ? void 0 : A.render) == null ? void 0 : Se.call(A) : f(z, M({
1636
1627
  type: "primary",
1637
- ghost: O.mode === "cancel"
1638
- }, (O == null ? void 0 : O.props) || {}, (N == null ? void 0 : N.buttonProps) || {}, {
1628
+ ghost: A.mode === "cancel"
1629
+ }, (A == null ? void 0 : A.props) || {}, (S == null ? void 0 : S.buttonProps) || {}, {
1639
1630
  style: {
1640
1631
  ...U,
1641
- ...(O == null ? void 0 : O.style) || {}
1632
+ ...(A == null ? void 0 : A.style) || {}
1642
1633
  },
1643
- loading: b[fe],
1634
+ loading: p[fe],
1644
1635
  onClick: async () => {
1645
- var Se, Ie;
1646
- if (O.mode === "cancel")
1647
- (Se = D.value) == null || Se.destroy();
1636
+ var Ie, Me;
1637
+ if (A.mode === "cancel")
1638
+ (Ie = D.value) == null || Ie.destroy();
1648
1639
  else {
1649
- const ce = () => b[fe] = !0, Me = () => b[fe] = !1;
1650
- O != null && O.loading && ce();
1640
+ const ce = () => p[fe] = !0, Fe = () => p[fe] = !1;
1641
+ A != null && A.loading && ce();
1651
1642
  try {
1652
- console.log("model", y(c)), O != null && O.valid && await G(), console.log(O == null ? void 0 : O.valid), (O != null && O.valid || O != null && O.loading) && ce(), await ((Ie = O == null ? void 0 : O.onClick) == null ? void 0 : Ie.call(O, {
1653
- model: y(c),
1654
- comfirm: k,
1643
+ console.log("model", c(d)), A != null && A.valid && await G(), console.log(A == null ? void 0 : A.valid), (A != null && A.valid || A != null && A.loading) && ce(), await ((Me = A == null ? void 0 : A.onClick) == null ? void 0 : Me.call(A, {
1644
+ model: c(d),
1645
+ comfirm: v,
1655
1646
  cancel: F,
1656
1647
  validate: G,
1657
1648
  showLoading: ce,
1658
- hideLoading: Me
1649
+ hideLoading: Fe
1659
1650
  }));
1660
- } catch (tt) {
1661
- console.log(tt);
1651
+ } catch (at) {
1652
+ console.log(at);
1662
1653
  } finally {
1663
- (O != null && O.valid || O != null && O.loading) && Me();
1654
+ (A != null && A.valid || A != null && A.loading) && Fe();
1664
1655
  }
1665
1656
  }
1666
1657
  }
1667
1658
  }), {
1668
- default: () => [O.label || ""]
1659
+ default: () => [A.label || ""]
1669
1660
  });
1670
- })) ? S : {
1671
- default: () => [S]
1661
+ })) ? I : {
1662
+ default: () => [I]
1672
1663
  });
1673
- }, se = A.create({
1664
+ }, se = _.create({
1674
1665
  type: "info",
1675
1666
  ...pl,
1676
1667
  ...l ? {} : {
1677
- title: R || (((De = m[u]) == null ? void 0 : De.sub) ?? "") + e
1668
+ title: R || (((Ne = h[u]) == null ? void 0 : Ne.sub) ?? "") + e
1678
1669
  },
1679
1670
  style: {
1680
1671
  width: "500px"
1681
1672
  },
1682
- content: () => f(Ge, {
1683
- ref: (S) => {
1684
- x.value = S;
1673
+ content: () => f(Xe, {
1674
+ ref: (I) => {
1675
+ x.value = I;
1685
1676
  },
1686
1677
  options: a,
1687
- value: y(c),
1688
- "onUpdate:value": (S) => c.value = S,
1689
- isNo: d,
1690
- read: p ?? _,
1678
+ value: c(d),
1679
+ "onUpdate:value": (I) => d.value = I,
1680
+ isNo: y,
1681
+ read: b ?? O,
1691
1682
  labelField: n,
1692
1683
  formProps: o,
1693
- contentStyle: M,
1684
+ contentStyle: N,
1694
1685
  dialog: !0
1695
1686
  }, null),
1696
1687
  action: ie,
1697
1688
  // ...readButton.value,
1698
1689
  ...r,
1699
- class: `core-dialog ${p ?? _ ? "core-dialog-read" : ""} ${(r == null ? void 0 : r.class) || ""}`
1690
+ class: `core-dialog ${b ?? O ? "core-dialog-read" : ""} ${(r == null ? void 0 : r.class) || ""}`
1700
1691
  });
1701
1692
  return D.value = se, {
1702
1693
  cancel: F,
1703
- setValue: (S, O) => O ? c.value[O] = S : c.value = {
1704
- ...c.value,
1705
- ...S
1694
+ setValue: (I, A) => A ? d.value[A] = I : d.value = {
1695
+ ...d.value,
1696
+ ...I
1706
1697
  },
1707
- model: y(c),
1708
- modeEnum: m
1698
+ model: c(d),
1699
+ modeEnum: h
1709
1700
  };
1710
1701
  }
1711
- function Vl() {
1712
- const e = Ce();
1713
- return He(e), (l, t) => Je(l, t);
1702
+ function zl() {
1703
+ const e = _e();
1704
+ return Ge(e), (l, t) => Ze(l, t);
1714
1705
  }
1715
- const _l = {
1706
+ const Ol = {
1716
1707
  class: "flex-1"
1717
1708
  }, Cl = /* @__PURE__ */ j({
1718
1709
  __name: "CommonQuery",
@@ -1758,68 +1749,68 @@ const _l = {
1758
1749
  setup(e, {
1759
1750
  emit: l
1760
1751
  }) {
1761
- var A;
1762
- const t = re();
1763
- (A = t == null ? void 0 : t.appContext) != null && A.app && ee(t.appContext.app);
1764
- function a(m, x) {
1765
- let b;
1766
- return function(...c) {
1767
- clearTimeout(b), b = setTimeout(() => {
1768
- m.apply(this, c);
1752
+ var _;
1753
+ const t = ue();
1754
+ (_ = t == null ? void 0 : t.appContext) != null && _.app && Z(t.appContext.app);
1755
+ function a(h, x) {
1756
+ let p;
1757
+ return function(...d) {
1758
+ clearTimeout(p), p = setTimeout(() => {
1759
+ h.apply(this, d);
1769
1760
  }, x);
1770
1761
  };
1771
1762
  }
1772
1763
  const u = l, i = e;
1773
- function n(m) {
1774
- return m.map((x) => ({
1764
+ function n(h) {
1765
+ return h.map((x) => ({
1775
1766
  ...x,
1776
1767
  props: {
1777
1768
  ...x.props,
1778
1769
  ...!x.way || x.way === "input" ? {
1779
- onUpdateValue: (...b) => {
1780
- var c, C;
1781
- (C = (c = x.props) == null ? void 0 : c.onUpdateValue) == null || C.call(c, ...b), d();
1770
+ onUpdateValue: (...p) => {
1771
+ var d, C;
1772
+ (C = (d = x.props) == null ? void 0 : d.onUpdateValue) == null || C.call(d, ...p), y();
1782
1773
  }
1783
1774
  } : {},
1784
1775
  ...(x == null ? void 0 : x.way) === "select" ? {
1785
- onUpdateValue: (...b) => {
1786
- var c, C;
1787
- (C = (c = x.props) == null ? void 0 : c.onUpdateValue) == null || C.call(c, ...b), d();
1776
+ onUpdateValue: (...p) => {
1777
+ var d, C;
1778
+ (C = (d = x.props) == null ? void 0 : d.onUpdateValue) == null || C.call(d, ...p), y();
1788
1779
  }
1789
1780
  } : {}
1790
1781
  }
1791
1782
  }));
1792
1783
  }
1793
- const d = a(() => {
1784
+ const y = a(() => {
1794
1785
  u("submit");
1795
1786
  }, 500);
1796
1787
  function o() {
1797
- d();
1788
+ y();
1798
1789
  }
1799
- const s = P(!1), g = Le(e, "query"), w = {
1790
+ const s = P(!1), g = Ve(e, "query"), w = {
1800
1791
  style: {
1801
1792
  width: "33%"
1802
1793
  }
1803
- }, p = Y(() => {
1804
- var m;
1805
- return (m = i.options) == null ? void 0 : m.map((x) => (x == null ? void 0 : x.way) || "input");
1794
+ }, b = Y(() => {
1795
+ var h;
1796
+ return (h = i.options) == null ? void 0 : h.map((x) => (x == null ? void 0 : x.way) || "input");
1806
1797
  });
1807
- je(p.value);
1808
- const _ = Y(() => {
1809
- var m;
1798
+ Qe(b.value);
1799
+ const O = Y(() => {
1800
+ var h;
1810
1801
  try {
1811
1802
  const x = [];
1812
- for (let b = 0; b < (((m = i.options) == null ? void 0 : m.length) || 0); b++) {
1813
- const c = i.options[b];
1814
- if (c != null && c.enum && !(c != null && c.options) && (c.options = We(c.enum)), c != null && c.props || (c.props = {
1803
+ for (let p = 0; p < (((h = i.options) == null ? void 0 : h.length) || 0); p++) {
1804
+ const d = i.options[p];
1805
+ if (d != null && d.enum && !(d != null && d.options) && (d.options = je(d.enum)), d != null && d.props || (d.props = {
1815
1806
  size: i.size
1816
- }), !(c != null && c.formItemProps))
1817
- c.formItemProps = {
1807
+ }), !(d != null && d.formItemProps))
1808
+ d.formItemProps = {
1818
1809
  ...w
1819
1810
  };
1820
1811
  else {
1821
- const U = typeof c.formItemProps == "function" ? c.formItemProps({}, {}) : c.formItemProps;
1822
- c.formItemProps = {
1812
+ const U = typeof d.formItemProps == "function" ? d.formItemProps({}, {}) : d.formItemProps;
1813
+ d.formItemProps = {
1823
1814
  ...w,
1824
1815
  ...U,
1825
1816
  style: {
@@ -1828,10 +1819,10 @@ const _l = {
1828
1819
  }
1829
1820
  };
1830
1821
  }
1831
- const C = (c == null ? void 0 : c.key) || (c == null ? void 0 : c.value);
1822
+ const C = (d == null ? void 0 : d.key) || (d == null ? void 0 : d.value);
1832
1823
  if (!C) throw new Error("key no set");
1833
1824
  x.push({
1834
- ...c,
1825
+ ...d,
1835
1826
  key: C
1836
1827
  });
1837
1828
  }
@@ -1839,76 +1830,76 @@ const _l = {
1839
1830
  } catch (x) {
1840
1831
  return console.warn("error", x), [];
1841
1832
  }
1842
- }), h = {
1833
+ }), m = {
1843
1834
  style: {
1844
1835
  borderRadius: "3px"
1845
1836
  }
1846
- }, M = {
1847
- search: () => f(z, I({
1837
+ }, N = {
1838
+ search: () => f(z, M({
1848
1839
  type: i.type,
1849
1840
  loading: s.value,
1850
1841
  "default-props": {
1851
1842
  attrType: "submit"
1852
1843
  },
1853
1844
  onClick: () => o()
1854
- }, h), {
1845
+ }, m), {
1855
1846
  default: () => "搜索",
1856
- icon: () => f(kt, null, null)
1847
+ icon: () => f(vt, null, null)
1857
1848
  }),
1858
- reset: () => f(z, I({
1849
+ reset: () => f(z, M({
1859
1850
  type: "default",
1860
1851
  onClick: () => {
1861
- N();
1852
+ S();
1862
1853
  }
1863
- }, h), {
1854
+ }, m), {
1864
1855
  default: () => "重置",
1865
1856
  icon: () => f(Yt, null, null)
1866
1857
  })
1867
1858
  };
1868
- function N() {
1869
- var m;
1870
- (m = i.options) == null || m.forEach((x) => {
1871
- const b = (x == null ? void 0 : x.key) || (x == null ? void 0 : x.value);
1872
- b && (x != null && x.queryType ? (g.value[x.queryType] || (g.value[x.queryType] = {}), g.value[x.queryType][b] = null) : g.value[b] = null);
1859
+ function S() {
1860
+ var h;
1861
+ (h = i.options) == null || h.forEach((x) => {
1862
+ const p = (x == null ? void 0 : x.key) || (x == null ? void 0 : x.value);
1863
+ p && (x != null && x.queryType ? (g.value[x.queryType] || (g.value[x.queryType] = {}), g.value[x.queryType][p] = null) : g.value[p] = null);
1873
1864
  }), u("reset");
1874
1865
  }
1875
- function r(m) {
1876
- m.key === "Enter" && o();
1866
+ function r(h) {
1867
+ h.key === "Enter" && o();
1877
1868
  }
1878
- return ke(() => {
1869
+ return Le(() => {
1879
1870
  document.addEventListener("keydown", r);
1880
- }), ft(() => {
1871
+ }), yt(() => {
1881
1872
  document.removeEventListener("keydown", r);
1882
- }), (m, x) => (B(), K(y(V), {
1873
+ }), (h, x) => (B(), K(c(k), {
1883
1874
  "wrap-item": !1,
1884
1875
  justify: "space-between",
1885
1876
  align: "center",
1886
1877
  wrap: !1
1887
1878
  }, {
1888
- default: v(() => [_e("div", _l, [f(Ge, {
1879
+ default: L(() => [Ae("div", Ol, [f(Xe, {
1889
1880
  value: g.value,
1890
- "onUpdate:value": x[0] || (x[0] = (b) => g.value = b),
1891
- options: _.value,
1881
+ "onUpdate:value": x[0] || (x[0] = (p) => g.value = p),
1882
+ options: O.value,
1892
1883
  "form-props": {
1893
1884
  showFeedback: !1
1894
1885
  }
1895
- }, null, 8, ["value", "options"])]), i.noButton ? ct("", !0) : (B(), K(y(V), {
1886
+ }, null, 8, ["value", "options"])]), i.noButton ? gt("", !0) : (B(), K(c(k), {
1896
1887
  key: 0,
1897
1888
  align: "center",
1898
1889
  wrap: !1
1899
1890
  }, {
1900
- default: v(() => [be(m.$slots, "left-btn", {}, void 0, !0), (B(!0), ne(ue, null, he(i.btn, (b, c) => {
1891
+ default: L(() => [be(h.$slots, "left-btn", {}, void 0, !0), (B(!0), le(ae, null, he(i.btn, (p, d) => {
1901
1892
  var C;
1902
- return B(), K(dt((C = M == null ? void 0 : M[b]) == null ? void 0 : C.call(M)), {
1903
- key: c
1893
+ return B(), K(mt((C = N == null ? void 0 : N[p]) == null ? void 0 : C.call(N)), {
1894
+ key: d
1904
1895
  });
1905
- }), 128)), be(m.$slots, "right-btn", {}, void 0, !0)]),
1896
+ }), 128)), be(h.$slots, "right-btn", {}, void 0, !0)]),
1906
1897
  _: 3
1907
1898
  }))]),
1908
1899
  _: 3
1909
1900
  }));
1910
1901
  }
1911
- }), zl = /* @__PURE__ */ oe(Cl, [["__scopeId", "data-v-643f6214"]]), Qe = /* @__PURE__ */ j(({
1902
+ }), Wl = /* @__PURE__ */ re(Cl, [["__scopeId", "data-v-e03318bb"]]), et = /* @__PURE__ */ j(({
1912
1903
  action: e,
1913
1904
  row: l,
1914
1905
  index: t
@@ -1918,10 +1909,10 @@ const _l = {
1918
1909
  disabled: u,
1919
1910
  type: i = "primary",
1920
1911
  loading: n = !1,
1921
- label: d = null,
1912
+ label: y = null,
1922
1913
  ...o
1923
1914
  } = e || {}, s = P(!1);
1924
- return () => f(z, I({
1915
+ return () => f(z, M({
1925
1916
  text: !0,
1926
1917
  onClick: async () => {
1927
1918
  if (a)
@@ -1935,7 +1926,7 @@ const _l = {
1935
1926
  loading: s.value,
1936
1927
  type: typeof u == "function" && u(l) ? "default" : i
1937
1928
  }, o), {
1938
- default: () => [typeof d == "function" ? d == null ? void 0 : d(l) : d]
1929
+ default: () => [typeof y == "function" ? y == null ? void 0 : y(l) : y]
1939
1930
  });
1940
1931
  }, {
1941
1932
  props: {
@@ -1952,7 +1943,7 @@ const _l = {
1952
1943
  default: 0
1953
1944
  }
1954
1945
  }
1955
- }), Xe = /* @__PURE__ */ j(({
1946
+ }), tt = /* @__PURE__ */ j(({
1956
1947
  onClick: e,
1957
1948
  row: l,
1958
1949
  index: t,
@@ -2002,48 +1993,48 @@ const _l = {
2002
1993
  }
2003
1994
  }
2004
1995
  });
2005
- function Be(e) {
2006
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
1996
+ function Ye(e) {
1997
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !te(e);
2007
1998
  }
2008
- const Ol = /* @__PURE__ */ j((e) => {
1999
+ const Al = /* @__PURE__ */ j((e) => {
2009
2000
  const l = e.options.length, t = P(!1), a = Y(() => e.options.slice(0, t.value ? l : e.max)), u = Y(() => e.options.slice(e.max));
2010
2001
  function i(n) {
2011
2002
  return n == null ? void 0 : n.map(({
2012
- isRender: d = () => !0,
2003
+ isRender: y = () => !0,
2013
2004
  onClick: o = null,
2014
2005
  mode: s = null,
2015
2006
  disabled: g = !1,
2016
2007
  type: w = "primary",
2017
- ...p
2018
- }, _) => (typeof d == "function" ? d(e.data) : d) ? s === "pop" ? f(Xe, {
2008
+ ...b
2009
+ }, O) => (typeof y == "function" ? y(e.data) : y) ? s === "pop" ? f(tt, {
2019
2010
  onClick: o,
2020
2011
  row: e.data,
2021
2012
  index: e.index,
2022
- action: p,
2023
- key: ae(e.data, e.index) + _
2013
+ action: b,
2014
+ key: ne(e.data, e.index) + O
2024
2015
  }, {
2025
- default: () => [f(z, I({
2016
+ default: () => [f(z, M({
2026
2017
  text: !0,
2027
2018
  disabled: typeof g == "function" ? g(e.data) : g,
2028
2019
  type: typeof g == "function" && g(e.data) ? "default" : w
2029
- }, p), {
2030
- default: () => [typeof (p == null ? void 0 : p.label) == "function" ? p == null ? void 0 : p.label(e.data) : p == null ? void 0 : p.label]
2020
+ }, b), {
2021
+ default: () => [typeof (b == null ? void 0 : b.label) == "function" ? b == null ? void 0 : b.label(e.data) : b == null ? void 0 : b.label]
2031
2022
  })]
2032
- }) : f(Qe, {
2023
+ }) : f(et, {
2033
2024
  row: e.data,
2034
2025
  action: {
2035
- ...p,
2026
+ ...b,
2036
2027
  disabled: g,
2037
2028
  onClick: o,
2038
2029
  type: w
2039
2030
  },
2040
2031
  index: e.index,
2041
- key: ae(e.data, e.index) + _
2042
- }, null) : void 0).filter((d) => d !== void 0);
2032
+ key: ne(e.data, e.index) + O
2033
+ }, null) : void 0).filter((y) => y !== void 0);
2043
2034
  }
2044
2035
  return () => {
2045
2036
  let n;
2046
- return f(V, {
2037
+ return f(k, {
2047
2038
  style: {
2048
2039
  width: "100%"
2049
2040
  },
@@ -2051,10 +2042,10 @@ const Ol = /* @__PURE__ */ j((e) => {
2051
2042
  justify: "center",
2052
2043
  align: "center"
2053
2044
  }, {
2054
- default: () => [f(V, {
2045
+ default: () => [f(k, {
2055
2046
  "wrap-item": !1,
2056
2047
  align: "center"
2057
- }, Be(n = i(a.value)) ? n : {
2048
+ }, Ye(n = i(a.value)) ? n : {
2058
2049
  default: () => [n]
2059
2050
  }), f(qt, {
2060
2051
  trigger: "click"
@@ -2063,19 +2054,19 @@ const Ol = /* @__PURE__ */ j((e) => {
2063
2054
  text: !0,
2064
2055
  type: "info"
2065
2056
  }, {
2066
- default: () => [Z("更多")]
2057
+ default: () => [X("更多")]
2067
2058
  }),
2068
2059
  default: () => {
2069
- let d;
2070
- return f(V, {
2060
+ let y;
2061
+ return f(k, {
2071
2062
  "wrap-item": !1,
2072
2063
  align: "center",
2073
2064
  style: {
2074
2065
  width: "250px",
2075
2066
  padding: "5px"
2076
2067
  }
2077
- }, Be(d = i(u.value)) ? d : {
2078
- default: () => [d]
2068
+ }, Ye(y = i(u.value)) ? y : {
2069
+ default: () => [y]
2079
2070
  });
2080
2071
  }
2081
2072
  })]
@@ -2102,13 +2093,13 @@ const Ol = /* @__PURE__ */ j((e) => {
2102
2093
  }
2103
2094
  }
2104
2095
  });
2105
- function Al() {
2096
+ function _l() {
2106
2097
  var l;
2107
2098
  const e = el();
2108
2099
  if (e)
2109
2100
  return e;
2110
2101
  try {
2111
- const t = re();
2102
+ const t = ue();
2112
2103
  if ((l = t == null ? void 0 : t.appContext) != null && l.app)
2113
2104
  return null;
2114
2105
  } catch {
@@ -2125,13 +2116,13 @@ function Q(e = {}, l = null) {
2125
2116
  }
2126
2117
  } : e;
2127
2118
  }
2128
- function Wl(e, l = {}) {
2119
+ function Hl(e, l = {}) {
2129
2120
  if (!e)
2130
2121
  throw new Error("dialogInstance 是必需的。请在组件中使用 useDialog() 获取实例,然后传递给此函数。");
2131
2122
  const t = Q(l, e);
2132
2123
  return e.create(t);
2133
2124
  }
2134
- function Hl(e) {
2125
+ function Kl(e) {
2135
2126
  if (!e)
2136
2127
  throw new Error("dialogInstance 是必需的。请在组件中使用 useDialog() 获取实例。");
2137
2128
  return {
@@ -2158,10 +2149,10 @@ function Hl(e) {
2158
2149
  };
2159
2150
  }
2160
2151
  function Dl(e) {
2161
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !le(e);
2152
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !te(e);
2162
2153
  }
2163
- const ae = (e, l) => e ? JSON.stringify(e) : String(l);
2164
- function Kl(e, l = null, t) {
2154
+ const ne = (e, l) => e ? JSON.stringify(e) : String(l);
2155
+ function jl(e, l = null, t) {
2165
2156
  const a = {
2166
2157
  max: 4,
2167
2158
  width: 80
@@ -2174,11 +2165,11 @@ function Kl(e, l = null, t) {
2174
2165
  throw new TypeError("需要配置数组");
2175
2166
  console.log("ddd");
2176
2167
  let i = [], n = 0;
2177
- const d = [];
2168
+ const y = [];
2178
2169
  return Array.isArray(e) && (i = e, i.forEach((o, s) => {
2179
2170
  var g, w;
2180
- o.permission ? we(o.permission) && ((!t || typeof u == "object" && s < u.max) && (n += (typeof (o == null ? void 0 : o.label) == "string" ? (g = o == null ? void 0 : o.label) == null ? void 0 : g.length : 10) * 12 + 36), d.push(o)) : ((!t || typeof u == "object" && s < u.max) && (n += (typeof (o == null ? void 0 : o.label) == "string" ? (w = o == null ? void 0 : o.label) == null ? void 0 : w.length : 10) * 12 + 36), d.push(o));
2181
- })), n = Math.max(80, n), n += 0, u && (n += 2), d.length ? {
2171
+ o.permission ? Ce(o.permission) && ((!t || typeof u == "object" && s < u.max) && (n += (typeof (o == null ? void 0 : o.label) == "string" ? (g = o == null ? void 0 : o.label) == null ? void 0 : g.length : 10) * 12 + 36), y.push(o)) : ((!t || typeof u == "object" && s < u.max) && (n += (typeof (o == null ? void 0 : o.label) == "string" ? (w = o == null ? void 0 : o.label) == null ? void 0 : w.length : 10) * 12 + 36), y.push(o));
2172
+ })), n = Math.max(80, n), n += 0, u && (n += 2), y.length ? {
2182
2173
  title: "操作",
2183
2174
  key: "opr",
2184
2175
  fixed: "right",
@@ -2186,48 +2177,48 @@ function Kl(e, l = null, t) {
2186
2177
  width: n,
2187
2178
  ...l,
2188
2179
  render(o, s) {
2189
- const g = u ? f(Ol, {
2180
+ const g = u ? f(Al, {
2190
2181
  data: o,
2191
2182
  index: s,
2192
2183
  max: u.max,
2193
- options: d
2194
- }, null) : d.map(({
2184
+ options: y
2185
+ }, null) : y.map(({
2195
2186
  isRender: w = () => !0,
2196
- onClick: p = null,
2197
- mode: _ = null,
2198
- disabled: h = !1,
2199
- type: M = "primary",
2200
- ...N
2201
- }, r) => (typeof w == "function" ? w(o) : w) ? _ === "pop" ? f(Xe, {
2202
- onClick: p,
2187
+ onClick: b = null,
2188
+ mode: O = null,
2189
+ disabled: m = !1,
2190
+ type: N = "primary",
2191
+ ...S
2192
+ }, r) => (typeof w == "function" ? w(o) : w) ? O === "pop" ? f(tt, {
2193
+ onClick: b,
2203
2194
  row: o,
2204
2195
  index: s,
2205
- action: N,
2206
- key: ae(o, s) + r
2196
+ action: S,
2197
+ key: ne(o, s) + r
2207
2198
  }, {
2208
- default: () => [f(z, I({
2199
+ default: () => [f(z, M({
2209
2200
  text: !0,
2210
- disabled: typeof h == "function" ? h(o) : h,
2211
- type: typeof h == "function" && h(o) ? "default" : M
2212
- }, N), {
2213
- default: () => [typeof (N == null ? void 0 : N.label) == "function" ? N == null ? void 0 : N.label(o) : N == null ? void 0 : N.label]
2201
+ disabled: typeof m == "function" ? m(o) : m,
2202
+ type: typeof m == "function" && m(o) ? "default" : N
2203
+ }, S), {
2204
+ default: () => [typeof (S == null ? void 0 : S.label) == "function" ? S == null ? void 0 : S.label(o) : S == null ? void 0 : S.label]
2214
2205
  })]
2215
- }) : f(Qe, {
2206
+ }) : f(et, {
2216
2207
  row: o,
2217
2208
  action: {
2218
- ...N,
2219
- disabled: h,
2220
- onClick: p,
2221
- type: M
2209
+ ...S,
2210
+ disabled: m,
2211
+ onClick: b,
2212
+ type: N
2222
2213
  },
2223
2214
  index: s,
2224
- key: ae(o, s) + r
2215
+ key: ne(o, s) + r
2225
2216
  }, null) : void 0).filter((w) => w !== void 0);
2226
- return l != null && l.isRender ? l == null ? void 0 : l.render(o) : f(V, {
2217
+ return l != null && l.isRender ? l == null ? void 0 : l.render(o) : f(k, {
2227
2218
  align: "center",
2228
2219
  "wrap-item": !1,
2229
2220
  size: 18,
2230
- key: ae(o, s)
2221
+ key: ne(o, s)
2231
2222
  }, Dl(g) ? g : {
2232
2223
  default: () => [g]
2233
2224
  });
@@ -2235,7 +2226,7 @@ function Kl(e, l = null, t) {
2235
2226
  } : void 0;
2236
2227
  }
2237
2228
  async function Nl(e, l = null) {
2238
- const t = Al();
2229
+ const t = _l();
2239
2230
  if (!t)
2240
2231
  throw new Error("无法获取 dialog 实例。请使用 useQRCode hook 或在组件中通过 setupConfig 注册 dialog 实例。");
2241
2232
  const a = P(null), u = P(!1), i = Q({
@@ -2263,19 +2254,19 @@ async function Nl(e, l = null) {
2263
2254
  }, t);
2264
2255
  return t.info(i), l && (u.value = !0, a.value = await l(), u.value = !1), !0;
2265
2256
  }
2266
- function jl() {
2267
- const e = Ce();
2268
- return He(e), (l, t) => Nl(l, t);
2257
+ function Gl() {
2258
+ const e = _e();
2259
+ return Ge(e), (l, t) => Nl(l, t);
2269
2260
  }
2270
2261
  function Sl(e) {
2271
2262
  var l, t;
2272
2263
  if ((l = e == null ? void 0 : e.children) != null && l.length) {
2273
2264
  const a = [];
2274
2265
  e.children.forEach((u) => {
2275
- var n, d, o, s;
2266
+ var n, y, o, s;
2276
2267
  Sl(u);
2277
2268
  let i = [];
2278
- typeof ((n = u == null ? void 0 : u.meta) == null ? void 0 : n.permission) == "string" ? i = [u.meta.permission] : Array.isArray((d = u.meta) == null ? void 0 : d.permission) ? i.push(...u.meta.permission) : typeof ((o = u.meta) == null ? void 0 : o.permission) == "object" ? i.push(...Il(Ze(u.meta.permission))) : (s = u == null ? void 0 : u.meta) != null && s.permission || (i = null), u.meta.permission = i, a.push(...new Set(i));
2269
+ typeof ((n = u == null ? void 0 : u.meta) == null ? void 0 : n.permission) == "string" ? i = [u.meta.permission] : Array.isArray((y = u.meta) == null ? void 0 : y.permission) ? i.push(...u.meta.permission) : typeof ((o = u.meta) == null ? void 0 : o.permission) == "object" ? i.push(...Il(lt(u.meta.permission))) : (s = u == null ? void 0 : u.meta) != null && s.permission || (i = null), u.meta.permission = i, a.push(...new Set(i));
2279
2270
  }), (t = e == null ? void 0 : e.meta) != null && t.permission ? e.meta.permission = [...new Set(e.meta.permission.concat(a))] : e.meta.permission = a;
2280
2271
  }
2281
2272
  return e;
@@ -2284,37 +2275,37 @@ function Il(...e) {
2284
2275
  const l = e == null ? void 0 : e.map((t) => Array.isArray(t) ? t : t == null ? void 0 : t.ALL);
2285
2276
  return [].concat(...l);
2286
2277
  }
2287
- function Ze(e) {
2288
- return e ? Object.keys(e).reduce((l, t) => (typeof e[t] != "string" ? l.concat(Ze(e[t])) : l.push(e[t]), l), []) : [];
2278
+ function lt(e) {
2279
+ return e ? Object.keys(e).reduce((l, t) => (typeof e[t] != "string" ? l.concat(lt(e[t])) : l.push(e[t]), l), []) : [];
2289
2280
  }
2290
- function Gl(...e) {
2281
+ function Jl(...e) {
2291
2282
  return {
2292
- ...et("auth", e)
2283
+ ...nt("auth", e)
2293
2284
  };
2294
2285
  }
2295
- function Jl(...e) {
2286
+ function Ql(...e) {
2296
2287
  return {
2297
- ...et("api", e)
2288
+ ...nt("api", e)
2298
2289
  };
2299
2290
  }
2300
- function Ql(e, l = {}) {
2291
+ function Xl(e, l = {}) {
2301
2292
  const t = Object.keys(l);
2302
2293
  return t.length && t.forEach((a) => {
2303
2294
  const u = new RegExp(`${a}`, "g");
2304
2295
  e = e == null ? void 0 : e.replace(u, l[a]);
2305
2296
  }), e;
2306
2297
  }
2307
- function et(e, l) {
2298
+ function nt(e, l) {
2308
2299
  var n;
2309
- const t = ze(), a = zt(), u = Ye(((n = t == null ? void 0 : t.meta) == null ? void 0 : n[e]) ?? {}), i = Oe(l[0]);
2300
+ const t = Ke(), a = zt(), u = ve(((n = t == null ? void 0 : t.meta) == null ? void 0 : n[e]) ?? {}), i = De(l[0]);
2310
2301
  return i != null && i.length && a.getRoutes().filter((o) => i.includes(o.name)).forEach((o) => {
2311
2302
  var s;
2312
- (s = o.meta) != null && s[e] && (u[o.name] = Ye(o.meta[e]));
2303
+ (s = o.meta) != null && s[e] && (u[o.name] = ve(o.meta[e]));
2313
2304
  }), {
2314
2305
  ...u
2315
2306
  };
2316
2307
  }
2317
- function Ye(e = {}) {
2308
+ function ve(e = {}) {
2318
2309
  return Object.keys(e).reduce((l, t) => {
2319
2310
  const a = e[t];
2320
2311
  return typeof a == "object" ? l[t] = a == null ? void 0 : a.key : typeof a == "string" && (l[t] = String(a)), l;
@@ -2332,7 +2323,7 @@ const me = {
2332
2323
  descend: {
2333
2324
  title: "降序",
2334
2325
  value: !1,
2335
- Icon: ye(Lt),
2326
+ Icon: ye(kt),
2336
2327
  fn: (e) => {
2337
2328
  e.sortFieldName = "", e.desc = !0;
2338
2329
  }
@@ -2340,7 +2331,7 @@ const me = {
2340
2331
  false: {
2341
2332
  title: "默认",
2342
2333
  value: null,
2343
- Icon: ye(vt, {
2334
+ Icon: ye(Lt, {
2344
2335
  style: "transform:rotateZ(90deg)"
2345
2336
  }),
2346
2337
  fn: (e) => {
@@ -2349,33 +2340,33 @@ const me = {
2349
2340
  }
2350
2341
  };
2351
2342
  function Ml(e, l = {}) {
2352
- ee(e);
2343
+ Z(e);
2353
2344
  }
2354
- const Xl = {
2345
+ const Zl = {
2355
2346
  install: Ml
2356
2347
  };
2357
2348
  export {
2358
- $e as ArrayToObject,
2359
- zl as CommonQuery,
2360
- Xl as CorePlugin,
2361
- Ge as DataForm,
2349
+ Te as ArrayToObject,
2350
+ Wl as CommonQuery,
2351
+ Zl as CorePlugin,
2352
+ Xe as DataForm,
2362
2353
  al as DataTable,
2363
- We as ObjectToArray,
2364
- Qe as OprButton,
2354
+ je as ObjectToArray,
2355
+ et as OprButton,
2365
2356
  hl as Options,
2366
- Xe as Pop,
2357
+ tt as Pop,
2367
2358
  Yl as autoRegisterDirectives,
2368
2359
  Sl as cellectChildenPermission,
2369
- we as checkPermission,
2370
- Je as commonDialogMethod,
2371
- Kl as createActionColumnJsx,
2372
- Wl as createDialog,
2373
- Hl as createDialogMethods,
2360
+ Ce as checkPermission,
2361
+ Ze as commonDialogMethod,
2362
+ jl as createActionColumnJsx,
2363
+ Hl as createDialog,
2364
+ Kl as createDialogMethods,
2374
2365
  Q as createDialogOptions,
2375
2366
  Nl as createQRCode,
2376
2367
  ul as customUpload,
2377
- qe as ellipsis,
2378
- vl as getAllOptions,
2368
+ Ee as ellipsis,
2369
+ kl as getAllOptions,
2379
2370
  Qt as getBaseURL,
2380
2371
  Tl as getConfig,
2381
2372
  Zt as getDialogConfig,
@@ -2383,24 +2374,25 @@ export {
2383
2374
  W as getFileUrl,
2384
2375
  ll as getGlobalApp,
2385
2376
  Bl as getHasPermission,
2386
- je as getOptions,
2377
+ Qe as getOptions,
2387
2378
  Xt as getUploadMethod,
2388
2379
  $ as globalLabelField,
2389
2380
  T as globalValueField,
2390
- Ql as handleParams,
2391
- tn as initRouteMeta,
2381
+ Xl as handleParams,
2382
+ ln as initRouteMeta,
2392
2383
  bl as initRules,
2393
2384
  Ml as install,
2394
2385
  me as orderEnum,
2395
2386
  tl as permissionDirective,
2396
- He as registerDialogInstance,
2397
- ee as registerDirectives,
2398
- kl as registryUpload,
2387
+ Ge as registerDialogInstance,
2388
+ Z as registerDirectives,
2389
+ vl as registryUpload,
2399
2390
  Jt as setupConfig,
2400
- Ll as setupOptions,
2401
- Oe as toArray,
2402
- Jl as useApiConfig,
2403
- Gl as useAuthPermission,
2404
- Vl as useCommonDialog,
2405
- jl as useQRCode
2391
+ Ll as setupInitOptions,
2392
+ Vl as setupOptions,
2393
+ De as toArray,
2394
+ Ql as useApiConfig,
2395
+ Jl as useAuthPermission,
2396
+ zl as useCommonDialog,
2397
+ Gl as useQRCode
2406
2398
  };