asiaint-lowcode 3.0.22 → 3.0.24

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 (33) hide show
  1. package/dist/asiaint-lowcode.js +1 -1
  2. package/dist/asiaint-lowcode.umd.cjs +45 -45
  3. package/dist/index.d.ts +2 -0
  4. package/dist/lazy/{Card-BSIlk7sl.js → Card-DWHXO8QF.js} +1 -1
  5. package/dist/lazy/{Cascader-CJCSooPT.js → Cascader-BRSxnuqk.js} +1 -1
  6. package/dist/lazy/{Checkbox-Cfget8PO.js → Checkbox-FOpBQ2u7.js} +2 -2
  7. package/dist/lazy/{Collapse-B00z3bax.js → Collapse-NyEQs15R.js} +1 -1
  8. package/dist/lazy/{Component-DJfaia_x.js → Component-4MN_4phy.js} +1 -1
  9. package/dist/lazy/{Component-CR9rcr7C.js → Component-Bh3J0rdf.js} +1 -1
  10. package/dist/lazy/Component-CEM0gst0.js +93 -0
  11. package/dist/lazy/{Component-DqouCzcp.js → Component-DrDAFMp3.js} +1 -1
  12. package/dist/lazy/{Component-0b7VFD3U.js → Component-tnTacQmK.js} +1 -1
  13. package/dist/lazy/{Component-CPH7THgQ.js → Component-xNOvM2iR.js} +1 -1
  14. package/dist/lazy/{CurdCard-DzXT2vx0.js → CurdCard-D1pm5KZ5.js} +23 -23
  15. package/dist/lazy/{Custom-B0dZl7am.js → Custom-BPTzdX6c.js} +1 -1
  16. package/dist/lazy/{FormList-CzVjz4-M.js → FormList-Cilxebcn.js} +1 -1
  17. package/dist/lazy/{Grid-D6SyYDkl.js → Grid-CT8qq4Pi.js} +3 -3
  18. package/dist/lazy/{Inline-BfYU-rEo.js → Inline-ChdliYlO.js} +1 -1
  19. package/dist/lazy/{JsonEdit-DR4TytpB.js → JsonEdit-CWKx0wA9.js} +1 -1
  20. package/dist/lazy/{ObjGroup-By9aSlqC.js → ObjGroup-UNJvnh1b.js} +1 -1
  21. package/dist/lazy/{OfferDetails-C_YLBbcS.js → OfferDetails-CUZi3yz4.js} +2 -1
  22. package/dist/lazy/{Radio-BVkBOQzX.js → Radio-DtPOd1to.js} +2 -2
  23. package/dist/lazy/{SearchSelect-BMNjq_HJ.js → SearchSelect-DtZPSGCS.js} +2 -2
  24. package/dist/lazy/{Select-m5wicy9a.js → Select-BNV3Zt9l.js} +2 -2
  25. package/dist/lazy/Table-BkvHcRpT.js +280 -0
  26. package/dist/lazy/{Tabs-CEd7LSXR.js → Tabs-CcBlFBej.js} +1 -1
  27. package/dist/lazy/{Wrapper-CC-1VGmf.js → Wrapper-CQbgkAfW.js} +1 -1
  28. package/dist/lazy/{index-BbRXuTVK.js → index-DCpsxjeZ.js} +335 -328
  29. package/dist/lazy/{useSelect-BtL1_7JS.js → useSelect-N-3TdoV-.js} +1 -1
  30. package/dist/style.css +2 -2
  31. package/package.json +1 -1
  32. package/dist/lazy/Component-H3v1KWfh.js +0 -89
  33. package/dist/lazy/Table-fzR3oAK4.js +0 -296
@@ -0,0 +1,280 @@
1
+ import { defineComponent as de, inject as b, ref as h, useTemplateRef as ge, readonly as he, toRefs as ye, onUnmounted as fe, resolveComponent as B, openBlock as u, createElementBlock as k, normalizeClass as N, withDirectives as V, createElementVNode as y, createVNode as S, unref as c, withCtx as f, createBlock as w, createCommentVNode as m, Fragment as R, renderList as $, toDisplayString as P, withModifiers as me, createTextVNode as Ce, vShow as F, mergeProps as ve } from "vue";
2
+ import { $ as ke, h as we, _ as ze, f as Se, I as Re, C as be, b as Be } from "./index-DCpsxjeZ.js";
3
+ import { ElTable as Ne } from "element-plus";
4
+ const Pe = { class: "empty-content" }, De = ["title"], Te = ["title"], _e = /* @__PURE__ */ de({
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
+ pagerCount: {},
28
+ defaultPageSize: {},
29
+ typeSwitch: { type: Boolean },
30
+ displayType: { default: "table" },
31
+ onMounted: {},
32
+ height: {},
33
+ name: {}
34
+ },
35
+ setup(U, { expose: j }) {
36
+ const n = U, p = b("ruleModule", void 0), d = b("pageMethodMap", {}), D = b(ke), z = D ? D.translateFn : null, C = h(), H = (e, t, a) => {
37
+ s.value[e] && (s.value[e][t] = a);
38
+ }, K = (e, t) => {
39
+ const a = n.columns.find((i) => i.key === e);
40
+ a && (a.hidden = !t);
41
+ }, L = (e, t, a) => {
42
+ try {
43
+ p[e.onClick](d, t, a);
44
+ } catch (i) {
45
+ console.error(i);
46
+ }
47
+ }, A = (e) => {
48
+ if (n.rowClick)
49
+ try {
50
+ p[n.rowClick](d, e);
51
+ } catch (t) {
52
+ console.error(t);
53
+ }
54
+ }, W = (e) => {
55
+ if (n.rowDbClick)
56
+ try {
57
+ p[n.rowDbClick](d, e);
58
+ } catch (t) {
59
+ console.error(t);
60
+ }
61
+ }, q = h([]), G = (e) => {
62
+ q.value = e;
63
+ }, I = () => {
64
+ var e;
65
+ (e = C.value) == null || e.clearSelection();
66
+ }, J = () => s.value, T = h(), O = (e) => {
67
+ if (T.value = e, !!n.handleCurrentChange)
68
+ try {
69
+ p[n.handleCurrentChange](d, e);
70
+ } catch (t) {
71
+ console.error(t);
72
+ }
73
+ }, Q = () => T.value, X = () => {
74
+ var e;
75
+ return (e = C.value) == null ? void 0 : e.getSelectionRows();
76
+ }, Y = async () => !0, Z = (e, t) => {
77
+ var i;
78
+ const a = (i = n.topBtns) == null ? void 0 : i.find((v) => v.key === e);
79
+ a && (a.hidden = t);
80
+ }, x = (e, t) => {
81
+ var i;
82
+ const a = (i = n.rowBtns) == null ? void 0 : i.find((v) => v.key === e);
83
+ a && (a.condition = !t);
84
+ }, _ = h(0), ee = (e) => {
85
+ _.value = e;
86
+ }, l = h({ pageNum: 1, pageSize: n.defaultPageSize || 5 }), te = () => l.value, ne = (e) => {
87
+ let t = !1;
88
+ return e.pageNum > -1 && (l.value.pageNum !== e.pageNum && (t = !0), l.value.pageNum = e.pageNum), e.pageSize > -1 && (l.value.pageSize !== e.pageSize && (t = !0), l.value.pageSize = e.pageSize), { pagination: l.value, isChange: t };
89
+ }, ae = (e) => {
90
+ if (l.value.pageNum = 1, l.value.pageSize = e, !!n.sizeChange)
91
+ try {
92
+ p[n.sizeChange](d, l.value);
93
+ } catch (t) {
94
+ console.error(t);
95
+ }
96
+ }, oe = (e) => {
97
+ if (l.value.pageNum = e, !!n.pageChange)
98
+ try {
99
+ p[n.pageChange](d, l.value);
100
+ } catch (t) {
101
+ console.error(t);
102
+ }
103
+ }, le = (e) => {
104
+ var t;
105
+ (t = C.value) == null || t.setCurrentRow(e);
106
+ }, ie = (e) => {
107
+ var t;
108
+ (t = C.value) == null || t.setCurrentRow(s.value[e]);
109
+ }, re = (e, t, a) => {
110
+ n.columns.forEach((i) => {
111
+ i.key === e && i[t] && (i[t] = a);
112
+ });
113
+ }, s = h([]), se = (e) => {
114
+ s.value = e;
115
+ }, ue = (e = {}) => {
116
+ s.value.push(e);
117
+ }, ce = (e) => {
118
+ e >= 0 && e < s.value.length && s.value.splice(e, 1);
119
+ }, pe = async () => {
120
+ s.value = [...s.value];
121
+ }, M = ge("rootRef"), E = he({
122
+ ...ye(n),
123
+ setCellData: H,
124
+ clearSelection: I,
125
+ getData: J,
126
+ getCurrentRow: Q,
127
+ getSelectedRows: X,
128
+ addRow: ue,
129
+ deleteRow: ce,
130
+ refresh: pe,
131
+ validate: Y,
132
+ setData: se,
133
+ selectRow: le,
134
+ selectRowNum: ie,
135
+ setTotal: ee,
136
+ getPagination: te,
137
+ setPagination: ne,
138
+ setTopBtnHidden: Z,
139
+ setColVisible: K,
140
+ setColumn: re,
141
+ setRowsBtnHidden: x,
142
+ rootRef: M,
143
+ type: "table"
144
+ });
145
+ if (n.name) {
146
+ const e = we(n.name, E);
147
+ fe(() => {
148
+ e();
149
+ });
150
+ }
151
+ return j(E), (e, t) => {
152
+ const a = B("el-table-column"), i = B("el-button"), v = B("el-pagination");
153
+ return e.hidden ? m("", !0) : (u(), k("div", {
154
+ key: 0,
155
+ class: N(["table-render", { tableBorder: e.displayType === "table" }]),
156
+ ref_key: "rootRef",
157
+ ref: M
158
+ }, [
159
+ V(y("div", null, [
160
+ S(c(Ne), {
161
+ ref_key: "tableRef",
162
+ ref: C,
163
+ data: s.value,
164
+ "highlight-current-row": e.highlightCurrentRow,
165
+ "row-key": e.rowKey,
166
+ stripe: e.stripe,
167
+ onRowClick: A,
168
+ onRowDblclick: W,
169
+ onSelectionChange: G,
170
+ onCurrentChange: O,
171
+ height: e.height
172
+ }, {
173
+ empty: f(() => [
174
+ y("div", Pe, [
175
+ S(c(ze), {
176
+ name: "tableEmpty",
177
+ style: { width: 56, height: 56 }
178
+ }),
179
+ t[2] || (t[2] = y("div", null, "No data available,please check", -1))
180
+ ])
181
+ ]),
182
+ default: f(() => [
183
+ e.multipleSelection ? (u(), w(a, {
184
+ key: 0,
185
+ type: "selection",
186
+ width: "55"
187
+ })) : m("", !0),
188
+ (u(!0), k(R, null, $(e.columns, (o) => (u(), k(R, {
189
+ key: o.key
190
+ }, [
191
+ o.hidden ? m("", !0) : (u(), w(a, {
192
+ key: 0,
193
+ prop: o.key,
194
+ "min-width": o.minWidth,
195
+ fixed: o.fixed || !1
196
+ }, {
197
+ header: f(() => [
198
+ y("div", {
199
+ class: "text-ellipsis",
200
+ title: o.label
201
+ }, P(o.label), 9, De)
202
+ ]),
203
+ default: f(({ row: g }) => [
204
+ y("div", {
205
+ class: "text-ellipsis",
206
+ title: c(z) ? c(z)(o.key, g) : g[o.key]
207
+ }, P(c(z) ? c(z)(o.key, g) : g[o.key]), 9, Te)
208
+ ]),
209
+ _: 2
210
+ }, 1032, ["prop", "min-width", "fixed"]))
211
+ ], 64))), 128)),
212
+ e.rowBtns && e.rowBtns.length > 0 ? (u(), w(a, {
213
+ key: 1,
214
+ label: "Action",
215
+ fixed: "right",
216
+ align: "left"
217
+ }, {
218
+ default: f(({ row: o, $index: g }) => [
219
+ (u(!0), k(R, null, $(e.rowBtns, (r) => (u(), k(R, {
220
+ key: r.key
221
+ }, [
222
+ r.condition === void 0 || r.condition === null || c(Se)(r.condition, { $row: o }) ? (u(), w(i, {
223
+ key: 0,
224
+ disabled: r.disabled,
225
+ link: "",
226
+ size: "small",
227
+ type: r.type,
228
+ onClick: me((Me) => L(r, o, g), ["stop"])
229
+ }, {
230
+ default: f(() => [
231
+ r.icon ? (u(), w(Re, {
232
+ key: 0,
233
+ name: r.icon.name,
234
+ color: r.icon.color,
235
+ class: N({ "btn-icon": r.text || r.label })
236
+ }, null, 8, ["name", "color", "class"])) : m("", !0),
237
+ Ce(" " + P(r.label), 1)
238
+ ]),
239
+ _: 2
240
+ }, 1032, ["disabled", "type", "onClick"])) : m("", !0)
241
+ ], 64))), 128))
242
+ ]),
243
+ _: 1
244
+ })) : m("", !0)
245
+ ]),
246
+ _: 1
247
+ }, 8, ["data", "highlight-current-row", "row-key", "stripe", "height"])
248
+ ], 512), [
249
+ [F, e.displayType === "table"]
250
+ ]),
251
+ V(S(be, ve({ data: s.value }, n), null, 16, ["data"]), [
252
+ [F, e.displayType === "card"]
253
+ ]),
254
+ y("div", {
255
+ class: N(["pagination-wrapper", {
256
+ hidePagination: e.hiddenPagination,
257
+ cardlistPadding: e.displayType === "card"
258
+ }])
259
+ }, [
260
+ S(v, {
261
+ layout: "total,sizes, prev, pager, next,jumper",
262
+ total: _.value,
263
+ "page-sizes": e.pageSizes || [5, 10, 20, 30, 40],
264
+ "default-page-size": e.defaultPageSize,
265
+ "current-page": l.value.pageNum,
266
+ "onUpdate:currentPage": t[0] || (t[0] = (o) => l.value.pageNum = o),
267
+ "page-size": l.value.pageSize,
268
+ "onUpdate:pageSize": t[1] || (t[1] = (o) => l.value.pageSize = o),
269
+ "pager-count": e.pagerCount,
270
+ onSizeChange: ae,
271
+ onCurrentChange: oe
272
+ }, null, 8, ["total", "page-sizes", "default-page-size", "current-page", "page-size", "pager-count"])
273
+ ], 2)
274
+ ], 2));
275
+ };
276
+ }
277
+ }), Fe = /* @__PURE__ */ Be(_e, [["__scopeId", "data-v-86240a0f"]]);
278
+ export {
279
+ Fe as default
280
+ };
@@ -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-BbRXuTVK.js";
2
+ import { a as V } from "./index-DCpsxjeZ.js";
3
3
  import "element-plus";
4
4
  const w = /* @__PURE__ */ i({
5
5
  __name: "Tabs",
@@ -1,5 +1,5 @@
1
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-BbRXuTVK.js";
2
+ import { a as _, b as d } from "./index-DCpsxjeZ.js";
3
3
  import "element-plus";
4
4
  const y = /* @__PURE__ */ o({
5
5
  __name: "Wrapper",