asiaint-lowcode 3.0.74 → 3.1.0
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/README.md +31 -31
- package/dist/asiaint-lowcode.js +3 -3
- package/dist/asiaint-lowcode.umd.cjs +142 -142
- package/dist/index.d.ts +168 -28
- package/dist/lazy/{Card-BLkyronF.js → Card-6y3b8xK9.js} +2 -2
- package/dist/lazy/{Cascader-BWayPZsj.js → Cascader-1XEBAirk.js} +2 -1
- package/dist/lazy/{Checkbox-B0f2osCE.js → Checkbox-DY7Ufmrz.js} +8 -7
- package/dist/lazy/{Collapse-CwiKPgVS.js → Collapse-BT7RNNg6.js} +1 -1
- package/dist/lazy/{Component-BgbXAvZP.js → Component-AYxGCLAH.js} +20 -20
- package/dist/lazy/{Component-CxjtIKb4.js → Component-BYlYtzWb.js} +2 -2
- package/dist/lazy/{Component-DtKK0pz0.js → Component-CF4m_685.js} +1 -1
- package/dist/lazy/{Component-B0YN5w1O.js → Component-CkSnYtMh.js} +1 -1
- package/dist/lazy/{Component-BTW9MMvF.js → Component-DITfSg2v.js} +1 -1
- package/dist/lazy/{Component-DN6wPVjw.js → Component-DZMCcrpa.js} +2 -2
- package/dist/lazy/CurdCard-BXOxRtCA.js +167 -0
- package/dist/lazy/{Custom-BHrk3rwy.js → Custom-Df5H1QJV.js} +7 -7
- package/dist/lazy/{DragList-BfxZ0XM8.js → DragList-BH1VY62B.js} +59 -57
- package/dist/lazy/{FormList-Bve4HUdY.js → FormList-BMk_lCx8.js} +1 -1
- package/dist/lazy/{Grid-gYua8Lbh.js → Grid-SVpxXRzO.js} +1 -1
- package/dist/lazy/Inline-CE2A9Of4.js +35 -0
- package/dist/lazy/{JsonEdit-DspEkIiw.js → JsonEdit-C_CUvw5t.js} +3 -3
- package/dist/lazy/{LogList-BJ0N-SZh.js → LogList-COeBYixP.js} +7 -7
- package/dist/lazy/{ObjGroup-DwogU-tX.js → ObjGroup-BB2eQigf.js} +1 -1
- package/dist/lazy/{OfferDetails-BRQXALnl.js → OfferDetails-BEyNKQsf.js} +8 -7
- package/dist/lazy/{Progress-CZiRwjox.js → Progress-CYBbCXFh.js} +5 -5
- package/dist/lazy/{Radio-DAQ63lEp.js → Radio-qI1r_rWj.js} +24 -22
- package/dist/lazy/{SearchSelect-B4rd3IEr.js → SearchSelect-ZmOPM_QH.js} +18 -17
- package/dist/lazy/{Select-B9ka9Z-o.js → Select-CxtVmfLu.js} +10 -9
- package/dist/lazy/Table-YeT82lnr.js +438 -0
- package/dist/lazy/{Tabs-D_jMk0g4.js → Tabs-DFvfP_nb.js} +1 -1
- package/dist/lazy/Wrapper-DAFSrkAr.js +87 -0
- package/dist/lazy/{index-CPs7U1jG.js → index-DQ889qV3.js} +10461 -9979
- package/dist/lazy/useSelect-EfaZqc6a.js +77 -0
- package/dist/style.css +2 -2
- package/global.d.ts +10 -10
- package/package.json +36 -36
- package/dist/lazy/CurdCard-YilgvVgg.js +0 -160
- package/dist/lazy/Inline-DP_W3TA1.js +0 -33
- package/dist/lazy/Table-BT_PlC1e.js +0 -351
- package/dist/lazy/Wrapper-Db2njs9z.js +0 -36
- package/dist/lazy/useSelect-DBsTZmYm.js +0 -76
package/global.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
declare module 'vue' {
|
|
2
|
-
export interface GlobalComponents {
|
|
3
|
-
FormRender: (typeof import('asiaint-lowcode'))['FormRender']
|
|
4
|
-
FormDesign: (typeof import('asiaint-lowcode'))['FormDesign']
|
|
5
|
-
TableRender: (typeof import('asiaint-lowcode'))['TableRender']
|
|
6
|
-
PageRender: (typeof import('asiaint-lowcode'))['PageRender']
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export {}
|
|
1
|
+
declare module 'vue' {
|
|
2
|
+
export interface GlobalComponents {
|
|
3
|
+
FormRender: (typeof import('asiaint-lowcode'))['FormRender']
|
|
4
|
+
FormDesign: (typeof import('asiaint-lowcode'))['FormDesign']
|
|
5
|
+
TableRender: (typeof import('asiaint-lowcode'))['TableRender']
|
|
6
|
+
PageRender: (typeof import('asiaint-lowcode'))['PageRender']
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export {}
|
package/package.json
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "asiaint-lowcode",
|
|
3
|
-
"version": "3.0
|
|
4
|
-
"private": false,
|
|
5
|
-
"type": "module",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"build": "vite build",
|
|
8
|
-
"v": "npm version patch",
|
|
9
|
-
"release": "vite build && npm publish"
|
|
10
|
-
},
|
|
11
|
-
"peerDependencies": {
|
|
12
|
-
"vue": "^3.2.0",
|
|
13
|
-
"element-plus": "^2.6.0"
|
|
14
|
-
},
|
|
15
|
-
"dependencies": {
|
|
16
|
-
"element-plus": "^2.8.3",
|
|
17
|
-
"vue": "^3.5.8"
|
|
18
|
-
},
|
|
19
|
-
"devDependencies": {
|
|
20
|
-
"vite-plugin-dts": "^3.7.3",
|
|
21
|
-
"vite-plugin-libcss": "^1.1.1"
|
|
22
|
-
},
|
|
23
|
-
"files": [
|
|
24
|
-
"dist",
|
|
25
|
-
"global.d.ts"
|
|
26
|
-
],
|
|
27
|
-
"main": "./dist/asiaint-lowcode.js",
|
|
28
|
-
"module": "./dist/asiaint-lowcode.js",
|
|
29
|
-
"types": "dist/index.d.ts",
|
|
30
|
-
"keywords": [
|
|
31
|
-
"component",
|
|
32
|
-
"vue",
|
|
33
|
-
"form",
|
|
34
|
-
"element-ui"
|
|
35
|
-
]
|
|
36
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "asiaint-lowcode",
|
|
3
|
+
"version": "3.1.0",
|
|
4
|
+
"private": false,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"build": "vite build",
|
|
8
|
+
"v": "npm version patch",
|
|
9
|
+
"release": "vite build && npm publish"
|
|
10
|
+
},
|
|
11
|
+
"peerDependencies": {
|
|
12
|
+
"vue": "^3.2.0",
|
|
13
|
+
"element-plus": "^2.6.0"
|
|
14
|
+
},
|
|
15
|
+
"dependencies": {
|
|
16
|
+
"element-plus": "^2.8.3",
|
|
17
|
+
"vue": "^3.5.8"
|
|
18
|
+
},
|
|
19
|
+
"devDependencies": {
|
|
20
|
+
"vite-plugin-dts": "^3.7.3",
|
|
21
|
+
"vite-plugin-libcss": "^1.1.1"
|
|
22
|
+
},
|
|
23
|
+
"files": [
|
|
24
|
+
"dist",
|
|
25
|
+
"global.d.ts"
|
|
26
|
+
],
|
|
27
|
+
"main": "./dist/asiaint-lowcode.js",
|
|
28
|
+
"module": "./dist/asiaint-lowcode.js",
|
|
29
|
+
"types": "dist/index.d.ts",
|
|
30
|
+
"keywords": [
|
|
31
|
+
"component",
|
|
32
|
+
"vue",
|
|
33
|
+
"form",
|
|
34
|
+
"element-ui"
|
|
35
|
+
]
|
|
36
|
+
}
|
|
@@ -1,160 +0,0 @@
|
|
|
1
|
-
import { defineComponent as z, inject as V, ref as I, resolveComponent as C, openBlock as a, createElementBlock as s, createElementVNode as i, normalizeClass as y, createBlock as r, createCommentVNode as m, toDisplayString as M, withCtx as f, Fragment as w, renderList as $, createTextVNode as j, createVNode as p, unref as T, withDirectives as P, vShow as U } from "vue";
|
|
2
|
-
import { u as q, I as u, B as A, a as R, h as G, b as H } from "./index-CPs7U1jG.js";
|
|
3
|
-
import "element-plus";
|
|
4
|
-
const J = { class: "crm-curd-card" }, K = { class: "left-part" }, O = { class: "title" }, Q = { class: "right-part" }, W = {
|
|
5
|
-
key: 0,
|
|
6
|
-
class: "switch-panel"
|
|
7
|
-
}, X = { key: 2 }, Y = /* @__PURE__ */ z({
|
|
8
|
-
__name: "CurdCard",
|
|
9
|
-
props: {
|
|
10
|
-
name: {},
|
|
11
|
-
children: {},
|
|
12
|
-
collapsible: { type: Boolean },
|
|
13
|
-
onCollapsed: {},
|
|
14
|
-
typeSwitch: { type: Boolean },
|
|
15
|
-
title: {},
|
|
16
|
-
btns: {},
|
|
17
|
-
type: {},
|
|
18
|
-
mainIcon: {},
|
|
19
|
-
extraIcons: {},
|
|
20
|
-
displayType: {},
|
|
21
|
-
radioList: {},
|
|
22
|
-
onRadioChange: {},
|
|
23
|
-
radioDefault: {}
|
|
24
|
-
},
|
|
25
|
-
setup(S) {
|
|
26
|
-
const c = V("ruleModule", void 0), k = V("pageMethodMap", {}), n = S, b = I(n.radioDefault ?? "2"), B = (e) => {
|
|
27
|
-
if (e && c)
|
|
28
|
-
try {
|
|
29
|
-
c[e](k);
|
|
30
|
-
} catch (o) {
|
|
31
|
-
console.error(o);
|
|
32
|
-
}
|
|
33
|
-
}, D = (e) => {
|
|
34
|
-
n.onRadioChange && c && c[n.onRadioChange](k, e);
|
|
35
|
-
}, L = () => {
|
|
36
|
-
d.value = !d.value, n.onCollapsed && c && c[n.onCollapsed](k, d.value);
|
|
37
|
-
}, d = I(!1), v = I(n.displayType || (n.typeSwitch ? "card" : "table")), N = q(), g = (e) => {
|
|
38
|
-
v.value = e;
|
|
39
|
-
const o = G(N.schema.items, n.name), h = (_) => {
|
|
40
|
-
_.forEach((t) => {
|
|
41
|
-
t.component === "Table" && t.props && (t.props.displayType = e), t.children && t.children.length > 0 && h(t.children);
|
|
42
|
-
});
|
|
43
|
-
};
|
|
44
|
-
o && o.children && h(o.children);
|
|
45
|
-
};
|
|
46
|
-
return g(v.value), (e, o) => {
|
|
47
|
-
const h = C("el-radio"), _ = C("el-radio-group"), t = C("el-tooltip"), E = C("el-collapse-transition");
|
|
48
|
-
return a(), s("div", J, [
|
|
49
|
-
i("div", {
|
|
50
|
-
class: y(["card-header", {
|
|
51
|
-
inline: e.type === "inline",
|
|
52
|
-
mix: e.type === "mix",
|
|
53
|
-
default: e.type === "default",
|
|
54
|
-
collapsedPadding: d.value && e.onCollapsed
|
|
55
|
-
}])
|
|
56
|
-
}, [
|
|
57
|
-
i("div", K, [
|
|
58
|
-
e.mainIcon ? (a(), r(u, {
|
|
59
|
-
key: 0,
|
|
60
|
-
class: "title-icon",
|
|
61
|
-
size: "large",
|
|
62
|
-
name: e.mainIcon.name,
|
|
63
|
-
color: e.mainIcon.color
|
|
64
|
-
}, null, 8, ["name", "color"])) : m("", !0),
|
|
65
|
-
i("span", O, M(e.title), 1),
|
|
66
|
-
e.radioList ? (a(), r(_, {
|
|
67
|
-
key: 1,
|
|
68
|
-
class: "ml-9",
|
|
69
|
-
modelValue: b.value,
|
|
70
|
-
"onUpdate:modelValue": o[0] || (o[0] = (l) => b.value = l),
|
|
71
|
-
onChange: o[1] || (o[1] = (l) => D(b.value))
|
|
72
|
-
}, {
|
|
73
|
-
default: f(() => [
|
|
74
|
-
(a(!0), s(w, null, $(e.radioList, (l) => (a(), r(h, {
|
|
75
|
-
value: l.value,
|
|
76
|
-
key: l.value
|
|
77
|
-
}, {
|
|
78
|
-
default: f(() => [
|
|
79
|
-
j(M(l.label), 1)
|
|
80
|
-
]),
|
|
81
|
-
_: 2
|
|
82
|
-
}, 1032, ["value"]))), 128))
|
|
83
|
-
]),
|
|
84
|
-
_: 1
|
|
85
|
-
}, 8, ["modelValue"])) : m("", !0),
|
|
86
|
-
(a(!0), s(w, null, $(e.extraIcons, (l) => (a(), s(w, {
|
|
87
|
-
key: l.name
|
|
88
|
-
}, [
|
|
89
|
-
l.tips ? (a(), r(t, {
|
|
90
|
-
key: 0,
|
|
91
|
-
content: l.tips,
|
|
92
|
-
placement: "right"
|
|
93
|
-
}, {
|
|
94
|
-
default: f(() => [
|
|
95
|
-
p(u, {
|
|
96
|
-
class: "extra-icon",
|
|
97
|
-
name: l.name,
|
|
98
|
-
color: l.color,
|
|
99
|
-
onClick: (F) => B(l.onClick)
|
|
100
|
-
}, null, 8, ["name", "color", "onClick"])
|
|
101
|
-
]),
|
|
102
|
-
_: 2
|
|
103
|
-
}, 1032, ["content"])) : (a(), r(u, {
|
|
104
|
-
key: 1,
|
|
105
|
-
class: "extra-icon",
|
|
106
|
-
name: l.name,
|
|
107
|
-
color: l.color,
|
|
108
|
-
onClick: (F) => B(l.onClick)
|
|
109
|
-
}, null, 8, ["name", "color", "onClick"]))
|
|
110
|
-
], 64))), 128))
|
|
111
|
-
]),
|
|
112
|
-
i("div", Q, [
|
|
113
|
-
e.typeSwitch ? (a(), s("div", W, [
|
|
114
|
-
i("div", {
|
|
115
|
-
class: y(["switch-icon-wrapper", { active: v.value === "card" }]),
|
|
116
|
-
onClick: o[2] || (o[2] = (l) => g("card"))
|
|
117
|
-
}, [
|
|
118
|
-
p(u, { name: "icon-kapian" })
|
|
119
|
-
], 2),
|
|
120
|
-
i("div", {
|
|
121
|
-
class: y(["switch-icon-wrapper", { active: v.value === "table" }]),
|
|
122
|
-
onClick: o[3] || (o[3] = (l) => g("table"))
|
|
123
|
-
}, [
|
|
124
|
-
p(u, { name: "icon-biaoge" })
|
|
125
|
-
], 2)
|
|
126
|
-
])) : m("", !0),
|
|
127
|
-
e.collapsible ? (a(), s("div", {
|
|
128
|
-
key: 1,
|
|
129
|
-
class: y(["collapse-icon-wrapper", { collapsed: d.value }]),
|
|
130
|
-
onClick: L
|
|
131
|
-
}, [
|
|
132
|
-
p(u, { name: "icon-shaixuan" })
|
|
133
|
-
], 2)) : m("", !0),
|
|
134
|
-
e.btns && e.btns.length > 0 ? (a(), s("div", X, [
|
|
135
|
-
p(T(A), {
|
|
136
|
-
btns: e.btns || []
|
|
137
|
-
}, null, 8, ["btns"])
|
|
138
|
-
])) : m("", !0)
|
|
139
|
-
])
|
|
140
|
-
], 2),
|
|
141
|
-
e.onCollapsed ? (a(), r(T(R), {
|
|
142
|
-
key: 1,
|
|
143
|
-
list: e.children
|
|
144
|
-
}, null, 8, ["list"])) : (a(), r(E, { key: 0 }, {
|
|
145
|
-
default: f(() => [
|
|
146
|
-
P(i("div", null, [
|
|
147
|
-
p(T(R), { list: e.children }, null, 8, ["list"])
|
|
148
|
-
], 512), [
|
|
149
|
-
[U, !d.value]
|
|
150
|
-
])
|
|
151
|
-
]),
|
|
152
|
-
_: 1
|
|
153
|
-
}))
|
|
154
|
-
]);
|
|
155
|
-
};
|
|
156
|
-
}
|
|
157
|
-
}), le = /* @__PURE__ */ H(Y, [["__scopeId", "data-v-fadf0058"]]);
|
|
158
|
-
export {
|
|
159
|
-
le as default
|
|
160
|
-
};
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { defineComponent as o, computed as l, openBlock as i, createElementBlock as r, normalizeStyle as p, createVNode as s, unref as c } from "vue";
|
|
2
|
-
import { a as m, b as f } from "./index-CPs7U1jG.js";
|
|
3
|
-
import "element-plus";
|
|
4
|
-
const d = /* @__PURE__ */ o({
|
|
5
|
-
__name: "Inline",
|
|
6
|
-
props: {
|
|
7
|
-
children: {},
|
|
8
|
-
align: {},
|
|
9
|
-
autoWrap: { type: Boolean },
|
|
10
|
-
gap: {},
|
|
11
|
-
alignItems: {}
|
|
12
|
-
},
|
|
13
|
-
setup(n) {
|
|
14
|
-
const e = n, t = l(() => ({
|
|
15
|
-
width: "100%",
|
|
16
|
-
display: "flex",
|
|
17
|
-
"justify-content": e.align,
|
|
18
|
-
"align-items": e.alignItems,
|
|
19
|
-
"flex-wrap": e.autoWrap ? "wrap" : "nowrap",
|
|
20
|
-
"overflow-x": "auto",
|
|
21
|
-
gap: `${e.gap || 12}px`
|
|
22
|
-
}));
|
|
23
|
-
return (a, u) => (i(), r("div", {
|
|
24
|
-
class: "form-item-inline",
|
|
25
|
-
style: p(t.value)
|
|
26
|
-
}, [
|
|
27
|
-
s(c(m), { list: a.children }, null, 8, ["list"])
|
|
28
|
-
], 4));
|
|
29
|
-
}
|
|
30
|
-
}), y = /* @__PURE__ */ f(d, [["__scopeId", "data-v-b9d2c15b"]]);
|
|
31
|
-
export {
|
|
32
|
-
y as default
|
|
33
|
-
};
|
|
@@ -1,351 +0,0 @@
|
|
|
1
|
-
import { defineComponent as Se, computed as _, inject as k, ref as v, useTemplateRef as ze, readonly as Be, toRefs as Re, onMounted as Pe, nextTick as _e, onActivated as Ne, onUnmounted as Me, resolveComponent as B, openBlock as u, createElementBlock as g, normalizeClass as N, withDirectives as j, createElementVNode as f, createVNode as b, unref as R, withCtx as h, createBlock as S, createCommentVNode as m, Fragment as P, renderList as G, toDisplayString as M, withModifiers as Te, vShow as H, mergeProps as De } from "vue";
|
|
2
|
-
import { $ as $e, f as K, i as Fe, _ as Ee, I as Ae, C as Le, b as Ve } from "./index-CPs7U1jG.js";
|
|
3
|
-
import { ElTable as Ue, ElLoading as W } from "element-plus";
|
|
4
|
-
const je = ["id"], Ge = { class: "empty-content" }, He = ["title"], Ke = ["title", "onClick"], We = ["title"], qe = { class: "row-btn-wrapper" }, Ie = /* @__PURE__ */ Se({
|
|
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
|
-
onActivated: {},
|
|
33
|
-
height: {},
|
|
34
|
-
collapsible: { type: Boolean },
|
|
35
|
-
name: {}
|
|
36
|
-
},
|
|
37
|
-
setup(q, { expose: I }) {
|
|
38
|
-
const n = q, z = _(() => n.displayType ? n.displayType : n.typeSwitch ? "card" : "table"), J = k("ruleModule", void 0), T = k("ruleMap", void 0), c = _(() => n.rulePath && T[n.rulePath] ? T[n.rulePath] : J), d = k("pageMethodMap", {}), D = k("getGlobalParams", () => {
|
|
39
|
-
}), $ = k($e), F = $ ? $.translateFn : null, y = v(), O = (e, t, a) => {
|
|
40
|
-
i.value[e] && (i.value[e][t] = a);
|
|
41
|
-
}, Q = (e, t) => {
|
|
42
|
-
const a = n.columns.find((l) => l.key === e);
|
|
43
|
-
a && (a.hidden = !t);
|
|
44
|
-
}, E = (e, t, a) => {
|
|
45
|
-
try {
|
|
46
|
-
c.value[e.onClick](d, t, a);
|
|
47
|
-
} catch (l) {
|
|
48
|
-
console.error(l);
|
|
49
|
-
}
|
|
50
|
-
}, X = (e) => {
|
|
51
|
-
if (n.rowClick)
|
|
52
|
-
try {
|
|
53
|
-
c.value[n.rowClick](d, e);
|
|
54
|
-
} catch (t) {
|
|
55
|
-
console.error(t);
|
|
56
|
-
}
|
|
57
|
-
}, Y = (e) => {
|
|
58
|
-
if (n.rowDbClick)
|
|
59
|
-
try {
|
|
60
|
-
c.value[n.rowDbClick](d, e);
|
|
61
|
-
} catch (t) {
|
|
62
|
-
console.error(t);
|
|
63
|
-
}
|
|
64
|
-
}, Z = v([]), x = (e) => {
|
|
65
|
-
Z.value = e;
|
|
66
|
-
}, ee = () => {
|
|
67
|
-
var e;
|
|
68
|
-
(e = y.value) == null || e.clearSelection();
|
|
69
|
-
}, te = () => i.value, A = v(), ne = (e) => {
|
|
70
|
-
if (A.value = e, !!n.handleCurrentChange)
|
|
71
|
-
try {
|
|
72
|
-
c.value[n.handleCurrentChange](d, e);
|
|
73
|
-
} catch (t) {
|
|
74
|
-
console.error(t);
|
|
75
|
-
}
|
|
76
|
-
}, ae = () => A.value, oe = () => {
|
|
77
|
-
var e;
|
|
78
|
-
return (e = y.value) == null ? void 0 : e.getSelectionRows();
|
|
79
|
-
}, le = async () => !0, ie = (e, t) => {
|
|
80
|
-
var l;
|
|
81
|
-
const a = (l = n.topBtns) == null ? void 0 : l.find((w) => w.key === e);
|
|
82
|
-
a && (a.hidden = t);
|
|
83
|
-
}, re = (e, t) => {
|
|
84
|
-
var l;
|
|
85
|
-
const a = (l = n.rowBtns) == null ? void 0 : l.find((w) => w.key === e);
|
|
86
|
-
a && (a.condition = !t);
|
|
87
|
-
}, L = v(0), se = (e) => {
|
|
88
|
-
L.value = e;
|
|
89
|
-
}, r = v({ pageNum: 1, pageSize: n.defaultPageSize || 5 }), ue = () => r.value, ce = (e) => {
|
|
90
|
-
let t = !1;
|
|
91
|
-
return e.pageNum !== void 0 && e.pageNum > -1 && (r.value.pageNum !== e.pageNum && (t = !0), r.value.pageNum = e.pageNum), e.pageSize !== void 0 && e.pageSize > -1 && (r.value.pageSize !== e.pageSize && (t = !0), r.value.pageSize = e.pageSize), { pagination: r.value, isChange: t };
|
|
92
|
-
}, de = async (e) => {
|
|
93
|
-
if (r.value.pageNum = 1, r.value.pageSize = e, !n.sizeChange)
|
|
94
|
-
return;
|
|
95
|
-
const t = W.service({
|
|
96
|
-
target: `#${n.name}`,
|
|
97
|
-
text: "Loading..."
|
|
98
|
-
});
|
|
99
|
-
try {
|
|
100
|
-
await c.value[n.sizeChange](d, r.value);
|
|
101
|
-
} catch (a) {
|
|
102
|
-
console.error(a);
|
|
103
|
-
} finally {
|
|
104
|
-
t.close();
|
|
105
|
-
}
|
|
106
|
-
}, pe = async (e) => {
|
|
107
|
-
if (r.value.pageNum = e, !n.pageChange)
|
|
108
|
-
return;
|
|
109
|
-
const t = W.service({
|
|
110
|
-
target: `#${n.name}`,
|
|
111
|
-
text: "Loading..."
|
|
112
|
-
});
|
|
113
|
-
try {
|
|
114
|
-
await c.value[n.pageChange](d, r.value);
|
|
115
|
-
} catch (a) {
|
|
116
|
-
console.error(a);
|
|
117
|
-
} finally {
|
|
118
|
-
t.close();
|
|
119
|
-
}
|
|
120
|
-
}, ge = (e) => {
|
|
121
|
-
var t;
|
|
122
|
-
(t = y.value) == null || t.setCurrentRow(e);
|
|
123
|
-
}, he = (e) => {
|
|
124
|
-
var t;
|
|
125
|
-
(t = y.value) == null || t.setCurrentRow(i.value[e]);
|
|
126
|
-
}, ve = (e, t, a) => {
|
|
127
|
-
n.columns.forEach((l) => {
|
|
128
|
-
l.key === e && l[t] && (l[t] = a);
|
|
129
|
-
});
|
|
130
|
-
}, i = v([]), fe = (e) => {
|
|
131
|
-
i.value = e;
|
|
132
|
-
}, me = (e = {}) => {
|
|
133
|
-
i.value.push(e);
|
|
134
|
-
}, ye = (e) => {
|
|
135
|
-
e >= 0 && e < i.value.length && i.value.splice(e, 1);
|
|
136
|
-
}, Ce = async () => {
|
|
137
|
-
i.value = [...i.value];
|
|
138
|
-
}, V = ze("rootRef"), U = Be({
|
|
139
|
-
...Re(n),
|
|
140
|
-
setCellData: O,
|
|
141
|
-
clearSelection: ee,
|
|
142
|
-
getData: te,
|
|
143
|
-
getCurrentRow: ae,
|
|
144
|
-
getSelectedRows: oe,
|
|
145
|
-
addRow: me,
|
|
146
|
-
deleteRow: ye,
|
|
147
|
-
refresh: Ce,
|
|
148
|
-
validate: le,
|
|
149
|
-
setData: fe,
|
|
150
|
-
selectRow: ge,
|
|
151
|
-
selectRowNum: he,
|
|
152
|
-
setTotal: se,
|
|
153
|
-
getPagination: ue,
|
|
154
|
-
setPagination: ce,
|
|
155
|
-
setTopBtnHidden: ie,
|
|
156
|
-
setColVisible: Q,
|
|
157
|
-
setColumn: ve,
|
|
158
|
-
setRowsBtnHidden: re,
|
|
159
|
-
rootRef: V,
|
|
160
|
-
type: "table"
|
|
161
|
-
}), C = (e, t) => {
|
|
162
|
-
const a = F ? F(e.key, t) : t[e.key];
|
|
163
|
-
if (!e.encrypted || !a)
|
|
164
|
-
return a;
|
|
165
|
-
const l = `${a}`;
|
|
166
|
-
return l.length <= 4 ? "*".repeat(l.length) : l.slice(0, -4) + "****";
|
|
167
|
-
}, we = _(() => !n.rowBtns || n.rowBtns.length === 0 || !i.value || i.value.length === 0 ? !1 : i.value.some(
|
|
168
|
-
(e) => {
|
|
169
|
-
var t;
|
|
170
|
-
return (t = n.rowBtns) == null ? void 0 : t.some((a) => a.condition === void 0 || a.condition === null ? !0 : K(a.condition, {
|
|
171
|
-
$row: e,
|
|
172
|
-
$globalParams: D()
|
|
173
|
-
}));
|
|
174
|
-
}
|
|
175
|
-
));
|
|
176
|
-
if (Pe(async () => {
|
|
177
|
-
if (!n.onMounted || !c.value)
|
|
178
|
-
return;
|
|
179
|
-
await _e();
|
|
180
|
-
const e = n.onMounted;
|
|
181
|
-
try {
|
|
182
|
-
c.value[e](d);
|
|
183
|
-
} catch (t) {
|
|
184
|
-
console.error(t);
|
|
185
|
-
}
|
|
186
|
-
}), Ne(() => {
|
|
187
|
-
if (!n.onActivated || !c.value)
|
|
188
|
-
return;
|
|
189
|
-
const e = n.onActivated;
|
|
190
|
-
try {
|
|
191
|
-
c.value[e](d);
|
|
192
|
-
} catch (t) {
|
|
193
|
-
console.error(t);
|
|
194
|
-
}
|
|
195
|
-
}), n.name) {
|
|
196
|
-
const e = Fe(n.name, U);
|
|
197
|
-
Me(() => {
|
|
198
|
-
e();
|
|
199
|
-
});
|
|
200
|
-
}
|
|
201
|
-
return I(U), (e, t) => {
|
|
202
|
-
const a = B("el-table-column"), l = B("el-tooltip"), w = B("el-button"), ke = B("el-pagination");
|
|
203
|
-
return e.hidden ? m("", !0) : (u(), g("div", {
|
|
204
|
-
key: 0,
|
|
205
|
-
class: N(["table-render", { tableBorder: z.value === "table" }]),
|
|
206
|
-
ref_key: "rootRef",
|
|
207
|
-
ref: V,
|
|
208
|
-
id: e.name
|
|
209
|
-
}, [
|
|
210
|
-
j(f("div", null, [
|
|
211
|
-
b(R(Ue), {
|
|
212
|
-
ref_key: "tableRef",
|
|
213
|
-
ref: y,
|
|
214
|
-
data: i.value,
|
|
215
|
-
"highlight-current-row": "",
|
|
216
|
-
"row-key": e.rowKey,
|
|
217
|
-
stripe: e.stripe,
|
|
218
|
-
"show-overflow-tooltip": "",
|
|
219
|
-
onRowClick: X,
|
|
220
|
-
onRowDblclick: Y,
|
|
221
|
-
onSelectionChange: x,
|
|
222
|
-
onCurrentChange: ne,
|
|
223
|
-
height: e.height
|
|
224
|
-
}, {
|
|
225
|
-
empty: h(() => [
|
|
226
|
-
f("div", Ge, [
|
|
227
|
-
b(R(Ee), {
|
|
228
|
-
name: "tableEmpty",
|
|
229
|
-
style: { width: 56, height: 56 }
|
|
230
|
-
}),
|
|
231
|
-
t[2] || (t[2] = f("div", null, "No data available,please check", -1))
|
|
232
|
-
])
|
|
233
|
-
]),
|
|
234
|
-
default: h(() => [
|
|
235
|
-
e.multipleSelection ? (u(), S(a, {
|
|
236
|
-
key: 0,
|
|
237
|
-
type: "selection",
|
|
238
|
-
width: "55"
|
|
239
|
-
})) : m("", !0),
|
|
240
|
-
(u(!0), g(P, null, G(e.columns, (o) => (u(), g(P, {
|
|
241
|
-
key: o.key
|
|
242
|
-
}, [
|
|
243
|
-
o.hidden ? m("", !0) : (u(), S(a, {
|
|
244
|
-
key: 0,
|
|
245
|
-
prop: o.key,
|
|
246
|
-
"min-width": o.minWidth,
|
|
247
|
-
fixed: o.fixed || !1
|
|
248
|
-
}, {
|
|
249
|
-
header: h(() => [
|
|
250
|
-
f("div", {
|
|
251
|
-
class: "text-ellipsis",
|
|
252
|
-
title: o.label
|
|
253
|
-
}, M(o.label), 9, He)
|
|
254
|
-
]),
|
|
255
|
-
default: h(({ row: p, $index: s }) => [
|
|
256
|
-
o.type === "link" ? (u(), g("div", {
|
|
257
|
-
key: 0,
|
|
258
|
-
class: N(["text-ellipsis link-style", { "click-style": o.onClick }]),
|
|
259
|
-
title: C(o, p),
|
|
260
|
-
onClick: (be) => E(o, p, s)
|
|
261
|
-
}, M(C(o, p)), 11, Ke)) : (u(), g("div", {
|
|
262
|
-
key: 1,
|
|
263
|
-
class: "text-ellipsis",
|
|
264
|
-
title: C(o, p)
|
|
265
|
-
}, M(C(o, p)), 9, We))
|
|
266
|
-
]),
|
|
267
|
-
_: 2
|
|
268
|
-
}, 1032, ["prop", "min-width", "fixed"]))
|
|
269
|
-
], 64))), 128)),
|
|
270
|
-
we.value && e.rowBtns && e.rowBtns.length > 0 ? (u(), S(a, {
|
|
271
|
-
key: 1,
|
|
272
|
-
label: "Action",
|
|
273
|
-
fixed: "right",
|
|
274
|
-
align: "left",
|
|
275
|
-
width: e.rowBtns.length * 34 + 12 > 100 ? e.rowBtns.length * 34 + 12 : 100
|
|
276
|
-
}, {
|
|
277
|
-
default: h(({ row: o, $index: p }) => [
|
|
278
|
-
f("div", qe, [
|
|
279
|
-
(u(!0), g(P, null, G(e.rowBtns, (s) => (u(), g(P, {
|
|
280
|
-
key: s.key
|
|
281
|
-
}, [
|
|
282
|
-
s.condition === void 0 || s.condition === null || R(K)(s.condition, { $row: o, $globalParams: R(D)() }) ? (u(), S(w, {
|
|
283
|
-
key: 0,
|
|
284
|
-
disabled: s.disabled,
|
|
285
|
-
link: "",
|
|
286
|
-
size: "small",
|
|
287
|
-
type: s.type,
|
|
288
|
-
onClick: Te((be) => E(s, o, p), ["stop"])
|
|
289
|
-
}, {
|
|
290
|
-
default: h(() => [
|
|
291
|
-
b(l, {
|
|
292
|
-
class: "box-item",
|
|
293
|
-
effect: "dark",
|
|
294
|
-
content: s.label,
|
|
295
|
-
placement: "top",
|
|
296
|
-
"popper-class": "low-tsp"
|
|
297
|
-
}, {
|
|
298
|
-
default: h(() => [
|
|
299
|
-
s.icon ? (u(), S(Ae, {
|
|
300
|
-
key: 0,
|
|
301
|
-
name: s.icon.name,
|
|
302
|
-
color: s.icon.color
|
|
303
|
-
}, null, 8, ["name", "color"])) : m("", !0)
|
|
304
|
-
]),
|
|
305
|
-
_: 2
|
|
306
|
-
}, 1032, ["content"])
|
|
307
|
-
]),
|
|
308
|
-
_: 2
|
|
309
|
-
}, 1032, ["disabled", "type", "onClick"])) : m("", !0)
|
|
310
|
-
], 64))), 128))
|
|
311
|
-
])
|
|
312
|
-
]),
|
|
313
|
-
_: 1
|
|
314
|
-
}, 8, ["width"])) : m("", !0)
|
|
315
|
-
]),
|
|
316
|
-
_: 1
|
|
317
|
-
}, 8, ["data", "row-key", "stripe", "height"])
|
|
318
|
-
], 512), [
|
|
319
|
-
[H, z.value === "table"]
|
|
320
|
-
]),
|
|
321
|
-
j(b(Le, De({ data: i.value }, n, { getColText: C }), null, 16, ["data"]), [
|
|
322
|
-
[H, z.value === "card"]
|
|
323
|
-
]),
|
|
324
|
-
f("div", {
|
|
325
|
-
class: N(["pagination-wrapper", {
|
|
326
|
-
hidePagination: (e.hiddenPagination || i.value.length === 0) && !e.height,
|
|
327
|
-
transparentPagination: (e.hiddenPagination || i.value.length === 0) && e.height,
|
|
328
|
-
cardlistPadding: z.value === "card"
|
|
329
|
-
}])
|
|
330
|
-
}, [
|
|
331
|
-
b(ke, {
|
|
332
|
-
layout: "total,sizes, prev, pager, next,jumper",
|
|
333
|
-
total: L.value,
|
|
334
|
-
"page-sizes": e.pageSizes || [5, 10, 20, 30, 40],
|
|
335
|
-
"default-page-size": e.defaultPageSize,
|
|
336
|
-
"current-page": r.value.pageNum,
|
|
337
|
-
"onUpdate:currentPage": t[0] || (t[0] = (o) => r.value.pageNum = o),
|
|
338
|
-
"page-size": r.value.pageSize,
|
|
339
|
-
"onUpdate:pageSize": t[1] || (t[1] = (o) => r.value.pageSize = o),
|
|
340
|
-
"pager-count": e.pagerCount,
|
|
341
|
-
onSizeChange: de,
|
|
342
|
-
onCurrentChange: pe
|
|
343
|
-
}, null, 8, ["total", "page-sizes", "default-page-size", "current-page", "page-size", "pager-count"])
|
|
344
|
-
], 2)
|
|
345
|
-
], 10, je));
|
|
346
|
-
};
|
|
347
|
-
}
|
|
348
|
-
}), Xe = /* @__PURE__ */ Ve(Ie, [["__scopeId", "data-v-2a908c73"]]);
|
|
349
|
-
export {
|
|
350
|
-
Xe as default
|
|
351
|
-
};
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { defineComponent as t, resolveComponent as n, openBlock as a, createElementBlock as r, normalizeStyle as s, createVNode as l, withCtx as p, withDirectives as i, createElementVNode as c, normalizeClass as m, unref as _, vShow as y } from "vue";
|
|
2
|
-
import { a as d, b as f } from "./index-CPs7U1jG.js";
|
|
3
|
-
import "element-plus";
|
|
4
|
-
const u = /* @__PURE__ */ t({
|
|
5
|
-
__name: "Wrapper",
|
|
6
|
-
props: {
|
|
7
|
-
children: {},
|
|
8
|
-
style: { type: [Boolean, null, String, Object, Array] },
|
|
9
|
-
type: {},
|
|
10
|
-
collapse: { type: Boolean }
|
|
11
|
-
},
|
|
12
|
-
setup(h) {
|
|
13
|
-
return (e, v) => {
|
|
14
|
-
const o = n("el-collapse-transition");
|
|
15
|
-
return a(), r("div", {
|
|
16
|
-
style: s(e.style)
|
|
17
|
-
}, [
|
|
18
|
-
l(o, null, {
|
|
19
|
-
default: p(() => [
|
|
20
|
-
i(c("div", {
|
|
21
|
-
class: m({ normal: e.type === "normal", onlytable: e.type === "onlytable" })
|
|
22
|
-
}, [
|
|
23
|
-
l(_(d), { list: e.children }, null, 8, ["list"])
|
|
24
|
-
], 2), [
|
|
25
|
-
[y, !e.collapse]
|
|
26
|
-
])
|
|
27
|
-
]),
|
|
28
|
-
_: 1
|
|
29
|
-
})
|
|
30
|
-
], 4);
|
|
31
|
-
};
|
|
32
|
-
}
|
|
33
|
-
}), w = /* @__PURE__ */ f(u, [["__scopeId", "data-v-aa5669f3"]]);
|
|
34
|
-
export {
|
|
35
|
-
w as default
|
|
36
|
-
};
|