@vue-start/pro 0.5.36 → 0.5.38
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/CHANGELOG.md +13 -0
- package/dist/index.css +23 -2
- package/dist/index.d.ts +182 -12
- package/dist/index.es.js +1407 -1317
- package/dist/index.js +2 -2
- package/package.json +2 -2
package/dist/index.es.js
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { reduce as
|
|
3
|
-
import { filter as
|
|
4
|
-
import { map as
|
|
5
|
-
import { mergeStateToData as
|
|
6
|
-
import { useRequestProvide as
|
|
7
|
-
import { useDispatchStore as
|
|
8
|
-
import { parseQuery as
|
|
9
|
-
import { css as
|
|
10
|
-
import
|
|
11
|
-
const
|
|
1
|
+
import { defineComponent as w, provide as ve, inject as he, reactive as Ae, createVNode as i, Fragment as le, computed as O, h as Ce, isVNode as Ee, mergeProps as K, ref as z, createTextVNode as We, toRef as dn } from "vue";
|
|
2
|
+
import { reduce as ae, get as m, map as F, isString as ue, forEach as te, size as X, endsWith as Mt, set as ie, isArray as _, pick as H, add as fn, subtract as mn, isFunction as V, filter as Y, has as Xe, keys as W, isObject as Me, omit as $, some as ye, isNumber as _e, head as yn, split as vn, isEmpty as Tt, mergeWith as hn, startsWith as bn, mapKeys as gn, debounce as It, clone as Sn, isBoolean as Te, sortBy as Nt, every as Pn, join as Ye, findLast as pn, cloneDeep as Ot } from "lodash";
|
|
3
|
+
import { filter as Re, tap as Le, merge as Cn, Subject as En } from "rxjs";
|
|
4
|
+
import { map as Mn, tap as Tn } from "rxjs/operators";
|
|
5
|
+
import { mergeStateToData as In, mergeStateToData2 as Nn, useEffect as ce, findFirstValidMenu as On, setReactiveValue as At, restorePath as $t, isValidPath as wt, isPathHasParent as Kt, useUpdateKey as Dt, useRuleState as qe, convertCollection as Ft, useWatch as xt, useState as lt, signTableMerge as An, useResizeObserver as De, decimalFixed as $n, thousandDivision as wn, listToMap as Kn, treeToMap as Dn, getMenuTopNameMap as Fn, findTreeItem as it, strToJson as Rt, jsonToStr as xn, useSafeActivated as Rn } from "@vue-start/hooks";
|
|
6
|
+
import { useRequestProvide as $e, isDoneRequestActor as Lt, isFailedRequestActor as jt } from "@vue-start/request";
|
|
7
|
+
import { useDispatchStore as kt, useStore as Ut, useObservableRef as Ln, useStoreConn as jn, shallowEqual as kn, createStateUse as Un } from "@vue-start/store";
|
|
8
|
+
import { parseQuery as dt, stringifyQuery as Bn, useRouter as Qe, useRoute as Je } from "vue-router";
|
|
9
|
+
import { css as ft } from "@emotion/css";
|
|
10
|
+
import mt from "dayjs";
|
|
11
|
+
const qn = () => ({
|
|
12
12
|
elementMap: { type: Object },
|
|
13
13
|
formElementMap: { type: Object },
|
|
14
14
|
columns: { type: Array },
|
|
15
15
|
convertColumn: { type: Function },
|
|
16
16
|
columnState: { type: Object },
|
|
17
17
|
columnState2: { type: Object }
|
|
18
|
-
}),
|
|
18
|
+
}), be = qn(), Ue = (e, t, r) => {
|
|
19
19
|
let o = e;
|
|
20
|
-
return t && (o =
|
|
21
|
-
},
|
|
20
|
+
return t && (o = In(o, t, (a) => de(a))), r && (o = Nn(o, r, (a) => de(a))), o;
|
|
21
|
+
}, Vn = () => ({
|
|
22
22
|
elementMap: { type: Object },
|
|
23
23
|
formElementMap: { type: Object },
|
|
24
24
|
formExtraMap: { type: Object },
|
|
@@ -27,31 +27,31 @@ const Fn = () => ({
|
|
|
27
27
|
registerMetas: { type: Array },
|
|
28
28
|
convertRouter: { type: Function },
|
|
29
29
|
expressionMethods: { type: Object },
|
|
30
|
-
showMsg: { type:
|
|
31
|
-
showModal: { type:
|
|
32
|
-
showNotify: { type:
|
|
33
|
-
}),
|
|
34
|
-
const { showMsg: e } =
|
|
30
|
+
showMsg: { type: Function },
|
|
31
|
+
showModal: { type: Function },
|
|
32
|
+
showNotify: { type: Function }
|
|
33
|
+
}), Ze = Symbol("pro-config"), ne = () => he(Ze) || {}, ea = () => {
|
|
34
|
+
const { showMsg: e } = ne();
|
|
35
35
|
return (t) => e(t);
|
|
36
|
-
},
|
|
37
|
-
const { showModal: e } =
|
|
36
|
+
}, ta = () => {
|
|
37
|
+
const { showModal: e } = ne();
|
|
38
38
|
return (t) => e(t);
|
|
39
|
-
},
|
|
40
|
-
const { showNotify: e } =
|
|
39
|
+
}, na = () => {
|
|
40
|
+
const { showNotify: e } = ne();
|
|
41
41
|
return (t) => e(t);
|
|
42
|
-
},
|
|
42
|
+
}, ra = w({
|
|
43
43
|
props: {
|
|
44
|
-
...
|
|
44
|
+
...Vn()
|
|
45
45
|
},
|
|
46
46
|
setup: (e, { slots: t }) => {
|
|
47
|
-
const r =
|
|
48
|
-
|
|
49
|
-
const { dispatchRequest: n } =
|
|
50
|
-
const
|
|
51
|
-
if (!!
|
|
52
|
-
return n(
|
|
47
|
+
const r = ae(e.registerStores, (c, s) => ({ ...c, [s.key]: s }), {}), o = ae(e.registerActors, (c, s) => ({ ...c, [s.actor.name]: s }), {}), a = ae(e.registerMetas, (c, s) => ({ ...c, [s.actorName]: s }), {});
|
|
48
|
+
Wn(a, o);
|
|
49
|
+
const { dispatchRequest: n } = $e(), u = (c, s, d) => {
|
|
50
|
+
const y = m(o, c);
|
|
51
|
+
if (!!y)
|
|
52
|
+
return n(y.actor, s, d);
|
|
53
53
|
};
|
|
54
|
-
return
|
|
54
|
+
return ve(Ze, {
|
|
55
55
|
elementMap: e.elementMap,
|
|
56
56
|
formElementMap: e.formElementMap,
|
|
57
57
|
formExtraMap: e.formExtraMap,
|
|
@@ -68,14 +68,14 @@ const Fn = () => ({
|
|
|
68
68
|
return (c = t.default) == null ? void 0 : c.call(t);
|
|
69
69
|
};
|
|
70
70
|
}
|
|
71
|
-
}),
|
|
72
|
-
t.provide(
|
|
73
|
-
},
|
|
74
|
-
const { requestSubject$: o } =
|
|
75
|
-
|
|
71
|
+
}), aa = (e = {}) => (t) => {
|
|
72
|
+
t.provide(Ze, e);
|
|
73
|
+
}, Bt = (e) => (t, r) => {
|
|
74
|
+
const { requestSubject$: o } = $e(), a = new Set(F(t, (n) => ue(n) ? n : n.name));
|
|
75
|
+
ce(() => {
|
|
76
76
|
const n = o.pipe(
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
Re(e),
|
|
78
|
+
Le((u) => {
|
|
79
79
|
a.has(u.name) && r(u);
|
|
80
80
|
})
|
|
81
81
|
).subscribe();
|
|
@@ -83,37 +83,37 @@ const Fn = () => ({
|
|
|
83
83
|
n.unsubscribe();
|
|
84
84
|
};
|
|
85
85
|
}, []);
|
|
86
|
-
},
|
|
87
|
-
const { requestSubject$: o, dispatchRequest: a } =
|
|
88
|
-
|
|
89
|
-
const c =
|
|
86
|
+
}, oa = Bt(Lt), ua = Bt(jt), zn = (e, t, r) => {
|
|
87
|
+
const { requestSubject$: o, dispatchRequest: a } = $e(), n = new Set(F(e, (c) => ue(c) ? c : c.name)), u = {};
|
|
88
|
+
ce(() => {
|
|
89
|
+
const c = Cn(
|
|
90
90
|
o.pipe(
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
var
|
|
94
|
-
n.has(
|
|
91
|
+
Re(Lt),
|
|
92
|
+
Le((s) => {
|
|
93
|
+
var d, y;
|
|
94
|
+
n.has(s.name) && ((d = t.onSuccess) == null || d.call(t, s), (y = t.onFinish) == null || y.call(t, s), u[s.name] = void 0);
|
|
95
95
|
})
|
|
96
96
|
),
|
|
97
97
|
o.pipe(
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
var
|
|
101
|
-
n.has(
|
|
98
|
+
Re(jt),
|
|
99
|
+
Le((s) => {
|
|
100
|
+
var d, y;
|
|
101
|
+
n.has(s.name) && ((d = t.onFailed) == null || d.call(t, s), (y = t.onFinish) == null || y.call(t, s), u[s.name] = void 0);
|
|
102
102
|
})
|
|
103
103
|
)
|
|
104
104
|
).subscribe();
|
|
105
105
|
return () => {
|
|
106
|
-
c.unsubscribe(), r &&
|
|
107
|
-
|
|
106
|
+
c.unsubscribe(), r && te(u, (s) => {
|
|
107
|
+
s && a({ ...s, stage: "CANCEL" });
|
|
108
108
|
});
|
|
109
109
|
};
|
|
110
110
|
}, []);
|
|
111
|
-
},
|
|
111
|
+
}, Hn = (e, t, r) => {
|
|
112
112
|
var a;
|
|
113
113
|
const o = (a = e.res) == null ? void 0 : a.data;
|
|
114
114
|
return t ? t(o, e) : r ? m(o, r) : o;
|
|
115
|
-
},
|
|
116
|
-
const e =
|
|
115
|
+
}, ca = () => {
|
|
116
|
+
const e = Ut(), { registerMetaMap: t, dispatchRequest: r } = ne();
|
|
117
117
|
return (o) => {
|
|
118
118
|
const a = m(t, o);
|
|
119
119
|
if (!a)
|
|
@@ -121,27 +121,27 @@ const Fn = () => ({
|
|
|
121
121
|
const n = a.storeName || o;
|
|
122
122
|
m(e.value, n) || r(o, a.initParams || {});
|
|
123
123
|
};
|
|
124
|
-
},
|
|
125
|
-
const { requestSubject$: r } =
|
|
124
|
+
}, Wn = (e, t) => {
|
|
125
|
+
const { requestSubject$: r } = $e(), o = kt(), a = (n) => {
|
|
126
126
|
const u = m(e, n.name), c = m(t, n.name);
|
|
127
127
|
return !!(u && c && c.actor);
|
|
128
128
|
};
|
|
129
|
-
|
|
129
|
+
ce(() => {
|
|
130
130
|
const n = r.pipe(
|
|
131
|
-
|
|
132
|
-
|
|
131
|
+
Re(a),
|
|
132
|
+
Le((u) => {
|
|
133
133
|
const c = m(e, u.name);
|
|
134
134
|
if (!c)
|
|
135
135
|
return;
|
|
136
|
-
const
|
|
137
|
-
o(
|
|
136
|
+
const s = c.storeName || u.name, d = Hn(u, c.convertData, c.convertPath);
|
|
137
|
+
o(s, d, !1, void 0);
|
|
138
138
|
})
|
|
139
139
|
).subscribe();
|
|
140
140
|
return () => {
|
|
141
141
|
n.unsubscribe();
|
|
142
142
|
};
|
|
143
143
|
}, []);
|
|
144
|
-
},
|
|
144
|
+
}, Gn = {
|
|
145
145
|
open: (e, t, r) => window.open(e, t, r),
|
|
146
146
|
parseStr: (e) => {
|
|
147
147
|
var n;
|
|
@@ -153,7 +153,7 @@ const Fn = () => ({
|
|
|
153
153
|
protocol: u.protocol,
|
|
154
154
|
path: u.pathname,
|
|
155
155
|
origin: u.origin,
|
|
156
|
-
query:
|
|
156
|
+
query: dt(u.search),
|
|
157
157
|
url: u.origin + u.pathname
|
|
158
158
|
};
|
|
159
159
|
} catch {
|
|
@@ -161,18 +161,18 @@ const Fn = () => ({
|
|
|
161
161
|
const t = e.indexOf("//") > -1 ? (n = e.split("//")) == null ? void 0 : n[0] : "";
|
|
162
162
|
let r = "", o = "";
|
|
163
163
|
e.indexOf("?") >= -1 && (r = e.substring(0, e.indexOf("?")), o = e.substring(e.indexOf("?")));
|
|
164
|
-
const a = o ?
|
|
164
|
+
const a = o ? dt(o) : {};
|
|
165
165
|
return { protocol: t, query: a, url: r };
|
|
166
166
|
},
|
|
167
167
|
stringifyUrl: ({ url: e, query: t }) => {
|
|
168
|
-
const r =
|
|
168
|
+
const r = Bn(t);
|
|
169
169
|
return `${e}${r ? "?" : ""}${r || ""}`;
|
|
170
170
|
}
|
|
171
|
-
},
|
|
172
|
-
const { convertRouter: e } =
|
|
171
|
+
}, qt = () => {
|
|
172
|
+
const { convertRouter: e } = ne(), t = Qe(), r = Je(), a = { ...t, openMenu: (u) => {
|
|
173
173
|
if (!!u) {
|
|
174
174
|
if (X(u.children) > 0) {
|
|
175
|
-
const c =
|
|
175
|
+
const c = On(u.children, (s) => !s.children || X(s.children) <= 0);
|
|
176
176
|
if (c) {
|
|
177
177
|
t.push({ name: c.value });
|
|
178
178
|
return;
|
|
@@ -180,56 +180,56 @@ const Fn = () => ({
|
|
|
180
180
|
}
|
|
181
181
|
t.push({ name: u.value });
|
|
182
182
|
}
|
|
183
|
-
}, ...
|
|
183
|
+
}, ...Gn };
|
|
184
184
|
return { router: e ? e(a) : a, route: r };
|
|
185
|
-
},
|
|
185
|
+
}, Xn = (e) => {
|
|
186
186
|
if (!_(e) || X(e) <= 0)
|
|
187
187
|
return !1;
|
|
188
188
|
const t = e[0];
|
|
189
|
-
return
|
|
190
|
-
},
|
|
191
|
-
if (
|
|
189
|
+
return ue(t) ? Mt(t, "$") : !1;
|
|
190
|
+
}, _n = (e) => typeof e != "object" || !e.type$ ? !1 : e.type$ === "data$" && e.type$, Yn = (e) => typeof e != "object" || !e.type$ ? !1 : e.type$ === "obj", Qn = { get: m, pick: H, add: fn, subtract: mn }, je = (e, t) => {
|
|
191
|
+
if (_n(e)) {
|
|
192
192
|
const r = m(t, e.name$);
|
|
193
193
|
return e.namePath$ ? m(r, e.namePath$) : r;
|
|
194
|
-
} else if (
|
|
194
|
+
} else if (Yn(e)) {
|
|
195
195
|
const r = {};
|
|
196
|
-
return
|
|
196
|
+
return te(e, (o, a) => {
|
|
197
197
|
if (a !== "type$")
|
|
198
|
-
if (
|
|
199
|
-
const n =
|
|
200
|
-
|
|
198
|
+
if (Mt(a, "$")) {
|
|
199
|
+
const n = je(o, t);
|
|
200
|
+
ie(r, a.replace("$", ""), n);
|
|
201
201
|
} else
|
|
202
202
|
r[a] = o;
|
|
203
203
|
}), r;
|
|
204
|
-
} else if (
|
|
205
|
-
const [r, ...o] = e, a = t.expressionMethods ||
|
|
204
|
+
} else if (Xn(e)) {
|
|
205
|
+
const [r, ...o] = e, a = t.expressionMethods || Qn, n = m(a, r.replace("$", ""));
|
|
206
206
|
if (!n) {
|
|
207
207
|
console.log("ex", "\u672A\u627E\u5230\u5BF9\u5E94\u7684\u65B9\u6CD5", e);
|
|
208
208
|
return;
|
|
209
209
|
}
|
|
210
|
-
const u = F(o, (c) =>
|
|
210
|
+
const u = F(o, (c) => je(c, t));
|
|
211
211
|
return n(...u);
|
|
212
212
|
}
|
|
213
213
|
return e;
|
|
214
|
-
},
|
|
215
|
-
const e =
|
|
214
|
+
}, Jn = () => {
|
|
215
|
+
const e = kt(), { registerStoreMap: t } = ne();
|
|
216
216
|
return (r, o) => {
|
|
217
217
|
const a = m(t, r);
|
|
218
218
|
!a || e(r, o, !!a.persist, a.initialState);
|
|
219
219
|
};
|
|
220
|
-
},
|
|
221
|
-
const { registerStoreMap: t } =
|
|
222
|
-
return
|
|
220
|
+
}, sa = (e) => {
|
|
221
|
+
const { registerStoreMap: t } = ne(), r = m(t, e), o = `${r != null && r.persist ? "$" : ""}${r == null ? void 0 : r.key}`;
|
|
222
|
+
return Ln(jn((n) => {
|
|
223
223
|
const u = m(n, o);
|
|
224
|
-
return u || (
|
|
224
|
+
return u || (V(r == null ? void 0 : r.initialState) ? r == null ? void 0 : r.initialState() : r == null ? void 0 : r.initialState);
|
|
225
225
|
}));
|
|
226
|
-
},
|
|
227
|
-
|
|
228
|
-
},
|
|
226
|
+
}, Vt = Symbol("pro-module"), ge = () => he(Vt), Zn = (e) => {
|
|
227
|
+
ve(Vt, e);
|
|
228
|
+
}, et = (e) => {
|
|
229
229
|
const {
|
|
230
230
|
subject$: t
|
|
231
|
-
} =
|
|
232
|
-
|
|
231
|
+
} = ge();
|
|
232
|
+
ce(() => {
|
|
233
233
|
const r = t.subscribe({
|
|
234
234
|
next: (o) => {
|
|
235
235
|
e(o);
|
|
@@ -237,10 +237,10 @@ const Fn = () => ({
|
|
|
237
237
|
});
|
|
238
238
|
return () => r.unsubscribe();
|
|
239
239
|
}, []);
|
|
240
|
-
},
|
|
240
|
+
}, Ie = {
|
|
241
241
|
Success: "request-success$",
|
|
242
242
|
Fail: "request-fail$"
|
|
243
|
-
},
|
|
243
|
+
}, er = () => ({
|
|
244
244
|
state: {
|
|
245
245
|
type: Object
|
|
246
246
|
},
|
|
@@ -265,186 +265,189 @@ const Fn = () => ({
|
|
|
265
265
|
requests: {
|
|
266
266
|
type: Array
|
|
267
267
|
}
|
|
268
|
-
}),
|
|
268
|
+
}), Fe = w({
|
|
269
269
|
props: {
|
|
270
|
-
...
|
|
270
|
+
...er()
|
|
271
271
|
},
|
|
272
272
|
setup: (e, {
|
|
273
273
|
slots: t,
|
|
274
274
|
expose: r
|
|
275
275
|
}) => {
|
|
276
|
-
const o =
|
|
276
|
+
const o = Ut(), {
|
|
277
277
|
router: a
|
|
278
|
-
} =
|
|
278
|
+
} = qt(), {
|
|
279
279
|
elementMap: n,
|
|
280
280
|
registerStoreMap: u,
|
|
281
281
|
expressionMethods: c
|
|
282
|
-
} =
|
|
283
|
-
|
|
284
|
-
}, f = Y(e.storeKeys, (
|
|
285
|
-
const
|
|
282
|
+
} = ne(), s = e.elementMap || n, d = (b) => _(b) ? nt(s, b) : Ne(s, b), y = new En(), h = (b) => {
|
|
283
|
+
y.next(b);
|
|
284
|
+
}, f = Y(e.storeKeys, (b) => Xe(u, b)), S = () => ae(f, (b, P) => {
|
|
285
|
+
const C = m(u, P);
|
|
286
286
|
return {
|
|
287
|
-
...
|
|
288
|
-
[
|
|
287
|
+
...b,
|
|
288
|
+
[P]: m(o.value, `${C.persist ? "$" : ""}${P}`) || m(u, [P, "initialState"])
|
|
289
289
|
};
|
|
290
|
-
}, {}),
|
|
291
|
-
...
|
|
290
|
+
}, {}), p = S(), v = e.state || Ae({
|
|
291
|
+
...p,
|
|
292
292
|
...e.initState
|
|
293
|
-
}), T = {},
|
|
294
|
-
const
|
|
295
|
-
if (
|
|
296
|
-
|
|
293
|
+
}), T = {}, N = (b) => {
|
|
294
|
+
const P = v[b.type], C = V(b.payload) ? b.payload(P) : b.payload;
|
|
295
|
+
if (Me(P)) {
|
|
296
|
+
At(v[b.type], C);
|
|
297
297
|
return;
|
|
298
298
|
}
|
|
299
|
-
|
|
300
|
-
},
|
|
301
|
-
dispatch:
|
|
302
|
-
dispatchStore:
|
|
299
|
+
v[b.type] = C;
|
|
300
|
+
}, l = Jn(), g = {
|
|
301
|
+
dispatch: N,
|
|
302
|
+
dispatchStore: l
|
|
303
303
|
};
|
|
304
|
-
|
|
305
|
-
const
|
|
306
|
-
|
|
307
|
-
const
|
|
308
|
-
|
|
304
|
+
ce(() => {
|
|
305
|
+
const b = o.pipe(Mn(() => S()), Tn((P) => {
|
|
306
|
+
te(P, (C, L) => {
|
|
307
|
+
const Z = m(v, L);
|
|
308
|
+
kn(Z, C) || N({
|
|
309
309
|
type: L,
|
|
310
|
-
payload:
|
|
310
|
+
payload: C
|
|
311
311
|
});
|
|
312
312
|
});
|
|
313
313
|
})).subscribe();
|
|
314
314
|
return () => {
|
|
315
|
-
|
|
315
|
+
b.unsubscribe();
|
|
316
316
|
};
|
|
317
317
|
}, []);
|
|
318
318
|
const {
|
|
319
|
-
dispatchRequest:
|
|
320
|
-
} =
|
|
321
|
-
const
|
|
322
|
-
...
|
|
319
|
+
dispatchRequest: E
|
|
320
|
+
} = $e(), M = (() => {
|
|
321
|
+
const b = {}, P = ae(e.actors || [], (C, L) => ({
|
|
322
|
+
...C,
|
|
323
323
|
[L.name]: L
|
|
324
324
|
}), {});
|
|
325
|
-
return
|
|
326
|
-
if (
|
|
327
|
-
const L = m(
|
|
325
|
+
return te(e.requests, (C) => {
|
|
326
|
+
if (ue(C.actor)) {
|
|
327
|
+
const L = m(P, C.actor);
|
|
328
328
|
if (!L)
|
|
329
329
|
return;
|
|
330
|
-
|
|
330
|
+
C.actor = L;
|
|
331
331
|
}
|
|
332
|
-
!
|
|
333
|
-
}),
|
|
334
|
-
})(),
|
|
335
|
-
var
|
|
336
|
-
return
|
|
337
|
-
},
|
|
338
|
-
const
|
|
339
|
-
if (!
|
|
332
|
+
!C.actor || (b[C.actor.name] = C, C.action && (b[C.action] = C));
|
|
333
|
+
}), b;
|
|
334
|
+
})(), R = (b, ...P) => b.convertParams ? b.convertParams(...P) : b.convertParamsEx ? G(b.convertParamsEx, P) : m(P, 0), j = (b, P) => {
|
|
335
|
+
var C;
|
|
336
|
+
return b.convertData ? b.convertData(P) : b.convertDataEx ? G(b.convertDataEx, P) : (C = P.res) == null ? void 0 : C.data;
|
|
337
|
+
}, q = (b, ...P) => {
|
|
338
|
+
const C = m(M, b);
|
|
339
|
+
if (!C)
|
|
340
340
|
return;
|
|
341
|
-
const L =
|
|
342
|
-
|
|
343
|
-
type:
|
|
341
|
+
const L = R(C, ...P);
|
|
342
|
+
C.loadingName && N({
|
|
343
|
+
type: C.loadingName,
|
|
344
344
|
payload: !0
|
|
345
|
-
}), C
|
|
345
|
+
}), E(C.actor, L);
|
|
346
346
|
};
|
|
347
|
-
|
|
348
|
-
onSuccess: (
|
|
347
|
+
zn(W(M), {
|
|
348
|
+
onSuccess: (b) => {
|
|
349
349
|
var L;
|
|
350
|
-
const
|
|
351
|
-
|
|
352
|
-
type:
|
|
353
|
-
payload:
|
|
350
|
+
const P = m(M, b.name), C = j(P, b);
|
|
351
|
+
P != null && P.stateName && N({
|
|
352
|
+
type: P.stateName,
|
|
353
|
+
payload: C
|
|
354
354
|
}), h({
|
|
355
|
-
type:
|
|
355
|
+
type: Ie.Success,
|
|
356
356
|
payload: {
|
|
357
|
-
actor:
|
|
358
|
-
requestOpts:
|
|
357
|
+
actor: b,
|
|
358
|
+
requestOpts: P
|
|
359
359
|
}
|
|
360
|
-
}), (L =
|
|
360
|
+
}), (L = P.onSuccess) == null || L.call(P, b), P.onSuccessEx && J(P.onSuccessEx, [C]);
|
|
361
361
|
},
|
|
362
|
-
onFailed: (
|
|
363
|
-
var
|
|
364
|
-
const
|
|
362
|
+
onFailed: (b) => {
|
|
363
|
+
var C;
|
|
364
|
+
const P = m(M, b.name);
|
|
365
365
|
h({
|
|
366
|
-
type:
|
|
366
|
+
type: Ie.Fail,
|
|
367
367
|
payload: {
|
|
368
|
-
actor:
|
|
369
|
-
requestOpts:
|
|
368
|
+
actor: b,
|
|
369
|
+
requestOpts: P
|
|
370
370
|
}
|
|
371
|
-
}), (
|
|
371
|
+
}), (C = P.onFailed) == null || C.call(P, b), P.onFailedEx && J(P.onFailedEx, [b.err]);
|
|
372
372
|
},
|
|
373
|
-
onFinish: (
|
|
374
|
-
const
|
|
375
|
-
|
|
376
|
-
type:
|
|
373
|
+
onFinish: (b) => {
|
|
374
|
+
const P = m(M, [b.name, "loadingName"]);
|
|
375
|
+
P && N({
|
|
376
|
+
type: P,
|
|
377
377
|
payload: !1
|
|
378
378
|
});
|
|
379
379
|
}
|
|
380
380
|
}, !0);
|
|
381
|
-
const
|
|
382
|
-
state:
|
|
381
|
+
const G = (b, P) => je(b, {
|
|
382
|
+
state: v,
|
|
383
383
|
data: T,
|
|
384
|
-
args:
|
|
384
|
+
args: P,
|
|
385
385
|
expressionMethods: c
|
|
386
|
-
}),
|
|
387
|
-
if (!
|
|
386
|
+
}), J = (b, P) => {
|
|
387
|
+
if (!b)
|
|
388
388
|
return;
|
|
389
|
-
const
|
|
390
|
-
state:
|
|
389
|
+
const C = {
|
|
390
|
+
state: v,
|
|
391
391
|
data: T,
|
|
392
|
-
args:
|
|
392
|
+
args: P,
|
|
393
393
|
expressionMethods: c
|
|
394
394
|
};
|
|
395
|
-
|
|
395
|
+
te(b, (L) => {
|
|
396
396
|
if (!_(L) || X(L) < 2) {
|
|
397
397
|
console.log("execute invalid", L);
|
|
398
398
|
return;
|
|
399
399
|
}
|
|
400
|
-
const [
|
|
401
|
-
let
|
|
402
|
-
switch (
|
|
400
|
+
const [Z, k, ...se] = L;
|
|
401
|
+
let A;
|
|
402
|
+
switch (Z) {
|
|
403
403
|
case "router":
|
|
404
|
-
|
|
404
|
+
A = m(a, k);
|
|
405
405
|
break;
|
|
406
406
|
case "state":
|
|
407
|
-
|
|
407
|
+
A = m(g, k);
|
|
408
408
|
break;
|
|
409
409
|
}
|
|
410
|
-
if (
|
|
410
|
+
if (A)
|
|
411
411
|
try {
|
|
412
|
-
const
|
|
413
|
-
|
|
414
|
-
} catch (
|
|
415
|
-
console.log("execute err",
|
|
412
|
+
const x = F(se, (ee) => je(ee, C));
|
|
413
|
+
A(...x);
|
|
414
|
+
} catch (x) {
|
|
415
|
+
console.log("execute err", x);
|
|
416
416
|
}
|
|
417
417
|
});
|
|
418
418
|
};
|
|
419
|
-
return
|
|
420
|
-
elementMap:
|
|
421
|
-
subject$:
|
|
419
|
+
return Zn({
|
|
420
|
+
elementMap: s,
|
|
421
|
+
subject$: y,
|
|
422
422
|
sendEvent: h,
|
|
423
|
-
state:
|
|
424
|
-
dispatch:
|
|
423
|
+
state: v,
|
|
424
|
+
dispatch: N,
|
|
425
425
|
data: T,
|
|
426
426
|
requests: e.requests,
|
|
427
|
-
sendRequest:
|
|
428
|
-
executeExp:
|
|
429
|
-
execute:
|
|
427
|
+
sendRequest: q,
|
|
428
|
+
executeExp: G,
|
|
429
|
+
execute: J
|
|
430
430
|
}), r({
|
|
431
431
|
sendEvent: h,
|
|
432
|
-
sendRequest:
|
|
432
|
+
sendRequest: q
|
|
433
433
|
}), () => {
|
|
434
|
-
var
|
|
435
|
-
return
|
|
434
|
+
var b;
|
|
435
|
+
return i(le, null, [X(e.elementConfigs) > 0 && d(e.elementConfigs), (b = t.default) == null ? void 0 : b.call(t)]);
|
|
436
436
|
};
|
|
437
437
|
}
|
|
438
|
-
}),
|
|
438
|
+
}), xe = (e) => {
|
|
439
|
+
var t, r;
|
|
440
|
+
return !(!e || ((r = (t = e == null ? void 0 : e[0]) == null ? void 0 : t.type) == null ? void 0 : r.toString()) === "Symbol(Comment)");
|
|
441
|
+
}, zt = (e) => e.formValueType || e.valueType || "text", de = (e) => {
|
|
439
442
|
var o, a;
|
|
440
443
|
const t = (o = e.formItemProps) == null ? void 0 : o.name;
|
|
441
444
|
return ((a = e.inputProps) == null ? void 0 : a.name) || t || e.dataIndex;
|
|
442
|
-
},
|
|
445
|
+
}, tr = (e, t) => {
|
|
443
446
|
let r = t;
|
|
444
|
-
return
|
|
445
|
-
},
|
|
446
|
-
var
|
|
447
|
-
const a =
|
|
447
|
+
return ue(t) && (r = m(e, t)), V(r) || (r = m(e, "render")), V(r) ? r : void 0;
|
|
448
|
+
}, tt = (e, t, r, o) => {
|
|
449
|
+
var y, h, f;
|
|
450
|
+
const a = tr(t, o == null ? void 0 : o.render);
|
|
448
451
|
if (a)
|
|
449
452
|
return a({
|
|
450
453
|
...r,
|
|
@@ -453,33 +456,33 @@ const Fn = () => ({
|
|
|
453
456
|
const n = t.valueType || "text", u = m(e, n);
|
|
454
457
|
if (!u)
|
|
455
458
|
return null;
|
|
456
|
-
const c = ((
|
|
457
|
-
u.props.showProps && (
|
|
458
|
-
const
|
|
459
|
+
const c = ((y = t.props) == null ? void 0 : y.slots) || ((h = t.formFieldProps) == null ? void 0 : h.slots) || {}, s = r || {};
|
|
460
|
+
u.props.showProps && (s.showProps = t.props ? (f = t.props) == null ? void 0 : f.showProps : t.showProps);
|
|
461
|
+
const d = t.props ? {
|
|
459
462
|
...$(t.props, "slots"),
|
|
460
|
-
...
|
|
463
|
+
...s
|
|
461
464
|
} : {
|
|
462
465
|
...$(t.formFieldProps, "slots"),
|
|
463
|
-
...
|
|
466
|
+
...s
|
|
464
467
|
};
|
|
465
|
-
return
|
|
466
|
-
...
|
|
468
|
+
return Ce(u, {
|
|
469
|
+
...d
|
|
467
470
|
}, c);
|
|
468
|
-
},
|
|
469
|
-
var
|
|
470
|
-
const o =
|
|
471
|
+
}, Ht = (e, t, r) => {
|
|
472
|
+
var y, h;
|
|
473
|
+
const o = zt(r), a = m(t, o);
|
|
471
474
|
if (!a)
|
|
472
475
|
return null;
|
|
473
|
-
const n = r.inputProps, u = ((
|
|
474
|
-
!u.renderInput &&
|
|
476
|
+
const n = r.inputProps, u = ((y = n == null ? void 0 : n.fieldProps) == null ? void 0 : y.slots) || ((h = r.formFieldProps) == null ? void 0 : h.slots) || {};
|
|
477
|
+
!u.renderInput && V(r.inputRender) && (u.renderInput = (f) => r.inputRender({
|
|
475
478
|
...f,
|
|
476
479
|
column: r
|
|
477
|
-
})), u.renderShow || (u.renderShow = (f) =>
|
|
480
|
+
})), u.renderShow || (u.renderShow = (f) => tt(e, r, {
|
|
478
481
|
value: f.value
|
|
479
482
|
}, {
|
|
480
483
|
render: "formReadRender"
|
|
481
484
|
}) || f.value);
|
|
482
|
-
const c =
|
|
485
|
+
const c = de(r), s = r.title, d = n ? {
|
|
483
486
|
...n,
|
|
484
487
|
fieldProps: $(n.fieldProps, "slots")
|
|
485
488
|
} : {
|
|
@@ -487,72 +490,72 @@ const Fn = () => ({
|
|
|
487
490
|
fieldProps: $(r.formFieldProps, "slots"),
|
|
488
491
|
showProps: r.showProps
|
|
489
492
|
};
|
|
490
|
-
return
|
|
493
|
+
return Ce(a, {
|
|
491
494
|
key: c,
|
|
492
495
|
name: c,
|
|
493
|
-
label:
|
|
494
|
-
...
|
|
496
|
+
label: s,
|
|
497
|
+
...d
|
|
495
498
|
}, u);
|
|
496
|
-
},
|
|
499
|
+
}, nr = (e) => e && !V(e) && e.elementType, nt = (e, t) => F(t, (r) => Ne(e, r)), Wt = (e, t) => {
|
|
497
500
|
var n;
|
|
498
501
|
const r = t.elementProps, o = {
|
|
499
502
|
...t.elementProps
|
|
500
503
|
}, a = r == null ? void 0 : r.class;
|
|
501
|
-
return a && (typeof a == "object" ? o.class =
|
|
504
|
+
return a && (typeof a == "object" ? o.class = ft(a) : ue(a) && a.indexOf(":") > 0 && (o.class = ft`
|
|
502
505
|
${a}
|
|
503
|
-
`)),
|
|
506
|
+
`)), te((n = t.highConfig$) == null ? void 0 : n.registerPropsTrans, (u) => {
|
|
504
507
|
const c = m(r, u.name);
|
|
505
|
-
if (!(!c ||
|
|
508
|
+
if (!(!c || Ee(c))) {
|
|
506
509
|
if (_(c)) {
|
|
507
|
-
if (
|
|
510
|
+
if (ye(c, (s) => Ee(s)))
|
|
508
511
|
return;
|
|
509
|
-
|
|
512
|
+
ie(o, u.name, nt(e, c));
|
|
510
513
|
return;
|
|
511
514
|
}
|
|
512
|
-
!c.elementType || (u.isFun ?
|
|
513
|
-
const
|
|
515
|
+
!c.elementType || (u.isFun ? ie(o, u.name, (...s) => {
|
|
516
|
+
const d = u.needParams ? {
|
|
514
517
|
...c.elementProps,
|
|
515
|
-
params$:
|
|
518
|
+
params$: s
|
|
516
519
|
} : c.elementProps;
|
|
517
|
-
return
|
|
520
|
+
return Ne(e, {
|
|
518
521
|
...c,
|
|
519
|
-
elementProps:
|
|
522
|
+
elementProps: d
|
|
520
523
|
});
|
|
521
|
-
}) :
|
|
524
|
+
}) : ie(o, u.name, Ne(e, c)));
|
|
522
525
|
}
|
|
523
526
|
}), o;
|
|
524
|
-
},
|
|
525
|
-
const r = X(t.children) > 0 ?
|
|
526
|
-
return
|
|
527
|
+
}, Gt = (e, t) => {
|
|
528
|
+
const r = X(t.children) > 0 ? nt(e, t.children) : void 0, o = t.childrenSlotName || "default", a = $(t.slots, r ? o : "");
|
|
529
|
+
return te(W(a), (n) => {
|
|
527
530
|
const u = a[n];
|
|
528
|
-
|
|
529
|
-
const
|
|
531
|
+
nr(u) ? a[n] = (...c) => {
|
|
532
|
+
const s = u.needParams ? {
|
|
530
533
|
...u.elementProps,
|
|
531
534
|
params$: c
|
|
532
535
|
} : u.elementProps;
|
|
533
|
-
return
|
|
536
|
+
return Ne(e, {
|
|
534
537
|
...u,
|
|
535
|
-
elementProps:
|
|
538
|
+
elementProps: s
|
|
536
539
|
});
|
|
537
|
-
} : (
|
|
540
|
+
} : (ue(u) || _e(u)) && (a[n] = () => u);
|
|
538
541
|
}), {
|
|
539
542
|
[o]: r ? () => r : void 0,
|
|
540
543
|
...a
|
|
541
544
|
};
|
|
542
|
-
},
|
|
545
|
+
}, Ne = (e, t) => {
|
|
543
546
|
const r = m(e, t.elementType) || t.elementType;
|
|
544
547
|
if (t.highConfig$)
|
|
545
|
-
return
|
|
548
|
+
return Ce(ar, {
|
|
546
549
|
key: t.elementId,
|
|
547
550
|
elementMap: e,
|
|
548
551
|
elementConfig: t
|
|
549
552
|
});
|
|
550
|
-
const o =
|
|
551
|
-
return
|
|
553
|
+
const o = Gt(e, t), a = Wt(e, t);
|
|
554
|
+
return Ce(r, {
|
|
552
555
|
key: t.elementId,
|
|
553
556
|
...a
|
|
554
557
|
}, o);
|
|
555
|
-
},
|
|
558
|
+
}, rr = (e) => _(e) ? yn(e) : ue(e) && e.indexOf(".") > 0 ? e.substring(0, e.indexOf(".")) : e, ar = w({
|
|
556
559
|
props: {
|
|
557
560
|
elementMap: {
|
|
558
561
|
type: Object
|
|
@@ -567,44 +570,44 @@ const Fn = () => ({
|
|
|
567
570
|
state: t,
|
|
568
571
|
sendEvent: r,
|
|
569
572
|
execute: o
|
|
570
|
-
} =
|
|
573
|
+
} = ge(), {
|
|
571
574
|
elementMap: a,
|
|
572
575
|
elementConfig: n
|
|
573
|
-
} = e, u = n.highConfig$, c =
|
|
574
|
-
|
|
575
|
-
const
|
|
576
|
-
const
|
|
576
|
+
} = e, u = n.highConfig$, c = Wt(a, n);
|
|
577
|
+
te((S = n.highConfig$) == null ? void 0 : S.registerEventList, (p) => {
|
|
578
|
+
const v = (...N) => {
|
|
579
|
+
const l = `${n.elementId}-${p.name}`;
|
|
577
580
|
r({
|
|
578
|
-
type:
|
|
579
|
-
payload:
|
|
580
|
-
}), o(
|
|
581
|
-
}, T =
|
|
582
|
-
c &&
|
|
581
|
+
type: l,
|
|
582
|
+
payload: N
|
|
583
|
+
}), o(p.executeList, N);
|
|
584
|
+
}, T = $t(p.name, c);
|
|
585
|
+
c && wt(T) && Kt(T, c) && ie(c, T, v);
|
|
583
586
|
});
|
|
584
|
-
const
|
|
587
|
+
const s = O(() => {
|
|
585
588
|
if (!u.registerStateList || X(u.registerStateList) <= 0)
|
|
586
589
|
return;
|
|
587
|
-
const
|
|
590
|
+
const p = {
|
|
588
591
|
...c
|
|
589
|
-
},
|
|
590
|
-
const
|
|
591
|
-
return
|
|
592
|
+
}, v = Y(u.registerStateList, (N) => !N.target || N.target === "prop"), T = F(v, (N) => {
|
|
593
|
+
const l = N.mapName || N.name, g = m(t, N.name);
|
|
594
|
+
return ie(p, l, g), rr(l);
|
|
592
595
|
});
|
|
593
|
-
return
|
|
594
|
-
}),
|
|
595
|
-
...
|
|
596
|
-
[
|
|
596
|
+
return H(p, T);
|
|
597
|
+
}), d = m(a, n.elementType) || n.elementType, y = Gt(a, n), h = ae(Y(u.registerStateList, (p) => p.target === "slot"), (p, v) => ({
|
|
598
|
+
...p,
|
|
599
|
+
[v.mapName]: () => m(t, v.name)
|
|
597
600
|
}), {}), f = {
|
|
598
|
-
...
|
|
601
|
+
...y,
|
|
599
602
|
...h
|
|
600
603
|
};
|
|
601
|
-
return () => m(
|
|
604
|
+
return () => m(s.value, "show$") === !1 ? null : Ce(d, {
|
|
602
605
|
key: n.elementId,
|
|
603
606
|
...c,
|
|
604
|
-
...$(
|
|
607
|
+
...$(s.value, "show$")
|
|
605
608
|
}, f);
|
|
606
609
|
}
|
|
607
|
-
}),
|
|
610
|
+
}), U = {
|
|
608
611
|
TypographyKey: "Typography$",
|
|
609
612
|
LoadingKey: "Loading$",
|
|
610
613
|
RowKey: "Row$",
|
|
@@ -614,10 +617,12 @@ const Fn = () => ({
|
|
|
614
617
|
DescriptionsItemKey: "ProDescriptionsItem$",
|
|
615
618
|
PaginationKey: "Pagination$",
|
|
616
619
|
PopoverKey: "Popover$",
|
|
620
|
+
TooltipKey: "Tooltip$",
|
|
617
621
|
CheckboxKey: "Checkbox$",
|
|
618
622
|
MenusKey: "Menus$",
|
|
619
623
|
ModalKey: "Modal$",
|
|
620
624
|
ScrollKey: "Scroll$",
|
|
625
|
+
PageKey: "Page$",
|
|
621
626
|
FormKey: "Form$",
|
|
622
627
|
FormItemKey: "FormItem$",
|
|
623
628
|
TableKey: "Table$",
|
|
@@ -627,15 +632,16 @@ const Fn = () => ({
|
|
|
627
632
|
ProSearchFormKey: "ProSearchForm$",
|
|
628
633
|
ProTableKey: "ProTable$",
|
|
629
634
|
ProCurdKey: "ProCurd$",
|
|
630
|
-
ProListKey: "ProList$"
|
|
635
|
+
ProListKey: "ProList$",
|
|
636
|
+
ProPageKey: "ProPage$"
|
|
631
637
|
}, Q = () => {
|
|
632
|
-
const { elementMap: e } =
|
|
638
|
+
const { elementMap: e } = ne();
|
|
633
639
|
return (t) => m(e, t);
|
|
634
640
|
};
|
|
635
|
-
function
|
|
636
|
-
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !
|
|
641
|
+
function or(e) {
|
|
642
|
+
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Ee(e);
|
|
637
643
|
}
|
|
638
|
-
const
|
|
644
|
+
const ur = () => ({
|
|
639
645
|
row: {
|
|
640
646
|
type: Object,
|
|
641
647
|
default: void 0
|
|
@@ -646,15 +652,15 @@ const er = () => ({
|
|
|
646
652
|
items: {
|
|
647
653
|
type: Array
|
|
648
654
|
}
|
|
649
|
-
}),
|
|
655
|
+
}), Pe = w({
|
|
650
656
|
props: {
|
|
651
|
-
...
|
|
657
|
+
...ur()
|
|
652
658
|
},
|
|
653
659
|
setup: (e) => {
|
|
654
|
-
const t = Q(), r = t(
|
|
660
|
+
const t = Q(), r = t(U.RowKey), o = t(U.ColKey);
|
|
655
661
|
return () => {
|
|
656
662
|
let a;
|
|
657
|
-
return !r || !o ? null :
|
|
663
|
+
return !r || !o ? null : i(r, e.row, or(a = F(e.items, (n) => i(o, K({
|
|
658
664
|
key: n.rowKey
|
|
659
665
|
}, e.col, n.col), {
|
|
660
666
|
default: () => [n.vNode]
|
|
@@ -663,27 +669,27 @@ const er = () => ({
|
|
|
663
669
|
});
|
|
664
670
|
};
|
|
665
671
|
}
|
|
666
|
-
}),
|
|
672
|
+
}), cr = (e, t, r) => {
|
|
667
673
|
if (t) {
|
|
668
|
-
const o = Y(
|
|
674
|
+
const o = Y(W(t), (a) => !t[a]);
|
|
669
675
|
return $(e, o);
|
|
670
676
|
}
|
|
671
677
|
if (r) {
|
|
672
|
-
const o = Y(
|
|
678
|
+
const o = Y(W(r), (a) => !r[a](e));
|
|
673
679
|
return $(e, o);
|
|
674
680
|
}
|
|
675
681
|
return e;
|
|
676
|
-
},
|
|
682
|
+
}, Xt = (e) => {
|
|
677
683
|
if (!!e)
|
|
678
|
-
return _(e) ? e : e &&
|
|
679
|
-
},
|
|
680
|
-
const a =
|
|
681
|
-
return !n ||
|
|
684
|
+
return _(e) ? e : e && ue(e) && e.indexOf(".") > 0 ? vn(e, ".") : [e];
|
|
685
|
+
}, la = (e, t, r) => !t || !r ? e : F(e, (o) => {
|
|
686
|
+
const a = V(r) ? r(o) : m(o, r), n = m(t, a);
|
|
687
|
+
return !n || Tt(n) || V(n) || !Me(n) ? o : hn(o, n, (u, c) => {
|
|
682
688
|
if (_(u) || _(c))
|
|
683
689
|
return c;
|
|
684
690
|
});
|
|
685
|
-
}),
|
|
686
|
-
const r =
|
|
691
|
+
}), Se = (e, t) => {
|
|
692
|
+
const r = ae(
|
|
687
693
|
e,
|
|
688
694
|
(o, a) => ({
|
|
689
695
|
...o,
|
|
@@ -695,20 +701,20 @@ const er = () => ({
|
|
|
695
701
|
{}
|
|
696
702
|
);
|
|
697
703
|
return r.originRef = t, r;
|
|
698
|
-
},
|
|
704
|
+
}, ia = (e, t, r) => {
|
|
699
705
|
const o = { originRef: e, ...r };
|
|
700
|
-
return t && X(t) > 0 &&
|
|
706
|
+
return t && X(t) > 0 && te(t, (a) => {
|
|
701
707
|
o[a] = (...n) => {
|
|
702
708
|
var u, c;
|
|
703
709
|
return (c = (u = e.value) == null ? void 0 : u[a]) == null ? void 0 : c.call(u, ...n);
|
|
704
710
|
};
|
|
705
711
|
}), o;
|
|
706
|
-
},
|
|
707
|
-
const r =
|
|
708
|
-
return
|
|
709
|
-
},
|
|
710
|
-
|
|
711
|
-
},
|
|
712
|
+
}, sr = (e, t) => m(e, ["extra", t]) || m(e, t), fe = (e, t) => {
|
|
713
|
+
const r = W(e), o = `${t}-`, a = Y(r, (u) => bn(u, o)), n = H(e, a);
|
|
714
|
+
return gn(n, (u, c) => c.replace(o, ""));
|
|
715
|
+
}, _t = Symbol("pro-form-list"), Yt = () => he(_t), Qt = (e) => {
|
|
716
|
+
ve(_t, e);
|
|
717
|
+
}, lr = w({
|
|
712
718
|
props: {
|
|
713
719
|
pathList: {
|
|
714
720
|
type: Array
|
|
@@ -716,13 +722,13 @@ const er = () => ({
|
|
|
716
722
|
},
|
|
717
723
|
setup: (e, {
|
|
718
724
|
slots: t
|
|
719
|
-
}) => (
|
|
725
|
+
}) => (Qt({
|
|
720
726
|
pathList: e.pathList
|
|
721
727
|
}), () => {
|
|
722
728
|
var r;
|
|
723
729
|
return (r = t.default) == null ? void 0 : r.call(t);
|
|
724
730
|
})
|
|
725
|
-
}),
|
|
731
|
+
}), yt = () => ({
|
|
726
732
|
rowKey: {
|
|
727
733
|
type: String,
|
|
728
734
|
default: "id"
|
|
@@ -759,120 +765,120 @@ const er = () => ({
|
|
|
759
765
|
onRemove: {
|
|
760
766
|
type: Function
|
|
761
767
|
}
|
|
762
|
-
}),
|
|
768
|
+
}), da = w({
|
|
763
769
|
props: {
|
|
764
|
-
...
|
|
765
|
-
...$(
|
|
770
|
+
...yt(),
|
|
771
|
+
...$(Pe.props, "items")
|
|
766
772
|
},
|
|
767
773
|
setup: (e, {
|
|
768
774
|
slots: t
|
|
769
775
|
}) => {
|
|
770
|
-
const o = Q()(
|
|
776
|
+
const o = Q()(U.FormItemKey), {
|
|
771
777
|
formState: a,
|
|
772
778
|
readonly: n,
|
|
773
779
|
elementMap: u,
|
|
774
780
|
formElementMap: c
|
|
775
|
-
} =
|
|
776
|
-
var
|
|
777
|
-
if (((
|
|
781
|
+
} = Zt(), s = Yt(), d = Xt(e.name), y = s != null && s.pathList ? [...s.pathList, ...d] : d, [h, f] = Dt(), S = () => {
|
|
782
|
+
var E;
|
|
783
|
+
if (((E = e.onPreAdd) == null ? void 0 : E.call(e)) === !0)
|
|
778
784
|
return;
|
|
779
|
-
const
|
|
780
|
-
let I = m(a,
|
|
785
|
+
const g = () => {
|
|
786
|
+
let I = m(a, y);
|
|
781
787
|
_(I) || (I = []), I.push({
|
|
782
788
|
[e.rowKey]: new Date().valueOf()
|
|
783
|
-
}),
|
|
789
|
+
}), ie(a, y, I);
|
|
784
790
|
};
|
|
785
791
|
if (e.onAdd) {
|
|
786
|
-
e.onAdd(
|
|
792
|
+
e.onAdd(g);
|
|
787
793
|
return;
|
|
788
794
|
}
|
|
789
|
-
|
|
790
|
-
},
|
|
791
|
-
var
|
|
792
|
-
if (((
|
|
793
|
-
index:
|
|
794
|
-
item:
|
|
795
|
+
g();
|
|
796
|
+
}, p = (l, g) => {
|
|
797
|
+
var M;
|
|
798
|
+
if (((M = e.onPreRemove) == null ? void 0 : M.call(e, {
|
|
799
|
+
index: l,
|
|
800
|
+
item: g
|
|
795
801
|
})) === !0)
|
|
796
802
|
return;
|
|
797
803
|
const I = () => {
|
|
798
|
-
const
|
|
799
|
-
X(
|
|
804
|
+
const R = m(a, y);
|
|
805
|
+
X(R) <= 0 || (R.splice(l, 1), f());
|
|
800
806
|
};
|
|
801
807
|
if (e.onRemove) {
|
|
802
808
|
e.onRemove(I, {
|
|
803
|
-
index:
|
|
804
|
-
item:
|
|
809
|
+
index: l,
|
|
810
|
+
item: g
|
|
805
811
|
});
|
|
806
812
|
return;
|
|
807
813
|
}
|
|
808
814
|
I();
|
|
809
|
-
},
|
|
810
|
-
const
|
|
811
|
-
return
|
|
812
|
-
item:
|
|
815
|
+
}, v = (l, g) => {
|
|
816
|
+
const E = de(l);
|
|
817
|
+
return E && t[E] ? t[E]({
|
|
818
|
+
item: l,
|
|
813
819
|
formState: a,
|
|
814
|
-
pathList:
|
|
815
|
-
}) :
|
|
816
|
-
}, T = (
|
|
820
|
+
pathList: g
|
|
821
|
+
}) : Ht(u, c, l);
|
|
822
|
+
}, T = (l, g) => {
|
|
817
823
|
if (!c || X(e.columns) <= 0)
|
|
818
824
|
return null;
|
|
819
825
|
if (!e.row)
|
|
820
|
-
return F(e.columns, (I) =>
|
|
821
|
-
const
|
|
822
|
-
rowKey:
|
|
823
|
-
vNode:
|
|
826
|
+
return F(e.columns, (I) => v(I, l));
|
|
827
|
+
const E = F(e.columns, (I) => ({
|
|
828
|
+
rowKey: de(I),
|
|
829
|
+
vNode: v(I, l),
|
|
824
830
|
col: m(I, ["extra", "col"])
|
|
825
831
|
}));
|
|
826
|
-
return
|
|
832
|
+
return i(Pe, {
|
|
827
833
|
row: e.row,
|
|
828
834
|
col: e.col,
|
|
829
|
-
items:
|
|
835
|
+
items: E
|
|
830
836
|
}, null);
|
|
831
|
-
},
|
|
832
|
-
return () => o ?
|
|
837
|
+
}, N = W(yt());
|
|
838
|
+
return () => o ? i(o, K({
|
|
833
839
|
class: `pro-form-list ${e.inline ? "pro-form-list-inline" : ""}`,
|
|
834
840
|
name: e.name
|
|
835
|
-
}, $(e,
|
|
841
|
+
}, $(e, N)), {
|
|
836
842
|
default: () => {
|
|
837
|
-
var
|
|
838
|
-
return [F(m(a,
|
|
839
|
-
const
|
|
840
|
-
return
|
|
841
|
-
key:
|
|
842
|
-
pathList:
|
|
843
|
+
var l, g;
|
|
844
|
+
return [F(m(a, y), (E, I) => {
|
|
845
|
+
const M = [...y, I];
|
|
846
|
+
return i(lr, {
|
|
847
|
+
key: E[e.rowKey] + h.value,
|
|
848
|
+
pathList: M
|
|
843
849
|
}, {
|
|
844
850
|
default: () => {
|
|
845
|
-
var
|
|
846
|
-
return [
|
|
851
|
+
var R, j, q, G, J, b;
|
|
852
|
+
return [i("div", {
|
|
847
853
|
class: "pro-form-list-item"
|
|
848
|
-
}, [(
|
|
854
|
+
}, [(R = t.start) == null ? void 0 : R.call(t, {
|
|
849
855
|
state: a,
|
|
850
|
-
path:
|
|
856
|
+
path: y,
|
|
851
857
|
index: I
|
|
852
|
-
}), T(
|
|
858
|
+
}), T(M), (j = t.default) == null ? void 0 : j.call(t), !n.value && i(le, null, [i("div", {
|
|
853
859
|
class: "pro-form-list-item-add",
|
|
854
860
|
onClick: S
|
|
855
|
-
}, [((
|
|
861
|
+
}, [((q = t.itemAdd) == null ? void 0 : q.call(t)) || ((G = e.renderItemAdd) == null ? void 0 : G.call(e))]), i("div", {
|
|
856
862
|
class: "pro-form-list-item-minus",
|
|
857
|
-
onClick: () =>
|
|
858
|
-
}, [((
|
|
863
|
+
onClick: () => p(I, E)
|
|
864
|
+
}, [((J = t.itemMinus) == null ? void 0 : J.call(t)) || ((b = e.renderItemMinus) == null ? void 0 : b.call(e))])])])];
|
|
859
865
|
}
|
|
860
866
|
});
|
|
861
|
-
}), !n.value &&
|
|
867
|
+
}), !n.value && i("div", {
|
|
862
868
|
class: "pro-form-list-add",
|
|
863
869
|
onClick: S
|
|
864
|
-
}, [((
|
|
870
|
+
}, [((l = t.add) == null ? void 0 : l.call(t)) || ((g = e.renderAdd) == null ? void 0 : g.call(e))])];
|
|
865
871
|
}
|
|
866
872
|
}) : null;
|
|
867
873
|
}
|
|
868
|
-
}),
|
|
869
|
-
|
|
874
|
+
}), Jt = Symbol("pro-form"), Zt = () => he(Jt), ir = (e, t = 300, r) => It(e, t, r), dr = (e) => {
|
|
875
|
+
ve(Jt, e);
|
|
870
876
|
};
|
|
871
|
-
let
|
|
877
|
+
let re;
|
|
872
878
|
(function(e) {
|
|
873
879
|
e.RESET = "RESET", e.SUBMIT = "SUBMIT", e.CONTINUE = "CONTINUE";
|
|
874
|
-
})(
|
|
875
|
-
const
|
|
880
|
+
})(re || (re = {}));
|
|
881
|
+
const vt = () => ({
|
|
876
882
|
clsName: {
|
|
877
883
|
type: String,
|
|
878
884
|
default: "pro-form"
|
|
@@ -922,12 +928,12 @@ const ct = () => ({
|
|
|
922
928
|
type: Function,
|
|
923
929
|
default: void 0
|
|
924
930
|
}
|
|
925
|
-
}),
|
|
931
|
+
}), fa = w({
|
|
926
932
|
inheritAttrs: !1,
|
|
927
933
|
props: {
|
|
928
|
-
...
|
|
929
|
-
...
|
|
930
|
-
...$(
|
|
934
|
+
...be,
|
|
935
|
+
...vt(),
|
|
936
|
+
...$(Pe.props, "items")
|
|
931
937
|
},
|
|
932
938
|
setup: (e, {
|
|
933
939
|
slots: t,
|
|
@@ -938,116 +944,128 @@ const ct = () => ({
|
|
|
938
944
|
const {
|
|
939
945
|
elementMap: n,
|
|
940
946
|
formElementMap: u
|
|
941
|
-
} =
|
|
942
|
-
const
|
|
943
|
-
return e.convertColumn ?
|
|
944
|
-
}),
|
|
945
|
-
var
|
|
946
|
-
((
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
},
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
947
|
+
} = ne(), c = e.elementMap || n, s = e.formElementMap || u, d = e.model || Ae({}), y = qe(d, e.showStateRules, e.showState), h = qe(d, e.readonlyStateRules, e.readonlyState), f = qe(d, e.disableStateRules, e.disableState), S = O(() => e.readonly), p = O(() => {
|
|
948
|
+
const A = Ue(e.columns, e.columnState, e.columnState2);
|
|
949
|
+
return e.convertColumn ? Ft(A, e.convertColumn) : A;
|
|
950
|
+
}), v = z(!1), T = z(0), N = (...A) => {
|
|
951
|
+
var ee;
|
|
952
|
+
((ee = e.onPreFinish) == null ? void 0 : ee.call(e, ...A)) !== !0 && r("finish", ...A, {
|
|
953
|
+
userOpe: v,
|
|
954
|
+
asyncNum: T
|
|
955
|
+
});
|
|
956
|
+
}, l = e.debounceSubmit, g = (typeof l == "object" ? l.wait : l) || 300, E = ir((...A) => N(...A), g, l == null ? void 0 : l.options), I = (A) => {
|
|
957
|
+
const x = cr(A, y, e.showStateRules);
|
|
958
|
+
l !== void 0 ? E(x, A) : N(x, A);
|
|
959
|
+
}, M = z();
|
|
960
|
+
o({
|
|
961
|
+
...Se(e.formMethods || [], M),
|
|
962
|
+
userOpe: v,
|
|
963
|
+
asyncNum: T
|
|
964
|
+
}), dr({
|
|
965
|
+
formState: d,
|
|
966
|
+
showState: y,
|
|
954
967
|
readonlyState: h,
|
|
955
968
|
disableState: f,
|
|
956
969
|
elementMap: c,
|
|
957
|
-
formElementMap:
|
|
970
|
+
formElementMap: s,
|
|
958
971
|
readonly: S,
|
|
959
|
-
columns:
|
|
960
|
-
formRef:
|
|
972
|
+
columns: p,
|
|
973
|
+
formRef: M,
|
|
974
|
+
userOpe: v,
|
|
975
|
+
asyncNum: T,
|
|
961
976
|
...e.provideExtra
|
|
962
|
-
}),
|
|
963
|
-
const
|
|
964
|
-
value:
|
|
977
|
+
}), Qt({});
|
|
978
|
+
const R = [{
|
|
979
|
+
value: re.RESET,
|
|
965
980
|
label: "\u91CD\u7F6E"
|
|
966
981
|
}, {
|
|
967
|
-
value:
|
|
982
|
+
value: re.SUBMIT,
|
|
968
983
|
label: "\u63D0\u4EA4",
|
|
969
984
|
extraProps: {
|
|
970
985
|
type: "primary"
|
|
971
986
|
}
|
|
972
|
-
}],
|
|
973
|
-
var
|
|
974
|
-
if ((
|
|
987
|
+
}], j = () => {
|
|
988
|
+
var A, x;
|
|
989
|
+
if ((A = e.operate) != null && A.onReset) {
|
|
975
990
|
e.operate.onReset({
|
|
976
|
-
form:
|
|
991
|
+
form: M.value
|
|
977
992
|
});
|
|
978
993
|
return;
|
|
979
994
|
}
|
|
980
|
-
(
|
|
981
|
-
},
|
|
982
|
-
var
|
|
983
|
-
if ((
|
|
995
|
+
(x = M.value) == null || x.resetFields();
|
|
996
|
+
}, q = () => {
|
|
997
|
+
var A, x;
|
|
998
|
+
if ((A = e.operate) != null && A.onSubmit) {
|
|
984
999
|
e.operate.onSubmit({
|
|
985
|
-
form:
|
|
1000
|
+
form: M.value
|
|
986
1001
|
});
|
|
987
1002
|
return;
|
|
988
1003
|
}
|
|
989
|
-
(
|
|
990
|
-
},
|
|
991
|
-
var
|
|
992
|
-
(
|
|
993
|
-
form:
|
|
1004
|
+
(x = M.value) == null || x.submit();
|
|
1005
|
+
}, G = () => {
|
|
1006
|
+
var A, x;
|
|
1007
|
+
(x = (A = e.operate) == null ? void 0 : A.onContinue) == null || x.call(A, {
|
|
1008
|
+
form: M.value
|
|
994
1009
|
});
|
|
995
|
-
},
|
|
996
|
-
[
|
|
997
|
-
[
|
|
998
|
-
[
|
|
999
|
-
},
|
|
1000
|
-
const
|
|
1001
|
-
return F(
|
|
1002
|
-
...
|
|
1003
|
-
onClick: m(
|
|
1004
|
-
} :
|
|
1005
|
-
}),
|
|
1006
|
-
var
|
|
1010
|
+
}, J = {
|
|
1011
|
+
[re.RESET]: j,
|
|
1012
|
+
[re.SUBMIT]: q,
|
|
1013
|
+
[re.CONTINUE]: G
|
|
1014
|
+
}, b = O(() => {
|
|
1015
|
+
const A = e.operate, x = (A == null ? void 0 : A.items) || R;
|
|
1016
|
+
return F(x, (ee) => !ee.onClick && !m(A == null ? void 0 : A.itemState, [ee.value, "onClick"]) ? {
|
|
1017
|
+
...ee,
|
|
1018
|
+
onClick: m(J, ee.value)
|
|
1019
|
+
} : ee);
|
|
1020
|
+
}), P = O(() => {
|
|
1021
|
+
var A;
|
|
1007
1022
|
return {
|
|
1008
|
-
[
|
|
1009
|
-
value:
|
|
1023
|
+
[re.SUBMIT]: {
|
|
1024
|
+
value: re.SUBMIT,
|
|
1010
1025
|
loading: e.submitLoading
|
|
1011
1026
|
},
|
|
1012
|
-
...(
|
|
1027
|
+
...(A = e.operate) == null ? void 0 : A.itemState
|
|
1013
1028
|
};
|
|
1014
|
-
}),
|
|
1015
|
-
const
|
|
1016
|
-
return
|
|
1017
|
-
},
|
|
1018
|
-
const
|
|
1019
|
-
const
|
|
1020
|
-
return !!m(
|
|
1029
|
+
}), C = (A) => {
|
|
1030
|
+
const x = de(A);
|
|
1031
|
+
return x && t[x] ? t[x](A, d) : Ht(c, s, A);
|
|
1032
|
+
}, L = O(() => {
|
|
1033
|
+
const A = Y(p.value, (x) => {
|
|
1034
|
+
const ee = de(x);
|
|
1035
|
+
return !!m(y, ee, !0);
|
|
1021
1036
|
});
|
|
1022
|
-
return e.row ? F(
|
|
1023
|
-
rowKey:
|
|
1024
|
-
vNode:
|
|
1025
|
-
col: m(
|
|
1026
|
-
})) : F(
|
|
1027
|
-
}),
|
|
1028
|
-
return () =>
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1037
|
+
return e.row ? F(A, (x) => ({
|
|
1038
|
+
rowKey: de(x),
|
|
1039
|
+
vNode: C(x),
|
|
1040
|
+
col: m(x, ["extra", "col"])
|
|
1041
|
+
})) : F(A, (x) => C(x));
|
|
1042
|
+
}), Z = [...W(vt()), ...W(be)], k = W($(Pe.props, "items")), se = m(n, U.FormKey);
|
|
1043
|
+
return () => {
|
|
1044
|
+
var ut, ct, st;
|
|
1045
|
+
if (!se)
|
|
1046
|
+
return null;
|
|
1047
|
+
const A = (ut = t.start) == null ? void 0 : ut.call(t), x = (ct = t.default) == null ? void 0 : ct.call(t), ee = (st = t.end) == null ? void 0 : st.call(t), at = [e.clsName], ot = X(L.value) <= 0 && !xe(A) && !xe(x) && !xe(ee);
|
|
1048
|
+
return ot && at.push("is-empty"), i(se, K({
|
|
1049
|
+
ref: M,
|
|
1050
|
+
class: at
|
|
1051
|
+
}, $(a, "onFinish"), $(e, ...Z, ...k, "onFinish", "operate"), {
|
|
1052
|
+
model: d,
|
|
1053
|
+
onFinish: I
|
|
1054
|
+
}), {
|
|
1055
|
+
default: () => [A, s && X(p.value) > 0 && i(le, null, [e.row ? i(Pe, {
|
|
1038
1056
|
row: e.row,
|
|
1039
1057
|
col: e.col,
|
|
1040
|
-
items:
|
|
1041
|
-
}, null) :
|
|
1058
|
+
items: L.value
|
|
1059
|
+
}, null) : L.value]), x, e.operate && !ot && i(an, K({
|
|
1042
1060
|
class: `${e.clsName}-operate`
|
|
1043
1061
|
}, $(e.operate, "items", "itemState", "onReset", "onSubmit", "onContinue"), {
|
|
1044
|
-
items:
|
|
1045
|
-
itemState:
|
|
1046
|
-
}), null),
|
|
1047
|
-
}
|
|
1048
|
-
}
|
|
1062
|
+
items: b.value,
|
|
1063
|
+
itemState: P.value
|
|
1064
|
+
}), null), ee]
|
|
1065
|
+
});
|
|
1066
|
+
};
|
|
1049
1067
|
}
|
|
1050
|
-
}),
|
|
1068
|
+
}), ma = {
|
|
1051
1069
|
text: "\u8BF7\u8F93\u5165",
|
|
1052
1070
|
digit: "\u8BF7\u8F93\u5165",
|
|
1053
1071
|
select: "\u8BF7\u9009\u62E9",
|
|
@@ -1059,18 +1077,18 @@ const ct = () => ({
|
|
|
1059
1077
|
date: "\u8BF7\u9009\u62E9",
|
|
1060
1078
|
time: "\u8BF7\u9009\u62E9"
|
|
1061
1079
|
};
|
|
1062
|
-
let
|
|
1080
|
+
let ke;
|
|
1063
1081
|
(function(e) {
|
|
1064
1082
|
e.AUTO = "AUTO", e.MANUAL = "MANUAL";
|
|
1065
|
-
})(
|
|
1066
|
-
const
|
|
1083
|
+
})(ke || (ke = {}));
|
|
1084
|
+
const ht = () => ({
|
|
1067
1085
|
initEmit: {
|
|
1068
1086
|
type: Boolean,
|
|
1069
1087
|
default: !0
|
|
1070
1088
|
},
|
|
1071
1089
|
searchMode: {
|
|
1072
1090
|
type: String,
|
|
1073
|
-
default:
|
|
1091
|
+
default: ke.AUTO
|
|
1074
1092
|
},
|
|
1075
1093
|
debounceKeys: {
|
|
1076
1094
|
type: Array
|
|
@@ -1083,9 +1101,9 @@ const st = () => ({
|
|
|
1083
1101
|
type: Number,
|
|
1084
1102
|
default: 800
|
|
1085
1103
|
}
|
|
1086
|
-
}),
|
|
1104
|
+
}), ya = w({
|
|
1087
1105
|
props: {
|
|
1088
|
-
...
|
|
1106
|
+
...ht(),
|
|
1089
1107
|
needRules: {
|
|
1090
1108
|
type: Boolean,
|
|
1091
1109
|
default: !1
|
|
@@ -1095,44 +1113,71 @@ const st = () => ({
|
|
|
1095
1113
|
slots: t,
|
|
1096
1114
|
expose: r
|
|
1097
1115
|
}) => {
|
|
1098
|
-
const a = Q()(
|
|
1099
|
-
const T =
|
|
1116
|
+
const a = Q()(U.ProFormKey), n = e.model || Ae({}), u = new Set(e.debounceTypes), c = F(Y(e.columns, (v) => {
|
|
1117
|
+
const T = zt(v);
|
|
1100
1118
|
return u.has(T);
|
|
1101
|
-
}), (
|
|
1102
|
-
...
|
|
1103
|
-
formItemProps: $(
|
|
1104
|
-
}))),
|
|
1105
|
-
r(
|
|
1119
|
+
}), (v) => de(v)), s = O(() => F(e.columns, (v) => ({
|
|
1120
|
+
...v,
|
|
1121
|
+
formItemProps: $(v.formItemProps, "required")
|
|
1122
|
+
}))), d = z(), y = e.formMethods || [];
|
|
1123
|
+
r(Se(y, d));
|
|
1106
1124
|
const h = () => {
|
|
1107
|
-
var
|
|
1108
|
-
(
|
|
1109
|
-
}, f =
|
|
1125
|
+
var v;
|
|
1126
|
+
(v = d.value) == null || v.submit();
|
|
1127
|
+
}, f = It(() => {
|
|
1110
1128
|
h();
|
|
1111
1129
|
}, e.debounceTime);
|
|
1112
|
-
|
|
1130
|
+
ce(() => {
|
|
1113
1131
|
e.initEmit && h();
|
|
1114
1132
|
}, []);
|
|
1115
|
-
const S = (
|
|
1116
|
-
|
|
1117
|
-
if (e.searchMode !==
|
|
1133
|
+
const S = (v, T, N) => ye(N, (l) => m(v, l) !== m(T, l));
|
|
1134
|
+
xt((v, T) => {
|
|
1135
|
+
if (e.searchMode !== ke.AUTO)
|
|
1118
1136
|
return;
|
|
1119
|
-
const
|
|
1120
|
-
if (X(
|
|
1137
|
+
const N = X(e.debounceKeys) > 0 ? e.debounceKeys : c;
|
|
1138
|
+
if (X(N) > 0 && S(v, T, N)) {
|
|
1121
1139
|
f();
|
|
1122
1140
|
return;
|
|
1123
1141
|
}
|
|
1124
1142
|
h();
|
|
1125
|
-
}, () =>
|
|
1126
|
-
const
|
|
1127
|
-
return () => a ?
|
|
1128
|
-
ref:
|
|
1143
|
+
}, () => Sn(n));
|
|
1144
|
+
const p = W(ht());
|
|
1145
|
+
return () => a ? i(a, K({
|
|
1146
|
+
ref: d,
|
|
1129
1147
|
class: "pro-search-form"
|
|
1130
|
-
}, $(e,
|
|
1131
|
-
columns:
|
|
1148
|
+
}, $(e, p, "columns"), {
|
|
1149
|
+
columns: s.value,
|
|
1132
1150
|
model: n
|
|
1133
1151
|
}), t) : null;
|
|
1134
1152
|
}
|
|
1135
|
-
}),
|
|
1153
|
+
}), fr = () => ({
|
|
1154
|
+
title: String,
|
|
1155
|
+
content: String,
|
|
1156
|
+
renderDom: {
|
|
1157
|
+
type: Function,
|
|
1158
|
+
default: () => i("span", {
|
|
1159
|
+
class: "pro-tip-dom"
|
|
1160
|
+
}, [We("?")])
|
|
1161
|
+
}
|
|
1162
|
+
}), mr = w({
|
|
1163
|
+
props: {
|
|
1164
|
+
...fr()
|
|
1165
|
+
},
|
|
1166
|
+
setup: (e, {
|
|
1167
|
+
slots: t
|
|
1168
|
+
}) => {
|
|
1169
|
+
const o = Q()(U.TooltipKey);
|
|
1170
|
+
return () => i(o, $(e, "renderDom"), {
|
|
1171
|
+
default: () => {
|
|
1172
|
+
var a, n;
|
|
1173
|
+
return [((a = t.default) == null ? void 0 : a.call(t)) || ((n = e.renderDom) == null ? void 0 : n.call(e))];
|
|
1174
|
+
},
|
|
1175
|
+
content: () => e.content,
|
|
1176
|
+
title: () => e.title,
|
|
1177
|
+
...t
|
|
1178
|
+
});
|
|
1179
|
+
}
|
|
1180
|
+
}), bt = () => ({
|
|
1136
1181
|
readonly: {
|
|
1137
1182
|
type: Boolean,
|
|
1138
1183
|
default: void 0
|
|
@@ -1145,97 +1190,108 @@ const st = () => ({
|
|
|
1145
1190
|
},
|
|
1146
1191
|
slots: {
|
|
1147
1192
|
type: Object
|
|
1193
|
+
},
|
|
1194
|
+
tip: {
|
|
1195
|
+
type: [String, Object]
|
|
1196
|
+
},
|
|
1197
|
+
tipProps: {
|
|
1198
|
+
type: Object
|
|
1148
1199
|
}
|
|
1149
|
-
}),
|
|
1200
|
+
}), va = (e, t) => ({
|
|
1150
1201
|
InputComp: r,
|
|
1151
1202
|
valueType: o,
|
|
1152
1203
|
name: a
|
|
1153
|
-
}) =>
|
|
1204
|
+
}) => w({
|
|
1154
1205
|
name: a,
|
|
1155
1206
|
props: {
|
|
1156
1207
|
...e.props,
|
|
1157
|
-
...
|
|
1208
|
+
...bt()
|
|
1158
1209
|
},
|
|
1159
1210
|
setup: (n, {
|
|
1160
1211
|
slots: u
|
|
1161
1212
|
}) => {
|
|
1162
1213
|
const {
|
|
1163
1214
|
formExtraMap: c,
|
|
1164
|
-
elementMap:
|
|
1165
|
-
} =
|
|
1166
|
-
formState:
|
|
1167
|
-
readonlyState:
|
|
1215
|
+
elementMap: s
|
|
1216
|
+
} = ne(), {
|
|
1217
|
+
formState: d,
|
|
1218
|
+
readonlyState: y,
|
|
1168
1219
|
disableState: h,
|
|
1169
|
-
readonly: f
|
|
1170
|
-
|
|
1220
|
+
readonly: f,
|
|
1221
|
+
userOpe: S
|
|
1222
|
+
} = Zt(), p = Yt(), v = O(() => Te(n.readonly) ? n.readonly : Te(y[n.name]) ? y[n.name] : f.value), T = () => `${m(c == null ? void 0 : c.rulePrefixMap, o) || "\u8BF7\u8F93\u5165"}${n.label || ""}`, N = O(() => c != null && c.rulePrefixMap ? n.required === !0 && !n.rules ? [{
|
|
1171
1223
|
required: !0,
|
|
1172
|
-
message:
|
|
1173
|
-
}] : n.rules ? F(n.rules, (
|
|
1174
|
-
|
|
1175
|
-
},
|
|
1176
|
-
const
|
|
1224
|
+
message: T()
|
|
1225
|
+
}] : n.rules ? F(n.rules, (j) => (j.required && !j.message && (j.message = T()), j)) : n.rules : n.rules), l = Xt(n.name), g = p != null && p.pathList ? [...p.pathList, ...l] : l, E = (j) => {
|
|
1226
|
+
S.value = !0, ie(d, g, j);
|
|
1227
|
+
}, I = W(bt()), M = () => {
|
|
1228
|
+
const j = m(d, g);
|
|
1177
1229
|
if (u.renderShow)
|
|
1178
1230
|
return u.renderShow({
|
|
1179
|
-
value:
|
|
1180
|
-
record:
|
|
1181
|
-
path:
|
|
1231
|
+
value: j,
|
|
1232
|
+
record: d,
|
|
1233
|
+
path: g
|
|
1182
1234
|
});
|
|
1183
|
-
const
|
|
1184
|
-
return
|
|
1185
|
-
value:
|
|
1235
|
+
const q = m(s, o);
|
|
1236
|
+
return q ? i(q, K({
|
|
1237
|
+
value: j
|
|
1186
1238
|
}, n.fieldProps, {
|
|
1187
1239
|
showProps: n.showProps
|
|
1188
|
-
}), u) :
|
|
1189
|
-
},
|
|
1190
|
-
const
|
|
1240
|
+
}), u) : i("span", null, [j]);
|
|
1241
|
+
}, R = () => {
|
|
1242
|
+
const j = m(d, g), q = m(h, g);
|
|
1191
1243
|
return u.renderInput ? u.renderInput({
|
|
1192
|
-
value:
|
|
1193
|
-
setValue:
|
|
1194
|
-
disabled:
|
|
1195
|
-
record:
|
|
1196
|
-
path:
|
|
1197
|
-
}) :
|
|
1244
|
+
value: j,
|
|
1245
|
+
setValue: E,
|
|
1246
|
+
disabled: q,
|
|
1247
|
+
record: d,
|
|
1248
|
+
path: g
|
|
1249
|
+
}) : i(r, K(t(j, E, q), n.fieldProps), u);
|
|
1198
1250
|
};
|
|
1199
|
-
return () =>
|
|
1251
|
+
return () => i(e, K({
|
|
1200
1252
|
class: "pro-form-item"
|
|
1201
|
-
}, $(n, ...
|
|
1202
|
-
name:
|
|
1203
|
-
rules:
|
|
1253
|
+
}, $(n, ...I, "name", "rules"), {
|
|
1254
|
+
name: g,
|
|
1255
|
+
rules: N.value
|
|
1204
1256
|
}), {
|
|
1205
|
-
default: () => [
|
|
1257
|
+
default: () => [v.value ? M() : R()],
|
|
1258
|
+
label: () => i(le, null, [n.label, n.tip && i(mr, K({
|
|
1259
|
+
content: n.tip,
|
|
1260
|
+
title: n.tip
|
|
1261
|
+
}, n.tipProps), null)]),
|
|
1206
1262
|
...n.slots
|
|
1207
1263
|
});
|
|
1208
1264
|
}
|
|
1209
|
-
}),
|
|
1210
|
-
const [e, t] =
|
|
1265
|
+
}), en = Un("access", void 0, !0), yr = () => {
|
|
1266
|
+
const [e, t] = en();
|
|
1211
1267
|
return { access: e, setAccess: t, delAccess: () => {
|
|
1212
1268
|
t(void 0);
|
|
1213
1269
|
} };
|
|
1214
|
-
},
|
|
1215
|
-
const [e, t] =
|
|
1270
|
+
}, ha = () => {
|
|
1271
|
+
const [e, t] = en();
|
|
1216
1272
|
return [e, t, () => {
|
|
1217
1273
|
t(void 0);
|
|
1218
1274
|
}];
|
|
1219
|
-
},
|
|
1220
|
-
const [r, o] =
|
|
1221
|
-
return
|
|
1275
|
+
}, tn = Symbol("logon-user"), vr = () => he(tn), ba = w((e, { slots: t }) => {
|
|
1276
|
+
const [r, o] = lt(), [a, n] = lt();
|
|
1277
|
+
return ve(tn, { user: r, setUser: o, per: a, setPer: n, opts: {} }), () => {
|
|
1222
1278
|
var c;
|
|
1223
1279
|
return (c = t.default) == null ? void 0 : c.call(t);
|
|
1224
1280
|
};
|
|
1225
|
-
}),
|
|
1226
|
-
const { access: o } =
|
|
1227
|
-
return
|
|
1281
|
+
}), ga = w((e, { slots: t, emit: r }) => {
|
|
1282
|
+
const { access: o } = yr(), a = O(() => o && o.token);
|
|
1283
|
+
return ce(() => {
|
|
1228
1284
|
a.value || r("toLogin");
|
|
1229
1285
|
}, a), () => {
|
|
1230
1286
|
var n;
|
|
1231
1287
|
return a.value ? (n = t.default) == null ? void 0 : n.call(t) : null;
|
|
1232
1288
|
};
|
|
1233
|
-
}),
|
|
1289
|
+
}), Sa = {
|
|
1234
1290
|
Add: "add",
|
|
1235
1291
|
Edit: "edit",
|
|
1236
1292
|
Delete: "delete"
|
|
1237
|
-
},
|
|
1238
|
-
const { per: e } =
|
|
1293
|
+
}, hr = (e, t) => !e || !t ? !1 : _(t) ? ye(t, (r) => e[r]) : e[t], nn = () => {
|
|
1294
|
+
const { per: e } = vr() || { per: { menus: [], buttonMap: {} } }, t = Je();
|
|
1239
1295
|
return (r, o) => {
|
|
1240
1296
|
if (!r)
|
|
1241
1297
|
return !1;
|
|
@@ -1244,32 +1300,32 @@ const st = () => ({
|
|
|
1244
1300
|
const n = t.name ? t.name.toString() : "", u = (o == null ? void 0 : o.splitStr) || "_";
|
|
1245
1301
|
a = _(a) ? F(a, (c) => `${n}${u}${c}`) : `${n}${u}${a}`;
|
|
1246
1302
|
}
|
|
1247
|
-
return
|
|
1303
|
+
return hr(e.buttonMap, a);
|
|
1248
1304
|
};
|
|
1249
|
-
},
|
|
1250
|
-
const e =
|
|
1305
|
+
}, rn = () => {
|
|
1306
|
+
const e = nn();
|
|
1251
1307
|
return (t, r, o) => t ? e(t) : r ? e(r, { suffix: !0, splitStr: o }) : !0;
|
|
1252
|
-
},
|
|
1308
|
+
}, br = () => ({
|
|
1253
1309
|
suffix: { type: [String, Array] },
|
|
1254
1310
|
value: { type: [String, Array] },
|
|
1255
1311
|
splitStr: { type: String }
|
|
1256
|
-
}),
|
|
1312
|
+
}), Pa = w({
|
|
1257
1313
|
inheritAttrs: !1,
|
|
1258
1314
|
props: {
|
|
1259
|
-
...
|
|
1315
|
+
...br()
|
|
1260
1316
|
},
|
|
1261
1317
|
setup: (e, { slots: t }) => {
|
|
1262
|
-
const r =
|
|
1318
|
+
const r = nn(), o = O(() => e.value ? r(e.value) : e.suffix ? r(e.suffix, { suffix: !0, splitStr: e.splitStr }) : !1);
|
|
1263
1319
|
return () => {
|
|
1264
1320
|
var a;
|
|
1265
1321
|
return o.value ? (a = t.default) == null ? void 0 : a.call(t) : null;
|
|
1266
1322
|
};
|
|
1267
1323
|
}
|
|
1268
1324
|
});
|
|
1269
|
-
function
|
|
1270
|
-
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !
|
|
1325
|
+
function gr(e) {
|
|
1326
|
+
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Ee(e);
|
|
1271
1327
|
}
|
|
1272
|
-
const
|
|
1328
|
+
const Sr = () => ({
|
|
1273
1329
|
clsName: {
|
|
1274
1330
|
type: String,
|
|
1275
1331
|
default: "pro-operate"
|
|
@@ -1282,48 +1338,61 @@ const dr = () => ({
|
|
|
1282
1338
|
},
|
|
1283
1339
|
elementKey: {
|
|
1284
1340
|
type: String,
|
|
1285
|
-
default:
|
|
1341
|
+
default: U.ButtonKey
|
|
1286
1342
|
},
|
|
1287
1343
|
splitStr: {
|
|
1288
1344
|
type: String
|
|
1289
1345
|
}
|
|
1290
|
-
}),
|
|
1346
|
+
}), an = w({
|
|
1291
1347
|
props: {
|
|
1292
|
-
...
|
|
1348
|
+
...Sr()
|
|
1293
1349
|
},
|
|
1294
1350
|
setup: (e, {
|
|
1295
1351
|
slots: t
|
|
1296
1352
|
}) => {
|
|
1297
|
-
const r =
|
|
1298
|
-
const
|
|
1299
|
-
...
|
|
1300
|
-
...m(e.itemState,
|
|
1301
|
-
} :
|
|
1302
|
-
return
|
|
1303
|
-
}), a = (
|
|
1304
|
-
var
|
|
1305
|
-
(
|
|
1306
|
-
}, n = Q(), u = e.elementKey ? n(e.elementKey) : void 0;
|
|
1307
|
-
return () =>
|
|
1353
|
+
const r = rn(), o = O(() => {
|
|
1354
|
+
const s = Y(e.items, (y) => r(y.per, y.perSuffix, e.splitStr) ? V(y.show) ? y.show() : Te(y.show) ? y.show : !0 : !1), d = F(s, (y) => Xe(e.itemState, y.value) ? {
|
|
1355
|
+
...y,
|
|
1356
|
+
...m(e.itemState, y.value)
|
|
1357
|
+
} : y);
|
|
1358
|
+
return Nt(d, (y) => y.sort);
|
|
1359
|
+
}), a = (s) => {
|
|
1360
|
+
var d;
|
|
1361
|
+
(d = s.onClick) == null || d.call(s, s);
|
|
1362
|
+
}, n = Q(), u = e.elementKey ? n(e.elementKey) : void 0, c = n(U.TooltipKey);
|
|
1363
|
+
return () => i("div", {
|
|
1308
1364
|
class: e.clsName
|
|
1309
|
-
}, [F(o.value, (
|
|
1310
|
-
const
|
|
1311
|
-
...$(
|
|
1312
|
-
disabled:
|
|
1365
|
+
}, [F(o.value, (s) => {
|
|
1366
|
+
const d = V(s.disabled) ? s.disabled() : s.disabled, y = V(s.loading) ? s.loading() : s.loading, h = V(s.label) ? s.label() : s.label, f = V(s.extraProps) ? s.extraProps() : s.extraProps, S = {
|
|
1367
|
+
...$(s, "show", "disabled", "element"),
|
|
1368
|
+
disabled: d
|
|
1313
1369
|
};
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1370
|
+
if (s.element && V(s.element))
|
|
1371
|
+
return s.element(S);
|
|
1372
|
+
if (t[s.value])
|
|
1373
|
+
return t[s.value](S);
|
|
1374
|
+
if (u) {
|
|
1375
|
+
const p = i(u, K({
|
|
1376
|
+
disabled: d,
|
|
1377
|
+
loading: y,
|
|
1378
|
+
onClick: () => a(s)
|
|
1379
|
+
}, f), gr(h) ? h : {
|
|
1380
|
+
default: () => [h]
|
|
1381
|
+
});
|
|
1382
|
+
return s.tip && c ? i(c, K({
|
|
1383
|
+
placement: "top"
|
|
1384
|
+
}, s.tipProps), {
|
|
1385
|
+
default: () => [p],
|
|
1386
|
+
content: () => s.tip
|
|
1387
|
+
}) : p;
|
|
1388
|
+
}
|
|
1389
|
+
return i("div", {
|
|
1321
1390
|
class: `${e.clsName}-item`,
|
|
1322
|
-
onClick: () => a(
|
|
1323
|
-
}, [
|
|
1391
|
+
onClick: () => a(s)
|
|
1392
|
+
}, [h]);
|
|
1324
1393
|
})]);
|
|
1325
1394
|
}
|
|
1326
|
-
}),
|
|
1395
|
+
}), Pr = () => ({
|
|
1327
1396
|
clsName: {
|
|
1328
1397
|
type: String,
|
|
1329
1398
|
default: "pro-table-toolbar-column"
|
|
@@ -1344,105 +1413,105 @@ const dr = () => ({
|
|
|
1344
1413
|
type: Function,
|
|
1345
1414
|
default: () => "\u5217\u8BBE\u7F6E"
|
|
1346
1415
|
}
|
|
1347
|
-
}),
|
|
1416
|
+
}), pr = w({
|
|
1348
1417
|
props: {
|
|
1349
|
-
...
|
|
1418
|
+
...Pr()
|
|
1350
1419
|
},
|
|
1351
1420
|
setup: (e, {
|
|
1352
1421
|
slots: t
|
|
1353
1422
|
}) => {
|
|
1354
|
-
const r = Q(), o = r(
|
|
1423
|
+
const r = Q(), o = r(U.PopoverKey), a = r(U.CheckboxKey), {
|
|
1355
1424
|
originColumns: n,
|
|
1356
1425
|
selectIdsRef: u
|
|
1357
|
-
} =
|
|
1358
|
-
let
|
|
1359
|
-
const
|
|
1360
|
-
|
|
1426
|
+
} = Cr(), [c, s] = Dt();
|
|
1427
|
+
let d = {};
|
|
1428
|
+
const y = (l) => {
|
|
1429
|
+
d[l] = !1;
|
|
1361
1430
|
}, h = () => {
|
|
1362
|
-
|
|
1363
|
-
|
|
1431
|
+
te(u.value, (l) => {
|
|
1432
|
+
d[l] = !0;
|
|
1364
1433
|
});
|
|
1365
|
-
}, f = O(() =>
|
|
1366
|
-
...
|
|
1367
|
-
[
|
|
1368
|
-
}), {})), S = (
|
|
1369
|
-
|
|
1370
|
-
u.value = F(Y(n.value, (
|
|
1371
|
-
var
|
|
1372
|
-
return e.useSelectedStatus &&
|
|
1373
|
-
}), (
|
|
1374
|
-
}, n),
|
|
1375
|
-
var
|
|
1376
|
-
|
|
1434
|
+
}, f = O(() => ae(u.value, (l, g) => ({
|
|
1435
|
+
...l,
|
|
1436
|
+
[g]: !0
|
|
1437
|
+
}), {})), S = (l) => sr(l, e.signName);
|
|
1438
|
+
ce(() => {
|
|
1439
|
+
u.value = F(Y(n.value, (l) => {
|
|
1440
|
+
var g;
|
|
1441
|
+
return e.useSelectedStatus && Xe(d, l.dataIndex) ? d[l.dataIndex] : ((g = S(l)) == null ? void 0 : g.initShow) !== !1;
|
|
1442
|
+
}), (l) => l.dataIndex);
|
|
1443
|
+
}, n), xt(() => {
|
|
1444
|
+
var l;
|
|
1445
|
+
s(), h(), (l = e.onColumnSelectChange) == null || l.call(e, u.value);
|
|
1377
1446
|
}, u);
|
|
1378
|
-
const
|
|
1379
|
-
const
|
|
1447
|
+
const p = O(() => {
|
|
1448
|
+
const l = Pn(n.value, (E) => {
|
|
1380
1449
|
var I;
|
|
1381
|
-
return (I = S(
|
|
1382
|
-
}),
|
|
1450
|
+
return (I = S(E)) != null && I.disabled ? !0 : m(f.value, E.dataIndex);
|
|
1451
|
+
}), g = ye(n.value, (E) => {
|
|
1383
1452
|
var I;
|
|
1384
|
-
return (I = S(
|
|
1453
|
+
return (I = S(E)) != null && I.disabled ? !0 : m(f.value, E.dataIndex);
|
|
1385
1454
|
});
|
|
1386
1455
|
return {
|
|
1387
|
-
checked:
|
|
1388
|
-
indeterminate:
|
|
1456
|
+
checked: l,
|
|
1457
|
+
indeterminate: l ? !1 : g
|
|
1389
1458
|
};
|
|
1390
|
-
}),
|
|
1391
|
-
var
|
|
1392
|
-
(
|
|
1393
|
-
var
|
|
1394
|
-
return (
|
|
1459
|
+
}), v = (l) => {
|
|
1460
|
+
var E;
|
|
1461
|
+
(Me(l) ? (E = l.target) == null ? void 0 : E.checked : l) ? u.value = F(n.value, (I) => I.dataIndex) : u.value = F(Y(n.value, (I) => {
|
|
1462
|
+
var M;
|
|
1463
|
+
return (M = S(I)) != null && M.disabled ? !0 : (y(I.dataIndex), !1);
|
|
1395
1464
|
}), (I) => I.dataIndex);
|
|
1396
1465
|
}, T = () => {
|
|
1397
|
-
u.value = F(Y(n.value, (
|
|
1398
|
-
var
|
|
1399
|
-
return ((
|
|
1400
|
-
}), (
|
|
1401
|
-
},
|
|
1466
|
+
u.value = F(Y(n.value, (l) => {
|
|
1467
|
+
var g;
|
|
1468
|
+
return ((g = S(l)) == null ? void 0 : g.initShow) === !1 ? (y(l.dataIndex), !1) : !0;
|
|
1469
|
+
}), (l) => l.dataIndex);
|
|
1470
|
+
}, N = (l, g) => {
|
|
1402
1471
|
var I;
|
|
1403
|
-
(
|
|
1472
|
+
(Me(g) ? (I = g.target) == null ? void 0 : I.checked : g) ? u.value = [...u.value, l.dataIndex] : u.value = Y(u.value, (M) => l.dataIndex === M ? (y(l.dataIndex), !1) : !0);
|
|
1404
1473
|
};
|
|
1405
|
-
return () => o ?
|
|
1474
|
+
return () => o ? i(o, K({
|
|
1406
1475
|
trigger: "click"
|
|
1407
1476
|
}, e.popoverProps), {
|
|
1408
1477
|
default: () => {
|
|
1409
|
-
var
|
|
1410
|
-
return [((
|
|
1478
|
+
var l, g;
|
|
1479
|
+
return [((l = t.default) == null ? void 0 : l.call(t)) || ((g = e.renderDom) == null ? void 0 : g.call(e))];
|
|
1411
1480
|
},
|
|
1412
|
-
content: () =>
|
|
1481
|
+
content: () => i("div", {
|
|
1413
1482
|
class: `${e.clsName}`
|
|
1414
|
-
}, [
|
|
1483
|
+
}, [i("div", {
|
|
1415
1484
|
class: `${e.clsName}-header`
|
|
1416
|
-
}, [
|
|
1485
|
+
}, [i(a, {
|
|
1417
1486
|
key: c.value,
|
|
1418
|
-
checked:
|
|
1419
|
-
indeterminate:
|
|
1420
|
-
onChange:
|
|
1487
|
+
checked: p.value.checked,
|
|
1488
|
+
indeterminate: p.value.indeterminate,
|
|
1489
|
+
onChange: v
|
|
1421
1490
|
}, {
|
|
1422
|
-
default: () => [
|
|
1423
|
-
}),
|
|
1491
|
+
default: () => [We("\u5217\u5C55\u793A")]
|
|
1492
|
+
}), i("a", {
|
|
1424
1493
|
onClick: T
|
|
1425
|
-
}, [
|
|
1494
|
+
}, [We("\u91CD\u7F6E")])]), i("div", {
|
|
1426
1495
|
key: c.value,
|
|
1427
1496
|
class: `${e.clsName}-list`
|
|
1428
|
-
}, [F(n.value, (
|
|
1429
|
-
const
|
|
1430
|
-
return
|
|
1431
|
-
checked:
|
|
1432
|
-
disabled:
|
|
1497
|
+
}, [F(n.value, (l) => {
|
|
1498
|
+
const g = S(l), E = m(f.value, l.dataIndex, !1);
|
|
1499
|
+
return i(a, {
|
|
1500
|
+
checked: E,
|
|
1501
|
+
disabled: g == null ? void 0 : g.disabled,
|
|
1433
1502
|
onChange: (I) => {
|
|
1434
|
-
|
|
1503
|
+
N(l, I);
|
|
1435
1504
|
}
|
|
1436
1505
|
}, {
|
|
1437
|
-
default: () => [
|
|
1506
|
+
default: () => [l.title]
|
|
1438
1507
|
});
|
|
1439
1508
|
})])]),
|
|
1440
1509
|
...$(t, "default")
|
|
1441
1510
|
}) : null;
|
|
1442
1511
|
}
|
|
1443
|
-
}),
|
|
1444
|
-
|
|
1445
|
-
},
|
|
1512
|
+
}), on = Symbol("pro-table"), Cr = () => he(on), Er = (e) => {
|
|
1513
|
+
ve(on, e);
|
|
1514
|
+
}, gt = () => ({
|
|
1446
1515
|
clsName: {
|
|
1447
1516
|
type: String,
|
|
1448
1517
|
default: "pro-table"
|
|
@@ -1483,11 +1552,11 @@ const dr = () => ({
|
|
|
1483
1552
|
dataSource: {
|
|
1484
1553
|
type: Array
|
|
1485
1554
|
}
|
|
1486
|
-
}),
|
|
1555
|
+
}), pa = w({
|
|
1487
1556
|
inheritAttrs: !1,
|
|
1488
1557
|
props: {
|
|
1489
|
-
...
|
|
1490
|
-
...
|
|
1558
|
+
...be,
|
|
1559
|
+
...gt()
|
|
1491
1560
|
},
|
|
1492
1561
|
setup: (e, {
|
|
1493
1562
|
slots: t,
|
|
@@ -1496,141 +1565,143 @@ const dr = () => ({
|
|
|
1496
1565
|
}) => {
|
|
1497
1566
|
const {
|
|
1498
1567
|
elementMap: a
|
|
1499
|
-
} =
|
|
1568
|
+
} = ne(), n = e.elementMap || a, u = m(a, U.TableKey), c = () => ({
|
|
1500
1569
|
title: "\u5E8F\u53F7",
|
|
1501
1570
|
dataIndex: "serialNumber",
|
|
1502
1571
|
width: 80,
|
|
1503
1572
|
...e.column,
|
|
1504
|
-
...
|
|
1573
|
+
...Te(e.serialNumber) ? void 0 : e.serialNumber,
|
|
1505
1574
|
customRender: ({
|
|
1506
|
-
index:
|
|
1575
|
+
index: b
|
|
1507
1576
|
}) => {
|
|
1508
|
-
var
|
|
1509
|
-
return ((
|
|
1577
|
+
var P, C;
|
|
1578
|
+
return ((P = e.paginationState) == null ? void 0 : P.page) && ((C = e.paginationState) == null ? void 0 : C.pageSize) ? e.paginationState.pageSize * (e.paginationState.page - 1) + b + 1 : b + 1;
|
|
1510
1579
|
}
|
|
1511
|
-
}),
|
|
1512
|
-
var
|
|
1513
|
-
if (e.operateItemClickMap && e.operateItemClickMap[
|
|
1514
|
-
e.operateItemClickMap[
|
|
1580
|
+
}), s = (b, P) => {
|
|
1581
|
+
var C;
|
|
1582
|
+
if (e.operateItemClickMap && e.operateItemClickMap[P.value]) {
|
|
1583
|
+
e.operateItemClickMap[P.value](b, P);
|
|
1515
1584
|
return;
|
|
1516
1585
|
}
|
|
1517
|
-
(
|
|
1518
|
-
},
|
|
1519
|
-
const
|
|
1520
|
-
...m(e.operateItemState,
|
|
1521
|
-
...
|
|
1522
|
-
...m(
|
|
1586
|
+
(C = P.onClick) == null || C.call(P, b);
|
|
1587
|
+
}, d = fe(t, "operate"), y = () => {
|
|
1588
|
+
const b = e.operate, P = F(b.items, (C) => ({
|
|
1589
|
+
...m(e.operateItemState, C.value),
|
|
1590
|
+
...C,
|
|
1591
|
+
...m(b.itemState, C.value)
|
|
1523
1592
|
}));
|
|
1524
1593
|
return {
|
|
1525
1594
|
...e.column,
|
|
1526
1595
|
title: "\u64CD\u4F5C",
|
|
1527
1596
|
dataIndex: "operate",
|
|
1528
1597
|
fixed: "right",
|
|
1529
|
-
...
|
|
1598
|
+
...b.column,
|
|
1530
1599
|
customRender: ({
|
|
1531
|
-
record:
|
|
1600
|
+
record: C
|
|
1532
1601
|
}) => {
|
|
1533
|
-
const L = F(
|
|
1534
|
-
...
|
|
1535
|
-
show:
|
|
1536
|
-
disabled:
|
|
1537
|
-
loading:
|
|
1538
|
-
extraProps:
|
|
1539
|
-
element:
|
|
1540
|
-
onClick: () =>
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1602
|
+
const L = F(P, (k) => ({
|
|
1603
|
+
...k,
|
|
1604
|
+
show: V(k.show) ? k.show(C) : k.show,
|
|
1605
|
+
disabled: V(k.disabled) ? k.disabled(C) : k.disabled,
|
|
1606
|
+
loading: V(k.loading) ? k.loading(C) : k.loading,
|
|
1607
|
+
extraProps: V(k.extraProps) ? k.extraProps(C) : k.extraProps,
|
|
1608
|
+
element: V(k.element) ? (se) => k.element(C, se) : k.element,
|
|
1609
|
+
onClick: () => s(C, k),
|
|
1610
|
+
tip: V(k.tip) ? k.tip(C) : k.tip,
|
|
1611
|
+
tipProps: V(k.tipProps) ? k.tipProps(C) : k.tipProps
|
|
1612
|
+
})), Z = ae(W(d), (k, se) => ({
|
|
1613
|
+
...k,
|
|
1614
|
+
[se]: (A) => {
|
|
1615
|
+
var x;
|
|
1616
|
+
return (x = d[se]) == null ? void 0 : x.call(d, C, A);
|
|
1546
1617
|
}
|
|
1547
1618
|
}), {});
|
|
1548
|
-
return
|
|
1619
|
+
return i(an, {
|
|
1549
1620
|
class: `${e.clsName}-operate`,
|
|
1550
1621
|
items: L,
|
|
1551
|
-
elementKey:
|
|
1552
|
-
},
|
|
1622
|
+
elementKey: b.elementKey || U.TableOperateKey
|
|
1623
|
+
}, Z);
|
|
1553
1624
|
}
|
|
1554
1625
|
};
|
|
1555
|
-
}, h =
|
|
1556
|
-
var
|
|
1557
|
-
return !!((
|
|
1558
|
-
}), S =
|
|
1626
|
+
}, h = z([]), f = O(() => {
|
|
1627
|
+
var b;
|
|
1628
|
+
return !!((b = e.toolbar) != null && b.columnSetting);
|
|
1629
|
+
}), S = dn(e, "columns"), p = O(() => {
|
|
1559
1630
|
if (!f.value)
|
|
1560
1631
|
return e.columns;
|
|
1561
|
-
const
|
|
1562
|
-
...
|
|
1563
|
-
[
|
|
1632
|
+
const b = ae(h.value, (P, C) => ({
|
|
1633
|
+
...P,
|
|
1634
|
+
[C]: !0
|
|
1564
1635
|
}), {});
|
|
1565
|
-
return Y(e.columns, (
|
|
1566
|
-
}),
|
|
1567
|
-
const
|
|
1636
|
+
return Y(e.columns, (P) => m(b, P.dataIndex));
|
|
1637
|
+
}), v = (b) => F(b, (P) => {
|
|
1638
|
+
const C = {
|
|
1568
1639
|
...e.column,
|
|
1569
|
-
...
|
|
1570
|
-
}, L = e.convertColumn ? e.convertColumn(
|
|
1571
|
-
return
|
|
1572
|
-
value:
|
|
1573
|
-
}) => typeof
|
|
1574
|
-
value:
|
|
1640
|
+
...P
|
|
1641
|
+
}, L = e.convertColumn ? e.convertColumn(C) : C;
|
|
1642
|
+
return P.children && X(P.children) > 0 ? (L.children = v(P.children), L) : (P.customRender || (L.customRender = ({
|
|
1643
|
+
value: Z
|
|
1644
|
+
}) => typeof Z > "u" || Z === null || Z === "" ? e.columnEmptyText : tt(n, P, {
|
|
1645
|
+
value: Z
|
|
1575
1646
|
}, {
|
|
1576
1647
|
render: "tableRender"
|
|
1577
|
-
}) ||
|
|
1648
|
+
}) || Z), L);
|
|
1578
1649
|
}), T = O(() => {
|
|
1579
|
-
const
|
|
1580
|
-
return e.serialNumber &&
|
|
1581
|
-
}),
|
|
1582
|
-
var
|
|
1583
|
-
const
|
|
1584
|
-
return
|
|
1585
|
-
}),
|
|
1586
|
-
|
|
1650
|
+
const b = Ue(p.value, e.columnState, e.columnState2), P = v(b);
|
|
1651
|
+
return e.serialNumber && P.unshift(c()), e.operate && e.operate.items && ye(e.operate.items, (C) => C.show) && P.push(y()), P;
|
|
1652
|
+
}), N = O(() => {
|
|
1653
|
+
var P, C;
|
|
1654
|
+
const b = e.dataSource;
|
|
1655
|
+
return b && (((P = e.mergeOpts) == null ? void 0 : P.rowNames) || ((C = e.mergeOpts) == null ? void 0 : C.colNames)) && An(b, e.mergeOpts), b;
|
|
1656
|
+
}), l = z();
|
|
1657
|
+
Er({
|
|
1587
1658
|
columns: T,
|
|
1588
1659
|
originColumns: S,
|
|
1589
1660
|
selectIdsRef: h,
|
|
1590
|
-
tableRef:
|
|
1661
|
+
tableRef: l,
|
|
1591
1662
|
toolbar: e.toolbar,
|
|
1592
1663
|
...e.provideExtra
|
|
1593
|
-
}), r(
|
|
1594
|
-
const
|
|
1595
|
-
De(
|
|
1596
|
-
const
|
|
1597
|
-
if (
|
|
1598
|
-
const L =
|
|
1599
|
-
|
|
1664
|
+
}), r(Se(e.tableMethods || [], l));
|
|
1665
|
+
const g = z(), E = z(0), I = z(), M = z(!1), R = z(), j = z(!1);
|
|
1666
|
+
De(g, (b) => {
|
|
1667
|
+
const P = m(b, [0, "contentRect"]), C = window.getComputedStyle(g.value);
|
|
1668
|
+
if (P.height && C) {
|
|
1669
|
+
const L = C.getPropertyValue("margin-bottom"), Z = parseInt(L.replace("px", ""));
|
|
1670
|
+
E.value = P.height + Z;
|
|
1600
1671
|
}
|
|
1601
1672
|
}), De(I, () => {
|
|
1602
|
-
|
|
1603
|
-
}), De(
|
|
1604
|
-
|
|
1673
|
+
M.value = !!I.value.innerText;
|
|
1674
|
+
}), De(R, () => {
|
|
1675
|
+
j.value = !!R.value.innerText;
|
|
1605
1676
|
});
|
|
1606
|
-
const
|
|
1677
|
+
const q = O(() => j.value || M.value ? `${e.clsName}-toolbar-valid` : ""), G = W(gt()), J = fe(t, "columnSetting");
|
|
1607
1678
|
return () => {
|
|
1608
|
-
var
|
|
1679
|
+
var P, C;
|
|
1609
1680
|
if (!u)
|
|
1610
1681
|
return null;
|
|
1611
|
-
const
|
|
1612
|
-
return
|
|
1682
|
+
const b = f.value ? i(pr, (P = e.toolbar) == null ? void 0 : P.columnSetting, J) : null;
|
|
1683
|
+
return i("div", K({
|
|
1613
1684
|
class: e.clsName,
|
|
1614
|
-
style: `--pro-table-toolbar-hei: ${
|
|
1615
|
-
},
|
|
1616
|
-
ref:
|
|
1617
|
-
class: `${e.clsName}-toolbar ${
|
|
1618
|
-
}, [
|
|
1685
|
+
style: `--pro-table-toolbar-hei: ${E.value}px`
|
|
1686
|
+
}, H(o, "class")), [i("div", {
|
|
1687
|
+
ref: g,
|
|
1688
|
+
class: `${e.clsName}-toolbar ${q.value}`
|
|
1689
|
+
}, [i("div", {
|
|
1619
1690
|
ref: I,
|
|
1620
1691
|
class: `${e.clsName}-toolbar-start`
|
|
1621
|
-
}, [(
|
|
1622
|
-
ref:
|
|
1692
|
+
}, [(C = t.toolbar) == null ? void 0 : C.call(t)]), i("div", {
|
|
1693
|
+
ref: R,
|
|
1623
1694
|
class: `${e.clsName}-toolbar-extra`
|
|
1624
|
-
}, [t.toolbarExtra ? t.toolbarExtra([
|
|
1625
|
-
ref:
|
|
1626
|
-
}, $(o, "class"), $(e,
|
|
1695
|
+
}, [t.toolbarExtra ? t.toolbarExtra([b]) : i(le, null, [b])])]), i(u, K({
|
|
1696
|
+
ref: l
|
|
1697
|
+
}, $(o, "class"), $(e, G), {
|
|
1627
1698
|
mergeOpts: e.mergeOpts,
|
|
1628
|
-
dataSource:
|
|
1699
|
+
dataSource: N.value,
|
|
1629
1700
|
columns: T.value
|
|
1630
1701
|
}), t)]);
|
|
1631
1702
|
};
|
|
1632
1703
|
}
|
|
1633
|
-
}),
|
|
1704
|
+
}), Mr = () => ({
|
|
1634
1705
|
title: {
|
|
1635
1706
|
type: String
|
|
1636
1707
|
},
|
|
@@ -1649,14 +1720,14 @@ const dr = () => ({
|
|
|
1649
1720
|
type: Function,
|
|
1650
1721
|
default: () => "\u8FD4\u56DE"
|
|
1651
1722
|
}
|
|
1652
|
-
}),
|
|
1723
|
+
}), Ve = w({
|
|
1653
1724
|
props: {
|
|
1654
|
-
...
|
|
1725
|
+
...Mr()
|
|
1655
1726
|
},
|
|
1656
1727
|
setup: (e, {
|
|
1657
1728
|
slots: t
|
|
1658
1729
|
}) => {
|
|
1659
|
-
const r =
|
|
1730
|
+
const r = Qe(), o = () => {
|
|
1660
1731
|
var a;
|
|
1661
1732
|
if (e.onBackClick) {
|
|
1662
1733
|
(a = e.onBackClick) == null || a.call(e);
|
|
@@ -1665,25 +1736,25 @@ const dr = () => ({
|
|
|
1665
1736
|
r.back();
|
|
1666
1737
|
};
|
|
1667
1738
|
return () => {
|
|
1668
|
-
var n, u, c,
|
|
1739
|
+
var n, u, c, s, d;
|
|
1669
1740
|
const a = e.hideWhileNoHistory && ((u = (n = window.history) == null ? void 0 : n.state) == null ? void 0 : u.back) || e.hideWhileNoHistory === !1;
|
|
1670
|
-
return
|
|
1741
|
+
return i("div", {
|
|
1671
1742
|
class: "pro-page-header"
|
|
1672
|
-
}, [e.showBack && a &&
|
|
1743
|
+
}, [e.showBack && a && i("div", {
|
|
1673
1744
|
class: "pro-page-header-back",
|
|
1674
1745
|
onClick: o
|
|
1675
|
-
}, [t.backIcon ? t.backIcon() : (c = e.renderBackIcon) == null ? void 0 : c.call(e)]),
|
|
1746
|
+
}, [t.backIcon ? t.backIcon() : (c = e.renderBackIcon) == null ? void 0 : c.call(e)]), i("div", {
|
|
1676
1747
|
class: "pro-page-header-title"
|
|
1677
|
-
}, [t.title ? t.title() : e.title]),
|
|
1748
|
+
}, [t.title ? t.title() : e.title]), i("div", {
|
|
1678
1749
|
class: "pro-page-header-sub-title"
|
|
1679
|
-
}, [t.subTitle ? t.subTitle() : e.subTitle]),
|
|
1750
|
+
}, [t.subTitle ? t.subTitle() : e.subTitle]), i("div", {
|
|
1680
1751
|
class: "pro-page-header-space"
|
|
1681
|
-
}, [(
|
|
1752
|
+
}, [(s = t.space) == null ? void 0 : s.call(t)]), i("div", {
|
|
1682
1753
|
class: "pro-page-header-extra"
|
|
1683
|
-
}, [(
|
|
1754
|
+
}, [(d = t.extra) == null ? void 0 : d.call(t)])]);
|
|
1684
1755
|
};
|
|
1685
1756
|
}
|
|
1686
|
-
}),
|
|
1757
|
+
}), Tr = () => ({
|
|
1687
1758
|
loading: {
|
|
1688
1759
|
type: Boolean,
|
|
1689
1760
|
default: !1
|
|
@@ -1696,42 +1767,42 @@ const dr = () => ({
|
|
|
1696
1767
|
as: {
|
|
1697
1768
|
type: String
|
|
1698
1769
|
}
|
|
1699
|
-
}),
|
|
1770
|
+
}), Ca = w({
|
|
1700
1771
|
props: {
|
|
1701
|
-
...
|
|
1702
|
-
...
|
|
1772
|
+
...Ve.props,
|
|
1773
|
+
...Tr()
|
|
1703
1774
|
},
|
|
1704
1775
|
setup: (e, {
|
|
1705
1776
|
slots: t
|
|
1706
1777
|
}) => {
|
|
1707
|
-
const r = Q(), o = r(
|
|
1778
|
+
const r = Q(), o = r(U.LoadingKey), a = e.as || r(U.ScrollKey) || "div", n = () => o ? i(o, K({
|
|
1708
1779
|
loading: !0
|
|
1709
1780
|
}, e.loadingOpts), {
|
|
1710
|
-
default: () => [
|
|
1781
|
+
default: () => [i("div", {
|
|
1711
1782
|
class: "pro-loading-dom"
|
|
1712
1783
|
}, null)]
|
|
1713
|
-
}) : null, u =
|
|
1784
|
+
}) : null, u = W(Ve.props);
|
|
1714
1785
|
return () => {
|
|
1715
|
-
var
|
|
1716
|
-
const c = e.title || t.title || e.subTitle || t.subTitle || t.extra,
|
|
1717
|
-
return d(a, {
|
|
1718
|
-
class:
|
|
1786
|
+
var h;
|
|
1787
|
+
const c = e.title || t.title || e.subTitle || t.subTitle || t.extra, s = (h = t.footer) == null ? void 0 : h.call(t), d = !e.loading && xe(s), y = ["pro-page"];
|
|
1788
|
+
return e.fillMode && y.push("pro-page-fill"), c && y.push("has-header"), d && y.push("has-footer"), i(a, {
|
|
1789
|
+
class: y
|
|
1719
1790
|
}, {
|
|
1720
1791
|
default: () => {
|
|
1721
|
-
var
|
|
1722
|
-
return [(
|
|
1792
|
+
var f, S;
|
|
1793
|
+
return [(f = t.start) == null ? void 0 : f.call(t), c && i(Ve, H(e, u), $(t, "start", "default", "footer")), i("div", {
|
|
1723
1794
|
class: "pro-page-content"
|
|
1724
|
-
}, [e.loading ? n() : (
|
|
1795
|
+
}, [e.loading ? n() : (S = t.default) == null ? void 0 : S.call(t)]), d && i("div", {
|
|
1725
1796
|
class: "pro-page-footer"
|
|
1726
|
-
}, [
|
|
1797
|
+
}, [s])];
|
|
1727
1798
|
}
|
|
1728
1799
|
});
|
|
1729
1800
|
};
|
|
1730
1801
|
}
|
|
1731
|
-
}),
|
|
1802
|
+
}), Ir = Object.freeze({
|
|
1732
1803
|
page: 1,
|
|
1733
1804
|
pageSize: 10
|
|
1734
|
-
}),
|
|
1805
|
+
}), Nr = () => ({
|
|
1735
1806
|
clsName: {
|
|
1736
1807
|
type: String,
|
|
1737
1808
|
default: "pro-list"
|
|
@@ -1765,43 +1836,43 @@ const dr = () => ({
|
|
|
1765
1836
|
end: {
|
|
1766
1837
|
type: Function
|
|
1767
1838
|
}
|
|
1768
|
-
}),
|
|
1839
|
+
}), Or = w({
|
|
1769
1840
|
props: {
|
|
1770
|
-
...
|
|
1841
|
+
...Nr()
|
|
1771
1842
|
},
|
|
1772
1843
|
setup: (e, {
|
|
1773
1844
|
slots: t,
|
|
1774
1845
|
emit: r
|
|
1775
1846
|
}) => {
|
|
1776
|
-
const o = Q(), a = o(
|
|
1777
|
-
...
|
|
1847
|
+
const o = Q(), a = o(U.ProSearchFormKey), n = o(U.ProTableKey), u = o(U.PaginationKey), c = e.pageState || Ae({
|
|
1848
|
+
...Ir
|
|
1778
1849
|
});
|
|
1779
|
-
let
|
|
1780
|
-
const
|
|
1850
|
+
let s;
|
|
1851
|
+
const d = () => {
|
|
1781
1852
|
r("search", {
|
|
1782
|
-
...
|
|
1853
|
+
...s,
|
|
1783
1854
|
...c
|
|
1784
1855
|
});
|
|
1785
|
-
},
|
|
1786
|
-
|
|
1787
|
-
}, h = (
|
|
1788
|
-
c.page =
|
|
1789
|
-
}, f =
|
|
1856
|
+
}, y = (v, T) => {
|
|
1857
|
+
s = v, c.page = T || 1, d();
|
|
1858
|
+
}, h = (v, T) => {
|
|
1859
|
+
c.page = v, c.pageSize = T, d();
|
|
1860
|
+
}, f = fe(t, "search"), S = fe(t, "table"), p = fe(t, "pagination");
|
|
1790
1861
|
return () => {
|
|
1791
|
-
var T,
|
|
1792
|
-
const
|
|
1793
|
-
executeSearchWithResetPage:
|
|
1862
|
+
var T, N, l, g, E, I, M, R;
|
|
1863
|
+
const v = t.search ? t.search({
|
|
1864
|
+
executeSearchWithResetPage: y,
|
|
1794
1865
|
pageState: c
|
|
1795
|
-
}) :
|
|
1866
|
+
}) : i(le, null, [a && i(a, K({
|
|
1796
1867
|
class: `${e.clsName}-search`
|
|
1797
1868
|
}, $(e.searchProps, "onFinish"), {
|
|
1798
|
-
onFinish: (
|
|
1869
|
+
onFinish: (j) => y(j)
|
|
1799
1870
|
}), f)]);
|
|
1800
|
-
return
|
|
1871
|
+
return i("div", {
|
|
1801
1872
|
class: e.clsName
|
|
1802
|
-
}, [((T = t.start) == null ? void 0 : T.call(t)) || ((
|
|
1873
|
+
}, [((T = t.start) == null ? void 0 : T.call(t)) || ((N = e.start) == null ? void 0 : N.call(e)), !e.searchInTable && v, ((l = t.divide) == null ? void 0 : l.call(t)) || ((g = e.divide) == null ? void 0 : g.call(e)), t.table ? t.table({
|
|
1803
1874
|
pageState: c
|
|
1804
|
-
}) :
|
|
1875
|
+
}) : i(le, null, [n && i(n, K({
|
|
1805
1876
|
class: `${e.clsName}-table`,
|
|
1806
1877
|
paginationState: {
|
|
1807
1878
|
page: c.page,
|
|
@@ -1810,20 +1881,20 @@ const dr = () => ({
|
|
|
1810
1881
|
pagination: !1
|
|
1811
1882
|
}, e.tableProps), {
|
|
1812
1883
|
...S,
|
|
1813
|
-
toolbar: e.searchInTable ? () => S.toolbar ? S.toolbar(
|
|
1814
|
-
})]), ((
|
|
1884
|
+
toolbar: e.searchInTable ? () => S.toolbar ? S.toolbar(v) : v : S.toolbar
|
|
1885
|
+
})]), ((E = t.divide2) == null ? void 0 : E.call(t)) || ((I = e.divide2) == null ? void 0 : I.call(e)), t.pagination ? t.pagination({
|
|
1815
1886
|
executePageChange: h,
|
|
1816
1887
|
pageState: c
|
|
1817
|
-
}) :
|
|
1888
|
+
}) : i(le, null, [e.paginationProps !== !1 && u && i("div", {
|
|
1818
1889
|
class: `${e.clsName}-pagination`
|
|
1819
|
-
}, [
|
|
1890
|
+
}, [i(u, K($(Te(e.paginationProps) ? {} : e.paginationProps, "onChange"), {
|
|
1820
1891
|
page: c.page,
|
|
1821
1892
|
pageSize: c.pageSize,
|
|
1822
1893
|
onComposeChange: h
|
|
1823
|
-
}),
|
|
1894
|
+
}), p)])]), ((M = t.end) == null ? void 0 : M.call(t)) || ((R = e.end) == null ? void 0 : R.call(e))]);
|
|
1824
1895
|
};
|
|
1825
1896
|
}
|
|
1826
|
-
}),
|
|
1897
|
+
}), St = () => ({
|
|
1827
1898
|
clsName: {
|
|
1828
1899
|
type: String,
|
|
1829
1900
|
default: "pro-desc"
|
|
@@ -1831,38 +1902,38 @@ const dr = () => ({
|
|
|
1831
1902
|
model: {
|
|
1832
1903
|
type: Object
|
|
1833
1904
|
}
|
|
1834
|
-
}),
|
|
1905
|
+
}), Ar = w({
|
|
1835
1906
|
props: {
|
|
1836
|
-
...
|
|
1837
|
-
...
|
|
1907
|
+
...be,
|
|
1908
|
+
...St()
|
|
1838
1909
|
},
|
|
1839
1910
|
setup: (e, {
|
|
1840
1911
|
slots: t
|
|
1841
1912
|
}) => {
|
|
1842
1913
|
const {
|
|
1843
1914
|
elementMap: r
|
|
1844
|
-
} =
|
|
1845
|
-
return () => !n || !u ? null :
|
|
1915
|
+
} = ne(), o = e.elementMap || r, a = Q(), n = a(U.DescriptionsKey), u = a(U.DescriptionsItemKey), c = O(() => Ue(e.columns, e.columnState, e.columnState2)), s = W(be), d = W(St());
|
|
1916
|
+
return () => !n || !u ? null : i(n, K({
|
|
1846
1917
|
class: e.clsName
|
|
1847
|
-
}, $(e, ...
|
|
1918
|
+
}, $(e, ...s, ...d, "model")), {
|
|
1848
1919
|
default: () => {
|
|
1849
|
-
var
|
|
1850
|
-
return [(
|
|
1851
|
-
const S = f.dataIndex,
|
|
1852
|
-
return
|
|
1920
|
+
var y, h;
|
|
1921
|
+
return [(y = t.start) == null ? void 0 : y.call(t), F(c.value, (f) => {
|
|
1922
|
+
const S = f.dataIndex, p = m(e.model, S);
|
|
1923
|
+
return i(u, K({
|
|
1853
1924
|
class: `${e.clsName}-item`
|
|
1854
1925
|
}, m(f.extra, "desc")), {
|
|
1855
1926
|
default: () => {
|
|
1856
|
-
var
|
|
1857
|
-
return [((
|
|
1858
|
-
value:
|
|
1927
|
+
var v, T;
|
|
1928
|
+
return [((v = t[S]) == null ? void 0 : v.call(t, p, f)) || ((T = t.value) == null ? void 0 : T.call(t, p, f)) || tt(o, f, {
|
|
1929
|
+
value: p
|
|
1859
1930
|
}, {
|
|
1860
1931
|
render: "descRender"
|
|
1861
1932
|
})];
|
|
1862
1933
|
},
|
|
1863
1934
|
label: () => {
|
|
1864
|
-
var
|
|
1865
|
-
return ((
|
|
1935
|
+
var v;
|
|
1936
|
+
return ((v = t.label) == null ? void 0 : v.call(t, f)) || f.title;
|
|
1866
1937
|
}
|
|
1867
1938
|
});
|
|
1868
1939
|
}), (h = t.default) == null ? void 0 : h.call(t)];
|
|
@@ -1870,38 +1941,53 @@ const dr = () => ({
|
|
|
1870
1941
|
...t
|
|
1871
1942
|
});
|
|
1872
1943
|
}
|
|
1873
|
-
}),
|
|
1944
|
+
}), un = (e, t) => _e(e) ? e : e || t, $r = () => ({
|
|
1945
|
+
value: {
|
|
1946
|
+
type: [String, Number]
|
|
1947
|
+
},
|
|
1948
|
+
emptyText: {
|
|
1949
|
+
type: String
|
|
1950
|
+
}
|
|
1951
|
+
}), Ea = w({
|
|
1952
|
+
props: {
|
|
1953
|
+
...$r()
|
|
1954
|
+
},
|
|
1955
|
+
setup: (e) => () => un(e.value, e.emptyText)
|
|
1956
|
+
}), wr = () => ({
|
|
1874
1957
|
content: {
|
|
1875
1958
|
type: [String, Number]
|
|
1876
1959
|
},
|
|
1877
1960
|
ellipsis: {
|
|
1878
1961
|
type: [Object, Boolean]
|
|
1879
1962
|
},
|
|
1880
|
-
popoverProps: Object
|
|
1881
|
-
|
|
1963
|
+
popoverProps: Object,
|
|
1964
|
+
emptyText: {
|
|
1965
|
+
type: String
|
|
1966
|
+
}
|
|
1967
|
+
}), Kr = w({
|
|
1882
1968
|
inheritAttrs: !1,
|
|
1883
1969
|
props: {
|
|
1884
|
-
...
|
|
1970
|
+
...wr()
|
|
1885
1971
|
},
|
|
1886
1972
|
setup: (e, {
|
|
1887
1973
|
attrs: t
|
|
1888
1974
|
}) => {
|
|
1889
|
-
const o = Q()(
|
|
1975
|
+
const o = Q()(U.PopoverKey), a = () => {
|
|
1890
1976
|
var n, u;
|
|
1891
1977
|
return e.ellipsis ? e.ellipsis === !0 ? 1 : ((n = e.ellipsis) == null ? void 0 : n.rows) || ((u = e.ellipsis) == null ? void 0 : u.num) || 1 : "unset";
|
|
1892
1978
|
};
|
|
1893
1979
|
return () => {
|
|
1894
|
-
const n =
|
|
1980
|
+
const n = i("span", K({
|
|
1895
1981
|
class: `pro-typography ${e.ellipsis ? "pro-typography-ellipsis" : ""}`,
|
|
1896
1982
|
style: `-webkit-line-clamp:${a()}`
|
|
1897
|
-
}, t), [e.content]);
|
|
1898
|
-
return !e.popoverProps || !o ? n :
|
|
1983
|
+
}, t), [un(e.content, e.emptyText)]);
|
|
1984
|
+
return !e.popoverProps || !o ? n : i(o, e.popoverProps, {
|
|
1899
1985
|
default: () => [n],
|
|
1900
1986
|
content: () => e.content
|
|
1901
1987
|
});
|
|
1902
1988
|
};
|
|
1903
1989
|
}
|
|
1904
|
-
}),
|
|
1990
|
+
}), we = {
|
|
1905
1991
|
value: {
|
|
1906
1992
|
type: [String, Number]
|
|
1907
1993
|
},
|
|
@@ -1911,27 +1997,27 @@ const dr = () => ({
|
|
|
1911
1997
|
convert: {
|
|
1912
1998
|
type: Function
|
|
1913
1999
|
}
|
|
1914
|
-
},
|
|
2000
|
+
}, Be = w({
|
|
1915
2001
|
inheritAttrs: !1,
|
|
1916
2002
|
props: {
|
|
1917
|
-
|
|
2003
|
+
...we
|
|
1918
2004
|
},
|
|
1919
2005
|
setup: (e, {
|
|
1920
2006
|
attrs: t
|
|
1921
2007
|
}) => {
|
|
1922
2008
|
const r = O(() => {
|
|
1923
2009
|
var n;
|
|
1924
|
-
const o = (n = e.showProps) == null ? void 0 : n.content, a = e.value ||
|
|
2010
|
+
const o = (n = e.showProps) == null ? void 0 : n.content, a = e.value || _e(e.value) ? e.value : o;
|
|
1925
2011
|
return e.convert ? e.convert(a, e) : a;
|
|
1926
2012
|
});
|
|
1927
|
-
return () =>
|
|
2013
|
+
return () => i(Kr, K(H(t, "style", "class"), $(e.showProps, "content"), {
|
|
1928
2014
|
content: r.value
|
|
1929
2015
|
}), null);
|
|
1930
2016
|
}
|
|
1931
|
-
}),
|
|
2017
|
+
}), Ma = w({
|
|
1932
2018
|
inheritAttrs: !1,
|
|
1933
2019
|
props: {
|
|
1934
|
-
|
|
2020
|
+
...we,
|
|
1935
2021
|
decimalFixed: {
|
|
1936
2022
|
type: Number,
|
|
1937
2023
|
default: 0
|
|
@@ -1946,17 +2032,17 @@ const dr = () => ({
|
|
|
1946
2032
|
}) => {
|
|
1947
2033
|
const r = O(() => {
|
|
1948
2034
|
let o = e.value;
|
|
1949
|
-
return o && e.decimalFixed && (o =
|
|
2035
|
+
return o && e.decimalFixed && (o = $n(o, e.decimalFixed || 2)), o && e.thousandDivision && (o = wn(o)), e.convert ? e.convert(o, e) : o;
|
|
1950
2036
|
});
|
|
1951
|
-
return () =>
|
|
2037
|
+
return () => i(Be, K(H(t, "style", "class"), {
|
|
1952
2038
|
value: r.value,
|
|
1953
2039
|
showProps: e.showProps
|
|
1954
2040
|
}), null);
|
|
1955
2041
|
}
|
|
1956
|
-
}),
|
|
2042
|
+
}), Ta = w({
|
|
1957
2043
|
inheritAttrs: !1,
|
|
1958
2044
|
props: {
|
|
1959
|
-
|
|
2045
|
+
...we,
|
|
1960
2046
|
value: {
|
|
1961
2047
|
type: [String, Number, Array]
|
|
1962
2048
|
},
|
|
@@ -1972,21 +2058,21 @@ const dr = () => ({
|
|
|
1972
2058
|
setup: (e, {
|
|
1973
2059
|
attrs: t
|
|
1974
2060
|
}) => {
|
|
1975
|
-
const r = O(() =>
|
|
2061
|
+
const r = O(() => Kn(e.options, (n) => n.label), void 0), o = O(() => {
|
|
1976
2062
|
const n = e.value;
|
|
1977
2063
|
let u = e.value;
|
|
1978
|
-
return _(n) ? u =
|
|
2064
|
+
return _(n) ? u = Ye(F(n, (c) => m(r.value, c, c)), e.splitStr) : u = m(r.value, n, e.value), e.convert ? e.convert(u, e) : u;
|
|
1979
2065
|
}), a = O(() => m(e.colorMap, e.value));
|
|
1980
|
-
return () =>
|
|
2066
|
+
return () => i(Be, K(H(t, "style", "class"), {
|
|
1981
2067
|
style: `color:${a.value || ""}`,
|
|
1982
2068
|
value: o.value,
|
|
1983
2069
|
showProps: e.showProps
|
|
1984
2070
|
}), null);
|
|
1985
2071
|
}
|
|
1986
|
-
}),
|
|
2072
|
+
}), Ia = w({
|
|
1987
2073
|
inheritAttrs: !1,
|
|
1988
2074
|
props: {
|
|
1989
|
-
|
|
2075
|
+
...we,
|
|
1990
2076
|
value: {
|
|
1991
2077
|
type: [String, Number, Array]
|
|
1992
2078
|
},
|
|
@@ -2005,23 +2091,23 @@ const dr = () => ({
|
|
|
2005
2091
|
}) => {
|
|
2006
2092
|
const r = O(() => {
|
|
2007
2093
|
const a = e.treeData || e.data || e.options, n = e.fieldNames || e.props;
|
|
2008
|
-
return
|
|
2094
|
+
return Dn(a, (u) => m(u, (n == null ? void 0 : n.label) || "label"), {
|
|
2009
2095
|
value: "value",
|
|
2010
2096
|
children: "children",
|
|
2011
2097
|
...n
|
|
2012
2098
|
});
|
|
2013
2099
|
}), o = O(() => {
|
|
2014
2100
|
let a = e.value;
|
|
2015
|
-
return _(e.value) ? a =
|
|
2101
|
+
return _(e.value) ? a = Ye(F(e.value, (n) => m(r.value, n, n)), e.splitStr) : a = m(r.value, e.value, e.value), e.convert ? e.convert(a, e) : a;
|
|
2016
2102
|
});
|
|
2017
|
-
return () =>
|
|
2103
|
+
return () => i(Be, K(H(t, "style", "class"), {
|
|
2018
2104
|
value: o.value,
|
|
2019
2105
|
showProps: e.showProps
|
|
2020
2106
|
}), null);
|
|
2021
2107
|
}
|
|
2022
|
-
}),
|
|
2108
|
+
}), Na = w({
|
|
2023
2109
|
props: {
|
|
2024
|
-
|
|
2110
|
+
...we,
|
|
2025
2111
|
value: {
|
|
2026
2112
|
type: [String, Number, Array]
|
|
2027
2113
|
},
|
|
@@ -2041,31 +2127,31 @@ const dr = () => ({
|
|
|
2041
2127
|
setup: (e, {
|
|
2042
2128
|
attrs: t
|
|
2043
2129
|
}) => {
|
|
2044
|
-
const r = (a) => a && (e.isUnix ?
|
|
2130
|
+
const r = (a) => a && (e.isUnix ? mt.unix(a).format(e.format) : mt(a).format(e.format)), o = O(() => {
|
|
2045
2131
|
let a = e.value;
|
|
2046
|
-
return _(e.value) ? a =
|
|
2132
|
+
return _(e.value) ? a = Ye(F(e.value, (n) => r(n) || ""), e.splitStr) : a = r(e.value) || "", e.convert ? e.convert(a, e) : a;
|
|
2047
2133
|
});
|
|
2048
|
-
return () =>
|
|
2134
|
+
return () => i(Be, K(H(t, "style", "class"), {
|
|
2049
2135
|
value: o.value,
|
|
2050
2136
|
showProps: e.showProps
|
|
2051
2137
|
}), null);
|
|
2052
2138
|
}
|
|
2053
|
-
}),
|
|
2139
|
+
}), Ke = w((e, {
|
|
2054
2140
|
slots: t
|
|
2055
2141
|
}) => {
|
|
2056
|
-
const r =
|
|
2142
|
+
const r = z(), o = z(0);
|
|
2057
2143
|
return De(r, (a) => {
|
|
2058
2144
|
var u;
|
|
2059
2145
|
const n = (u = a[0]) == null ? void 0 : u.contentRect;
|
|
2060
2146
|
o.value = n == null ? void 0 : n.width;
|
|
2061
2147
|
}), () => {
|
|
2062
2148
|
var a, n, u;
|
|
2063
|
-
return
|
|
2149
|
+
return i("header", null, [(a = t.start) == null ? void 0 : a.call(t), t.menus && i("div", {
|
|
2064
2150
|
ref: r,
|
|
2065
2151
|
class: "pro-header-menus-wrapper"
|
|
2066
2152
|
}, [t.menus(o.value)]), (n = t.default) == null ? void 0 : n.call(t), (u = t.end) == null ? void 0 : u.call(t)]);
|
|
2067
2153
|
};
|
|
2068
|
-
}),
|
|
2154
|
+
}), Dr = () => ({
|
|
2069
2155
|
clsName: {
|
|
2070
2156
|
type: String,
|
|
2071
2157
|
default: "pro-layout"
|
|
@@ -2103,118 +2189,118 @@ const dr = () => ({
|
|
|
2103
2189
|
menuProps: {
|
|
2104
2190
|
type: Object
|
|
2105
2191
|
}
|
|
2106
|
-
}),
|
|
2192
|
+
}), Oa = w({
|
|
2107
2193
|
inheritAttrs: !1,
|
|
2108
2194
|
props: {
|
|
2109
|
-
...
|
|
2195
|
+
...Dr()
|
|
2110
2196
|
},
|
|
2111
2197
|
setup: (e, {
|
|
2112
2198
|
slots: t,
|
|
2113
2199
|
attrs: r
|
|
2114
2200
|
}) => {
|
|
2115
|
-
const o = Q(), a = o(
|
|
2201
|
+
const o = Q(), a = o(U.MenusKey), n = o(U.ScrollKey) || "div", {
|
|
2116
2202
|
router: u,
|
|
2117
2203
|
route: c
|
|
2118
|
-
} =
|
|
2119
|
-
var
|
|
2120
|
-
return
|
|
2121
|
-
var
|
|
2122
|
-
const
|
|
2204
|
+
} = qt(), s = O(() => {
|
|
2205
|
+
var l;
|
|
2206
|
+
return Ft(e.menus, (g) => {
|
|
2207
|
+
var M, R;
|
|
2208
|
+
const E = ((M = e.fieldNames) == null ? void 0 : M.value) || "value", I = ((R = e.fieldNames) == null ? void 0 : R.label) || "label";
|
|
2123
2209
|
return {
|
|
2124
|
-
...$(
|
|
2125
|
-
value: m(
|
|
2126
|
-
label: m(
|
|
2210
|
+
...$(g, E, I),
|
|
2211
|
+
value: m(g, E),
|
|
2212
|
+
label: m(g, I)
|
|
2127
2213
|
};
|
|
2128
2214
|
}, {
|
|
2129
|
-
children: ((
|
|
2215
|
+
children: ((l = e.fieldNames) == null ? void 0 : l.children) || "children",
|
|
2130
2216
|
childrenName: "children"
|
|
2131
2217
|
});
|
|
2132
|
-
}),
|
|
2218
|
+
}), d = O(() => Fn(s.value)), y = O(() => {
|
|
2133
2219
|
if (e.findCurrentTopName)
|
|
2134
|
-
return e.findCurrentTopName(c,
|
|
2135
|
-
const
|
|
2136
|
-
if (
|
|
2137
|
-
return m(
|
|
2138
|
-
}), h = O(() =>
|
|
2220
|
+
return e.findCurrentTopName(c, d.value);
|
|
2221
|
+
const l = pn(c.matched, (g) => !!m(d.value, g.name));
|
|
2222
|
+
if (l)
|
|
2223
|
+
return m(d.value, l.name);
|
|
2224
|
+
}), h = O(() => y.value ? it(s.value, (l) => l.value === y.value).target : null), f = O(() => {
|
|
2139
2225
|
if (e.findActiveKey)
|
|
2140
|
-
return e.findActiveKey(c,
|
|
2141
|
-
if (c.name && m(
|
|
2226
|
+
return e.findActiveKey(c, d.value);
|
|
2227
|
+
if (c.name && m(d.value, c.name))
|
|
2142
2228
|
return c.name;
|
|
2143
|
-
}), S = (
|
|
2144
|
-
e.onMenuItemClick ? e.onMenuItemClick(
|
|
2145
|
-
},
|
|
2146
|
-
const
|
|
2147
|
-
S(
|
|
2148
|
-
},
|
|
2149
|
-
var
|
|
2150
|
-
return
|
|
2229
|
+
}), S = (l) => {
|
|
2230
|
+
e.onMenuItemClick ? e.onMenuItemClick(l) : u.openMenu(l);
|
|
2231
|
+
}, p = (l) => {
|
|
2232
|
+
const g = it(s.value, (E) => E.value === l.value).target;
|
|
2233
|
+
S(g);
|
|
2234
|
+
}, v = fe(t, "header"), T = fe(t, "menu"), N = (l) => {
|
|
2235
|
+
var g, E;
|
|
2236
|
+
return i("div", {
|
|
2151
2237
|
class: `${e.clsName}-menus-wrapper`
|
|
2152
|
-
}, [(
|
|
2238
|
+
}, [(g = T.start) == null ? void 0 : g.call(T), i(n, {
|
|
2153
2239
|
class: `${e.clsName}-menus-scroll`
|
|
2154
2240
|
}, {
|
|
2155
|
-
default: () => [
|
|
2156
|
-
}), (
|
|
2241
|
+
default: () => [i(a, l, T)]
|
|
2242
|
+
}), (E = T.end) == null ? void 0 : E.call(T)]);
|
|
2157
2243
|
};
|
|
2158
2244
|
return () => {
|
|
2159
2245
|
var I;
|
|
2160
2246
|
if (!a)
|
|
2161
2247
|
return null;
|
|
2162
|
-
const
|
|
2248
|
+
const l = H(r, "class"), g = {
|
|
2163
2249
|
class: `${e.clsName}-menus`,
|
|
2164
|
-
options:
|
|
2250
|
+
options: s.value,
|
|
2165
2251
|
activeKey: f.value,
|
|
2166
|
-
...
|
|
2252
|
+
...H(e, "convertSubMenuProps", "convertMenuItemProps"),
|
|
2167
2253
|
onMenuItemClick: S,
|
|
2168
2254
|
...e.menuProps
|
|
2169
|
-
},
|
|
2255
|
+
}, E = i("div", {
|
|
2170
2256
|
class: `${e.clsName}-section`
|
|
2171
2257
|
}, [(I = t.default) == null ? void 0 : I.call(t)]);
|
|
2172
|
-
return e.layout === "vertical" ?
|
|
2258
|
+
return e.layout === "vertical" ? i("main", K(l, {
|
|
2173
2259
|
class: `${e.clsName} ${e.clsName}-${e.layout}`
|
|
2174
|
-
}), [
|
|
2260
|
+
}), [i(Ke, {
|
|
2175
2261
|
class: `${e.clsName}-header`
|
|
2176
2262
|
}, {
|
|
2177
|
-
menus: (
|
|
2178
|
-
style: `width:${
|
|
2263
|
+
menus: (M) => M ? i(a, K({
|
|
2264
|
+
style: `width:${M}px`,
|
|
2179
2265
|
mode: "horizontal"
|
|
2180
|
-
},
|
|
2181
|
-
...
|
|
2182
|
-
}),
|
|
2266
|
+
}, g), T) : null,
|
|
2267
|
+
...v
|
|
2268
|
+
}), E]) : e.layout === "horizontal" ? i("main", K(l, {
|
|
2183
2269
|
class: `${e.clsName} ${e.clsName}-${e.layout}`
|
|
2184
|
-
}), [
|
|
2270
|
+
}), [N(g), i("div", {
|
|
2185
2271
|
class: `${e.clsName}-structure`
|
|
2186
|
-
}, [
|
|
2272
|
+
}, [i(Ke, {
|
|
2187
2273
|
class: `${e.clsName}-header`
|
|
2188
|
-
},
|
|
2274
|
+
}, v), E])]) : e.layout === "horizontal-v" ? i("main", K(l, {
|
|
2189
2275
|
class: `${e.clsName} ${e.clsName}-${e.layout}`
|
|
2190
|
-
}), [
|
|
2276
|
+
}), [i(Ke, {
|
|
2191
2277
|
class: `${e.clsName}-header`
|
|
2192
|
-
},
|
|
2278
|
+
}, v), i("div", {
|
|
2193
2279
|
class: `${e.clsName}-structure`
|
|
2194
|
-
}, [
|
|
2280
|
+
}, [N(g), E])]) : i("main", K(l, {
|
|
2195
2281
|
class: `${e.clsName} ${e.clsName}-${e.layout}`
|
|
2196
|
-
}), [
|
|
2282
|
+
}), [i(Ke, {
|
|
2197
2283
|
class: `${e.clsName}-header`
|
|
2198
2284
|
}, {
|
|
2199
|
-
menus: (
|
|
2200
|
-
style: `width:${
|
|
2285
|
+
menus: (M) => M ? i(a, K({
|
|
2286
|
+
style: `width:${M}px`,
|
|
2201
2287
|
class: `${e.clsName}-menus`,
|
|
2202
2288
|
mode: "horizontal",
|
|
2203
|
-
options: F(
|
|
2204
|
-
activeKey:
|
|
2205
|
-
},
|
|
2206
|
-
onMenuItemClick:
|
|
2289
|
+
options: F(s.value, (R) => $(R, "children")),
|
|
2290
|
+
activeKey: y.value
|
|
2291
|
+
}, H(e, "convertSubMenuProps", "convertMenuItemProps"), {
|
|
2292
|
+
onMenuItemClick: p
|
|
2207
2293
|
}), T) : null,
|
|
2208
|
-
...
|
|
2209
|
-
}),
|
|
2294
|
+
...v
|
|
2295
|
+
}), i("div", {
|
|
2210
2296
|
class: `${e.clsName}-structure`
|
|
2211
|
-
}, [h.value && X(h.value.children) > 0 &&
|
|
2212
|
-
...
|
|
2297
|
+
}, [h.value && X(h.value.children) > 0 && N({
|
|
2298
|
+
...g,
|
|
2213
2299
|
options: h.value.children
|
|
2214
|
-
}),
|
|
2300
|
+
}), E])]);
|
|
2215
2301
|
};
|
|
2216
2302
|
}
|
|
2217
|
-
}),
|
|
2303
|
+
}), Aa = w({
|
|
2218
2304
|
props: {
|
|
2219
2305
|
fieldNames: {
|
|
2220
2306
|
type: Object,
|
|
@@ -2232,11 +2318,11 @@ const dr = () => ({
|
|
|
2232
2318
|
slots: t,
|
|
2233
2319
|
emit: r
|
|
2234
2320
|
}) => {
|
|
2235
|
-
const a = Q()(
|
|
2236
|
-
const
|
|
2237
|
-
if (_(
|
|
2321
|
+
const a = Q()(U.UploaderKey), n = (d) => {
|
|
2322
|
+
const y = Rt(d);
|
|
2323
|
+
if (_(y)) {
|
|
2238
2324
|
const h = e.fieldNames;
|
|
2239
|
-
return F(
|
|
2325
|
+
return F(y, (f) => ({
|
|
2240
2326
|
...$(f, h.id, h.name, h.size),
|
|
2241
2327
|
id: m(f, h.id),
|
|
2242
2328
|
name: m(f, h.name),
|
|
@@ -2244,27 +2330,27 @@ const dr = () => ({
|
|
|
2244
2330
|
}));
|
|
2245
2331
|
}
|
|
2246
2332
|
return [];
|
|
2247
|
-
}, u = O(() => n(e.value)), c = O(() => n(e.modelValue)),
|
|
2333
|
+
}, u = O(() => n(e.value)), c = O(() => n(e.modelValue)), s = (d, y) => {
|
|
2248
2334
|
let h = "";
|
|
2249
|
-
|
|
2250
|
-
var
|
|
2251
|
-
const S = e.fieldNames,
|
|
2335
|
+
d && X(d) > 0 && (h = xn(F(d, (f) => {
|
|
2336
|
+
var v;
|
|
2337
|
+
const S = e.fieldNames, p = {
|
|
2252
2338
|
[S.id]: f.id,
|
|
2253
2339
|
[S.name]: f.name,
|
|
2254
2340
|
[S.size || "size"]: f.size
|
|
2255
2341
|
};
|
|
2256
|
-
return ((
|
|
2257
|
-
}))), r(
|
|
2342
|
+
return ((v = e.convertItem) == null ? void 0 : v.call(e, f)) || p;
|
|
2343
|
+
}))), r(y, h);
|
|
2258
2344
|
};
|
|
2259
|
-
return () => a ?
|
|
2345
|
+
return () => a ? i(a, K({
|
|
2260
2346
|
class: "pro-uploader-text",
|
|
2261
2347
|
value: u.value,
|
|
2262
|
-
"onUpdate:value": (
|
|
2348
|
+
"onUpdate:value": (d) => s(d, "update:value"),
|
|
2263
2349
|
modelValue: c.value,
|
|
2264
|
-
"onUpdate:modelValue": (
|
|
2350
|
+
"onUpdate:modelValue": (d) => s(d, "update:modelValue")
|
|
2265
2351
|
}, $(e, "value", "modelValue", "fieldNames")), t) : null;
|
|
2266
2352
|
}
|
|
2267
|
-
}),
|
|
2353
|
+
}), $a = w({
|
|
2268
2354
|
props: {
|
|
2269
2355
|
value: [String, Array],
|
|
2270
2356
|
fieldNames: {
|
|
@@ -2285,14 +2371,14 @@ const dr = () => ({
|
|
|
2285
2371
|
return !!m(u, ((c = e.fieldNames) == null ? void 0 : c.id) || "id");
|
|
2286
2372
|
}, a = O(() => {
|
|
2287
2373
|
let u = e.value;
|
|
2288
|
-
return u &&
|
|
2374
|
+
return u && ue(u) && (u = Rt(u)), u && !_(u) && Me(u) && o(u) && (u = [u]), _(u) ? F(Y(u, (c) => o(c)), (c) => {
|
|
2289
2375
|
var h, f, S;
|
|
2290
|
-
const
|
|
2376
|
+
const s = m(c, ((h = e.fieldNames) == null ? void 0 : h.id) || "id"), d = m(c, ((f = e.fieldNames) == null ? void 0 : f.name) || "name"), y = m(c, ((S = e.fieldNames) == null ? void 0 : S.name) || "size");
|
|
2291
2377
|
return {
|
|
2292
2378
|
...c,
|
|
2293
|
-
id:
|
|
2294
|
-
size:
|
|
2295
|
-
name:
|
|
2379
|
+
id: s,
|
|
2380
|
+
size: y,
|
|
2381
|
+
name: d || s
|
|
2296
2382
|
};
|
|
2297
2383
|
}) : [];
|
|
2298
2384
|
}), n = (u) => {
|
|
@@ -2300,44 +2386,44 @@ const dr = () => ({
|
|
|
2300
2386
|
};
|
|
2301
2387
|
return () => {
|
|
2302
2388
|
var u, c;
|
|
2303
|
-
return
|
|
2389
|
+
return i("div", {
|
|
2304
2390
|
class: "pro-upload-list"
|
|
2305
|
-
}, [(u = t.start) == null ? void 0 : u.call(t), F(a.value, (
|
|
2306
|
-
var
|
|
2307
|
-
return
|
|
2391
|
+
}, [(u = t.start) == null ? void 0 : u.call(t), F(a.value, (s) => {
|
|
2392
|
+
var d;
|
|
2393
|
+
return i("div", {
|
|
2308
2394
|
class: "pro-upload-list-item"
|
|
2309
|
-
}, [
|
|
2395
|
+
}, [i("span", {
|
|
2310
2396
|
class: "pro-upload-list-item-title",
|
|
2311
|
-
onClick: () => n(
|
|
2312
|
-
}, [
|
|
2397
|
+
onClick: () => n(s)
|
|
2398
|
+
}, [s.name]), (d = t.extra) == null ? void 0 : d.call(t, s)]);
|
|
2313
2399
|
}), (c = t.default) == null ? void 0 : c.call(t)]);
|
|
2314
2400
|
};
|
|
2315
2401
|
}
|
|
2316
|
-
}),
|
|
2317
|
-
!e || !t ||
|
|
2318
|
-
const a =
|
|
2319
|
-
if (!
|
|
2402
|
+
}), Fr = (e, t) => {
|
|
2403
|
+
!e || !t || Tt(t) || Ee(e) || te(t, (r, o) => {
|
|
2404
|
+
const a = $t(o, e);
|
|
2405
|
+
if (!wt(a)) {
|
|
2320
2406
|
console.log("ConfigExtra\uFF1A\u8865\u5145\u5BF9\u8C61key\u8F6C\u6362\u5931\u8D25", e.elementId, o);
|
|
2321
2407
|
return;
|
|
2322
2408
|
}
|
|
2323
|
-
if (!
|
|
2409
|
+
if (!Kt(a, e)) {
|
|
2324
2410
|
console.log("ConfigExtra\uFF1A\u8865\u5145\u5BF9\u8C61key\u672A\u627E\u5230\u7236\u7EA7", e.elementId, o, "->", a);
|
|
2325
2411
|
return;
|
|
2326
2412
|
}
|
|
2327
|
-
|
|
2413
|
+
ie(e, a, r);
|
|
2328
2414
|
});
|
|
2329
|
-
},
|
|
2330
|
-
|
|
2415
|
+
}, pe = (e, t) => {
|
|
2416
|
+
Fr(e, m(t, e.elementId));
|
|
2331
2417
|
const r = m(e, ["highConfig$", "registerPropsTrans"]);
|
|
2332
|
-
r && X(r) > 0 &&
|
|
2418
|
+
r && X(r) > 0 && te(r, (o) => {
|
|
2333
2419
|
const a = m(e.elementProps, o.name);
|
|
2334
|
-
_(a) ?
|
|
2335
|
-
|
|
2336
|
-
}) :
|
|
2337
|
-
}), e.children && X(e.children) > 0 &&
|
|
2338
|
-
|
|
2420
|
+
_(a) ? te(a, (n) => {
|
|
2421
|
+
pe(n, t);
|
|
2422
|
+
}) : pe(a, t);
|
|
2423
|
+
}), e.children && X(e.children) > 0 && te(e.children, (o) => {
|
|
2424
|
+
pe(o, t);
|
|
2339
2425
|
});
|
|
2340
|
-
},
|
|
2426
|
+
}, xr = w({
|
|
2341
2427
|
props: {
|
|
2342
2428
|
initExecuteList: {
|
|
2343
2429
|
type: Array
|
|
@@ -2346,43 +2432,43 @@ const dr = () => ({
|
|
|
2346
2432
|
setup: (e) => {
|
|
2347
2433
|
const {
|
|
2348
2434
|
execute: t
|
|
2349
|
-
} =
|
|
2350
|
-
return
|
|
2435
|
+
} = ge();
|
|
2436
|
+
return ce(() => {
|
|
2351
2437
|
e.initExecuteList && t(e.initExecuteList, []);
|
|
2352
2438
|
}, []), () => null;
|
|
2353
2439
|
}
|
|
2354
|
-
}),
|
|
2440
|
+
}), wa = ({
|
|
2355
2441
|
actors: e,
|
|
2356
2442
|
configData: t,
|
|
2357
2443
|
configDataExtra: r,
|
|
2358
2444
|
Logic: o
|
|
2359
|
-
}) =>
|
|
2360
|
-
const a =
|
|
2361
|
-
const
|
|
2362
|
-
return r && (_(
|
|
2445
|
+
}) => w(() => {
|
|
2446
|
+
const a = z(), n = (s) => {
|
|
2447
|
+
const d = Ot(s);
|
|
2448
|
+
return r && (_(d) ? te(d, (y) => pe(y, r)) : pe(d, r)), d;
|
|
2363
2449
|
};
|
|
2364
|
-
|
|
2450
|
+
ce(() => {
|
|
2365
2451
|
t && t.elementConfigs && (a.value = n(t.elementConfigs)), t != null && t.elementConfigs;
|
|
2366
2452
|
}, []);
|
|
2367
|
-
const c = Q()(
|
|
2368
|
-
return () => a.value ?
|
|
2453
|
+
const c = Q()(U.LoadingKey);
|
|
2454
|
+
return () => a.value ? i(Fe, {
|
|
2369
2455
|
initState: t == null ? void 0 : t.initState,
|
|
2370
2456
|
storeKeys: t == null ? void 0 : t.storeKeys,
|
|
2371
2457
|
actors: e,
|
|
2372
2458
|
requests: t == null ? void 0 : t.requests,
|
|
2373
2459
|
elementConfigs: a.value
|
|
2374
2460
|
}, {
|
|
2375
|
-
default: () => [
|
|
2376
|
-
}) : c ?
|
|
2461
|
+
default: () => [i(xr, null, null), o && i(o, null, null)]
|
|
2462
|
+
}) : c ? i(c, {
|
|
2377
2463
|
loading: !0
|
|
2378
2464
|
}, {
|
|
2379
|
-
default: () => [
|
|
2465
|
+
default: () => [i("div", {
|
|
2380
2466
|
class: "pro-module-loading-dom"
|
|
2381
2467
|
}, null)]
|
|
2382
2468
|
}) : null;
|
|
2383
|
-
}),
|
|
2384
|
-
var
|
|
2385
|
-
const
|
|
2469
|
+
}), cn = Symbol("pro-curd"), oe = () => he(cn), Rr = (e) => ve(cn, e);
|
|
2470
|
+
var D = /* @__PURE__ */ ((e) => (e.LIST = "LIST", e.DETAIL = "DETAIL", e.ADD = "ADD", e.EDIT = "EDIT", e.DELETE = "DELETE", e))(D || {}), B = /* @__PURE__ */ ((e) => (e.EMIT = "EMIT", e.EXECUTE = "EXECUTE", e.PAGE = "PAGE", e.SUCCESS = "SUCCESS", e.FAIL = "FAIL", e))(B || {}), me = /* @__PURE__ */ ((e) => (e.ADD = "ADD", e.EDIT = "EDIT", e.DETAIL = "DETAIL", e))(me || {}), Oe = /* @__PURE__ */ ((e) => (e.NORMAL = "NORMAL", e.CONTINUE = "CONTINUE", e))(Oe || {});
|
|
2471
|
+
const Lr = () => ({
|
|
2386
2472
|
rowKey: {
|
|
2387
2473
|
type: String,
|
|
2388
2474
|
default: "id"
|
|
@@ -2405,10 +2491,10 @@ const Ar = () => ({
|
|
|
2405
2491
|
modalProps: {
|
|
2406
2492
|
type: Object
|
|
2407
2493
|
}
|
|
2408
|
-
}),
|
|
2494
|
+
}), sn = ["sendCurdEvent", "refreshList", "sendEvent", "sendRequest"], Pt = w({
|
|
2409
2495
|
props: {
|
|
2410
|
-
...
|
|
2411
|
-
...
|
|
2496
|
+
...be,
|
|
2497
|
+
...Lr()
|
|
2412
2498
|
},
|
|
2413
2499
|
setup: (e, {
|
|
2414
2500
|
slots: t,
|
|
@@ -2419,90 +2505,90 @@ const Ar = () => ({
|
|
|
2419
2505
|
state: a,
|
|
2420
2506
|
sendEvent: n,
|
|
2421
2507
|
sendRequest: u
|
|
2422
|
-
} =
|
|
2423
|
-
const
|
|
2424
|
-
const
|
|
2425
|
-
return
|
|
2508
|
+
} = ge(), c = O(() => Ue(e.columns, e.columnState, e.columnState2)), s = (M, R) => {
|
|
2509
|
+
const j = Y(c.value, (q) => {
|
|
2510
|
+
const G = m(q, ["extra", M]) || m(q, M);
|
|
2511
|
+
return R ? G !== !1 : G;
|
|
2426
2512
|
});
|
|
2427
|
-
return
|
|
2428
|
-
},
|
|
2513
|
+
return Nt(j, (q) => m(q, ["extra", `${M}Sort`]) || m(q, `${M}Sort`));
|
|
2514
|
+
}, d = O(() => s("form", !0)), y = O(() => s("detail", !0)), h = O(() => s("table", !0)), f = O(() => s("search"));
|
|
2429
2515
|
let S;
|
|
2430
|
-
const
|
|
2431
|
-
u(
|
|
2516
|
+
const p = (M) => {
|
|
2517
|
+
u(D.LIST, {
|
|
2432
2518
|
...S,
|
|
2433
|
-
...
|
|
2519
|
+
...M
|
|
2434
2520
|
});
|
|
2435
|
-
},
|
|
2521
|
+
}, v = (M) => {
|
|
2436
2522
|
n({
|
|
2437
|
-
type:
|
|
2438
|
-
payload: $(
|
|
2439
|
-
source:
|
|
2523
|
+
type: M.action,
|
|
2524
|
+
payload: $(M, "action", "source"),
|
|
2525
|
+
source: M.source
|
|
2440
2526
|
});
|
|
2441
2527
|
};
|
|
2442
|
-
|
|
2443
|
-
type:
|
|
2444
|
-
payload:
|
|
2445
|
-
source:
|
|
2528
|
+
et(({
|
|
2529
|
+
type: M,
|
|
2530
|
+
payload: R,
|
|
2531
|
+
source: j
|
|
2446
2532
|
}) => {
|
|
2447
|
-
if (
|
|
2533
|
+
if (j)
|
|
2448
2534
|
return;
|
|
2449
|
-
let
|
|
2450
|
-
|
|
2535
|
+
let q = M, G = R == null ? void 0 : R.type;
|
|
2536
|
+
q === Ie.Success && (q = m(R, ["requestOpts", "action"]), G = B.SUCCESS);
|
|
2451
2537
|
const {
|
|
2452
|
-
values:
|
|
2453
|
-
record:
|
|
2454
|
-
} =
|
|
2455
|
-
switch (
|
|
2456
|
-
case
|
|
2457
|
-
|
|
2538
|
+
values: J,
|
|
2539
|
+
record: b
|
|
2540
|
+
} = R;
|
|
2541
|
+
switch (q) {
|
|
2542
|
+
case D.LIST:
|
|
2543
|
+
G === B.EMIT && (S = J, p());
|
|
2458
2544
|
return;
|
|
2459
|
-
case
|
|
2460
|
-
|
|
2545
|
+
case D.ADD:
|
|
2546
|
+
G === B.EXECUTE && u(D.ADD, J, a.detailData);
|
|
2461
2547
|
return;
|
|
2462
|
-
case
|
|
2463
|
-
|
|
2548
|
+
case D.EDIT:
|
|
2549
|
+
G === B.EXECUTE && u(D.EDIT, J, a.detailData);
|
|
2464
2550
|
return;
|
|
2465
|
-
case
|
|
2466
|
-
|
|
2551
|
+
case D.DELETE:
|
|
2552
|
+
G === B.EMIT ? u(D.DELETE, b, e.rowKey) : G === B.SUCCESS && p();
|
|
2467
2553
|
return;
|
|
2468
2554
|
}
|
|
2469
|
-
|
|
2555
|
+
q && M === B.EXECUTE && u(q, J);
|
|
2470
2556
|
});
|
|
2471
|
-
const T =
|
|
2472
|
-
...
|
|
2473
|
-
[
|
|
2474
|
-
}), {}),
|
|
2475
|
-
return
|
|
2557
|
+
const T = ae(e.operates, (M, R) => ({
|
|
2558
|
+
...M,
|
|
2559
|
+
[R.action]: R
|
|
2560
|
+
}), {}), N = (M) => m(T, M), l = O(() => e.listProps), g = O(() => e.formProps), E = O(() => e.descProps), I = O(() => e.modalProps);
|
|
2561
|
+
return Rr({
|
|
2476
2562
|
columns: c,
|
|
2477
|
-
getSignColumns:
|
|
2563
|
+
getSignColumns: s,
|
|
2478
2564
|
elementMap: o,
|
|
2479
2565
|
formElementMap: e.formElementMap,
|
|
2480
2566
|
rowKey: e.rowKey,
|
|
2481
2567
|
curdState: a,
|
|
2482
|
-
formColumns:
|
|
2483
|
-
descColumns:
|
|
2568
|
+
formColumns: d,
|
|
2569
|
+
descColumns: y,
|
|
2484
2570
|
tableColumns: h,
|
|
2485
2571
|
searchColumns: f,
|
|
2486
|
-
sendCurdEvent:
|
|
2572
|
+
sendCurdEvent: v,
|
|
2487
2573
|
operates: e.operates,
|
|
2488
|
-
getOperate:
|
|
2489
|
-
refreshList:
|
|
2490
|
-
listProps:
|
|
2491
|
-
formProps:
|
|
2492
|
-
descProps:
|
|
2574
|
+
getOperate: N,
|
|
2575
|
+
refreshList: p,
|
|
2576
|
+
listProps: l,
|
|
2577
|
+
formProps: g,
|
|
2578
|
+
descProps: E,
|
|
2493
2579
|
modalProps: I
|
|
2494
2580
|
}), r({
|
|
2495
|
-
sendCurdEvent:
|
|
2496
|
-
refreshList:
|
|
2581
|
+
sendCurdEvent: v,
|
|
2582
|
+
refreshList: p
|
|
2497
2583
|
}), () => {
|
|
2498
|
-
var
|
|
2499
|
-
return (
|
|
2584
|
+
var M;
|
|
2585
|
+
return (M = t.default) == null ? void 0 : M.call(t);
|
|
2500
2586
|
};
|
|
2501
2587
|
}
|
|
2502
|
-
}),
|
|
2588
|
+
}), Ge = w({
|
|
2503
2589
|
props: {
|
|
2504
|
-
...$(
|
|
2505
|
-
...
|
|
2590
|
+
...$(Fe.props, "state", "requests"),
|
|
2591
|
+
...Pt.props,
|
|
2506
2592
|
curdState: {
|
|
2507
2593
|
type: Object
|
|
2508
2594
|
}
|
|
@@ -2514,10 +2600,10 @@ const Ar = () => ({
|
|
|
2514
2600
|
const {
|
|
2515
2601
|
elementMap: o,
|
|
2516
2602
|
formElementMap: a
|
|
2517
|
-
} =
|
|
2603
|
+
} = ne(), n = z(), u = z(), c = e.curdState || Ae({
|
|
2518
2604
|
detailData: {}
|
|
2519
|
-
}),
|
|
2520
|
-
[
|
|
2605
|
+
}), s = {
|
|
2606
|
+
[D.LIST]: {
|
|
2521
2607
|
convertParams: (f) => f,
|
|
2522
2608
|
convertData: (f) => {
|
|
2523
2609
|
var S;
|
|
@@ -2526,8 +2612,8 @@ const Ar = () => ({
|
|
|
2526
2612
|
loadingName: "listLoading",
|
|
2527
2613
|
stateName: "listData"
|
|
2528
2614
|
},
|
|
2529
|
-
[
|
|
2530
|
-
convertParams: (f, S) =>
|
|
2615
|
+
[D.DETAIL]: {
|
|
2616
|
+
convertParams: (f, S) => H(f, S),
|
|
2531
2617
|
convertData: (f) => {
|
|
2532
2618
|
var S;
|
|
2533
2619
|
return (S = f.res) == null ? void 0 : S.data;
|
|
@@ -2536,7 +2622,7 @@ const Ar = () => ({
|
|
|
2536
2622
|
stateName: "detailData",
|
|
2537
2623
|
label: "\u8BE6\u60C5"
|
|
2538
2624
|
},
|
|
2539
|
-
[
|
|
2625
|
+
[D.ADD]: {
|
|
2540
2626
|
convertParams: (f, S) => ({
|
|
2541
2627
|
body: {
|
|
2542
2628
|
...S,
|
|
@@ -2546,7 +2632,7 @@ const Ar = () => ({
|
|
|
2546
2632
|
loadingName: "operateLoading",
|
|
2547
2633
|
label: "\u6DFB\u52A0"
|
|
2548
2634
|
},
|
|
2549
|
-
[
|
|
2635
|
+
[D.EDIT]: {
|
|
2550
2636
|
convertParams: (f, S) => ({
|
|
2551
2637
|
body: {
|
|
2552
2638
|
...S,
|
|
@@ -2556,18 +2642,18 @@ const Ar = () => ({
|
|
|
2556
2642
|
loadingName: "operateLoading",
|
|
2557
2643
|
label: "\u7F16\u8F91"
|
|
2558
2644
|
},
|
|
2559
|
-
[
|
|
2560
|
-
convertParams: (f, S) =>
|
|
2645
|
+
[D.DELETE]: {
|
|
2646
|
+
convertParams: (f, S) => H(f, S),
|
|
2561
2647
|
label: "\u5220\u9664"
|
|
2562
2648
|
}
|
|
2563
|
-
},
|
|
2564
|
-
var
|
|
2565
|
-
const S = m(
|
|
2649
|
+
}, d = F(e.operates, (f) => {
|
|
2650
|
+
var v;
|
|
2651
|
+
const S = m(s, f.action), p = ((v = e.convertOperate) == null ? void 0 : v.call(e, f, S)) || f;
|
|
2566
2652
|
return {
|
|
2567
2653
|
...S,
|
|
2568
|
-
...
|
|
2654
|
+
...p
|
|
2569
2655
|
};
|
|
2570
|
-
}),
|
|
2656
|
+
}), y = Y(d, (f) => f.actor), h = W($(Fe.props, "state", "requests"));
|
|
2571
2657
|
return r({
|
|
2572
2658
|
sendCurdEvent: (f) => {
|
|
2573
2659
|
var S;
|
|
@@ -2582,148 +2668,148 @@ const Ar = () => ({
|
|
|
2582
2668
|
(S = n.value) == null || S.sendEvent(f);
|
|
2583
2669
|
},
|
|
2584
2670
|
sendRequest: (f, ...S) => {
|
|
2585
|
-
var
|
|
2586
|
-
(
|
|
2671
|
+
var p;
|
|
2672
|
+
(p = n.value) == null || p.sendRequest(f, ...S);
|
|
2587
2673
|
}
|
|
2588
|
-
}), () =>
|
|
2674
|
+
}), () => i(Fe, K({
|
|
2589
2675
|
ref: n
|
|
2590
|
-
},
|
|
2676
|
+
}, H(e, h), {
|
|
2591
2677
|
elementMap: e.elementMap || o,
|
|
2592
2678
|
state: c,
|
|
2593
|
-
requests:
|
|
2679
|
+
requests: y
|
|
2594
2680
|
}), {
|
|
2595
|
-
default: () => [
|
|
2681
|
+
default: () => [i(Pt, K({
|
|
2596
2682
|
ref: u
|
|
2597
2683
|
}, $(e, ...h, "curdState", "operates", "convertOperate"), {
|
|
2598
2684
|
formElementMap: e.formElementMap || a,
|
|
2599
|
-
operates:
|
|
2685
|
+
operates: d
|
|
2600
2686
|
}), t)]
|
|
2601
2687
|
});
|
|
2602
2688
|
}
|
|
2603
|
-
}),
|
|
2689
|
+
}), jr = () => ({
|
|
2604
2690
|
defaultAddRecord: {
|
|
2605
2691
|
type: Object
|
|
2606
2692
|
}
|
|
2607
|
-
}),
|
|
2693
|
+
}), ze = w({
|
|
2608
2694
|
props: {
|
|
2609
|
-
...
|
|
2695
|
+
...jr()
|
|
2610
2696
|
},
|
|
2611
2697
|
setup: (e) => {
|
|
2612
2698
|
var S;
|
|
2613
2699
|
const {
|
|
2614
2700
|
dispatch: t,
|
|
2615
2701
|
sendRequest: r
|
|
2616
|
-
} =
|
|
2702
|
+
} = ge(), {
|
|
2617
2703
|
rowKey: o,
|
|
2618
2704
|
curdState: a,
|
|
2619
2705
|
listProps: n,
|
|
2620
2706
|
getOperate: u,
|
|
2621
2707
|
refreshList: c
|
|
2622
|
-
} =
|
|
2623
|
-
const
|
|
2624
|
-
|
|
2708
|
+
} = oe(), s = (S = n == null ? void 0 : n.value) == null ? void 0 : S.pageState, d = (p) => {
|
|
2709
|
+
const v = u(D.DETAIL);
|
|
2710
|
+
v != null && v.actor ? r(D.DETAIL, p, o) : t({
|
|
2625
2711
|
type: "detailData",
|
|
2626
|
-
payload:
|
|
2712
|
+
payload: Ot(p)
|
|
2627
2713
|
});
|
|
2628
|
-
},
|
|
2629
|
-
record:
|
|
2714
|
+
}, y = (p, {
|
|
2715
|
+
record: v
|
|
2630
2716
|
}) => {
|
|
2631
|
-
|
|
2717
|
+
p === B.EMIT && (t({
|
|
2632
2718
|
type: "mode",
|
|
2633
|
-
payload:
|
|
2634
|
-
}),
|
|
2635
|
-
}, h = (
|
|
2636
|
-
|
|
2719
|
+
payload: me.DETAIL
|
|
2720
|
+
}), d(v));
|
|
2721
|
+
}, h = (p) => {
|
|
2722
|
+
p === B.EMIT ? (t({
|
|
2637
2723
|
type: "mode",
|
|
2638
|
-
payload:
|
|
2724
|
+
payload: me.ADD
|
|
2639
2725
|
}), t({
|
|
2640
2726
|
type: "detailData",
|
|
2641
2727
|
payload: e.defaultAddRecord || {}
|
|
2642
|
-
})) :
|
|
2728
|
+
})) : p === B.SUCCESS && (s && (s.page = 1), c(), a.addAction === Oe.CONTINUE ? t({
|
|
2643
2729
|
type: "detailData",
|
|
2644
2730
|
payload: e.defaultAddRecord || {}
|
|
2645
2731
|
}) : t({
|
|
2646
2732
|
type: "mode",
|
|
2647
2733
|
payload: void 0
|
|
2648
2734
|
}));
|
|
2649
|
-
}, f = (
|
|
2650
|
-
record:
|
|
2735
|
+
}, f = (p, {
|
|
2736
|
+
record: v
|
|
2651
2737
|
}) => {
|
|
2652
|
-
|
|
2738
|
+
p === B.EMIT ? (t({
|
|
2653
2739
|
type: "mode",
|
|
2654
|
-
payload:
|
|
2655
|
-
}),
|
|
2740
|
+
payload: me.EDIT
|
|
2741
|
+
}), d(v)) : p === B.SUCCESS && (t({
|
|
2656
2742
|
type: "mode",
|
|
2657
2743
|
payload: void 0
|
|
2658
2744
|
}), c());
|
|
2659
2745
|
};
|
|
2660
|
-
return
|
|
2661
|
-
type:
|
|
2662
|
-
payload:
|
|
2746
|
+
return et(({
|
|
2747
|
+
type: p,
|
|
2748
|
+
payload: v,
|
|
2663
2749
|
source: T
|
|
2664
2750
|
}) => {
|
|
2665
2751
|
if (T)
|
|
2666
2752
|
return;
|
|
2667
|
-
let
|
|
2668
|
-
const
|
|
2669
|
-
switch (
|
|
2670
|
-
case
|
|
2671
|
-
|
|
2672
|
-
record:
|
|
2753
|
+
let N = p, l = v == null ? void 0 : v.type;
|
|
2754
|
+
const g = v == null ? void 0 : v.record;
|
|
2755
|
+
switch (N === Ie.Success && (N = m(v, ["requestOpts", "action"]), l = B.SUCCESS), N) {
|
|
2756
|
+
case D.DETAIL:
|
|
2757
|
+
y(l, {
|
|
2758
|
+
record: g
|
|
2673
2759
|
});
|
|
2674
2760
|
break;
|
|
2675
|
-
case
|
|
2676
|
-
h(
|
|
2761
|
+
case D.ADD:
|
|
2762
|
+
h(l);
|
|
2677
2763
|
break;
|
|
2678
|
-
case
|
|
2679
|
-
f(
|
|
2680
|
-
record:
|
|
2764
|
+
case D.EDIT:
|
|
2765
|
+
f(l, {
|
|
2766
|
+
record: g
|
|
2681
2767
|
});
|
|
2682
2768
|
break;
|
|
2683
2769
|
}
|
|
2684
2770
|
}), () => null;
|
|
2685
2771
|
}
|
|
2686
|
-
}),
|
|
2772
|
+
}), Ka = w({
|
|
2687
2773
|
props: {
|
|
2688
|
-
...
|
|
2689
|
-
...
|
|
2774
|
+
...Ge.props,
|
|
2775
|
+
...ze.props
|
|
2690
2776
|
},
|
|
2691
2777
|
setup: (e, {
|
|
2692
2778
|
slots: t,
|
|
2693
2779
|
expose: r
|
|
2694
2780
|
}) => {
|
|
2695
|
-
const o =
|
|
2696
|
-
r(
|
|
2697
|
-
const a =
|
|
2698
|
-
return () => u ?
|
|
2781
|
+
const o = z();
|
|
2782
|
+
r(Se(sn, o));
|
|
2783
|
+
const a = W(ze.props), u = Q()(U.ProCurdKey);
|
|
2784
|
+
return () => u ? i(u, K({
|
|
2699
2785
|
ref: o
|
|
2700
2786
|
}, $(e, a)), {
|
|
2701
2787
|
default: () => {
|
|
2702
2788
|
var c;
|
|
2703
|
-
return [
|
|
2789
|
+
return [i(ze, H(e, a), null), (c = t.default) == null ? void 0 : c.call(t)];
|
|
2704
2790
|
}
|
|
2705
2791
|
}) : null;
|
|
2706
2792
|
}
|
|
2707
|
-
}),
|
|
2793
|
+
}), kr = () => ({
|
|
2708
2794
|
defaultAddRecord: {
|
|
2709
2795
|
type: Object
|
|
2710
2796
|
},
|
|
2711
2797
|
routeBack: {
|
|
2712
2798
|
type: Function
|
|
2713
2799
|
}
|
|
2714
|
-
}),
|
|
2800
|
+
}), He = w({
|
|
2715
2801
|
props: {
|
|
2716
|
-
|
|
2802
|
+
...kr()
|
|
2717
2803
|
},
|
|
2718
2804
|
setup: (e) => {
|
|
2719
|
-
const t =
|
|
2805
|
+
const t = Qe(), r = Je(), {
|
|
2720
2806
|
dispatch: o,
|
|
2721
2807
|
sendRequest: a
|
|
2722
|
-
} =
|
|
2808
|
+
} = ge(), {
|
|
2723
2809
|
rowKey: n,
|
|
2724
2810
|
curdState: u
|
|
2725
|
-
} =
|
|
2726
|
-
h ===
|
|
2811
|
+
} = oe(), c = (h) => {
|
|
2812
|
+
h === B.PAGE && (o({
|
|
2727
2813
|
type: "mode",
|
|
2728
2814
|
payload: void 0
|
|
2729
2815
|
}), o({
|
|
@@ -2736,120 +2822,120 @@ const Ar = () => ({
|
|
|
2736
2822
|
type: "addAction",
|
|
2737
2823
|
payload: void 0
|
|
2738
2824
|
}));
|
|
2739
|
-
},
|
|
2825
|
+
}, s = (h, {
|
|
2740
2826
|
record: f
|
|
2741
2827
|
}) => {
|
|
2742
|
-
h ===
|
|
2828
|
+
h === B.EMIT ? t.push({
|
|
2743
2829
|
path: `${r.path}/detail`,
|
|
2744
|
-
query:
|
|
2745
|
-
}) : h ===
|
|
2830
|
+
query: H(f, n)
|
|
2831
|
+
}) : h === B.PAGE && (o({
|
|
2746
2832
|
type: "mode",
|
|
2747
|
-
payload:
|
|
2748
|
-
}), a(
|
|
2749
|
-
},
|
|
2750
|
-
h ===
|
|
2833
|
+
payload: me.DETAIL
|
|
2834
|
+
}), a(D.DETAIL, r.query, n));
|
|
2835
|
+
}, d = (h) => {
|
|
2836
|
+
h === B.EMIT ? t.push({
|
|
2751
2837
|
path: `${r.path}/add`
|
|
2752
|
-
}) : h ===
|
|
2838
|
+
}) : h === B.PAGE ? (o({
|
|
2753
2839
|
type: "mode",
|
|
2754
|
-
payload:
|
|
2840
|
+
payload: me.ADD
|
|
2755
2841
|
}), o({
|
|
2756
2842
|
type: "detailData",
|
|
2757
2843
|
payload: e.defaultAddRecord || {}
|
|
2758
|
-
})) : h ===
|
|
2844
|
+
})) : h === B.SUCCESS && (u.addAction === Oe.CONTINUE ? o({
|
|
2759
2845
|
type: "detailData",
|
|
2760
2846
|
payload: e.defaultAddRecord || {}
|
|
2761
|
-
}) : e.routeBack ? e.routeBack(
|
|
2762
|
-
},
|
|
2847
|
+
}) : e.routeBack ? e.routeBack(D.ADD) : t.go(-1));
|
|
2848
|
+
}, y = (h, {
|
|
2763
2849
|
record: f
|
|
2764
2850
|
}) => {
|
|
2765
|
-
h ===
|
|
2851
|
+
h === B.EMIT ? t.push({
|
|
2766
2852
|
path: `${r.path}/edit`,
|
|
2767
|
-
query:
|
|
2768
|
-
}) : h ===
|
|
2853
|
+
query: H(f, n)
|
|
2854
|
+
}) : h === B.PAGE ? (o({
|
|
2769
2855
|
type: "mode",
|
|
2770
|
-
payload:
|
|
2771
|
-
}), a(
|
|
2856
|
+
payload: me.EDIT
|
|
2857
|
+
}), a(D.DETAIL, r.query, n)) : h === B.SUCCESS && (e.routeBack ? e.routeBack(D.EDIT) : t.go(-1));
|
|
2772
2858
|
};
|
|
2773
|
-
return
|
|
2859
|
+
return et(({
|
|
2774
2860
|
type: h,
|
|
2775
2861
|
payload: f,
|
|
2776
2862
|
source: S
|
|
2777
2863
|
}) => {
|
|
2778
2864
|
if (S)
|
|
2779
2865
|
return;
|
|
2780
|
-
let
|
|
2866
|
+
let p = h, v = f == null ? void 0 : f.type;
|
|
2781
2867
|
const T = f == null ? void 0 : f.record;
|
|
2782
|
-
switch (
|
|
2783
|
-
case
|
|
2784
|
-
c(
|
|
2868
|
+
switch (p === Ie.Success && (p = m(f, ["requestOpts", "action"]), v = B.SUCCESS), p) {
|
|
2869
|
+
case D.LIST:
|
|
2870
|
+
c(v);
|
|
2785
2871
|
break;
|
|
2786
|
-
case
|
|
2787
|
-
|
|
2872
|
+
case D.DETAIL:
|
|
2873
|
+
s(v, {
|
|
2788
2874
|
record: T
|
|
2789
2875
|
});
|
|
2790
2876
|
break;
|
|
2791
|
-
case
|
|
2792
|
-
|
|
2877
|
+
case D.ADD:
|
|
2878
|
+
d(v);
|
|
2793
2879
|
break;
|
|
2794
|
-
case
|
|
2795
|
-
|
|
2880
|
+
case D.EDIT:
|
|
2881
|
+
y(v, {
|
|
2796
2882
|
record: T
|
|
2797
2883
|
});
|
|
2798
2884
|
break;
|
|
2799
2885
|
}
|
|
2800
2886
|
}), () => null;
|
|
2801
2887
|
}
|
|
2802
|
-
}),
|
|
2888
|
+
}), Da = w({
|
|
2803
2889
|
props: {
|
|
2804
|
-
...
|
|
2805
|
-
...
|
|
2890
|
+
...Ge.props,
|
|
2891
|
+
...He.props
|
|
2806
2892
|
},
|
|
2807
2893
|
setup: (e, {
|
|
2808
2894
|
slots: t,
|
|
2809
2895
|
expose: r
|
|
2810
2896
|
}) => {
|
|
2811
|
-
const o =
|
|
2812
|
-
r(
|
|
2813
|
-
const a =
|
|
2814
|
-
return () =>
|
|
2897
|
+
const o = z();
|
|
2898
|
+
r(Se(sn, o));
|
|
2899
|
+
const a = W(He.props);
|
|
2900
|
+
return () => i(Ge, K({
|
|
2815
2901
|
ref: o
|
|
2816
2902
|
}, $(e, a)), {
|
|
2817
2903
|
default: () => {
|
|
2818
2904
|
var n;
|
|
2819
|
-
return [
|
|
2905
|
+
return [i(He, H(e, a), null), (n = t.default) == null ? void 0 : n.call(t)];
|
|
2820
2906
|
}
|
|
2821
2907
|
});
|
|
2822
2908
|
}
|
|
2823
|
-
}),
|
|
2909
|
+
}), pt = w({
|
|
2824
2910
|
props: {
|
|
2825
2911
|
buttonProps: Object
|
|
2826
2912
|
},
|
|
2827
2913
|
setup: (e, {
|
|
2828
2914
|
slots: t
|
|
2829
2915
|
}) => {
|
|
2830
|
-
const r =
|
|
2916
|
+
const r = rn(), {
|
|
2831
2917
|
getOperate: o,
|
|
2832
2918
|
sendCurdEvent: a
|
|
2833
|
-
} =
|
|
2919
|
+
} = oe(), n = o(D.ADD), u = () => {
|
|
2834
2920
|
if (n != null && n.onClick) {
|
|
2835
2921
|
n.onClick();
|
|
2836
2922
|
return;
|
|
2837
2923
|
}
|
|
2838
2924
|
a({
|
|
2839
|
-
action:
|
|
2840
|
-
type:
|
|
2925
|
+
action: D.ADD,
|
|
2926
|
+
type: B.EMIT
|
|
2841
2927
|
});
|
|
2842
|
-
},
|
|
2843
|
-
return () => !n || !r(n.per, n.perSuffix) || !(
|
|
2928
|
+
}, s = Q()(U.ButtonKey);
|
|
2929
|
+
return () => !n || !r(n.per, n.perSuffix) || !(V(n.show) ? n.show({}) : n.show) ? null : n.element ? n.element({}, n) : t.default ? t.default(n, u) : s ? i(s, K({
|
|
2844
2930
|
class: "pro-curd-add-button",
|
|
2845
|
-
disabled:
|
|
2931
|
+
disabled: V(n.disabled) ? n.disabled() : n.disabled
|
|
2846
2932
|
}, e.buttonProps, {
|
|
2847
2933
|
onClick: u
|
|
2848
2934
|
}), {
|
|
2849
2935
|
default: () => [n.label]
|
|
2850
2936
|
}) : null;
|
|
2851
2937
|
}
|
|
2852
|
-
}),
|
|
2938
|
+
}), Ct = () => ({
|
|
2853
2939
|
addConfig: {
|
|
2854
2940
|
type: Object,
|
|
2855
2941
|
default: {
|
|
@@ -2860,10 +2946,10 @@ const Ar = () => ({
|
|
|
2860
2946
|
type: Boolean,
|
|
2861
2947
|
default: !0
|
|
2862
2948
|
}
|
|
2863
|
-
}),
|
|
2949
|
+
}), Ur = w({
|
|
2864
2950
|
props: {
|
|
2865
|
-
...
|
|
2866
|
-
...
|
|
2951
|
+
...Or.props,
|
|
2952
|
+
...Ct()
|
|
2867
2953
|
},
|
|
2868
2954
|
setup: (e, {
|
|
2869
2955
|
slots: t
|
|
@@ -2875,99 +2961,99 @@ const Ar = () => ({
|
|
|
2875
2961
|
searchColumns: n,
|
|
2876
2962
|
tableColumns: u,
|
|
2877
2963
|
sendCurdEvent: c,
|
|
2878
|
-
operates:
|
|
2879
|
-
refreshList:
|
|
2880
|
-
} =
|
|
2881
|
-
Y(
|
|
2882
|
-
const
|
|
2883
|
-
return
|
|
2964
|
+
operates: s,
|
|
2965
|
+
refreshList: d
|
|
2966
|
+
} = oe(), y = F(
|
|
2967
|
+
Y(s, (l) => {
|
|
2968
|
+
const g = l.action;
|
|
2969
|
+
return g === D.DETAIL || g === D.EDIT || g === D.DELETE || l.tableOperate;
|
|
2884
2970
|
}),
|
|
2885
|
-
(
|
|
2886
|
-
const
|
|
2887
|
-
...
|
|
2888
|
-
value:
|
|
2971
|
+
(l) => {
|
|
2972
|
+
const g = {
|
|
2973
|
+
...H(l, "label", "show", "disabled", "loading", "extraProps", "onClick", "element", "sort", "per", "perSuffix"),
|
|
2974
|
+
value: l.action
|
|
2889
2975
|
};
|
|
2890
|
-
return
|
|
2976
|
+
return g.onClick || (g.onClick = (E) => {
|
|
2891
2977
|
c({
|
|
2892
|
-
action:
|
|
2893
|
-
type:
|
|
2894
|
-
record:
|
|
2978
|
+
action: l.action,
|
|
2979
|
+
type: B.EMIT,
|
|
2980
|
+
record: E
|
|
2895
2981
|
});
|
|
2896
|
-
}),
|
|
2982
|
+
}), g;
|
|
2897
2983
|
}
|
|
2898
|
-
), h = (
|
|
2984
|
+
), h = (l) => {
|
|
2899
2985
|
c({
|
|
2900
|
-
action:
|
|
2901
|
-
type:
|
|
2902
|
-
values:
|
|
2986
|
+
action: D.LIST,
|
|
2987
|
+
type: B.EMIT,
|
|
2988
|
+
values: l
|
|
2903
2989
|
});
|
|
2904
2990
|
};
|
|
2905
|
-
|
|
2906
|
-
e.activatedRefresh &&
|
|
2991
|
+
Rn(() => {
|
|
2992
|
+
e.activatedRefresh && d();
|
|
2907
2993
|
});
|
|
2908
2994
|
const f = O(() => ({
|
|
2909
2995
|
formElementMap: o,
|
|
2910
2996
|
columns: n.value,
|
|
2911
2997
|
...e.searchProps
|
|
2912
2998
|
})), S = O(() => {
|
|
2913
|
-
var
|
|
2999
|
+
var l, g;
|
|
2914
3000
|
return {
|
|
2915
3001
|
elementMap: r,
|
|
2916
3002
|
columns: u.value,
|
|
2917
3003
|
loading: a.listLoading,
|
|
2918
|
-
dataSource: (
|
|
3004
|
+
dataSource: (l = a.listData) == null ? void 0 : l.dataSource,
|
|
2919
3005
|
...$(e.tableProps, "operate"),
|
|
2920
3006
|
operate: {
|
|
2921
|
-
items:
|
|
2922
|
-
...(
|
|
3007
|
+
items: y,
|
|
3008
|
+
...(g = e.tableProps) == null ? void 0 : g.operate
|
|
2923
3009
|
}
|
|
2924
3010
|
};
|
|
2925
|
-
}),
|
|
2926
|
-
var
|
|
3011
|
+
}), p = O(() => {
|
|
3012
|
+
var l;
|
|
2927
3013
|
return e.paginationProps === !1 ? !1 : {
|
|
2928
|
-
total: (
|
|
3014
|
+
total: (l = a.listData) == null ? void 0 : l.total,
|
|
2929
3015
|
...e.paginationProps
|
|
2930
3016
|
};
|
|
2931
|
-
}),
|
|
3017
|
+
}), v = W(Ct()), N = Q()(U.ProListKey);
|
|
2932
3018
|
return () => {
|
|
2933
|
-
var
|
|
2934
|
-
return
|
|
3019
|
+
var l, g;
|
|
3020
|
+
return N ? i(N, K({
|
|
2935
3021
|
class: "pro-curd-list"
|
|
2936
|
-
}, $(e, ...
|
|
3022
|
+
}, $(e, ...v, "searchProps", "tableProps", "paginationProps"), {
|
|
2937
3023
|
searchProps: f.value,
|
|
2938
3024
|
tableProps: S.value,
|
|
2939
|
-
paginationProps:
|
|
3025
|
+
paginationProps: p.value,
|
|
2940
3026
|
onSearch: h
|
|
2941
3027
|
}), {
|
|
2942
|
-
"search-end": (
|
|
2943
|
-
var
|
|
2944
|
-
return
|
|
3028
|
+
"search-end": (l = e.addConfig) != null && l.inSearch ? () => {
|
|
3029
|
+
var E;
|
|
3030
|
+
return i("div", {
|
|
2945
3031
|
class: "pro-curd-list-search-end"
|
|
2946
|
-
}, [
|
|
3032
|
+
}, [i(pt, (E = e.addConfig) == null ? void 0 : E.buttonProps, null)]);
|
|
2947
3033
|
} : void 0,
|
|
2948
|
-
"table-toolbarExtra": (
|
|
3034
|
+
"table-toolbarExtra": (g = e.addConfig) != null && g.inTable ? (E) => {
|
|
2949
3035
|
var I;
|
|
2950
|
-
return
|
|
3036
|
+
return i(le, null, [i(pt, (I = e.addConfig) == null ? void 0 : I.buttonProps, null), E]);
|
|
2951
3037
|
} : void 0,
|
|
2952
3038
|
...t,
|
|
2953
|
-
search: t.search ? (
|
|
2954
|
-
table: t.table ? (
|
|
2955
|
-
pagination: t.pagination ? (
|
|
3039
|
+
search: t.search ? (E) => t.search(E, f.value) : void 0,
|
|
3040
|
+
table: t.table ? (E) => t.table(E, S.value) : void 0,
|
|
3041
|
+
pagination: t.pagination ? (E) => t.pagination(E, p.value) : void 0
|
|
2956
3042
|
}) : null;
|
|
2957
3043
|
};
|
|
2958
3044
|
}
|
|
2959
|
-
}),
|
|
3045
|
+
}), Fa = w(() => {
|
|
2960
3046
|
const {
|
|
2961
3047
|
listProps: e
|
|
2962
|
-
} =
|
|
2963
|
-
return () =>
|
|
2964
|
-
}),
|
|
3048
|
+
} = oe();
|
|
3049
|
+
return () => i(Ur, $(e == null ? void 0 : e.value, "slots"), m(e == null ? void 0 : e.value, "slots"));
|
|
3050
|
+
}), Br = () => ({
|
|
2965
3051
|
signName: {
|
|
2966
3052
|
type: String
|
|
2967
3053
|
}
|
|
2968
|
-
}),
|
|
3054
|
+
}), rt = w({
|
|
2969
3055
|
props: {
|
|
2970
|
-
...
|
|
3056
|
+
...Br()
|
|
2971
3057
|
},
|
|
2972
3058
|
setup: (e, {
|
|
2973
3059
|
slots: t,
|
|
@@ -2979,78 +3065,78 @@ const Ar = () => ({
|
|
|
2979
3065
|
formElementMap: n,
|
|
2980
3066
|
curdState: u,
|
|
2981
3067
|
formColumns: c,
|
|
2982
|
-
getSignColumns:
|
|
2983
|
-
sendCurdEvent:
|
|
2984
|
-
} =
|
|
2985
|
-
r(
|
|
2986
|
-
const h = O(() => e.signName ?
|
|
2987
|
-
var
|
|
2988
|
-
u.addAction =
|
|
3068
|
+
getSignColumns: s,
|
|
3069
|
+
sendCurdEvent: d
|
|
3070
|
+
} = oe(), y = z();
|
|
3071
|
+
r(Se(e.formMethods || [], y));
|
|
3072
|
+
const h = O(() => e.signName ? s(e.signName) : c.value), f = () => {
|
|
3073
|
+
var l;
|
|
3074
|
+
u.addAction = Oe.NORMAL, (l = y.value) == null || l.submit();
|
|
2989
3075
|
}, S = () => {
|
|
2990
|
-
var
|
|
2991
|
-
u.addAction =
|
|
2992
|
-
},
|
|
3076
|
+
var l;
|
|
3077
|
+
u.addAction = Oe.CONTINUE, (l = y.value) == null || l.submit();
|
|
3078
|
+
}, p = [
|
|
2993
3079
|
{
|
|
2994
|
-
value:
|
|
3080
|
+
value: re.RESET,
|
|
2995
3081
|
label: "\u91CD\u7F6E"
|
|
2996
3082
|
},
|
|
2997
3083
|
{
|
|
2998
|
-
value:
|
|
3084
|
+
value: re.SUBMIT,
|
|
2999
3085
|
label: "\u63D0\u4EA4",
|
|
3000
3086
|
extraProps: {
|
|
3001
3087
|
type: "primary"
|
|
3002
3088
|
}
|
|
3003
3089
|
},
|
|
3004
3090
|
{
|
|
3005
|
-
value:
|
|
3091
|
+
value: re.CONTINUE,
|
|
3006
3092
|
label: "\u786E\u5B9A\u5E76\u7EE7\u7EED",
|
|
3007
3093
|
extraProps: {
|
|
3008
3094
|
type: "primary"
|
|
3009
3095
|
},
|
|
3010
3096
|
show: !1
|
|
3011
3097
|
}
|
|
3012
|
-
],
|
|
3013
|
-
o.onFinish || (u.mode ===
|
|
3014
|
-
action:
|
|
3015
|
-
type:
|
|
3016
|
-
values:
|
|
3017
|
-
}) :
|
|
3018
|
-
action:
|
|
3019
|
-
type:
|
|
3020
|
-
values:
|
|
3098
|
+
], v = (l) => {
|
|
3099
|
+
o.onFinish || (u.mode === D.EDIT ? d({
|
|
3100
|
+
action: D.EDIT,
|
|
3101
|
+
type: B.EXECUTE,
|
|
3102
|
+
values: l
|
|
3103
|
+
}) : d({
|
|
3104
|
+
action: D.ADD,
|
|
3105
|
+
type: B.EXECUTE,
|
|
3106
|
+
values: l
|
|
3021
3107
|
}));
|
|
3022
|
-
},
|
|
3023
|
-
return () =>
|
|
3024
|
-
ref:
|
|
3108
|
+
}, N = Q()(U.ProFormKey);
|
|
3109
|
+
return () => N ? i(N, K({
|
|
3110
|
+
ref: y,
|
|
3025
3111
|
class: "pro-curd-form"
|
|
3026
3112
|
}, $(e, "operate"), {
|
|
3027
3113
|
elementMap: e.elementMap || a,
|
|
3028
3114
|
formElementMap: e.formElementMap || n,
|
|
3029
3115
|
columns: e.columns || h.value,
|
|
3030
|
-
readonly: u.mode ===
|
|
3116
|
+
readonly: u.mode === D.DETAIL,
|
|
3031
3117
|
model: e.model || u.detailData,
|
|
3032
|
-
hideRequiredMark: u.mode ===
|
|
3118
|
+
hideRequiredMark: u.mode === D.DETAIL,
|
|
3033
3119
|
operate: e.operate ? {
|
|
3034
|
-
items:
|
|
3120
|
+
items: p,
|
|
3035
3121
|
onSubmit: f,
|
|
3036
3122
|
onContinue: S,
|
|
3037
3123
|
...e.operate
|
|
3038
3124
|
} : void 0,
|
|
3039
|
-
onFinish:
|
|
3125
|
+
onFinish: v
|
|
3040
3126
|
}), t) : null;
|
|
3041
3127
|
}
|
|
3042
|
-
}),
|
|
3128
|
+
}), xa = w(() => {
|
|
3043
3129
|
const {
|
|
3044
3130
|
formProps: e
|
|
3045
|
-
} =
|
|
3046
|
-
return () =>
|
|
3047
|
-
}),
|
|
3131
|
+
} = oe();
|
|
3132
|
+
return () => i(rt, $(e == null ? void 0 : e.value, "slots"), m(e == null ? void 0 : e.value, "slots"));
|
|
3133
|
+
}), qr = () => ({
|
|
3048
3134
|
signName: {
|
|
3049
3135
|
type: String
|
|
3050
3136
|
}
|
|
3051
|
-
}),
|
|
3137
|
+
}), Vr = w({
|
|
3052
3138
|
props: {
|
|
3053
|
-
...
|
|
3139
|
+
...qr()
|
|
3054
3140
|
},
|
|
3055
3141
|
setup: (e, {
|
|
3056
3142
|
slots: t
|
|
@@ -3059,23 +3145,23 @@ const Ar = () => ({
|
|
|
3059
3145
|
curdState: r,
|
|
3060
3146
|
descColumns: o,
|
|
3061
3147
|
getSignColumns: a
|
|
3062
|
-
} =
|
|
3063
|
-
return () =>
|
|
3148
|
+
} = oe(), n = O(() => e.signName ? a(e.signName) : o.value);
|
|
3149
|
+
return () => i(Ar, K($(e, "signName", "model", "columns"), {
|
|
3064
3150
|
model: e.model || r.detailData,
|
|
3065
3151
|
columns: n.value
|
|
3066
3152
|
}), t);
|
|
3067
3153
|
}
|
|
3068
|
-
}),
|
|
3154
|
+
}), Ra = w(() => {
|
|
3069
3155
|
const {
|
|
3070
3156
|
descProps: e
|
|
3071
|
-
} =
|
|
3072
|
-
return () =>
|
|
3157
|
+
} = oe();
|
|
3158
|
+
return () => i(Vr, K({
|
|
3073
3159
|
class: "pro-curd-desc"
|
|
3074
3160
|
}, $(e == null ? void 0 : e.value, "slots")), m(e == null ? void 0 : e.value, "slots"));
|
|
3075
|
-
}),
|
|
3161
|
+
}), Et = () => ({
|
|
3076
3162
|
validMode: {
|
|
3077
3163
|
type: Array,
|
|
3078
|
-
default: [
|
|
3164
|
+
default: [D.ADD, D.DETAIL, D.EDIT]
|
|
3079
3165
|
},
|
|
3080
3166
|
loadingOpts: {
|
|
3081
3167
|
type: Object
|
|
@@ -3083,39 +3169,39 @@ const Ar = () => ({
|
|
|
3083
3169
|
overrideProps: {
|
|
3084
3170
|
type: Object
|
|
3085
3171
|
}
|
|
3086
|
-
}),
|
|
3172
|
+
}), ln = w({
|
|
3087
3173
|
props: {
|
|
3088
|
-
...
|
|
3174
|
+
...Et()
|
|
3089
3175
|
},
|
|
3090
3176
|
setup: (e, {
|
|
3091
3177
|
slots: t
|
|
3092
3178
|
}) => {
|
|
3093
|
-
const r = Q(), o = r(
|
|
3179
|
+
const r = Q(), o = r(U.ModalKey), a = r(U.LoadingKey), {
|
|
3094
3180
|
curdState: n,
|
|
3095
3181
|
getOperate: u
|
|
3096
|
-
} =
|
|
3097
|
-
n.mode = void 0,
|
|
3098
|
-
},
|
|
3182
|
+
} = oe(), c = () => {
|
|
3183
|
+
n.mode = void 0, At(n.detailData, {}), n.detailLoading = !1, n.addAction = void 0;
|
|
3184
|
+
}, s = W(Et());
|
|
3099
3185
|
return () => {
|
|
3100
|
-
var
|
|
3101
|
-
const
|
|
3102
|
-
return !
|
|
3186
|
+
var y;
|
|
3187
|
+
const d = n.mode;
|
|
3188
|
+
return !ye(e.validMode, (h) => h === d) || !o ? null : i(o, K({
|
|
3103
3189
|
class: "pro-curd-modal"
|
|
3104
|
-
}, $(e,
|
|
3105
|
-
visible:
|
|
3106
|
-
title: e.title || ((
|
|
3190
|
+
}, $(e, s), {
|
|
3191
|
+
visible: ye(e.validMode, (h) => h === d),
|
|
3192
|
+
title: e.title || ((y = u(n.mode)) == null ? void 0 : y.label),
|
|
3107
3193
|
confirmLoading: n.operateLoading,
|
|
3108
|
-
maskClosable: n.mode ===
|
|
3109
|
-
footer: n.detailLoading || n.mode ===
|
|
3194
|
+
maskClosable: n.mode === D.DETAIL,
|
|
3195
|
+
footer: n.detailLoading || n.mode === D.DETAIL ? !1 : void 0
|
|
3110
3196
|
}, e.overrideProps, {
|
|
3111
3197
|
onCancel: c
|
|
3112
3198
|
}), {
|
|
3113
3199
|
default: () => {
|
|
3114
3200
|
var h;
|
|
3115
|
-
return [n.detailLoading && a ?
|
|
3201
|
+
return [n.detailLoading && a ? i(a, K({
|
|
3116
3202
|
loading: !0
|
|
3117
3203
|
}, e.loadingOpts), {
|
|
3118
|
-
default: () => [
|
|
3204
|
+
default: () => [i("div", {
|
|
3119
3205
|
class: "pro-curd-modal-loading-dom"
|
|
3120
3206
|
}, null)]
|
|
3121
3207
|
}) : (h = t.default) == null ? void 0 : h.call(t)];
|
|
@@ -3124,7 +3210,7 @@ const Ar = () => ({
|
|
|
3124
3210
|
});
|
|
3125
3211
|
};
|
|
3126
3212
|
}
|
|
3127
|
-
}),
|
|
3213
|
+
}), La = w({
|
|
3128
3214
|
props: {
|
|
3129
3215
|
modalProps: Object,
|
|
3130
3216
|
formProps: Object
|
|
@@ -3132,139 +3218,143 @@ const Ar = () => ({
|
|
|
3132
3218
|
setup: (e, {
|
|
3133
3219
|
slots: t
|
|
3134
3220
|
}) => {
|
|
3135
|
-
const r =
|
|
3136
|
-
return () =>
|
|
3221
|
+
const r = z(), o = fe(t, "modal"), a = fe(t, "form");
|
|
3222
|
+
return () => i(ln, K(e.modalProps, {
|
|
3137
3223
|
onOk: () => {
|
|
3138
3224
|
var n;
|
|
3139
3225
|
(n = r.value) == null || n.submit();
|
|
3140
3226
|
}
|
|
3141
3227
|
}), {
|
|
3142
|
-
default: () => [
|
|
3228
|
+
default: () => [i(rt, K({
|
|
3143
3229
|
ref: r
|
|
3144
3230
|
}, e.formProps), a)],
|
|
3145
3231
|
...o
|
|
3146
3232
|
});
|
|
3147
3233
|
}
|
|
3148
|
-
}),
|
|
3234
|
+
}), ja = w(() => {
|
|
3149
3235
|
const {
|
|
3150
3236
|
modalProps: e,
|
|
3151
3237
|
formProps: t
|
|
3152
|
-
} =
|
|
3153
|
-
return () =>
|
|
3238
|
+
} = oe(), r = z();
|
|
3239
|
+
return () => i(ln, K($(e == null ? void 0 : e.value, "slots"), {
|
|
3154
3240
|
onOk: () => {
|
|
3155
3241
|
var o;
|
|
3156
3242
|
(o = r.value) == null || o.submit();
|
|
3157
3243
|
}
|
|
3158
3244
|
}), {
|
|
3159
|
-
default: () => [
|
|
3245
|
+
default: () => [i(rt, K({
|
|
3160
3246
|
ref: r
|
|
3161
3247
|
}, $(t == null ? void 0 : t.value, "slots")), m(t == null ? void 0 : t.value, "slots"))],
|
|
3162
3248
|
...m(e == null ? void 0 : e.value, "slots")
|
|
3163
3249
|
});
|
|
3164
3250
|
});
|
|
3165
3251
|
export {
|
|
3166
|
-
|
|
3167
|
-
|
|
3168
|
-
|
|
3169
|
-
|
|
3170
|
-
|
|
3171
|
-
|
|
3172
|
-
|
|
3173
|
-
|
|
3174
|
-
|
|
3175
|
-
|
|
3176
|
-
|
|
3177
|
-
|
|
3178
|
-
|
|
3179
|
-
|
|
3180
|
-
|
|
3181
|
-
|
|
3182
|
-
|
|
3183
|
-
|
|
3184
|
-
|
|
3185
|
-
|
|
3186
|
-
|
|
3187
|
-
|
|
3188
|
-
|
|
3189
|
-
|
|
3190
|
-
|
|
3191
|
-
|
|
3192
|
-
|
|
3193
|
-
|
|
3194
|
-
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
|
|
3206
|
-
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
|
-
|
|
3210
|
-
|
|
3211
|
-
|
|
3212
|
-
|
|
3213
|
-
|
|
3214
|
-
|
|
3215
|
-
|
|
3216
|
-
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
|
|
3221
|
-
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3225
|
-
|
|
3226
|
-
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
|
|
3237
|
-
|
|
3238
|
-
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
|
|
3251
|
-
|
|
3252
|
-
|
|
3252
|
+
pt as AddButton,
|
|
3253
|
+
pr as ColumnSetting,
|
|
3254
|
+
D as CurdAction,
|
|
3255
|
+
Oe as CurdAddAction,
|
|
3256
|
+
me as CurdCurrentMode,
|
|
3257
|
+
sn as CurdMethods,
|
|
3258
|
+
B as CurdSubAction,
|
|
3259
|
+
U as ElementKeys,
|
|
3260
|
+
re as FormAction,
|
|
3261
|
+
ma as FormRulePrefixMap,
|
|
3262
|
+
ba as LogonUser,
|
|
3263
|
+
tn as LogonUserKey,
|
|
3264
|
+
ze as ModalCurdOpe,
|
|
3265
|
+
ga as MustLogon,
|
|
3266
|
+
Ve as PageHeader,
|
|
3267
|
+
Sa as PerSuffix,
|
|
3268
|
+
Pa as Permission,
|
|
3269
|
+
ra as ProConfig,
|
|
3270
|
+
Ge as ProCurd,
|
|
3271
|
+
Vr as ProCurdDesc,
|
|
3272
|
+
Ra as ProCurdDescConnect,
|
|
3273
|
+
rt as ProCurdForm,
|
|
3274
|
+
xa as ProCurdFormConnect,
|
|
3275
|
+
Ur as ProCurdList,
|
|
3276
|
+
Fa as ProCurdListConnect,
|
|
3277
|
+
ln as ProCurdModal,
|
|
3278
|
+
La as ProCurdModalForm,
|
|
3279
|
+
ja as ProCurdModalFormConnect,
|
|
3280
|
+
Ar as ProDesc,
|
|
3281
|
+
fa as ProForm,
|
|
3282
|
+
da as ProFormList,
|
|
3283
|
+
Pe as ProGrid,
|
|
3284
|
+
Oa as ProLayout,
|
|
3285
|
+
Or as ProList,
|
|
3286
|
+
Ka as ProModalCurd,
|
|
3287
|
+
Fe as ProModule,
|
|
3288
|
+
an as ProOperate,
|
|
3289
|
+
Ca as ProPage,
|
|
3290
|
+
Da as ProPageCurd,
|
|
3291
|
+
ya as ProSearchForm,
|
|
3292
|
+
Na as ProShowDate,
|
|
3293
|
+
Ma as ProShowDigit,
|
|
3294
|
+
Ta as ProShowOptions,
|
|
3295
|
+
Be as ProShowText,
|
|
3296
|
+
Ia as ProShowTree,
|
|
3297
|
+
pa as ProTable,
|
|
3298
|
+
mr as ProTip,
|
|
3299
|
+
Kr as ProTypography,
|
|
3300
|
+
$a as ProUploadList,
|
|
3301
|
+
Aa as ProUploaderText,
|
|
3302
|
+
Ea as ProValue,
|
|
3303
|
+
Ie as RequestAction,
|
|
3304
|
+
Gn as RouterMethods,
|
|
3305
|
+
ke as SearchMode,
|
|
3306
|
+
ar as Wrapper,
|
|
3307
|
+
Xt as convertPathToList,
|
|
3308
|
+
Hn as convertResData,
|
|
3309
|
+
Se as createExpose,
|
|
3310
|
+
ia as createExposeObj,
|
|
3311
|
+
va as createFormItemCompFn,
|
|
3312
|
+
wa as createModule,
|
|
3313
|
+
aa as createProConfig,
|
|
3314
|
+
Ir as defaultPage,
|
|
3315
|
+
fe as filterSlotsByPrefix,
|
|
3316
|
+
de as getColumnFormItemName,
|
|
3317
|
+
zt as getColumnValueType,
|
|
3318
|
+
rr as getFirstPropName,
|
|
3319
|
+
tr as getRealRender,
|
|
3320
|
+
sr as getSignValue,
|
|
3321
|
+
cr as getValidValues,
|
|
3322
|
+
nr as isValidConfig,
|
|
3323
|
+
xe as isValidNode,
|
|
3324
|
+
Ue as mergeState,
|
|
3325
|
+
la as mergeStateToList,
|
|
3326
|
+
be as proBaseProps,
|
|
3327
|
+
Rr as provideProCurd,
|
|
3328
|
+
Qt as provideProFormList,
|
|
3329
|
+
Zn as provideProModule,
|
|
3330
|
+
tt as renderColumn,
|
|
3331
|
+
Ne as renderElement,
|
|
3332
|
+
nt as renderElements,
|
|
3333
|
+
Ht as renderInputColumn,
|
|
3334
|
+
un as showValue,
|
|
3335
|
+
yr as useAccess,
|
|
3336
|
+
ha as useAccessMgr,
|
|
3337
|
+
zn as useComposeRequestActor,
|
|
3338
|
+
ca as useDispatchMeta,
|
|
3339
|
+
Jn as useDispatchStore,
|
|
3340
|
+
oa as useDoneRequestActor,
|
|
3341
|
+
ua as useFailedRequestActor,
|
|
3342
|
+
ir as useFormSubmit,
|
|
3253
3343
|
Q as useGetCompByKey,
|
|
3254
|
-
|
|
3255
|
-
|
|
3256
|
-
|
|
3257
|
-
|
|
3258
|
-
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
|
|
3266
|
-
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
|
|
3344
|
+
nn as useHasPer,
|
|
3345
|
+
rn as useHasPer2,
|
|
3346
|
+
vr as useLogonUser,
|
|
3347
|
+
Wn as useMetaRegister,
|
|
3348
|
+
et as useModuleEvent,
|
|
3349
|
+
ne as useProConfig,
|
|
3350
|
+
oe as useProCurd,
|
|
3351
|
+
Zt as useProForm,
|
|
3352
|
+
Yt as useProFormList,
|
|
3353
|
+
ta as useProModal,
|
|
3354
|
+
ge as useProModule,
|
|
3355
|
+
ea as useProMsg,
|
|
3356
|
+
na as useProNotify,
|
|
3357
|
+
qt as useProRouter,
|
|
3358
|
+
Cr as useProTable,
|
|
3359
|
+
sa as useReadStore
|
|
3270
3360
|
};
|