asiaint-lowcode 3.0.16 → 3.0.18

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/dist/asiaint-lowcode.js +1 -1
  2. package/dist/asiaint-lowcode.umd.cjs +137 -137
  3. package/dist/index.d.ts +19 -0
  4. package/dist/lazy/Card-BZBVb7aE.js +92 -0
  5. package/dist/lazy/CardList-DwWiAo9-.js +108 -0
  6. package/dist/lazy/{CardListItem-DbXsd1_k.js → CardListItem-yhIgxbTe.js} +4 -4
  7. package/dist/lazy/{Cascader-BZhmVWOO.js → Cascader-B4lz7iK6.js} +7 -6
  8. package/dist/lazy/{Checkbox-B1TSYANT.js → Checkbox-Bynb0NT0.js} +7 -6
  9. package/dist/lazy/{Collapse-C8VWxgHp.js → Collapse-G30hqmNm.js} +1 -1
  10. package/dist/lazy/{Component-Cmw2Jlj3.js → Component-B0hYH3vU.js} +1 -1
  11. package/dist/lazy/{Component-DUuuNUxC.js → Component-BeSgMnB2.js} +1 -1
  12. package/dist/lazy/{Component-D-Eh8B-j.js → Component-CPdFFbsj.js} +11 -11
  13. package/dist/lazy/{Component-NvoLQyab.js → Component-CWNB0Jlu.js} +1 -1
  14. package/dist/lazy/{Component-CqAhbbGQ.js → Component-DPvjrsCR.js} +1 -1
  15. package/dist/lazy/{Component-CUa78qLF.js → Component-fNOhYdFv.js} +1 -1
  16. package/dist/lazy/CurdCard-B7bGNxEj.js +107 -0
  17. package/dist/lazy/{Custom-zNcfkvdD.js → Custom-iAQ_31Jp.js} +1 -1
  18. package/dist/lazy/{FormList-ChQYp1l-.js → FormList-paORw3Fb.js} +1 -1
  19. package/dist/lazy/{Grid-GCB39VOw.js → Grid-CAcJjpEy.js} +1 -1
  20. package/dist/lazy/{Inline-D1ZMiudr.js → Inline-Dtx-csTe.js} +1 -1
  21. package/dist/lazy/{JsonEdit-BK25HRpb.js → JsonEdit-CvdrWLHq.js} +1 -1
  22. package/dist/lazy/{ObjGroup-DLXLO2wj.js → ObjGroup-Cjz4SzvJ.js} +1 -1
  23. package/dist/lazy/OfferDetails-BGoovbJm.js +163 -0
  24. package/dist/lazy/{Radio-DoOsjG7K.js → Radio-DKzZn31G.js} +22 -21
  25. package/dist/lazy/{SearchSelect-CktfCSrM.js → SearchSelect-B1YX-Ao2.js} +15 -14
  26. package/dist/lazy/{Select-DgAQhalx.js → Select-p4eyst_E.js} +4 -3
  27. package/dist/lazy/Table-CuJVitWt.js +279 -0
  28. package/dist/lazy/{Tabs-C7ZXJbOT.js → Tabs-10OyFGmb.js} +1 -1
  29. package/dist/lazy/Wrapper-DauMa47J.js +30 -0
  30. package/dist/lazy/{index-BvOUGCFQ.js → index-DMmaR_UH.js} +5037 -4876
  31. package/dist/lazy/{useSelect-BqqanrGo.js → useSelect-BsvU-jJC.js} +1 -1
  32. package/dist/style.css +2 -2
  33. package/package.json +1 -1
  34. package/dist/lazy/Card-DIBN4bRf.js +0 -59
  35. package/dist/lazy/CardList-DkwHDPNp.js +0 -51
  36. package/dist/lazy/CurdCard-BSgF68nl.js +0 -85
  37. package/dist/lazy/OfferDetails-CKwTw0z4.js +0 -95
  38. package/dist/lazy/Table-C3PlF9J4.js +0 -273
  39. package/dist/lazy/Wrapper-DIpJqF_p.js +0 -22
@@ -0,0 +1,163 @@
1
+ import { defineComponent as D, resolveComponent as I, openBlock as l, createBlock as N, withCtx as F, createVNode as T, createElementVNode as a, createElementBlock as r, Fragment as c, renderList as _, toDisplayString as f, createCommentVNode as O, ref as M, inject as y, watchEffect as P, onMounted as $, normalizeStyle as z } from "vue";
2
+ import { C as A } from "./CardListItem-yhIgxbTe.js";
3
+ import { $ as L, b as R } from "./index-DMmaR_UH.js";
4
+ const V = { class: "content" }, K = { class: "product-list" }, j = { class: "attribute-list" }, x = {
5
+ key: 0,
6
+ class: "attribute-list-item"
7
+ }, U = { class: "product-title attribute-title" }, q = { class: "attribute-item-list" }, G = { class: "attribute-label" }, H = { class: "attribute-value" }, J = /* @__PURE__ */ D({
8
+ __name: "OfferDetailItem",
9
+ props: {
10
+ data: {},
11
+ btns: {}
12
+ },
13
+ setup(g) {
14
+ return (o, d) => {
15
+ const b = I("el-popover");
16
+ return l(), N(b, {
17
+ "popper-class": "offer-detail",
18
+ placement: "right"
19
+ }, {
20
+ reference: F(() => [
21
+ T(A, {
22
+ data: o.data,
23
+ btns: o.btns
24
+ }, null, 8, ["data", "btns"])
25
+ ]),
26
+ default: F(() => [
27
+ a("div", V, [
28
+ d[0] || (d[0] = a("div", { class: "product-title" }, "Product", -1)),
29
+ a("div", K, [
30
+ (l(!0), r(c, null, _(o.data.product, (s) => (l(), r("div", {
31
+ class: "product-item",
32
+ key: s.label
33
+ }, f(s.label), 1))), 128))
34
+ ]),
35
+ a("div", j, [
36
+ (l(!0), r(c, null, _(o.data.product, (s) => (l(), r(c, {
37
+ key: s.label
38
+ }, [
39
+ s.children.length > 0 ? (l(), r("div", x, [
40
+ a("div", U, f(s.label), 1),
41
+ a("div", q, [
42
+ (l(!0), r(c, null, _(s.children, (u) => (l(), r("div", {
43
+ class: "attribute-item",
44
+ key: u.label
45
+ }, [
46
+ a("div", G, f(u.label), 1),
47
+ a("div", H, f(u.value || "--"), 1)
48
+ ]))), 128))
49
+ ])
50
+ ])) : O("", !0)
51
+ ], 64))), 128))
52
+ ])
53
+ ])
54
+ ]),
55
+ _: 1
56
+ });
57
+ };
58
+ }
59
+ }), Q = /* @__PURE__ */ D({
60
+ __name: "OfferDetails",
61
+ props: {
62
+ title: {},
63
+ key: {},
64
+ rulePath: {},
65
+ rowKey: {},
66
+ showDynamicSearch: { type: Boolean },
67
+ multipleSelection: { type: Boolean },
68
+ highlightCurrentRow: { type: Boolean },
69
+ "highlight-current-row": { type: Boolean },
70
+ stripe: { type: Boolean },
71
+ rowClick: {},
72
+ rowDbClick: {},
73
+ sizeChange: {},
74
+ pageChange: {},
75
+ topBtns: {},
76
+ rowBtns: {},
77
+ hidden: { type: Boolean },
78
+ hiddenPagination: { type: Boolean },
79
+ handleCurrentChange: {},
80
+ pageSizes: {},
81
+ defaultPageSize: {},
82
+ gridColumns: { default: 3 },
83
+ gap: { default: 16 },
84
+ footerText: {},
85
+ onClickFooter: {},
86
+ data: {},
87
+ columns: {}
88
+ },
89
+ setup(g) {
90
+ var B, E;
91
+ const o = g, d = M(), b = y("ruleModule", void 0), s = y("pageMethodMap", {}), u = () => {
92
+ try {
93
+ b[o.onClickFooter](s, o.data);
94
+ } catch (e) {
95
+ console.error(e);
96
+ }
97
+ }, k = M([]), m = (B = o.columns.find((e) => e.position === "title")) == null ? void 0 : B.key, v = (E = o.columns.find((e) => e.position === "subTitle")) == null ? void 0 : E.key, p = o.columns.find((e) => e.position === "footer"), S = (e) => {
98
+ const t = [];
99
+ return e.children && e.children.length > 0 && e.children.forEach((n) => {
100
+ const h = {
101
+ label: n.OFFER_NAME,
102
+ children: []
103
+ };
104
+ n.children && n.children.length > 0 && n.children.forEach((w) => {
105
+ h.children.push({
106
+ label: w.OFFER_NAME,
107
+ value: w.ATTR_VALUE
108
+ });
109
+ }), t.push(h);
110
+ }), t;
111
+ }, C = y(L), i = C ? C.translateFn : null;
112
+ return P(() => {
113
+ o.data && (d.value = o.data.map((e) => {
114
+ const t = {
115
+ content: []
116
+ };
117
+ return m && (t.title = i ? i(m, e) : e[m]), v && (t.subTitle = i ? i(v, e) : e[v]), p && (t.footer = {
118
+ icon: p.footerIcon || "icon-tishi",
119
+ text: `${p.label}: ${i ? i(p.key, e) : e[p.key]}`
120
+ }), e.children && (t.product = S(e)), o.columns.forEach((n) => {
121
+ n.position === "content" && t.content.push({
122
+ label: n.label,
123
+ value: i ? i(n.key, e) : e[n.key]
124
+ });
125
+ }), t;
126
+ }));
127
+ }), $(() => {
128
+ var e;
129
+ k.value = (e = o.rowBtns) == null ? void 0 : e.map((t) => ({
130
+ icon: t.icon && t.icon.name ? t.icon.name : "icon-tishi",
131
+ label: t.label,
132
+ onClick: t.onClick
133
+ }));
134
+ }), (e, t) => (l(), r(c, null, [
135
+ a("div", {
136
+ class: "card-list",
137
+ style: z({
138
+ "--columns": e.gridColumns,
139
+ "--gap": e.gap + "px"
140
+ })
141
+ }, [
142
+ (l(!0), r(c, null, _(d.value, (n, h) => (l(), r("div", {
143
+ class: "card-list-item",
144
+ key: h
145
+ }, [
146
+ T(J, {
147
+ data: n,
148
+ btns: k.value
149
+ }, null, 8, ["data", "btns"])
150
+ ]))), 128))
151
+ ], 4),
152
+ a("div", {
153
+ class: "card-list-footer",
154
+ onClick: u
155
+ }, [
156
+ a("span", null, f(e.footerText), 1)
157
+ ])
158
+ ], 64));
159
+ }
160
+ }), Z = /* @__PURE__ */ R(Q, [["__scopeId", "data-v-5365ff23"]]);
161
+ export {
162
+ Z as default
163
+ };
@@ -1,6 +1,6 @@
1
- import { defineComponent as z, mergeModels as S, useModel as T, inject as K, resolveComponent as p, resolveDirective as w, openBlock as a, createElementBlock as d, toDisplayString as F, unref as l, Fragment as m, createCommentVNode as N, withDirectives as I, createBlock as y, mergeProps as k, withCtx as C, createVNode as P, renderList as M } from "vue";
2
- import { u as $ } from "./index-BvOUGCFQ.js";
3
- import { u as j } from "./useSelect-BqqanrGo.js";
1
+ import { defineComponent as z, mergeModels as S, useModel as T, inject as K, resolveComponent as p, resolveDirective as w, openBlock as o, createElementBlock as d, toDisplayString as F, unref as l, Fragment as m, createCommentVNode as N, withDirectives as I, createBlock as y, mergeProps as k, withCtx as C, createVNode as P, renderList as M } from "vue";
2
+ import { u as $ } from "./index-DMmaR_UH.js";
3
+ import { u as j } from "./useSelect-BsvU-jJC.js";
4
4
  const E = { key: 0 }, L = {
5
5
  key: 0,
6
6
  style: { "font-size": "12px" }
@@ -17,6 +17,7 @@ const E = { key: 0 }, L = {
17
17
  name: { default: "" },
18
18
  onChange: {},
19
19
  read: { type: Boolean },
20
+ clearable: { type: Boolean },
20
21
  optionType: { default: "circle" },
21
22
  direction: { default: "horizontal" },
22
23
  space: { default: 20 }
@@ -26,7 +27,7 @@ const E = { key: 0 }, L = {
26
27
  }),
27
28
  emits: ["update:modelValue"],
28
29
  setup(f) {
29
- const u = f, c = T(f, "modelValue"), v = $(), b = K("ruleModule", void 0), V = K("pageMethodMap", {}), D = (e) => {
30
+ const u = f, c = T(f, "modelValue"), v = $(), b = K("ruleModule", void 0), V = K("pageMethodMap", {}), B = (e) => {
30
31
  const { valueKey: i = "value", name: s } = u;
31
32
  let t = {};
32
33
  if (t = n.value.find((r) => r[i] === e) || {}, v.selectData && s && v.updateSelectData(s, t), u.onChange && b)
@@ -38,13 +39,13 @@ const E = { key: 0 }, L = {
38
39
  }, { currentOptions: n, loading: g } = j(u);
39
40
  return (e, i) => {
40
41
  var h;
41
- const s = p("el-radio"), t = p("el-radio-button"), r = p("el-space"), _ = p("el-radio-group"), B = w("loading");
42
- return e.read ? (a(), d("div", E, F(((h = l(n).find((o) => o[e.valueKey] === c.value)) == null ? void 0 : h[e.labelKey]) || "--"), 1)) : (a(), d(m, { key: 1 }, [
43
- !l(n).length && !l(g) ? (a(), d("div", L, "暂无选项")) : N("", !0),
44
- I((a(), y(_, k({
42
+ const s = p("el-radio"), t = p("el-radio-button"), r = p("el-space"), D = p("el-radio-group"), _ = w("loading");
43
+ return e.read ? (o(), d("div", E, F(((h = l(n).find((a) => a[e.valueKey] === c.value)) == null ? void 0 : h[e.labelKey]) || "--"), 1)) : (o(), d(m, { key: 1 }, [
44
+ !l(n).length && !l(g) ? (o(), d("div", L, "暂无选项")) : N("", !0),
45
+ I((o(), y(D, k({
45
46
  modelValue: c.value,
46
- "onUpdate:modelValue": i[0] || (i[0] = (o) => c.value = o),
47
- onChange: D
47
+ "onUpdate:modelValue": i[0] || (i[0] = (a) => c.value = a),
48
+ onChange: B
48
49
  }, e.$attrs), {
49
50
  default: C(() => [
50
51
  P(r, {
@@ -54,17 +55,17 @@ const E = { key: 0 }, L = {
54
55
  alignment: "normal"
55
56
  }, {
56
57
  default: C(() => [
57
- e.optionType === "circle" || e.optionType === "border" ? (a(!0), d(m, { key: 0 }, M(l(n), (o) => (a(), y(s, {
58
- key: o[e.valueKey],
59
- label: o[e.labelKey],
60
- value: o[e.valueKey],
61
- disabled: o[e.disabledKey],
58
+ e.optionType === "circle" || e.optionType === "border" ? (o(!0), d(m, { key: 0 }, M(l(n), (a) => (o(), y(s, {
59
+ key: a[e.valueKey],
60
+ label: a[e.labelKey],
61
+ value: a[e.valueKey],
62
+ disabled: a[e.disabledKey],
62
63
  border: e.optionType === "border"
63
- }, null, 8, ["label", "value", "disabled", "border"]))), 128)) : (a(!0), d(m, { key: 1 }, M(l(n), (o) => (a(), y(t, k({
64
- key: o[e.valueKey],
65
- label: o[e.labelKey],
66
- value: o[e.valueKey],
67
- disabled: o[e.disabledKey],
64
+ }, null, 8, ["label", "value", "disabled", "border"]))), 128)) : (o(!0), d(m, { key: 1 }, M(l(n), (a) => (o(), y(t, k({
65
+ key: a[e.valueKey],
66
+ label: a[e.labelKey],
67
+ value: a[e.valueKey],
68
+ disabled: a[e.disabledKey],
68
69
  ref_for: !0
69
70
  }, e.$attrs), null, 16, ["label", "value", "disabled"]))), 128))
70
71
  ]),
@@ -73,7 +74,7 @@ const E = { key: 0 }, L = {
73
74
  ]),
74
75
  _: 1
75
76
  }, 16, ["modelValue"])), [
76
- [B, l(g)]
77
+ [_, l(g)]
77
78
  ])
78
79
  ], 64));
79
80
  };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as w, mergeModels as A, useModel as F, 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 C } from "vue";
2
- import { u as L, _ as O, b as T } from "./index-BvOUGCFQ.js";
3
- import { u as U } from "./useSelect-BqqanrGo.js";
2
+ import { u as L, _ as O, b as T } from "./index-DMmaR_UH.js";
3
+ import { u as U } from "./useSelect-BsvU-jJC.js";
4
4
  const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
5
5
  key: 1,
6
6
  class: "search-select-wrapper"
@@ -19,7 +19,8 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
19
19
  apiParams: {},
20
20
  dependentFields: {},
21
21
  name: { default: "" },
22
- onChange: {}
22
+ onChange: {},
23
+ clearable: { type: Boolean }
23
24
  }, {
24
25
  modelValue: { type: [String, Number, Boolean, Array] },
25
26
  modelModifiers: {}
@@ -27,34 +28,34 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
27
28
  emits: ["update:modelValue"],
28
29
  setup(v) {
29
30
  const t = v, d = F(v, "modelValue"), h = L(), c = S("ruleModule", void 0), _ = S("pageMethodMap", {}), M = (e) => {
30
- const { valueKey: r = "value", multiple: m, name: p } = t;
31
+ const { valueKey: s = "value", multiple: m, name: p } = t;
31
32
  let n = {};
32
- if (m && Array.isArray(e) ? n = s.value.filter((a) => e.includes(a[r])) : n = s.value.find((a) => a[r] === e) || {}, h.selectData && p && h.updateSelectData(p, n), t.onChange && c)
33
+ if (m && Array.isArray(e) ? n = r.value.filter((a) => e.includes(a[s])) : n = r.value.find((a) => a[s] === e) || {}, h.selectData && p && h.updateSelectData(p, n), t.onChange && c)
33
34
  try {
34
35
  c[t.onChange](_, e, n);
35
36
  } catch (a) {
36
37
  console.error(a);
37
38
  }
38
- }, V = () => {
39
+ }, B = () => {
39
40
  if (t.onSearch && c)
40
41
  try {
41
42
  c[t.onSearch](_);
42
43
  } catch (e) {
43
44
  console.error(e);
44
45
  }
45
- }, { currentOptions: s, loading: B } = U(t);
46
- return (e, r) => {
46
+ }, { currentOptions: r, loading: V } = U(t);
47
+ return (e, s) => {
47
48
  var g;
48
49
  const m = f("el-option"), p = f("el-select"), n = f("el-button"), a = I("loading");
49
50
  return e.read ? (o(), i("div", q, [
50
51
  e.multiple ? (o(), i("div", z, y(d.value && d.value.map((l) => {
51
52
  var K;
52
- return (K = u(s).find((D) => D[e.valueKey] === l)) == null ? void 0 : K[e.labelKey];
53
- }).join("、")), 1)) : (o(), i("div", G, y((g = u(s).find((l) => l[e.valueKey] === d.value)) == null ? void 0 : g[e.labelKey]), 1))
53
+ return (K = u(r).find((D) => D[e.valueKey] === l)) == null ? void 0 : K[e.labelKey];
54
+ }).join("、")), 1)) : (o(), i("div", G, y((g = u(r).find((l) => l[e.valueKey] === d.value)) == null ? void 0 : g[e.labelKey]), 1))
54
55
  ])) : (o(), i("div", H, [
55
56
  N((o(), k(p, j({
56
57
  modelValue: d.value,
57
- "onUpdate:modelValue": r[0] || (r[0] = (l) => d.value = l)
58
+ "onUpdate:modelValue": s[0] || (s[0] = (l) => d.value = l)
58
59
  }, e.$attrs, {
59
60
  onChange: M,
60
61
  multiple: e.multiple,
@@ -63,7 +64,7 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
63
64
  disabled: e.disabled
64
65
  }), {
65
66
  default: b(() => [
66
- (o(!0), i(P, null, $(u(s), (l) => (o(), k(m, {
67
+ (o(!0), i(P, null, $(u(r), (l) => (o(), k(m, {
67
68
  key: l[e.valueKey],
68
69
  label: l[e.labelKey],
69
70
  value: l[e.valueKey],
@@ -77,10 +78,10 @@ const q = { key: 0 }, z = { key: 0 }, G = { key: 1 }, H = {
77
78
  ]),
78
79
  _: 1
79
80
  }, 16, ["modelValue", "multiple", "disabled"])), [
80
- [a, u(B)]
81
+ [a, u(V)]
81
82
  ]),
82
83
  C(n, {
83
- onClick: V,
84
+ onClick: B,
84
85
  disabled: e.disabled,
85
86
  class: "search-btn"
86
87
  }, {
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as _, mergeModels as k, useModel as B, inject as f, computed as D, resolveComponent as y, resolveDirective as S, openBlock as r, createElementBlock as i, toDisplayString as v, createBlock as b, mergeProps as A, withCtx as g, withDirectives as F, Fragment as j, renderList as w, unref as h, createTextVNode as I } from "vue";
2
- import { u as N } from "./index-BvOUGCFQ.js";
3
- import { u as P } from "./useSelect-BqqanrGo.js";
2
+ import { u as N } from "./index-DMmaR_UH.js";
3
+ import { u as P } from "./useSelect-BsvU-jJC.js";
4
4
  const E = { key: 0 }, L = { style: { "min-height": "32px" } }, $ = /* @__PURE__ */ _({
5
5
  __name: "Select",
6
6
  props: /* @__PURE__ */ k({
@@ -14,7 +14,8 @@ const E = { key: 0 }, L = { style: { "min-height": "32px" } }, $ = /* @__PURE__
14
14
  dependentFields: {},
15
15
  name: { default: "" },
16
16
  onChange: {},
17
- read: { type: Boolean }
17
+ read: { type: Boolean },
18
+ clearable: { type: Boolean }
18
19
  }, {
19
20
  modelValue: { type: [String, Number, Boolean, Array] },
20
21
  modelModifiers: {}
@@ -0,0 +1,279 @@
1
+ import { defineComponent as pe, inject as _, ref as f, useTemplateRef as de, readonly as ge, toRefs as he, onUnmounted as fe, resolveComponent as R, openBlock as c, createElementBlock as k, createVNode as v, unref as p, withCtx as u, createElementVNode as w, createBlock as z, createCommentVNode as m, Fragment as b, renderList as E, toDisplayString as B, normalizeClass as V, createTextVNode as me } from "vue";
2
+ import { $ as ye, h as Ce, _ as ke, f as ve, I as we, b as ze } from "./index-DMmaR_UH.js";
3
+ import { ElTable as Se } from "element-plus";
4
+ const Re = { class: "empty-content" }, be = { class: "text-ellipsis" }, _e = { class: "text-ellipsis" }, Be = /* @__PURE__ */ pe({
5
+ __name: "Table",
6
+ props: {
7
+ title: {},
8
+ key: {},
9
+ rulePath: {},
10
+ rowKey: {},
11
+ showDynamicSearch: { type: Boolean },
12
+ multipleSelection: { type: Boolean },
13
+ highlightCurrentRow: { type: Boolean },
14
+ "highlight-current-row": { type: Boolean },
15
+ stripe: { type: Boolean },
16
+ rowClick: {},
17
+ rowDbClick: {},
18
+ sizeChange: {},
19
+ pageChange: {},
20
+ topBtns: {},
21
+ rowBtns: {},
22
+ columns: {},
23
+ hidden: { type: Boolean },
24
+ hiddenPagination: { type: Boolean },
25
+ handleCurrentChange: {},
26
+ pageSizes: {},
27
+ defaultPageSize: {},
28
+ name: {}
29
+ },
30
+ setup($, { expose: F }) {
31
+ const n = $, d = _("ruleModule", void 0), g = _("pageMethodMap", {}), N = _(ye), S = N ? N.translateFn : null, y = f(), U = (e, t, o) => {
32
+ s.value[e] && (s.value[e][t] = o);
33
+ }, j = (e, t) => {
34
+ const o = n.columns.find((l) => l.key === e);
35
+ o && (o.hidden = !t);
36
+ }, H = (e, t, o) => {
37
+ try {
38
+ d[e.onClick](g, t, o);
39
+ } catch (l) {
40
+ console.error(l);
41
+ }
42
+ }, K = (e) => {
43
+ if (n.rowClick)
44
+ try {
45
+ d[n.rowClick](g, e);
46
+ } catch (t) {
47
+ console.error(t);
48
+ }
49
+ }, x = (e) => {
50
+ if (n.rowDbClick)
51
+ try {
52
+ d[n.rowDbClick](g, e);
53
+ } catch (t) {
54
+ console.error(t);
55
+ }
56
+ }, A = f([]), L = (e) => {
57
+ A.value = e;
58
+ }, W = () => {
59
+ var e;
60
+ (e = y.value) == null || e.clearSelection();
61
+ }, q = () => s.value, P = f(), G = (e) => {
62
+ if (P.value = e, !!n.handleCurrentChange)
63
+ try {
64
+ d[n.handleCurrentChange](g, e);
65
+ } catch (t) {
66
+ console.error(t);
67
+ }
68
+ }, I = () => P.value, J = () => {
69
+ var e;
70
+ return (e = y.value) == null ? void 0 : e.getSelectionRows();
71
+ }, O = async () => !0, Q = (e, t) => {
72
+ var l;
73
+ const o = (l = n.topBtns) == null ? void 0 : l.find((C) => C.key === e);
74
+ o && (o.hidden = t);
75
+ }, X = (e, t) => {
76
+ var l;
77
+ const o = (l = n.rowBtns) == null ? void 0 : l.find((C) => C.key === e);
78
+ o && (o.condition = !t);
79
+ }, D = f(0), Y = (e) => {
80
+ D.value = e;
81
+ }, r = f({ pageNum: 1, pageSize: n.defaultPageSize || 5 }), Z = () => r.value, ee = (e) => {
82
+ let t = !1;
83
+ return e.pageNum > -1 && (r.value.pageNum !== e.pageNum && (t = !0), r.value.pageNum = e.pageNum), e.pageSize > -1 && (r.value.pageSize !== e.pageSize && (t = !0), r.value.pageSize = e.pageSize), { pagination: r.value, isChange: t };
84
+ }, te = (e) => {
85
+ if (r.value.pageNum = 1, r.value.pageSize = e, !!n.sizeChange)
86
+ try {
87
+ d[n.sizeChange](g, r.value);
88
+ } catch (t) {
89
+ console.error(t);
90
+ }
91
+ }, ne = (e) => {
92
+ if (r.value.pageNum = e, !!n.pageChange)
93
+ try {
94
+ d[n.pageChange](g, r.value);
95
+ } catch (t) {
96
+ console.error(t);
97
+ }
98
+ }, oe = (e) => {
99
+ var t;
100
+ (t = y.value) == null || t.setCurrentRow(e);
101
+ }, ae = (e) => {
102
+ var t;
103
+ (t = y.value) == null || t.setCurrentRow(s.value[e]);
104
+ }, le = (e, t, o) => {
105
+ n.columns.forEach((l) => {
106
+ l.key === e && l[t] && (l[t] = o);
107
+ });
108
+ }, s = f([]), re = (e) => {
109
+ s.value = e;
110
+ }, ie = (e = {}) => {
111
+ s.value.push(e);
112
+ }, se = (e) => {
113
+ e >= 0 && e < s.value.length && s.value.splice(e, 1);
114
+ }, ce = async () => {
115
+ s.value = [...s.value];
116
+ }, T = de("rootRef"), M = ge({
117
+ ...he(n),
118
+ setCellData: U,
119
+ clearSelection: W,
120
+ getData: q,
121
+ getCurrentRow: I,
122
+ getSelectedRows: J,
123
+ addRow: ie,
124
+ deleteRow: se,
125
+ refresh: ce,
126
+ validate: O,
127
+ setData: re,
128
+ selectRow: oe,
129
+ selectRowNum: ae,
130
+ setTotal: Y,
131
+ getPagination: Z,
132
+ setPagination: ee,
133
+ setTopBtnHidden: Q,
134
+ setColVisible: j,
135
+ setColumn: le,
136
+ setRowsBtnHidden: X,
137
+ rootRef: T,
138
+ type: "table"
139
+ });
140
+ if (n.name) {
141
+ const e = Ce(n.name, M);
142
+ fe(() => {
143
+ e();
144
+ });
145
+ }
146
+ return F(M), (e, t) => {
147
+ const o = R("el-table-column"), l = R("el-tooltip"), C = R("el-button"), ue = R("el-pagination");
148
+ return e.hidden ? m("", !0) : (c(), k("div", {
149
+ key: 0,
150
+ class: "table-render",
151
+ ref_key: "rootRef",
152
+ ref: T
153
+ }, [
154
+ v(p(Se), {
155
+ ref_key: "tableRef",
156
+ ref: y,
157
+ data: s.value,
158
+ "highlight-current-row": e.highlightCurrentRow,
159
+ "row-key": e.rowKey,
160
+ stripe: e.stripe,
161
+ onRowClick: K,
162
+ onRowDblclick: x,
163
+ onSelectionChange: L,
164
+ onCurrentChange: G
165
+ }, {
166
+ empty: u(() => [
167
+ w("div", Re, [
168
+ v(p(ke), {
169
+ name: "tableEmpty",
170
+ style: { width: 56, height: 56 }
171
+ }),
172
+ t[2] || (t[2] = w("div", null, "No data available,please check", -1))
173
+ ])
174
+ ]),
175
+ default: u(() => [
176
+ e.multipleSelection ? (c(), z(o, {
177
+ key: 0,
178
+ type: "selection",
179
+ width: "55"
180
+ })) : m("", !0),
181
+ (c(!0), k(b, null, E(e.columns, (a) => (c(), k(b, {
182
+ key: a.key
183
+ }, [
184
+ a.hidden ? m("", !0) : (c(), z(o, {
185
+ key: 0,
186
+ prop: a.key,
187
+ "min-width": a.minWidth,
188
+ fixed: a.fixed || !1
189
+ }, {
190
+ header: u(() => [
191
+ v(l, {
192
+ class: "box-item",
193
+ effect: "dark",
194
+ content: a.label,
195
+ "show-after": 300,
196
+ placement: "top"
197
+ }, {
198
+ default: u(() => [
199
+ w("div", be, B(a.label), 1)
200
+ ]),
201
+ _: 2
202
+ }, 1032, ["content"])
203
+ ]),
204
+ default: u(({ row: h }) => [
205
+ v(l, {
206
+ class: "box-item",
207
+ effect: "dark",
208
+ content: p(S) ? p(S)(a.key, h) : h[a.key],
209
+ "show-after": 300,
210
+ placement: "top"
211
+ }, {
212
+ default: u(() => [
213
+ w("div", _e, B(p(S) ? p(S)(a.key, h) : h[a.key]), 1)
214
+ ]),
215
+ _: 2
216
+ }, 1032, ["content"])
217
+ ]),
218
+ _: 2
219
+ }, 1032, ["prop", "min-width", "fixed"]))
220
+ ], 64))), 128)),
221
+ e.rowBtns && e.rowBtns.length > 0 ? (c(), z(o, {
222
+ key: 1,
223
+ label: "Action",
224
+ fixed: "right",
225
+ align: "left"
226
+ }, {
227
+ default: u(({ row: a, $index: h }) => [
228
+ (c(!0), k(b, null, E(e.rowBtns, (i) => (c(), k(b, {
229
+ key: i.key
230
+ }, [
231
+ i.condition === void 0 || i.condition === null || p(ve)(i.condition, { $row: a }) ? (c(), z(C, {
232
+ key: 0,
233
+ disabled: i.disabled,
234
+ size: "small",
235
+ type: i.type,
236
+ onClick: (Ne) => H(i, a, h)
237
+ }, {
238
+ default: u(() => [
239
+ i.icon ? (c(), z(we, {
240
+ key: 0,
241
+ name: i.icon.name,
242
+ color: i.icon.color,
243
+ class: V({ "btn-icon": i.text || i.label })
244
+ }, null, 8, ["name", "color", "class"])) : m("", !0),
245
+ me(" " + B(i.label), 1)
246
+ ]),
247
+ _: 2
248
+ }, 1032, ["disabled", "type", "onClick"])) : m("", !0)
249
+ ], 64))), 128))
250
+ ]),
251
+ _: 1
252
+ })) : m("", !0)
253
+ ]),
254
+ _: 1
255
+ }, 8, ["data", "highlight-current-row", "row-key", "stripe"]),
256
+ w("div", {
257
+ class: V(["pagination-wrapper", { hidePagination: e.hiddenPagination }])
258
+ }, [
259
+ v(ue, {
260
+ background: "",
261
+ layout: "total,sizes, prev, pager, next,jumper",
262
+ total: D.value,
263
+ "page-sizes": e.pageSizes || [5, 10, 20, 30, 40],
264
+ "default-page-size": e.defaultPageSize,
265
+ "current-page": r.value.pageNum,
266
+ "onUpdate:currentPage": t[0] || (t[0] = (a) => r.value.pageNum = a),
267
+ "page-size": r.value.pageSize,
268
+ "onUpdate:pageSize": t[1] || (t[1] = (a) => r.value.pageSize = a),
269
+ onSizeChange: te,
270
+ onCurrentChange: ne
271
+ }, null, 8, ["total", "page-sizes", "default-page-size", "current-page", "page-size"])
272
+ ], 2)
273
+ ], 512));
274
+ };
275
+ }
276
+ }), Me = /* @__PURE__ */ ze(Be, [["__scopeId", "data-v-7b1b78e9"]]);
277
+ export {
278
+ Me as default
279
+ };
@@ -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-BvOUGCFQ.js";
2
+ import { a as V } from "./index-DMmaR_UH.js";
3
3
  import "element-plus";
4
4
  const w = /* @__PURE__ */ i({
5
5
  __name: "Tabs",
@@ -0,0 +1,30 @@
1
+ import { defineComponent as o, openBlock as r, createBlock as t, Transition as a, withCtx as l, withDirectives as n, createElementVNode as s, normalizeStyle as p, normalizeClass as i, createVNode as c, unref as m, vShow as f } from "vue";
2
+ import { a as _, b as d } from "./index-DMmaR_UH.js";
3
+ import "element-plus";
4
+ const y = /* @__PURE__ */ o({
5
+ __name: "Wrapper",
6
+ props: {
7
+ children: {},
8
+ style: { type: [Boolean, null, String, Object, Array] },
9
+ type: {},
10
+ collapse: { type: Boolean }
11
+ },
12
+ setup(u) {
13
+ return (e, h) => (r(), t(a, { name: "collapse" }, {
14
+ default: l(() => [
15
+ n(s("div", {
16
+ style: p(e.style),
17
+ class: i({ normal: e.type === "normal" })
18
+ }, [
19
+ c(m(_), { list: e.children }, null, 8, ["list"])
20
+ ], 6), [
21
+ [f, !e.collapse]
22
+ ])
23
+ ]),
24
+ _: 1
25
+ }));
26
+ }
27
+ }), C = /* @__PURE__ */ d(y, [["__scopeId", "data-v-01fff3e6"]]);
28
+ export {
29
+ C as default
30
+ };