act-plus 1.1.7 → 1.1.9
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/act-plus.js +3 -3
- package/act-plus.umd.cjs +35 -29
- package/lib/{configBtns-3e0e1684.js → configBtns-a9232bff.js} +9 -9
- package/lib/{configFileds-c1d4ce56.js → configFileds-7fd1c760.js} +2 -2
- package/lib/{configTable-e9118be0.js → configTable-e9e10aff.js} +122 -87
- package/lib/{dashboardTest-ff000df5.js → dashboardTest-b3195aa2.js} +2 -2
- package/lib/{dialogAddField-d3143ae7.js → dialogAddField-d3fc005c.js} +27 -27
- package/lib/{dialogConfigBtn-deb51609.js → dialogConfigBtn-3f0f2a3a.js} +2 -2
- package/lib/index-4476192c.js +285 -0
- package/lib/index-7ef6e17e.js +12797 -0
- package/lib/{index-efdc0568.js → index-9e5c202e.js} +1 -1
- package/lib/index-a02a1e59.js +164 -0
- package/lib/index-b631c218.js +95 -0
- package/lib/{index-c44f99dd.js → index-dc6223c1.js} +36 -36
- package/package.json +1 -1
- package/style.css +1 -1
- package/lib/enum-d971526b.js +0 -18
- package/lib/index-1c82879a.js +0 -95
- package/lib/index-4ecc8bcf.js +0 -162
- package/lib/index-89b17cda.js +0 -11678
- package/lib/index-b53782e5.js +0 -286
package/lib/index-1c82879a.js
DELETED
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { ref, inject, watch, resolveComponent, openBlock, createElementBlock, Fragment, renderList, unref, createBlock, resolveDynamicComponent, withCtx, createVNode, createCommentVNode, createTextVNode, toDisplayString } from "vue";
|
|
2
|
-
import { _ as _export_sfc } from "./index-89b17cda.js";
|
|
3
|
-
import "vue-router";
|
|
4
|
-
const index_vue_vue_type_style_index_0_scoped_efdfad22_lang = "", _hoisted_1 = { class: "header-operate-container" }, _sfc_main = {
|
|
5
|
-
__name: "index",
|
|
6
|
-
props: {
|
|
7
|
-
data: { type: Object, default: () => ({}) }
|
|
8
|
-
},
|
|
9
|
-
emits: ["operate"],
|
|
10
|
-
setup(__props, { emit: __emit }) {
|
|
11
|
-
const emits = __emit, props = __props;
|
|
12
|
-
let queryButtons = ref([]);
|
|
13
|
-
const globalProps = inject("globalProps"), menuPermissionBtns = inject("menuPermissionBtns"), stringToBoolean = inject("stringToBoolean"), matchCondition = inject("matchCondition"), getTableData = inject("getTableData"), tableBtnRefs = inject("tableBtnRefs"), constructConditionArray = (dataItem) => {
|
|
14
|
-
if (!dataItem.matchFields.length)
|
|
15
|
-
return !0;
|
|
16
|
-
const matchFields = dataItem.matchFields.filter((t) => t.matchType != "default"), getMatchFileds = (t) => globalProps.matchData[t.matchType][t.matchFieldName];
|
|
17
|
-
let newStr = matchFields.reduce((t, n, o) => {
|
|
18
|
-
const r = getMatchFileds(n);
|
|
19
|
-
return t += matchCondition(n.matchCondition, r, n.fieldValue == "" ? null : n.fieldValue == "true" ? stringToBoolean(n.fieldValue) : n.fieldValue), o !== matchFields.length - 1 && (t += n.spliceCondition || "&&"), t;
|
|
20
|
-
}, ""), newSplitArray = newStr.split("||"), newSplitStr = newSplitArray.reduce((t, n, o) => (t += `(${n})`, o < newSplitArray.length - 1 && (t += "||"), t), "");
|
|
21
|
-
return eval(newSplitStr);
|
|
22
|
-
}, verTableBtn = (t) => menuPermissionBtns.value.some((n) => n.unique == t.permissionCode) && constructConditionArray(t), disposeHeaderButtons = (t) => {
|
|
23
|
-
queryButtons.value = (t || []).filter((n) => n.permissionCode !== 1001 && n.btnPostion.includes("header")).sort((n, o) => n.sort - o.sort);
|
|
24
|
-
};
|
|
25
|
-
watch(
|
|
26
|
-
() => props.data,
|
|
27
|
-
(t, n) => {
|
|
28
|
-
disposeHeaderButtons(t.buttons);
|
|
29
|
-
},
|
|
30
|
-
{ immediate: !0 }
|
|
31
|
-
);
|
|
32
|
-
const onOperate = (t) => {
|
|
33
|
-
emits("operate", t, {});
|
|
34
|
-
};
|
|
35
|
-
return (t, n) => {
|
|
36
|
-
const o = resolveComponent("a-svg-icon"), r = resolveComponent("el-button");
|
|
37
|
-
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
38
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(unref(queryButtons), (e, s) => (openBlock(), createElementBlock(Fragment, { key: s }, [
|
|
39
|
-
e.isCustomBtn && e.customType == "component" && verTableBtn(e) ? (openBlock(), createBlock(resolveDynamicComponent(e[e.customComponentName]), {
|
|
40
|
-
key: 0,
|
|
41
|
-
ref_for: !0,
|
|
42
|
-
ref: (a) => unref(tableBtnRefs)[`${e.customComponentName}-${e.permissionCode}`] = a,
|
|
43
|
-
buttonData: e,
|
|
44
|
-
onRefresh: n[0] || (n[0] = (a) => unref(getTableData)())
|
|
45
|
-
}, {
|
|
46
|
-
default: withCtx(() => [
|
|
47
|
-
createVNode(r, {
|
|
48
|
-
class: "el-btn",
|
|
49
|
-
type: e.btnColor,
|
|
50
|
-
onClick: (a) => onOperate(e)
|
|
51
|
-
}, {
|
|
52
|
-
default: withCtx(() => [
|
|
53
|
-
e.btnIcon ? (openBlock(), createBlock(o, {
|
|
54
|
-
key: 0,
|
|
55
|
-
class: "mr4",
|
|
56
|
-
name: e.btnIcon,
|
|
57
|
-
width: "12",
|
|
58
|
-
height: "12",
|
|
59
|
-
color: "#fff"
|
|
60
|
-
}, null, 8, ["name"])) : createCommentVNode("", !0),
|
|
61
|
-
createTextVNode(" " + toDisplayString(e.btnName), 1)
|
|
62
|
-
]),
|
|
63
|
-
_: 2
|
|
64
|
-
}, 1032, ["type", "onClick"])
|
|
65
|
-
]),
|
|
66
|
-
_: 2
|
|
67
|
-
}, 1064, ["buttonData"])) : createCommentVNode("", !0),
|
|
68
|
-
!e.isCustomBtn && verTableBtn(e) ? (openBlock(), createBlock(r, {
|
|
69
|
-
key: 1,
|
|
70
|
-
class: "el-btn",
|
|
71
|
-
type: e.btnColor,
|
|
72
|
-
loading: e.opeateLoading,
|
|
73
|
-
onClick: (a) => onOperate(e)
|
|
74
|
-
}, {
|
|
75
|
-
default: withCtx(() => [
|
|
76
|
-
e.btnIcon ? (openBlock(), createBlock(o, {
|
|
77
|
-
key: 0,
|
|
78
|
-
class: "mr4",
|
|
79
|
-
name: e.btnIcon,
|
|
80
|
-
width: "12",
|
|
81
|
-
height: "12",
|
|
82
|
-
color: "#fff"
|
|
83
|
-
}, null, 8, ["name"])) : createCommentVNode("", !0),
|
|
84
|
-
createTextVNode(" " + toDisplayString(e.opeateLoading ? e.btnName + "中..." : e.btnName), 1)
|
|
85
|
-
]),
|
|
86
|
-
_: 2
|
|
87
|
-
}, 1032, ["type", "loading", "onClick"])) : createCommentVNode("", !0)
|
|
88
|
-
], 64))), 128))
|
|
89
|
-
]);
|
|
90
|
-
};
|
|
91
|
-
}
|
|
92
|
-
}, index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-efdfad22"]]);
|
|
93
|
-
export {
|
|
94
|
-
index as default
|
|
95
|
-
};
|
package/lib/index-4ecc8bcf.js
DELETED
|
@@ -1,162 +0,0 @@
|
|
|
1
|
-
import { ref as T, watch as O, resolveComponent as u, openBlock as a, createElementBlock as p, unref as d, createBlock as o, withCtx as c, Fragment as i, renderList as f, createCommentVNode as y, createTextVNode as $, toDisplayString as L } from "vue";
|
|
2
|
-
import { P, T as U } from "./enum-d971526b.js";
|
|
3
|
-
import { _ as R } from "./index-89b17cda.js";
|
|
4
|
-
import "vue-router";
|
|
5
|
-
const A = { class: "search-module-container" }, D = {
|
|
6
|
-
__name: "index",
|
|
7
|
-
props: {
|
|
8
|
-
data: { type: Object, default: () => ({}) }
|
|
9
|
-
},
|
|
10
|
-
emits: ["reset", "search"],
|
|
11
|
-
setup(g, { emit: x }) {
|
|
12
|
-
const b = x, N = g;
|
|
13
|
-
let s = T([]), h = T([]);
|
|
14
|
-
const w = (n) => {
|
|
15
|
-
s.value = (n || []).filter((t) => t.useScenes.includes("tableSearch"));
|
|
16
|
-
}, I = (n) => {
|
|
17
|
-
const t = (n || []).filter((r) => r.permissionCode === 1001);
|
|
18
|
-
h.value = [...t, { btnName: "重置", permissionCode: "9999", btnColor: "info", btnIcon: "btn-reset" }];
|
|
19
|
-
};
|
|
20
|
-
O(
|
|
21
|
-
() => N.data,
|
|
22
|
-
(n, t) => {
|
|
23
|
-
w(n.fields), I(n.buttons);
|
|
24
|
-
},
|
|
25
|
-
{ immediate: !0 }
|
|
26
|
-
);
|
|
27
|
-
const _ = (n) => {
|
|
28
|
-
switch (n.permissionCode) {
|
|
29
|
-
case "9999":
|
|
30
|
-
s.value.forEach((r) => {
|
|
31
|
-
r.fieldType.includes("&") ? r.queryValue = [] : r.queryValue = void 0;
|
|
32
|
-
}), b("reset", []);
|
|
33
|
-
break;
|
|
34
|
-
default:
|
|
35
|
-
const t = s.value.filter((r) => !!r.queryValue);
|
|
36
|
-
b("search", t);
|
|
37
|
-
break;
|
|
38
|
-
}
|
|
39
|
-
};
|
|
40
|
-
return (n, t) => {
|
|
41
|
-
const r = u("el-input"), k = u("el-option"), v = u("el-select"), S = u("el-cascader"), C = u("el-date-picker"), q = u("el-form-item"), B = u("a-svg-icon"), E = u("el-button"), F = u("el-form");
|
|
42
|
-
return a(), p("div", A, [
|
|
43
|
-
d(s) && d(s).length ? (a(), o(F, {
|
|
44
|
-
key: 0,
|
|
45
|
-
class: "form-content",
|
|
46
|
-
ref: "elForm",
|
|
47
|
-
"label-suffix": ":",
|
|
48
|
-
"label-position": "right",
|
|
49
|
-
"label-width": "80px"
|
|
50
|
-
}, {
|
|
51
|
-
default: c(() => [
|
|
52
|
-
(a(!0), p(i, null, f(d(s), (e, m) => (a(), o(q, {
|
|
53
|
-
class: "search-form-item",
|
|
54
|
-
key: m,
|
|
55
|
-
label: e.fieldName
|
|
56
|
-
}, {
|
|
57
|
-
default: c(() => [
|
|
58
|
-
e.fieldType === "input" ? (a(), o(r, {
|
|
59
|
-
key: 0,
|
|
60
|
-
modelValue: e.queryValue,
|
|
61
|
-
"onUpdate:modelValue": (l) => e.queryValue = l,
|
|
62
|
-
placeholder: `请输入${e.fieldName}`,
|
|
63
|
-
clearable: ""
|
|
64
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder"])) : e.fieldType === "select" || e.fieldType === "switch" ? (a(), o(v, {
|
|
65
|
-
key: 1,
|
|
66
|
-
modelValue: e.queryValue,
|
|
67
|
-
"onUpdate:modelValue": (l) => e.queryValue = l,
|
|
68
|
-
placeholder: `请选择${e.fieldName}`,
|
|
69
|
-
clearable: "",
|
|
70
|
-
filterable: "",
|
|
71
|
-
onChange: t[0] || (t[0] = (l) => _({ permissionCode: 1001 }))
|
|
72
|
-
}, {
|
|
73
|
-
default: c(() => [
|
|
74
|
-
(a(!0), p(i, null, f(e.dataList, (l, V) => (a(), o(k, {
|
|
75
|
-
key: V,
|
|
76
|
-
label: l.key,
|
|
77
|
-
value: l.value
|
|
78
|
-
}, null, 8, ["label", "value"]))), 128))
|
|
79
|
-
]),
|
|
80
|
-
_: 2
|
|
81
|
-
}, 1032, ["modelValue", "onUpdate:modelValue", "placeholder"])) : e.fieldType === "multipleSelect" ? (a(), o(v, {
|
|
82
|
-
key: 2,
|
|
83
|
-
modelValue: e.queryValue,
|
|
84
|
-
"onUpdate:modelValue": (l) => e.queryValue = l,
|
|
85
|
-
placeholder: "请选择" + e.fieldName,
|
|
86
|
-
clearable: "",
|
|
87
|
-
filterable: "",
|
|
88
|
-
onChange: t[1] || (t[1] = (l) => _({ permissionCode: 1001 }))
|
|
89
|
-
}, {
|
|
90
|
-
default: c(() => [
|
|
91
|
-
(a(!0), p(i, null, f(e.dataList, (l, V) => (a(), o(k, {
|
|
92
|
-
key: V,
|
|
93
|
-
label: l.key,
|
|
94
|
-
value: l.value
|
|
95
|
-
}, null, 8, ["label", "value"]))), 128))
|
|
96
|
-
]),
|
|
97
|
-
_: 2
|
|
98
|
-
}, 1032, ["modelValue", "onUpdate:modelValue", "placeholder"])) : e.fieldType === "provinceCascade" ? (a(), o(S, {
|
|
99
|
-
key: 3,
|
|
100
|
-
modelValue: e.queryValue,
|
|
101
|
-
"onUpdate:modelValue": (l) => e.queryValue = l,
|
|
102
|
-
options: e.selectList,
|
|
103
|
-
props: { ...d(P), [e.fieldUiType]: !0 },
|
|
104
|
-
clearable: "",
|
|
105
|
-
filterable: "",
|
|
106
|
-
placeholder: "请选择" + e.fieldName
|
|
107
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "options", "props", "placeholder"])) : e.fieldType === "date" ? (a(), o(C, {
|
|
108
|
-
key: 4,
|
|
109
|
-
modelValue: e.queryValue,
|
|
110
|
-
"onUpdate:modelValue": (l) => e.queryValue = l,
|
|
111
|
-
type: e.fieldUiType,
|
|
112
|
-
placeholder: "请选择时间",
|
|
113
|
-
"value-format": d(U)[e.fieldUiType]
|
|
114
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "type", "value-format"])) : e.fieldType === "dateRange" ? (a(), o(C, {
|
|
115
|
-
key: 5,
|
|
116
|
-
modelValue: e.queryValue,
|
|
117
|
-
"onUpdate:modelValue": (l) => e.queryValue = l,
|
|
118
|
-
type: e.fieldUiType,
|
|
119
|
-
"start-placeholder": "开始时间",
|
|
120
|
-
"end-placeholder": "结束时间",
|
|
121
|
-
"value-format": d(U)[e.fieldUiType]
|
|
122
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "type", "value-format"])) : y("", !0)
|
|
123
|
-
]),
|
|
124
|
-
_: 2
|
|
125
|
-
}, 1032, ["label"]))), 128)),
|
|
126
|
-
d(s).length ? (a(), o(q, {
|
|
127
|
-
key: 0,
|
|
128
|
-
class: "search-form-btn",
|
|
129
|
-
"label-width": "0"
|
|
130
|
-
}, {
|
|
131
|
-
default: c(() => [
|
|
132
|
-
(a(!0), p(i, null, f(d(h), (e, m) => (a(), o(E, {
|
|
133
|
-
key: m,
|
|
134
|
-
type: e.btnColor,
|
|
135
|
-
onClick: (l) => _(e)
|
|
136
|
-
}, {
|
|
137
|
-
default: c(() => [
|
|
138
|
-
e.btnIcon ? (a(), o(B, {
|
|
139
|
-
key: 0,
|
|
140
|
-
class: "mr6",
|
|
141
|
-
name: e.btnIcon,
|
|
142
|
-
width: "12",
|
|
143
|
-
height: "12",
|
|
144
|
-
color: "#fff"
|
|
145
|
-
}, null, 8, ["name"])) : y("", !0),
|
|
146
|
-
$(" " + L(e.btnName), 1)
|
|
147
|
-
]),
|
|
148
|
-
_: 2
|
|
149
|
-
}, 1032, ["type", "onClick"]))), 128))
|
|
150
|
-
]),
|
|
151
|
-
_: 1
|
|
152
|
-
})) : y("", !0)
|
|
153
|
-
]),
|
|
154
|
-
_: 1
|
|
155
|
-
}, 512)) : y("", !0)
|
|
156
|
-
]);
|
|
157
|
-
};
|
|
158
|
-
}
|
|
159
|
-
}, G = /* @__PURE__ */ R(D, [["__scopeId", "data-v-26568f9a"]]);
|
|
160
|
-
export {
|
|
161
|
-
G as default
|
|
162
|
-
};
|