asiaint-lowcode 3.0.75 → 3.1.1

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.
Files changed (39) hide show
  1. package/README.md +31 -31
  2. package/dist/asiaint-lowcode.js +3 -3
  3. package/dist/asiaint-lowcode.umd.cjs +141 -141
  4. package/dist/index.d.ts +146 -26
  5. package/dist/lazy/{Card-BL132uF0.js → Card-BotexRow.js} +2 -2
  6. package/dist/lazy/{Cascader-BNajnGXt.js → Cascader-DlPFMm4q.js} +2 -1
  7. package/dist/lazy/{Checkbox-CB78q85K.js → Checkbox-B3ZlaMu-.js} +8 -7
  8. package/dist/lazy/{Collapse-BT3Z_TeL.js → Collapse-CvvDvzUe.js} +1 -1
  9. package/dist/lazy/{Component-DdZRdqp7.js → Component-1ifx_71s.js} +1 -1
  10. package/dist/lazy/{Component-OAYlB5bp.js → Component-BFthFsDN.js} +2 -2
  11. package/dist/lazy/{Component-Cwe8AZcy.js → Component-BMyo9RcE.js} +1 -1
  12. package/dist/lazy/{Component-CVbGsSj6.js → Component-C4EAi6pq.js} +4 -4
  13. package/dist/lazy/{Component-Dl3PXGm5.js → Component-CJLLkcKZ.js} +1 -1
  14. package/dist/lazy/{Component-BNOSHXwG.js → Component-k70ODABG.js} +2 -2
  15. package/dist/lazy/{CurdCard-BrBulKvO.js → CurdCard-Dxlf9fsv.js} +50 -44
  16. package/dist/lazy/{Custom-BliwSKbp.js → Custom-DjAqb9Wc.js} +7 -7
  17. package/dist/lazy/{DragList-Buw-1bQc.js → DragList-BaXe5qJv.js} +35 -34
  18. package/dist/lazy/{FormList-DTdAAtrD.js → FormList-k6c-UNG8.js} +1 -1
  19. package/dist/lazy/{Grid-DUAIHsOo.js → Grid-OhcM4HDS.js} +1 -1
  20. package/dist/lazy/{Inline-BkAIXUU0.js → Inline-Cwpbm9wv.js} +3 -3
  21. package/dist/lazy/{JsonEdit-Bx4jK-K8.js → JsonEdit-CU-J4fdd.js} +3 -3
  22. package/dist/lazy/{LogList-DHk7eKeC.js → LogList-C6LMjMRn.js} +7 -7
  23. package/dist/lazy/{ObjGroup-DXJerzS2.js → ObjGroup-CgsFd4Y8.js} +1 -1
  24. package/dist/lazy/{OfferDetails-Fs5y40J0.js → OfferDetails-DIbdP0vj.js} +16 -14
  25. package/dist/lazy/{Progress-pRaKkFkw.js → Progress-VUY-tDJv.js} +5 -5
  26. package/dist/lazy/{Radio-C9Z-5npS.js → Radio-Bu1hE1Bk.js} +8 -7
  27. package/dist/lazy/{SearchSelect-BU-_DOLr.js → SearchSelect-D9K6sG_e.js} +16 -15
  28. package/dist/lazy/{Select-DJ6Ky5mO.js → Select-79Jg1Epf.js} +10 -9
  29. package/dist/lazy/Table-jTmqdEAL.js +439 -0
  30. package/dist/lazy/{Tabs-meM_0XCE.js → Tabs-NufO7Fxk.js} +1 -1
  31. package/dist/lazy/Wrapper-DMqVpwXY.js +87 -0
  32. package/dist/lazy/{index-2Lph8ou3.js → index-ByB0wyc-.js} +9668 -9397
  33. package/dist/lazy/useSelect-B3ugkvd3.js +77 -0
  34. package/dist/style.css +2 -2
  35. package/global.d.ts +10 -10
  36. package/package.json +36 -36
  37. package/dist/lazy/Table-BlBWSnrv.js +0 -351
  38. package/dist/lazy/Wrapper-DlG2aZRe.js +0 -36
  39. package/dist/lazy/useSelect-CmUZu1rN.js +0 -76
@@ -1,10 +1,11 @@
1
1
  import { defineComponent as F, mergeModels as S, useModel as T, inject as g, resolveComponent as u, resolveDirective as w, openBlock as o, createElementBlock as c, toDisplayString as z, unref as i, withDirectives as I, createBlock as f, mergeProps as K, withCtx as h, createVNode as N, Fragment as k, renderList as M } from "vue";
2
- import { u as P, b as R } from "./index-2Lph8ou3.js";
3
- import { u as $ } from "./useSelect-CmUZu1rN.js";
4
- const j = { key: 0 }, E = /* @__PURE__ */ F({
2
+ import { u as O, b as P } from "./index-ByB0wyc-.js";
3
+ import { u as R } from "./useSelect-B3ugkvd3.js";
4
+ const $ = { key: 0 }, j = /* @__PURE__ */ F({
5
5
  __name: "Radio",
6
6
  props: /* @__PURE__ */ S({
7
7
  options: { default: () => [] },
8
+ defaultOptions: {},
8
9
  mode: { default: "static" },
9
10
  labelKey: { default: "label" },
10
11
  valueKey: { default: "value" },
@@ -27,7 +28,7 @@ const j = { key: 0 }, E = /* @__PURE__ */ F({
27
28
  }),
28
29
  emits: ["update:modelValue"],
29
30
  setup(y) {
30
- const t = y, p = T(y, "modelValue"), m = P(), b = g("ruleModule", void 0), C = g("pageMethodMap", {}), _ = (e) => {
31
+ const t = y, p = T(y, "modelValue"), m = O(), b = g("ruleModule", void 0), C = g("pageMethodMap", {}), _ = (e) => {
31
32
  const { valueKey: d = "value", name: s } = t;
32
33
  let l = {};
33
34
  if (l = r.value.find((n) => n[d] === e) || {}, m.selectData && s && m.updateSelectData(s, l), t.onChange && b)
@@ -36,11 +37,11 @@ const j = { key: 0 }, E = /* @__PURE__ */ F({
36
37
  } catch (n) {
37
38
  console.error(n);
38
39
  }
39
- }, { currentOptions: r, loading: B } = $(t);
40
+ }, { currentOptions: r, loading: B } = R(t);
40
41
  return (e, d) => {
41
42
  var v;
42
43
  const s = u("el-radio"), l = u("el-radio-button"), n = u("el-space"), V = u("el-radio-group"), D = w("loading");
43
- return e.read ? (o(), c("div", j, z(((v = i(r).find((a) => a[e.valueKey] === p.value)) == null ? void 0 : v[e.labelKey]) || "--"), 1)) : I((o(), f(V, K({
44
+ return e.read ? (o(), c("div", $, z(((v = i(r).find((a) => a[e.valueKey] === p.value)) == null ? void 0 : v[e.labelKey]) || "--"), 1)) : I((o(), f(V, K({
44
45
  key: 1,
45
46
  modelValue: p.value,
46
47
  "onUpdate:modelValue": d[0] || (d[0] = (a) => p.value = a),
@@ -78,7 +79,7 @@ const j = { key: 0 }, E = /* @__PURE__ */ F({
78
79
  ]);
79
80
  };
80
81
  }
81
- }), q = /* @__PURE__ */ R(E, [["__scopeId", "data-v-3a3fdad0"]]);
82
+ }), q = /* @__PURE__ */ P(j, [["__scopeId", "data-v-1315a0b2"]]);
82
83
  export {
83
84
  q as default
84
85
  };
@@ -1,6 +1,6 @@
1
- import { defineComponent as F, mergeModels as w, useModel as A, inject as S, resolveComponent as f, resolveDirective as I, openBlock as o, createElementBlock as i, toDisplayString as y, unref as u, withDirectives as N, createBlock as k, mergeProps as j, withCtx as b, Fragment as P, renderList as $, createTextVNode as E, createVNode as B } from "vue";
2
- import { u as L, _ as O, b as T } from "./index-2Lph8ou3.js";
3
- import { u as U } from "./useSelect-CmUZu1rN.js";
1
+ import { defineComponent as F, mergeModels as w, useModel as A, inject as S, resolveComponent as f, resolveDirective as I, openBlock as o, createElementBlock as i, toDisplayString as y, unref as u, withDirectives as N, createBlock as k, mergeProps as j, withCtx as b, Fragment as O, renderList as P, createTextVNode as $, createVNode as B } from "vue";
2
+ import { u as E, _ as L, b as T } from "./index-ByB0wyc-.js";
3
+ import { u as U } from "./useSelect-B3ugkvd3.js";
4
4
  const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
5
5
  key: 1,
6
6
  class: "search-select-wrapper"
@@ -11,6 +11,7 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
11
11
  disabled: { type: Boolean },
12
12
  read: { type: Boolean },
13
13
  options: { default: () => [] },
14
+ defaultOptions: {},
14
15
  multiple: { type: Boolean, default: !1 },
15
16
  mode: { default: "static" },
16
17
  labelKey: { default: "label" },
@@ -30,10 +31,10 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
30
31
  }),
31
32
  emits: ["update:modelValue"],
32
33
  setup(v) {
33
- const t = v, r = A(v, "modelValue"), h = L(), c = S("ruleModule", void 0), g = S("pageMethodMap", {}), C = (e) => {
34
- const { valueKey: s = "value", multiple: m, name: p } = t;
34
+ const t = v, r = A(v, "modelValue"), h = E(), c = S("ruleModule", void 0), g = S("pageMethodMap", {}), C = (e) => {
35
+ const { valueKey: d = "value", multiple: m, name: p } = t;
35
36
  let n = {};
36
- if (m && Array.isArray(e) ? n = d.value.filter((a) => e.includes(a[s])) : n = d.value.find((a) => a[s] === e) || {}, h.selectData && p && h.updateSelectData(p, n), t.onChange && c)
37
+ if (m && Array.isArray(e) ? n = s.value.filter((a) => e.includes(a[d])) : n = s.value.find((a) => a[d] === e) || {}, h.selectData && p && h.updateSelectData(p, n), t.onChange && c)
37
38
  try {
38
39
  c[t.onChange](g, e, n);
39
40
  } catch (a) {
@@ -46,19 +47,19 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
46
47
  } catch (e) {
47
48
  console.error(e);
48
49
  }
49
- }, { currentOptions: d, loading: V } = U(t);
50
- return (e, s) => {
50
+ }, { currentOptions: s, loading: V } = U(t);
51
+ return (e, d) => {
51
52
  var _;
52
53
  const m = f("el-option"), p = f("el-select"), n = f("el-button"), a = I("loading");
53
54
  return e.read ? (o(), i("div", q, [
54
55
  e.multiple ? (o(), i("div", z, y(r.value && r.value.map((l) => {
55
56
  var K;
56
- return (K = u(d).find((D) => D[e.valueKey] === l)) == null ? void 0 : K[e.labelKey];
57
- }).join("、")), 1)) : (o(), i("div", G, y(((_ = u(d).find((l) => l[e.valueKey] === r.value)) == null ? void 0 : _[e.labelKey]) || "--"), 1))
57
+ return (K = u(s).find((D) => D[e.valueKey] === l)) == null ? void 0 : K[e.labelKey];
58
+ }).join("、")), 1)) : (o(), i("div", G, y(((_ = u(s).find((l) => l[e.valueKey] === r.value)) == null ? void 0 : _[e.labelKey]) || "--"), 1))
58
59
  ])) : (o(), i("div", H, [
59
60
  N((o(), k(p, j({
60
61
  modelValue: r.value,
61
- "onUpdate:modelValue": s[0] || (s[0] = (l) => r.value = l)
62
+ "onUpdate:modelValue": d[0] || (d[0] = (l) => r.value = l)
62
63
  }, e.$attrs, {
63
64
  onChange: C,
64
65
  multiple: e.multiple,
@@ -67,14 +68,14 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
67
68
  disabled: e.disabled
68
69
  }), {
69
70
  default: b(() => [
70
- (o(!0), i(P, null, $(u(d), (l) => (o(), k(m, {
71
+ (o(!0), i(O, null, P(u(s), (l) => (o(), k(m, {
71
72
  key: l[e.valueKey],
72
73
  label: l[e.labelKey],
73
74
  value: l[e.valueKey],
74
75
  disabled: l[e.disabledKey]
75
76
  }, {
76
77
  default: b(() => [
77
- E(y(l[e.labelKey]), 1)
78
+ $(y(l[e.labelKey]), 1)
78
79
  ]),
79
80
  _: 2
80
81
  }, 1032, ["label", "value", "disabled"]))), 128))
@@ -89,14 +90,14 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
89
90
  class: "search-btn"
90
91
  }, {
91
92
  default: b(() => [
92
- B(u(O), { name: "search" })
93
+ B(u(L), { name: "search" })
93
94
  ]),
94
95
  _: 1
95
96
  }, 8, ["disabled"])
96
97
  ]));
97
98
  };
98
99
  }
99
- }), X = /* @__PURE__ */ T(J, [["__scopeId", "data-v-da2bde35"]]);
100
+ }), X = /* @__PURE__ */ T(J, [["__scopeId", "data-v-ce5f6b46"]]);
100
101
  export {
101
102
  X as default
102
103
  };
@@ -1,10 +1,11 @@
1
- import { defineComponent as D, mergeModels as F, computed as f, useModel as _, inject as v, resolveComponent as b, openBlock as i, createElementBlock as g, toDisplayString as h, createBlock as K, mergeProps as w, unref as V, withCtx as c, createElementVNode as r, Fragment as A, renderList as N, createTextVNode as j } from "vue";
2
- import { u as x } from "./index-2Lph8ou3.js";
3
- import { u as E } from "./useSelect-CmUZu1rN.js";
4
- const I = { key: 0 }, P = { style: { "min-height": "32px" } }, T = /* @__PURE__ */ D({
1
+ import { defineComponent as D, mergeModels as F, computed as y, useModel as _, inject as v, resolveComponent as b, openBlock as i, createElementBlock as g, toDisplayString as h, createBlock as K, mergeProps as w, unref as V, withCtx as c, createElementVNode as r, Fragment as A, renderList as N, createTextVNode as j } from "vue";
2
+ import { u as x } from "./index-ByB0wyc-.js";
3
+ import { u as E } from "./useSelect-B3ugkvd3.js";
4
+ const I = { key: 0 }, O = { style: { "min-height": "32px" } }, T = /* @__PURE__ */ D({
5
5
  __name: "Select",
6
6
  props: /* @__PURE__ */ F({
7
7
  options: { default: () => [] },
8
+ defaultOptions: {},
8
9
  multiple: { type: Boolean, default: !1 },
9
10
  mode: { default: "static" },
10
11
  labelKey: { default: "label" },
@@ -25,16 +26,16 @@ const I = { key: 0 }, P = { style: { "min-height": "32px" } }, T = /* @__PURE__
25
26
  }),
26
27
  emits: ["update:modelValue"],
27
28
  setup(p) {
28
- const l = p, k = f(() => l.clearable === null || l.clearable === void 0 ? !0 : !!l.clearable), d = _(p, "modelValue"), m = x(), y = v("ruleModule", void 0), B = v("pageMethodMap", {}), C = (e) => {
29
+ const l = p, k = y(() => l.clearable === null || l.clearable === void 0 ? !0 : !!l.clearable), d = _(p, "modelValue"), m = x(), f = v("ruleModule", void 0), B = v("pageMethodMap", {}), C = (e) => {
29
30
  const { valueKey: t = "value", multiple: n, name: o } = l;
30
31
  let a = {};
31
- if (n && Array.isArray(e) ? a = s.value.filter((u) => e.includes(u[t])) : a = s.value.find((u) => u[t] === e) || {}, m.selectData && o && m.updateSelectData(o, a), l.onChange && y)
32
+ if (n && Array.isArray(e) ? a = s.value.filter((u) => e.includes(u[t])) : a = s.value.find((u) => u[t] === e) || {}, m.selectData && o && m.updateSelectData(o, a), l.onChange && f)
32
33
  try {
33
- y[l.onChange](B, e, a);
34
+ f[l.onChange](B, e, a);
34
35
  } catch (u) {
35
36
  console.error(u);
36
37
  }
37
- }, { currentOptions: s, loading: M } = E(l), S = f(() => {
38
+ }, { currentOptions: s, loading: M } = E(l), S = y(() => {
38
39
  var t;
39
40
  if (l.multiple)
40
41
  return s.value.filter(
@@ -95,7 +96,7 @@ const I = { key: 0 }, P = { style: { "min-height": "32px" } }, T = /* @__PURE__
95
96
  ], -1)
96
97
  ])),
97
98
  default: c(() => [
98
- r("div", P, [
99
+ r("div", O, [
99
100
  (i(!0), g(A, null, N(V(s), (a) => (i(), K(n, {
100
101
  key: a[e.valueKey],
101
102
  label: a[e.labelKey],
@@ -0,0 +1,439 @@
1
+ import { defineComponent as Ne, computed as T, inject as z, ref as b, useTemplateRef as $e, readonly as Me, toRefs as Te, onMounted as De, nextTick as Fe, onActivated as Le, onUnmounted as Ee, resolveComponent as _, openBlock as s, createElementBlock as h, normalizeClass as D, withDirectives as W, createElementVNode as m, createVNode as v, unref as C, withCtx as d, createBlock as f, createCommentVNode as y, Fragment as B, renderList as q, toDisplayString as N, withModifiers as x, vShow as J, mergeProps as Ie } from "vue";
2
+ import { $ as Ae, f as F, i as Ve, _ as Ue, I as L, a as je, C as Ge, b as He } from "./index-ByB0wyc-.js";
3
+ import { ElTable as Ke, ElLoading as O } from "element-plus";
4
+ const We = ["id"], qe = { class: "empty-content" }, xe = ["title"], Je = ["title", "onClick"], Oe = {
5
+ key: 1,
6
+ class: "icon-text-wrapper"
7
+ }, Qe = ["title"], Xe = ["title"], Ye = { class: "row-btn-wrapper" }, Ze = /* @__PURE__ */ Ne({
8
+ __name: "Table",
9
+ props: {
10
+ title: {},
11
+ key: {},
12
+ rulePath: {},
13
+ rowKey: {},
14
+ showDynamicSearch: { type: Boolean },
15
+ multipleSelection: { type: Boolean },
16
+ highlightCurrentRow: { type: Boolean },
17
+ "highlight-current-row": { type: Boolean },
18
+ stripe: { type: Boolean },
19
+ rowClick: {},
20
+ rowDbClick: {},
21
+ sizeChange: {},
22
+ pageChange: {},
23
+ topBtns: {},
24
+ rowBtns: {},
25
+ columns: {},
26
+ hidden: { type: Boolean },
27
+ hiddenPagination: { type: Boolean },
28
+ handleCurrentChange: {},
29
+ selectable: {},
30
+ pageSizes: {},
31
+ pagerCount: {},
32
+ paginationLayout: {},
33
+ defaultPageSize: {},
34
+ typeSwitch: { type: Boolean },
35
+ displayType: { default: "table" },
36
+ onMounted: {},
37
+ onActivated: {},
38
+ height: {},
39
+ collapsible: { type: Boolean },
40
+ name: {},
41
+ gridColumns: {}
42
+ },
43
+ setup(Q, { expose: X }) {
44
+ const n = Q, R = T(() => n.displayType ? n.displayType : n.typeSwitch ? "card" : "table"), Y = z("ruleModule", void 0), E = z("ruleMap", void 0), u = T(() => n.rulePath && E[n.rulePath] ? E[n.rulePath] : Y), g = z("pageMethodMap", {}), $ = z("getGlobalParams", () => {
45
+ }), I = z(Ae), A = I ? I.translateFn : null, S = b(), Z = (e, t, a) => {
46
+ i.value[e] && (i.value[e][t] = a);
47
+ }, ee = (e, t) => {
48
+ const a = n.columns.find((r) => r.key === e);
49
+ a && (a.hidden = !t);
50
+ }, M = (e, t, a) => {
51
+ try {
52
+ u.value[e.onClick](g, t, a);
53
+ } catch (r) {
54
+ console.error(r);
55
+ }
56
+ }, te = (e) => {
57
+ if (n.rowClick)
58
+ try {
59
+ u.value[n.rowClick](g, e);
60
+ } catch (t) {
61
+ console.error(t);
62
+ }
63
+ }, ne = (e) => {
64
+ if (n.rowDbClick)
65
+ try {
66
+ u.value[n.rowDbClick](g, e);
67
+ } catch (t) {
68
+ console.error(t);
69
+ }
70
+ }, ae = b([]), oe = (e) => {
71
+ ae.value = e;
72
+ }, le = (e, t) => {
73
+ if (!n.selectable)
74
+ return !0;
75
+ try {
76
+ return u.value[n.selectable](g, e, t);
77
+ } catch (a) {
78
+ console.error(a);
79
+ }
80
+ return !0;
81
+ }, re = () => {
82
+ var e;
83
+ (e = S.value) == null || e.clearSelection();
84
+ }, ie = () => i.value, V = b(), se = (e) => {
85
+ if (V.value = e, !!n.handleCurrentChange)
86
+ try {
87
+ u.value[n.handleCurrentChange](g, e);
88
+ } catch (t) {
89
+ console.error(t);
90
+ }
91
+ }, ce = () => V.value, ue = () => {
92
+ var e;
93
+ return (e = S.value) == null ? void 0 : e.getSelectionRows();
94
+ }, pe = async () => !0, de = (e, t) => {
95
+ var r;
96
+ const a = (r = n.topBtns) == null ? void 0 : r.find((w) => w.key === e);
97
+ a && (a.hidden = t);
98
+ }, ge = (e, t) => {
99
+ var r;
100
+ const a = (r = n.rowBtns) == null ? void 0 : r.find((w) => w.key === e);
101
+ a && (a.condition = !t);
102
+ }, U = b(0), he = (e) => {
103
+ U.value = e;
104
+ }, c = b({ pageNum: 1, pageSize: n.defaultPageSize || 5 }), me = () => c.value, ve = (e) => {
105
+ let t = !1;
106
+ return e.pageNum !== void 0 && e.pageNum > -1 && (c.value.pageNum !== e.pageNum && (t = !0), c.value.pageNum = e.pageNum), e.pageSize !== void 0 && e.pageSize > -1 && (c.value.pageSize !== e.pageSize && (t = !0), c.value.pageSize = e.pageSize), { pagination: c.value, isChange: t };
107
+ }, fe = async (e) => {
108
+ if (c.value.pageNum = 1, c.value.pageSize = e, !n.sizeChange)
109
+ return;
110
+ const t = O.service({
111
+ target: `#${n.name}`,
112
+ text: "Loading..."
113
+ });
114
+ try {
115
+ await u.value[n.sizeChange](g, c.value);
116
+ } catch (a) {
117
+ console.error(a);
118
+ } finally {
119
+ t.close();
120
+ }
121
+ }, ye = async (e) => {
122
+ if (c.value.pageNum = e, !n.pageChange)
123
+ return;
124
+ const t = O.service({
125
+ target: `#${n.name}`,
126
+ text: "Loading..."
127
+ });
128
+ try {
129
+ await u.value[n.pageChange](g, c.value);
130
+ } catch (a) {
131
+ console.error(a);
132
+ } finally {
133
+ t.close();
134
+ }
135
+ }, ke = (e) => {
136
+ var t;
137
+ (t = S.value) == null || t.setCurrentRow(e);
138
+ }, Ce = (e) => {
139
+ var t;
140
+ (t = S.value) == null || t.setCurrentRow(i.value[e]);
141
+ }, we = (e, t, a) => {
142
+ n.columns.forEach((r) => {
143
+ r.key === e && r[t] && (r[t] = a);
144
+ });
145
+ }, i = b([]), be = (e) => {
146
+ i.value = e;
147
+ }, Se = (e = {}) => {
148
+ i.value.push(e);
149
+ }, ze = (e) => {
150
+ e >= 0 && e < i.value.length && i.value.splice(e, 1);
151
+ }, _e = async () => {
152
+ i.value = [...i.value];
153
+ }, j = $e("rootRef"), G = Me({
154
+ ...Te(n),
155
+ setCellData: Z,
156
+ clearSelection: re,
157
+ getData: ie,
158
+ getCurrentRow: ce,
159
+ getSelectedRows: ue,
160
+ addRow: Se,
161
+ deleteRow: ze,
162
+ refresh: _e,
163
+ validate: pe,
164
+ setData: be,
165
+ selectRow: ke,
166
+ selectRowNum: Ce,
167
+ setTotal: he,
168
+ getPagination: me,
169
+ setPagination: ve,
170
+ setTopBtnHidden: de,
171
+ setColVisible: ee,
172
+ setColumn: we,
173
+ setRowsBtnHidden: ge,
174
+ rootRef: j,
175
+ type: "table"
176
+ }), k = (e, t) => {
177
+ const a = A ? A(e.key, t) : t[e.key];
178
+ if (!e.encrypted || !a)
179
+ return a;
180
+ const r = `${a}`;
181
+ return r.length <= 4 ? "*".repeat(r.length) : r.slice(0, -4) + "****";
182
+ }, H = (e, t) => {
183
+ if (!(!e.getIconInfo || !u.value))
184
+ try {
185
+ return u.value[e.getIconInfo](g, t, e);
186
+ } catch (a) {
187
+ console.error(a);
188
+ }
189
+ }, Be = T(() => !n.rowBtns || n.rowBtns.length === 0 || !i.value || i.value.length === 0 ? !1 : i.value.some(
190
+ (e) => {
191
+ var t;
192
+ return (t = n.rowBtns) == null ? void 0 : t.some((a) => a.condition === void 0 || a.condition === null ? !0 : F(a.condition, {
193
+ $row: e,
194
+ $globalParams: $()
195
+ }));
196
+ }
197
+ ));
198
+ if (De(async () => {
199
+ if (!n.onMounted || !u.value)
200
+ return;
201
+ await Fe();
202
+ const e = n.onMounted;
203
+ try {
204
+ u.value[e](g);
205
+ } catch (t) {
206
+ console.error(t);
207
+ }
208
+ }), Le(() => {
209
+ if (!n.onActivated || !u.value)
210
+ return;
211
+ const e = n.onActivated;
212
+ try {
213
+ u.value[e](g);
214
+ } catch (t) {
215
+ console.error(t);
216
+ }
217
+ }), n.name) {
218
+ const e = Ve(n.name, G);
219
+ Ee(() => {
220
+ e();
221
+ });
222
+ }
223
+ return X(G), (e, t) => {
224
+ const a = _("el-table-column"), r = _("el-tooltip"), w = _("el-button"), Re = _("el-popover"), Pe = _("el-pagination");
225
+ return e.hidden ? y("", !0) : (s(), h("div", {
226
+ key: 0,
227
+ class: D(["table-render", { tableBorder: R.value === "table" }]),
228
+ ref_key: "rootRef",
229
+ ref: j,
230
+ id: e.name
231
+ }, [
232
+ W(m("div", null, [
233
+ v(C(Ke), {
234
+ ref_key: "tableRef",
235
+ ref: S,
236
+ data: i.value,
237
+ "highlight-current-row": "",
238
+ "row-key": e.rowKey,
239
+ stripe: e.stripe,
240
+ "show-overflow-tooltip": "",
241
+ onRowClick: te,
242
+ onRowDblclick: ne,
243
+ onSelectionChange: oe,
244
+ onCurrentChange: se,
245
+ height: e.height
246
+ }, {
247
+ empty: d(() => [
248
+ m("div", qe, [
249
+ v(C(Ue), {
250
+ name: "tableEmpty",
251
+ style: { width: 56, height: 56 }
252
+ }),
253
+ t[2] || (t[2] = m("div", null, "No data available,please check", -1))
254
+ ])
255
+ ]),
256
+ default: d(() => [
257
+ e.multipleSelection ? (s(), f(a, {
258
+ key: 0,
259
+ type: "selection",
260
+ width: "55",
261
+ selectable: le
262
+ })) : y("", !0),
263
+ (s(!0), h(B, null, q(e.columns, (o) => (s(), h(B, {
264
+ key: o.key
265
+ }, [
266
+ o.hidden ? y("", !0) : (s(), f(a, {
267
+ key: 0,
268
+ prop: o.key,
269
+ "min-width": o.minWidth,
270
+ fixed: o.fixed || !1
271
+ }, {
272
+ header: d(() => [
273
+ m("div", {
274
+ class: "text-ellipsis",
275
+ title: o.label
276
+ }, N(o.label), 9, xe)
277
+ ]),
278
+ default: d(({ row: p, $index: l }) => {
279
+ var P, K;
280
+ return [
281
+ o.type === "link" ? (s(), h("div", {
282
+ key: 0,
283
+ class: D(["text-ellipsis link-style", { "click-style": o.onClick }]),
284
+ title: k(o, p),
285
+ onClick: (et) => M(o, p, l)
286
+ }, N(k(o, p)), 11, Je)) : o.type === "iconText" ? (s(), h("div", Oe, [
287
+ v(L, {
288
+ name: (P = H(o, p)) == null ? void 0 : P.name,
289
+ color: (K = H(o, p)) == null ? void 0 : K.color
290
+ }, null, 8, ["name", "color"]),
291
+ m("span", {
292
+ class: "text-ellipsis",
293
+ title: k(o, p)
294
+ }, N(k(o, p)), 9, Qe)
295
+ ])) : (s(), h("div", {
296
+ key: 2,
297
+ class: "text-ellipsis",
298
+ title: k(o, p)
299
+ }, N(k(o, p)), 9, Xe))
300
+ ];
301
+ }),
302
+ _: 2
303
+ }, 1032, ["prop", "min-width", "fixed"]))
304
+ ], 64))), 128)),
305
+ Be.value && e.rowBtns && e.rowBtns.length > 0 ? (s(), f(a, {
306
+ key: 1,
307
+ label: "Action",
308
+ fixed: "right",
309
+ align: "left",
310
+ width: e.rowBtns.length * 34 + 12 > 100 ? e.rowBtns.length * 34 + 12 : 100
311
+ }, {
312
+ default: d(({ row: o, $index: p }) => [
313
+ m("div", Ye, [
314
+ (s(!0), h(B, null, q(e.rowBtns, (l) => (s(), h(B, {
315
+ key: l.key
316
+ }, [
317
+ l.component === "Popover" ? (s(), f(Re, {
318
+ key: 0,
319
+ title: l.label,
320
+ trigger: "click",
321
+ "popper-class": "btn-popover",
322
+ width: "400"
323
+ }, {
324
+ reference: d(() => [
325
+ l.condition === void 0 || l.condition === null || C(F)(l.condition, {
326
+ $row: o,
327
+ $globalParams: C($)()
328
+ }) ? (s(), f(w, {
329
+ key: 0,
330
+ disabled: l.disabled,
331
+ link: "",
332
+ size: "small",
333
+ type: l.type,
334
+ onClick: x((P) => M(l, o, p), ["stop"])
335
+ }, {
336
+ default: d(() => [
337
+ v(r, {
338
+ class: "box-item",
339
+ effect: "dark",
340
+ content: l.label,
341
+ placement: "top",
342
+ "popper-class": "low-tsp"
343
+ }, {
344
+ default: d(() => [
345
+ l.icon ? (s(), f(L, {
346
+ key: 0,
347
+ name: l.icon.name,
348
+ color: l.icon.color
349
+ }, null, 8, ["name", "color"])) : y("", !0)
350
+ ]),
351
+ _: 2
352
+ }, 1032, ["content"])
353
+ ]),
354
+ _: 2
355
+ }, 1032, ["disabled", "type", "onClick"])) : y("", !0)
356
+ ]),
357
+ default: d(() => [
358
+ m("div", null, [
359
+ v(C(je), {
360
+ list: l.children
361
+ }, null, 8, ["list"])
362
+ ])
363
+ ]),
364
+ _: 2
365
+ }, 1032, ["title"])) : (s(), h(B, { key: 1 }, [
366
+ l.condition === void 0 || l.condition === null || C(F)(l.condition, {
367
+ $row: o,
368
+ $globalParams: C($)()
369
+ }) ? (s(), f(w, {
370
+ key: 0,
371
+ disabled: l.disabled,
372
+ link: "",
373
+ size: "small",
374
+ type: l.type,
375
+ onClick: x((P) => M(l, o, p), ["stop"])
376
+ }, {
377
+ default: d(() => [
378
+ v(r, {
379
+ class: "box-item",
380
+ effect: "dark",
381
+ content: l.label,
382
+ placement: "top",
383
+ "popper-class": "low-tsp"
384
+ }, {
385
+ default: d(() => [
386
+ l.icon ? (s(), f(L, {
387
+ key: 0,
388
+ name: l.icon.name,
389
+ color: l.icon.color
390
+ }, null, 8, ["name", "color"])) : y("", !0)
391
+ ]),
392
+ _: 2
393
+ }, 1032, ["content"])
394
+ ]),
395
+ _: 2
396
+ }, 1032, ["disabled", "type", "onClick"])) : y("", !0)
397
+ ], 64))
398
+ ], 64))), 128))
399
+ ])
400
+ ]),
401
+ _: 1
402
+ }, 8, ["width"])) : y("", !0)
403
+ ]),
404
+ _: 1
405
+ }, 8, ["data", "row-key", "stripe", "height"])
406
+ ], 512), [
407
+ [J, R.value === "table"]
408
+ ]),
409
+ W(v(Ge, Ie({ data: i.value }, n, { getColText: k }), null, 16, ["data"]), [
410
+ [J, R.value === "card"]
411
+ ]),
412
+ m("div", {
413
+ class: D(["pagination-wrapper", {
414
+ hidePagination: (e.hiddenPagination || i.value.length === 0) && !e.height,
415
+ transparentPagination: (e.hiddenPagination || i.value.length === 0) && e.height,
416
+ cardlistPadding: R.value === "card"
417
+ }])
418
+ }, [
419
+ v(Pe, {
420
+ layout: e.paginationLayout || "total,sizes, prev, pager, next,jumper",
421
+ total: U.value,
422
+ "page-sizes": e.pageSizes || [5, 10, 20, 30, 40],
423
+ "default-page-size": e.defaultPageSize,
424
+ "current-page": c.value.pageNum,
425
+ "onUpdate:currentPage": t[0] || (t[0] = (o) => c.value.pageNum = o),
426
+ "page-size": c.value.pageSize,
427
+ "onUpdate:pageSize": t[1] || (t[1] = (o) => c.value.pageSize = o),
428
+ "pager-count": Number(e.pagerCount) || 5,
429
+ onSizeChange: fe,
430
+ onCurrentChange: ye
431
+ }, null, 8, ["layout", "total", "page-sizes", "default-page-size", "current-page", "page-size", "pager-count"])
432
+ ], 2)
433
+ ], 10, We));
434
+ };
435
+ }
436
+ }), ot = /* @__PURE__ */ He(Ze, [["__scopeId", "data-v-80bbe04a"]]);
437
+ export {
438
+ ot as default
439
+ };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as i, ref as m, watch as _, onMounted as h, resolveComponent as a, openBlock as l, createBlock as c, mergeProps as u, withCtx as d, createElementBlock as b, Fragment as v, renderList as y, createVNode as k, unref as K } from "vue";
2
- import { a as V } from "./index-2Lph8ou3.js";
2
+ import { a as V } from "./index-ByB0wyc-.js";
3
3
  import "element-plus";
4
4
  const w = /* @__PURE__ */ i({
5
5
  __name: "Tabs",