general-basic-form 2.0.40 → 2.0.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +533 -533
- package/dist/index.d.ts +16 -16
- package/dist/index.js +162 -168
- package/dist/index.umd.cjs +1 -1
- package/dist/style.css +1 -1
- package/package.json +56 -61
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as k, inject as h, resolveComponent as
|
|
1
|
+
import { defineComponent as k, inject as h, resolveComponent as d, openBlock as o, createBlock as c, mergeProps as b, withKeys as ne, createSlots as J, renderList as $, withCtx as f, resolveDynamicComponent as W, createCommentVNode as y, ref as g, unref as m, resolveDirective as U, withDirectives as C, createElementBlock as S, createVNode as T, createElementVNode as H, computed as j, onBeforeUnmount as oe, normalizeStyle as re, createTextVNode as I, toDisplayString as D, h as se, normalizeProps as ae, guardReactiveProps as le, Fragment as L, provide as O, renderSlot as Q, vShow as ie, watch as ue } from "vue";
|
|
2
2
|
import { useRoute as ce } from "vue-router";
|
|
3
3
|
const X = {
|
|
4
4
|
placeholder: "请输入",
|
|
@@ -14,11 +14,11 @@ const X = {
|
|
|
14
14
|
filterable: !0,
|
|
15
15
|
clearable: !0,
|
|
16
16
|
style: "width: 200px"
|
|
17
|
-
},
|
|
17
|
+
}, me = k({
|
|
18
18
|
components: {
|
|
19
19
|
InputArchive: (e) => {
|
|
20
|
-
const { templateEle:
|
|
21
|
-
return
|
|
20
|
+
const { templateEle: n } = e;
|
|
21
|
+
return n();
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
props: {
|
|
@@ -26,8 +26,8 @@ const X = {
|
|
|
26
26
|
// null就是any
|
|
27
27
|
},
|
|
28
28
|
setup() {
|
|
29
|
-
const e = h("queryParams", {}),
|
|
30
|
-
return { queryParams: e, getList:
|
|
29
|
+
const e = h("queryParams", {}), n = h("getList"), t = h("size");
|
|
30
|
+
return { queryParams: e, getList: n, size: t };
|
|
31
31
|
},
|
|
32
32
|
data() {
|
|
33
33
|
return {
|
|
@@ -54,24 +54,24 @@ const X = {
|
|
|
54
54
|
// console.log(val);
|
|
55
55
|
// },
|
|
56
56
|
// },
|
|
57
|
-
}), w = (e,
|
|
57
|
+
}), w = (e, n) => {
|
|
58
58
|
const t = e.__vccOpts || e;
|
|
59
|
-
for (const [a, l] of
|
|
59
|
+
for (const [a, l] of n)
|
|
60
60
|
t[a] = l;
|
|
61
61
|
return t;
|
|
62
62
|
};
|
|
63
|
-
function
|
|
64
|
-
const i =
|
|
65
|
-
return
|
|
63
|
+
function de(e, n, t, a, l, s) {
|
|
64
|
+
const i = d("el-input");
|
|
65
|
+
return o(), c(i, b({
|
|
66
66
|
onKeydown: ne(e.getList, ["enter"]),
|
|
67
67
|
modelValue: e.queryParams[e.item.prop],
|
|
68
|
-
"onUpdate:modelValue":
|
|
68
|
+
"onUpdate:modelValue": n[0] || (n[0] = (r) => e.queryParams[e.item.prop] = r),
|
|
69
69
|
size: e.size
|
|
70
70
|
}, e.inputSetting), J({ _: 2 }, [
|
|
71
71
|
$(e.item.template, (r, _) => ({
|
|
72
72
|
name: _,
|
|
73
73
|
fn: f(() => [
|
|
74
|
-
r ? (
|
|
74
|
+
r ? (o(), c(W(e.currentInputComponent()), {
|
|
75
75
|
key: _,
|
|
76
76
|
templateEle: r
|
|
77
77
|
}, null, 8, ["templateEle"])) : y("", !0)
|
|
@@ -79,22 +79,22 @@ function me(e, o, t, a, l, s) {
|
|
|
79
79
|
}))
|
|
80
80
|
]), 1040, ["onKeydown", "modelValue", "size"]);
|
|
81
81
|
}
|
|
82
|
-
const K = /* @__PURE__ */ w(
|
|
82
|
+
const K = /* @__PURE__ */ w(me, [["render", de]]), _e = /* @__PURE__ */ k({
|
|
83
83
|
__name: "index",
|
|
84
84
|
props: {
|
|
85
85
|
item: {}
|
|
86
86
|
},
|
|
87
87
|
setup(e) {
|
|
88
|
-
const { item:
|
|
88
|
+
const { item: n } = e, t = h("queryParams", {}), a = h("size"), l = g({
|
|
89
89
|
...X,
|
|
90
|
-
...
|
|
90
|
+
...n.inputSetting
|
|
91
91
|
});
|
|
92
92
|
return (s, i) => {
|
|
93
|
-
const r =
|
|
94
|
-
return
|
|
95
|
-
modelValue:
|
|
96
|
-
"onUpdate:modelValue": i[0] || (i[0] = (_) =>
|
|
97
|
-
size:
|
|
93
|
+
const r = d("el-input-number");
|
|
94
|
+
return o(), c(r, b({
|
|
95
|
+
modelValue: m(t)[s.item.prop],
|
|
96
|
+
"onUpdate:modelValue": i[0] || (i[0] = (_) => m(t)[s.item.prop] = _),
|
|
97
|
+
size: m(a)
|
|
98
98
|
}, l.value), null, 16, ["modelValue", "size"]);
|
|
99
99
|
};
|
|
100
100
|
}
|
|
@@ -104,18 +104,18 @@ const K = /* @__PURE__ */ w(de, [["render", me]]), _e = /* @__PURE__ */ k({
|
|
|
104
104
|
item: {}
|
|
105
105
|
},
|
|
106
106
|
setup(e) {
|
|
107
|
-
const { item:
|
|
107
|
+
const { item: n } = e, {
|
|
108
108
|
graphicSrc: t = "",
|
|
109
109
|
graphicAlt: a = "",
|
|
110
110
|
getGraphic: l = () => {
|
|
111
111
|
},
|
|
112
112
|
key: s
|
|
113
|
-
} =
|
|
113
|
+
} = n, { formLoading: i, updateFormLoading: r } = h(Z), _ = async () => {
|
|
114
114
|
l && !i.value && await l();
|
|
115
115
|
};
|
|
116
116
|
return (p, P) => {
|
|
117
|
-
const
|
|
118
|
-
return C((
|
|
117
|
+
const q = U("loading");
|
|
118
|
+
return C((o(), S("div", fe, [
|
|
119
119
|
T(K, {
|
|
120
120
|
item: p.item,
|
|
121
121
|
class: "input"
|
|
@@ -123,22 +123,22 @@ const K = /* @__PURE__ */ w(de, [["render", me]]), _e = /* @__PURE__ */ k({
|
|
|
123
123
|
H("img", {
|
|
124
124
|
class: "graphic",
|
|
125
125
|
onClick: _,
|
|
126
|
-
src:
|
|
127
|
-
alt:
|
|
126
|
+
src: m(t),
|
|
127
|
+
alt: m(a) || `${m(s)}`
|
|
128
128
|
}, null, 8, ye)
|
|
129
129
|
])), [
|
|
130
|
-
[
|
|
130
|
+
[q, m(i)]
|
|
131
131
|
]);
|
|
132
132
|
};
|
|
133
133
|
}
|
|
134
134
|
});
|
|
135
|
-
const ve = /* @__PURE__ */ w(he, [["__scopeId", "data-v-
|
|
135
|
+
const ve = /* @__PURE__ */ w(he, [["__scopeId", "data-v-006751c3"]]), B = "获取验证码", ge = 60, be = /* @__PURE__ */ k({
|
|
136
136
|
__name: "verification-button",
|
|
137
137
|
props: {
|
|
138
138
|
getSmscode: { type: Function }
|
|
139
139
|
},
|
|
140
140
|
setup(e) {
|
|
141
|
-
const { getSmscode:
|
|
141
|
+
const { getSmscode: n } = e, t = g(B), a = g(null), l = j(() => t.value === B), s = () => {
|
|
142
142
|
a && (clearInterval(a.value), a.value = null, t.value = B);
|
|
143
143
|
}, i = async () => {
|
|
144
144
|
if (t.value === B)
|
|
@@ -148,16 +148,16 @@ const ve = /* @__PURE__ */ w(he, [["__scopeId", "data-v-86d4d3d1"]]), B = "获
|
|
|
148
148
|
return;
|
|
149
149
|
} else
|
|
150
150
|
t.value = Number(t.value) - 1;
|
|
151
|
-
}, 1e3),
|
|
152
|
-
await
|
|
151
|
+
}, 1e3), n)
|
|
152
|
+
await n() === !1 && s();
|
|
153
153
|
else
|
|
154
154
|
return;
|
|
155
155
|
};
|
|
156
156
|
return oe(() => {
|
|
157
157
|
s();
|
|
158
158
|
}), (r, _) => {
|
|
159
|
-
const p =
|
|
160
|
-
return
|
|
159
|
+
const p = d("el-button");
|
|
160
|
+
return o(), c(p, {
|
|
161
161
|
class: "verifiaction-button",
|
|
162
162
|
style: re({
|
|
163
163
|
color: l.value ? "var(--color-primary, #409EFF)" : "var(--text-color-placeholder, #A8ABB2)",
|
|
@@ -173,27 +173,27 @@ const ve = /* @__PURE__ */ w(he, [["__scopeId", "data-v-86d4d3d1"]]), B = "获
|
|
|
173
173
|
};
|
|
174
174
|
}
|
|
175
175
|
});
|
|
176
|
-
const ke = /* @__PURE__ */ w(be, [["__scopeId", "data-v-
|
|
176
|
+
const ke = /* @__PURE__ */ w(be, [["__scopeId", "data-v-4074e137"]]), Se = /* @__PURE__ */ k({
|
|
177
177
|
__name: "index",
|
|
178
178
|
props: {
|
|
179
179
|
item: {}
|
|
180
180
|
},
|
|
181
181
|
setup(e) {
|
|
182
|
-
const { item:
|
|
182
|
+
const { item: n } = e, t = n;
|
|
183
183
|
return t.template = {
|
|
184
184
|
append: () => se(ke, {
|
|
185
185
|
getSmscode: t.getSmscode
|
|
186
186
|
})
|
|
187
|
-
}, (a, l) => (
|
|
188
|
-
item:
|
|
187
|
+
}, (a, l) => (o(), c(K, {
|
|
188
|
+
item: m(t),
|
|
189
189
|
class: "input"
|
|
190
190
|
}, null, 8, ["item"]));
|
|
191
191
|
}
|
|
192
192
|
}), ze = k({
|
|
193
193
|
components: {
|
|
194
194
|
slotArchive: (e) => {
|
|
195
|
-
const { templateEle:
|
|
196
|
-
return
|
|
195
|
+
const { templateEle: n } = e;
|
|
196
|
+
return n();
|
|
197
197
|
}
|
|
198
198
|
},
|
|
199
199
|
props: {
|
|
@@ -215,13 +215,13 @@ const ke = /* @__PURE__ */ w(be, [["__scopeId", "data-v-a6c3916a"]]), Se = /* @_
|
|
|
215
215
|
}
|
|
216
216
|
}
|
|
217
217
|
});
|
|
218
|
-
function $e(e,
|
|
219
|
-
const i =
|
|
220
|
-
return
|
|
218
|
+
function $e(e, n, t, a, l, s) {
|
|
219
|
+
const i = d("el-divider");
|
|
220
|
+
return o(), c(i, ae(le(e.dividerSetting)), J({ _: 2 }, [
|
|
221
221
|
$(e.item.template, (r, _) => ({
|
|
222
222
|
name: _,
|
|
223
223
|
fn: f(() => [
|
|
224
|
-
r ? (
|
|
224
|
+
r ? (o(), c(W(e.currentInputComponent()), {
|
|
225
225
|
key: _,
|
|
226
226
|
templateEle: r
|
|
227
227
|
}, null, 8, ["templateEle"])) : y("", !0)
|
|
@@ -229,25 +229,25 @@ function $e(e, o, t, a, l, s) {
|
|
|
229
229
|
}))
|
|
230
230
|
]), 1040);
|
|
231
231
|
}
|
|
232
|
-
const Pe = /* @__PURE__ */ w(ze, [["render", $e]]),
|
|
232
|
+
const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), qe = /* @__PURE__ */ k({
|
|
233
233
|
__name: "index",
|
|
234
234
|
props: {
|
|
235
235
|
item: {}
|
|
236
236
|
},
|
|
237
237
|
setup(e) {
|
|
238
|
-
const { item:
|
|
239
|
-
...
|
|
238
|
+
const { item: n } = e, t = h("queryParams", {}), a = h("size"), l = g({
|
|
239
|
+
...n.radioGroupSetting
|
|
240
240
|
});
|
|
241
241
|
return (s, i) => {
|
|
242
|
-
const r =
|
|
243
|
-
return
|
|
244
|
-
modelValue:
|
|
245
|
-
"onUpdate:modelValue": i[0] || (i[0] = (p) =>
|
|
246
|
-
size:
|
|
242
|
+
const r = d("el-radio"), _ = d("el-radio-group");
|
|
243
|
+
return o(), c(_, b({
|
|
244
|
+
modelValue: m(t)[s.item.prop],
|
|
245
|
+
"onUpdate:modelValue": i[0] || (i[0] = (p) => m(t)[s.item.prop] = p),
|
|
246
|
+
size: m(a)
|
|
247
247
|
}, l.value), {
|
|
248
248
|
default: f(() => [
|
|
249
|
-
(
|
|
250
|
-
size:
|
|
249
|
+
(o(!0), S(L, null, $(s.item.option || [], (p) => (o(), c(r, b({
|
|
250
|
+
size: m(a),
|
|
251
251
|
key: p.label
|
|
252
252
|
}, p), {
|
|
253
253
|
default: f(() => [
|
|
@@ -260,25 +260,25 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
260
260
|
}, 16, ["modelValue", "size"]);
|
|
261
261
|
};
|
|
262
262
|
}
|
|
263
|
-
}),
|
|
263
|
+
}), Ve = /* @__PURE__ */ k({
|
|
264
264
|
__name: "index",
|
|
265
265
|
props: {
|
|
266
266
|
item: {}
|
|
267
267
|
},
|
|
268
268
|
setup(e) {
|
|
269
|
-
const { item:
|
|
270
|
-
...
|
|
269
|
+
const { item: n } = e, t = h("queryParams", {}), a = h("size"), l = g({
|
|
270
|
+
...n.checkboxGroupSetting
|
|
271
271
|
});
|
|
272
272
|
return (s, i) => {
|
|
273
|
-
const r =
|
|
274
|
-
return
|
|
275
|
-
modelValue:
|
|
276
|
-
"onUpdate:modelValue": i[0] || (i[0] = (p) =>
|
|
277
|
-
size:
|
|
273
|
+
const r = d("el-checkbox"), _ = d("el-checkbox-group");
|
|
274
|
+
return o(), c(_, b({
|
|
275
|
+
modelValue: m(t)[s.item.prop],
|
|
276
|
+
"onUpdate:modelValue": i[0] || (i[0] = (p) => m(t)[s.item.prop] = p),
|
|
277
|
+
size: m(a)
|
|
278
278
|
}, l.value), {
|
|
279
279
|
default: f(() => [
|
|
280
|
-
(
|
|
281
|
-
size:
|
|
280
|
+
(o(!0), S(L, null, $(s.item.option || [], (p) => (o(), c(r, b({
|
|
281
|
+
size: m(a),
|
|
282
282
|
key: p.label
|
|
283
283
|
}, p), {
|
|
284
284
|
default: f(() => [
|
|
@@ -297,16 +297,16 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
297
297
|
item: {}
|
|
298
298
|
},
|
|
299
299
|
setup(e) {
|
|
300
|
-
const { item:
|
|
300
|
+
const { item: n } = e, t = h("queryParams", {}), a = h("size"), l = g({
|
|
301
301
|
...pe,
|
|
302
|
-
...
|
|
302
|
+
...n.datePackerSetting
|
|
303
303
|
});
|
|
304
304
|
return (s, i) => {
|
|
305
|
-
const r =
|
|
306
|
-
return
|
|
307
|
-
modelValue:
|
|
308
|
-
"onUpdate:modelValue": i[0] || (i[0] = (_) =>
|
|
309
|
-
size:
|
|
305
|
+
const r = d("el-date-picker");
|
|
306
|
+
return o(), c(r, b({
|
|
307
|
+
modelValue: m(t)[s.item.prop],
|
|
308
|
+
"onUpdate:modelValue": i[0] || (i[0] = (_) => m(t)[s.item.prop] = _),
|
|
309
|
+
size: m(a)
|
|
310
310
|
}, l.value), null, 16, ["modelValue", "size"]);
|
|
311
311
|
};
|
|
312
312
|
}
|
|
@@ -316,19 +316,19 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
316
316
|
item: {}
|
|
317
317
|
},
|
|
318
318
|
setup(e) {
|
|
319
|
-
const { item:
|
|
319
|
+
const { item: n } = e, t = h("queryParams", {}), a = h("size"), l = g({
|
|
320
320
|
...Y,
|
|
321
|
-
...
|
|
321
|
+
...n.selectSetting
|
|
322
322
|
});
|
|
323
323
|
return (s, i) => {
|
|
324
|
-
const r =
|
|
325
|
-
return
|
|
326
|
-
modelValue:
|
|
327
|
-
"onUpdate:modelValue": i[0] || (i[0] = (p) =>
|
|
328
|
-
size:
|
|
324
|
+
const r = d("el-option"), _ = d("el-select");
|
|
325
|
+
return o(), c(_, b({
|
|
326
|
+
modelValue: m(t)[s.item.prop],
|
|
327
|
+
"onUpdate:modelValue": i[0] || (i[0] = (p) => m(t)[s.item.prop] = p),
|
|
328
|
+
size: m(a)
|
|
329
329
|
}, l.value), {
|
|
330
330
|
default: f(() => [
|
|
331
|
-
(
|
|
331
|
+
(o(!0), S(L, null, $(s.item.option || [], (p) => (o(), c(r, {
|
|
332
332
|
key: p.value,
|
|
333
333
|
label: p.label,
|
|
334
334
|
value: p.value
|
|
@@ -344,16 +344,16 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
344
344
|
item: {}
|
|
345
345
|
},
|
|
346
346
|
setup(e) {
|
|
347
|
-
const { item:
|
|
347
|
+
const { item: n } = e, t = h("queryParams", {}), a = h("size"), l = g({
|
|
348
348
|
...Y,
|
|
349
|
-
...
|
|
349
|
+
...n.selectSetting
|
|
350
350
|
});
|
|
351
351
|
return (s, i) => {
|
|
352
|
-
const r =
|
|
353
|
-
return
|
|
354
|
-
modelValue:
|
|
355
|
-
"onUpdate:modelValue": i[0] || (i[0] = (_) =>
|
|
356
|
-
size:
|
|
352
|
+
const r = d("el-cascader");
|
|
353
|
+
return o(), c(r, b({
|
|
354
|
+
modelValue: m(t)[s.item.prop],
|
|
355
|
+
"onUpdate:modelValue": i[0] || (i[0] = (_) => m(t)[s.item.prop] = _),
|
|
356
|
+
size: m(a),
|
|
357
357
|
options: s.item.options || []
|
|
358
358
|
}, l.value), null, 16, ["modelValue", "size", "options"]);
|
|
359
359
|
};
|
|
@@ -366,8 +366,8 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
366
366
|
InputGraphicVerification: ve,
|
|
367
367
|
InputMobileVerification: Se,
|
|
368
368
|
Divider: Pe,
|
|
369
|
-
Radio:
|
|
370
|
-
Checkbox:
|
|
369
|
+
Radio: qe,
|
|
370
|
+
Checkbox: Ve,
|
|
371
371
|
DatePicker: Ie,
|
|
372
372
|
Select: Le,
|
|
373
373
|
Cascader: Ce
|
|
@@ -434,11 +434,12 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
434
434
|
},
|
|
435
435
|
data() {
|
|
436
436
|
return {
|
|
437
|
-
formLoading: this.loading || !1
|
|
437
|
+
formLoading: this.loading || !1,
|
|
438
|
+
trimRegex: /\S/
|
|
438
439
|
};
|
|
439
440
|
},
|
|
440
441
|
setup(e) {
|
|
441
|
-
const { size:
|
|
442
|
+
const { size: n, noUrlParameters: t, getList: a } = e, l = ce(), s = g({
|
|
442
443
|
...t ? {} : l == null ? void 0 : l.query
|
|
443
444
|
});
|
|
444
445
|
return O(
|
|
@@ -450,7 +451,7 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
450
451
|
/* 注入名 */
|
|
451
452
|
"size",
|
|
452
453
|
/* 值 */
|
|
453
|
-
|
|
454
|
+
n
|
|
454
455
|
), O(
|
|
455
456
|
/* 注入名 */
|
|
456
457
|
"getList",
|
|
@@ -462,8 +463,8 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
462
463
|
},
|
|
463
464
|
watch: {
|
|
464
465
|
formData: {
|
|
465
|
-
handler(e,
|
|
466
|
-
JSON.stringify(e) !== JSON.stringify(
|
|
466
|
+
handler(e, n) {
|
|
467
|
+
JSON.stringify(e) !== JSON.stringify(n) && (this.queryParams = {
|
|
467
468
|
...this.noUrlParameters ? {} : this.queryParams,
|
|
468
469
|
...e
|
|
469
470
|
});
|
|
@@ -484,21 +485,6 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
484
485
|
},
|
|
485
486
|
formLoading(e) {
|
|
486
487
|
this.loading !== e && this.$emit("update:loading", e);
|
|
487
|
-
},
|
|
488
|
-
noInputBlank: {
|
|
489
|
-
handler(e, o) {
|
|
490
|
-
if (e) {
|
|
491
|
-
const t = /\S/;
|
|
492
|
-
this.formItem.forEach((a) => {
|
|
493
|
-
a.type === "input" && ("rules" in a || (a.rules = []), a.rules.push({
|
|
494
|
-
pattern: t,
|
|
495
|
-
message: "请输入(不能仅输入空格)",
|
|
496
|
-
trigger: "blur"
|
|
497
|
-
}));
|
|
498
|
-
});
|
|
499
|
-
}
|
|
500
|
-
},
|
|
501
|
-
immediate: !0
|
|
502
488
|
}
|
|
503
489
|
},
|
|
504
490
|
provide() {
|
|
@@ -516,33 +502,41 @@ const Pe = /* @__PURE__ */ w(ze, [["render", $e]]), Ve = /* @__PURE__ */ k({
|
|
|
516
502
|
/** 搜索按钮操作 */
|
|
517
503
|
handleQuery() {
|
|
518
504
|
var t;
|
|
519
|
-
const e = { page: 1, limit: 10 },
|
|
505
|
+
const e = { page: 1, limit: 10 }, n = {
|
|
520
506
|
...(t = this.$route) == null ? void 0 : t.query,
|
|
521
507
|
...this.queryParams,
|
|
522
508
|
...e
|
|
523
509
|
};
|
|
524
510
|
this.noUrlParameters || this.$router.push({
|
|
525
|
-
query: { ...
|
|
511
|
+
query: { ...n }
|
|
526
512
|
}), this.getList({
|
|
527
|
-
...
|
|
513
|
+
...n
|
|
528
514
|
});
|
|
529
515
|
},
|
|
530
516
|
/** 重置按钮操作 */
|
|
531
517
|
async resetQuery() {
|
|
532
|
-
var
|
|
518
|
+
var n;
|
|
533
519
|
this.$refs.queryFormRef.resetFields();
|
|
534
520
|
const e = { page: 1 };
|
|
535
521
|
this.noUrlParameters || await this.$router.push({
|
|
536
522
|
query: { ...e }
|
|
537
523
|
}), this.queryParams = {
|
|
538
|
-
...this.noUrlParameters ? {} : (
|
|
524
|
+
...this.noUrlParameters ? {} : (n = this.$route) == null ? void 0 : n.query
|
|
539
525
|
}, this.afterReset(), this.handleQuery();
|
|
526
|
+
},
|
|
527
|
+
getItemRules(e) {
|
|
528
|
+
const { type: n, rules: t = [] } = e, a = [...t];
|
|
529
|
+
return this.noInputBlank && n === "input" && a.push({
|
|
530
|
+
pattern: this.trimRegex,
|
|
531
|
+
message: "请输入(不能仅输入空格)",
|
|
532
|
+
trigger: "blur"
|
|
533
|
+
}), a;
|
|
540
534
|
}
|
|
541
535
|
}
|
|
542
536
|
});
|
|
543
|
-
function we(e,
|
|
544
|
-
const i =
|
|
545
|
-
return C((
|
|
537
|
+
function we(e, n, t, a, l, s) {
|
|
538
|
+
const i = d("Input"), r = d("Radio"), _ = d("Select"), p = d("Divider"), P = d("Cascader"), q = d("Checkbox"), F = d("DatePicker"), G = d("InputNumber"), N = d("InputMobileVerification"), x = d("InputGraphicVerification"), V = d("el-form-item"), R = d("el-button"), E = d("el-form"), v = U("loading");
|
|
539
|
+
return C((o(), c(E, b({
|
|
546
540
|
model: e.queryParams,
|
|
547
541
|
ref: "queryFormRef",
|
|
548
542
|
inline: "",
|
|
@@ -550,51 +544,51 @@ function we(e, o, t, a, l, s) {
|
|
|
550
544
|
"label-width": e.labelWidth
|
|
551
545
|
}, e.$attrs), {
|
|
552
546
|
default: f(() => [
|
|
553
|
-
(
|
|
547
|
+
(o(!0), S(L, null, $(e.formItem, (u) => (o(), c(V, {
|
|
554
548
|
label: u.label,
|
|
555
549
|
prop: u.prop,
|
|
556
550
|
key: u.prop,
|
|
557
|
-
rules: u
|
|
551
|
+
rules: e.getItemRules(u)
|
|
558
552
|
}, {
|
|
559
553
|
default: f(() => [
|
|
560
|
-
u.type === "input" ? (
|
|
554
|
+
u.type === "input" ? (o(), c(i, {
|
|
561
555
|
key: 0,
|
|
562
556
|
item: u
|
|
563
557
|
}, null, 8, ["item"])) : y("", !0),
|
|
564
|
-
u.type === "radio" ? (
|
|
558
|
+
u.type === "radio" ? (o(), c(r, {
|
|
565
559
|
key: 1,
|
|
566
560
|
item: u
|
|
567
561
|
}, null, 8, ["item"])) : y("", !0),
|
|
568
|
-
u.type === "select" ? (
|
|
562
|
+
u.type === "select" ? (o(), c(_, {
|
|
569
563
|
key: 2,
|
|
570
564
|
item: u
|
|
571
565
|
}, null, 8, ["item"])) : y("", !0),
|
|
572
|
-
u.type === "divider" ? (
|
|
566
|
+
u.type === "divider" ? (o(), c(p, {
|
|
573
567
|
key: 3,
|
|
574
568
|
item: u
|
|
575
569
|
}, null, 8, ["item"])) : y("", !0),
|
|
576
|
-
u.type === "cascader" ? (
|
|
570
|
+
u.type === "cascader" ? (o(), c(P, {
|
|
577
571
|
key: 4,
|
|
578
572
|
item: u
|
|
579
573
|
}, null, 8, ["item"])) : y("", !0),
|
|
580
|
-
u.type === "checkbox" ? (
|
|
574
|
+
u.type === "checkbox" ? (o(), c(q, {
|
|
581
575
|
key: 5,
|
|
582
576
|
item: u
|
|
583
577
|
}, null, 8, ["item"])) : y("", !0),
|
|
584
|
-
u.type === "date-picker" ? (
|
|
578
|
+
u.type === "date-picker" ? (o(), c(F, {
|
|
585
579
|
key: 6,
|
|
586
580
|
item: u
|
|
587
581
|
}, null, 8, ["item"])) : y("", !0),
|
|
588
|
-
u.type === "input-number" ? (
|
|
582
|
+
u.type === "input-number" ? (o(), c(G, {
|
|
589
583
|
key: 7,
|
|
590
584
|
item: u
|
|
591
585
|
}, null, 8, ["item"])) : y("", !0),
|
|
592
586
|
u.type === "form-item-slot" ? Q(e.$slots, u.name, { key: 8 }) : y("", !0),
|
|
593
|
-
u.type === "input-mobile-verification" ? (
|
|
587
|
+
u.type === "input-mobile-verification" ? (o(), c(N, {
|
|
594
588
|
key: 9,
|
|
595
589
|
item: u
|
|
596
590
|
}, null, 8, ["item"])) : y("", !0),
|
|
597
|
-
u.type === "input-graphic-verification" ? (
|
|
591
|
+
u.type === "input-graphic-verification" ? (o(), c(x, {
|
|
598
592
|
item: u,
|
|
599
593
|
key: u.key
|
|
600
594
|
}, null, 8, ["item"])) : y("", !0)
|
|
@@ -602,9 +596,9 @@ function we(e, o, t, a, l, s) {
|
|
|
602
596
|
_: 2
|
|
603
597
|
}, 1032, ["label", "prop", "rules"]))), 128)),
|
|
604
598
|
Q(e.$slots, "default"),
|
|
605
|
-
e.formOnly ? y("", !0) : (
|
|
599
|
+
e.formOnly ? y("", !0) : (o(), c(V, { key: 0 }, {
|
|
606
600
|
default: f(() => [
|
|
607
|
-
C((
|
|
601
|
+
C((o(), c(R, {
|
|
608
602
|
type: "primary",
|
|
609
603
|
size: e.size,
|
|
610
604
|
onClick: e.handleQuery
|
|
@@ -616,7 +610,7 @@ function we(e, o, t, a, l, s) {
|
|
|
616
610
|
}, 8, ["size", "onClick"])), [
|
|
617
611
|
[v, e.formLoading]
|
|
618
612
|
]),
|
|
619
|
-
T(
|
|
613
|
+
T(R, {
|
|
620
614
|
size: e.size,
|
|
621
615
|
onClick: e.resetQuery
|
|
622
616
|
}, {
|
|
@@ -635,7 +629,7 @@ function we(e, o, t, a, l, s) {
|
|
|
635
629
|
[ie, e.showSearch]
|
|
636
630
|
]);
|
|
637
631
|
}
|
|
638
|
-
const xe = /* @__PURE__ */ w(De, [["render", we]]), Be = ["infinite-scroll-disabled"], Fe = ["infinite-scroll-disabled"],
|
|
632
|
+
const xe = /* @__PURE__ */ w(De, [["render", we]]), Be = ["infinite-scroll-disabled"], Fe = ["infinite-scroll-disabled"], Re = { class: "checkbox" }, Ue = /* @__PURE__ */ k({
|
|
639
633
|
__name: "InfiniteScrollList",
|
|
640
634
|
props: {
|
|
641
635
|
search: {
|
|
@@ -663,8 +657,8 @@ const xe = /* @__PURE__ */ w(De, [["render", we]]), Be = ["infinite-scroll-disab
|
|
|
663
657
|
required: !1
|
|
664
658
|
}
|
|
665
659
|
},
|
|
666
|
-
setup(e, { expose:
|
|
667
|
-
const t = e, { search: a, id: l, name: s, extra: i } = t, r = g([]), _ = g(1), p = g(!1), P = g([]),
|
|
660
|
+
setup(e, { expose: n }) {
|
|
661
|
+
const t = e, { search: a, id: l, name: s, extra: i } = t, r = g([]), _ = g(1), p = g(!1), P = g([]), q = g(!1), F = (v, u) => {
|
|
668
662
|
const { i: A } = v;
|
|
669
663
|
return i && i !== "false" ? i(A) : "";
|
|
670
664
|
}, G = (v) => {
|
|
@@ -681,48 +675,48 @@ const xe = /* @__PURE__ */ w(De, [["render", we]]), Be = ["infinite-scroll-disab
|
|
|
681
675
|
x(), P.value = [];
|
|
682
676
|
}, x = () => {
|
|
683
677
|
_.value = 1, r.value = [], p.value = !1;
|
|
684
|
-
},
|
|
685
|
-
if (
|
|
678
|
+
}, V = async () => {
|
|
679
|
+
if (q.value || p.value)
|
|
686
680
|
return;
|
|
687
|
-
|
|
681
|
+
q.value = !0;
|
|
688
682
|
const v = await a(_.value);
|
|
689
|
-
v && v.length > 0 ? (r.value = [...r.value, ...v], _.value += 1) : p.value = !0,
|
|
690
|
-
},
|
|
691
|
-
x(),
|
|
683
|
+
v && v.length > 0 ? (r.value = [...r.value, ...v], _.value += 1) : p.value = !0, q.value = !1;
|
|
684
|
+
}, R = () => {
|
|
685
|
+
x(), V();
|
|
692
686
|
}, E = j(
|
|
693
687
|
() => r.value.filter((v) => P.value.includes(v[l]))
|
|
694
688
|
) || {};
|
|
695
|
-
return
|
|
689
|
+
return n({
|
|
696
690
|
reset: N,
|
|
697
691
|
lowReset: x,
|
|
698
|
-
loadList:
|
|
692
|
+
loadList: V,
|
|
699
693
|
selectInfo: E,
|
|
700
694
|
list: r,
|
|
701
695
|
ifbottom: p,
|
|
702
|
-
refreshList:
|
|
696
|
+
refreshList: R
|
|
703
697
|
}), (v, u) => {
|
|
704
|
-
const A =
|
|
705
|
-
return t.checkbox ? C((
|
|
698
|
+
const A = d("el-checkbox"), ee = d("el-checkbox-group"), M = U("infinite-scroll"), te = U("loading");
|
|
699
|
+
return t.checkbox ? C((o(), c(ee, b({
|
|
706
700
|
key: 0,
|
|
707
701
|
modelValue: P.value,
|
|
708
702
|
"onUpdate:modelValue": u[0] || (u[0] = (z) => P.value = z)
|
|
709
703
|
}, t), {
|
|
710
704
|
default: f(() => [
|
|
711
|
-
C((
|
|
705
|
+
C((o(), S("ul", {
|
|
712
706
|
class: "list",
|
|
713
707
|
"infinite-scroll-disabled": p.value
|
|
714
708
|
}, [
|
|
715
|
-
(
|
|
716
|
-
key: z[
|
|
709
|
+
(o(!0), S(L, null, $(r.value, (z) => (o(), S("li", {
|
|
710
|
+
key: z[m(l)],
|
|
717
711
|
class: "list-item"
|
|
718
712
|
}, [
|
|
719
713
|
T(A, {
|
|
720
|
-
label: z[
|
|
714
|
+
label: z[m(l)],
|
|
721
715
|
class: "checkbox"
|
|
722
716
|
}, {
|
|
723
717
|
default: f(() => [
|
|
724
|
-
I(D(z[
|
|
725
|
-
t.extra ? (
|
|
718
|
+
I(D(z[m(s)]) + " ", 1),
|
|
719
|
+
t.extra ? (o(), c(F, {
|
|
726
720
|
key: 0,
|
|
727
721
|
i: z
|
|
728
722
|
}, null, 8, ["i"])) : y("", !0)
|
|
@@ -731,36 +725,36 @@ const xe = /* @__PURE__ */ w(De, [["render", we]]), Be = ["infinite-scroll-disab
|
|
|
731
725
|
}, 1032, ["label"])
|
|
732
726
|
]))), 128))
|
|
733
727
|
], 8, Be)), [
|
|
734
|
-
[M,
|
|
728
|
+
[M, V]
|
|
735
729
|
])
|
|
736
730
|
]),
|
|
737
731
|
_: 1
|
|
738
732
|
}, 16, ["modelValue"])), [
|
|
739
|
-
[te,
|
|
740
|
-
]) : C((
|
|
733
|
+
[te, q.value]
|
|
734
|
+
]) : C((o(), S("ul", b({
|
|
741
735
|
key: 1,
|
|
742
736
|
class: "list",
|
|
743
737
|
"infinite-scroll-disabled": p.value
|
|
744
738
|
}, t), [
|
|
745
|
-
(
|
|
746
|
-
key: z[
|
|
739
|
+
(o(!0), S(L, null, $(r.value, (z) => (o(), S("li", {
|
|
740
|
+
key: z[m(l)],
|
|
747
741
|
class: "list-item"
|
|
748
742
|
}, [
|
|
749
|
-
H("div",
|
|
750
|
-
I(D(z[
|
|
751
|
-
t.extra ? (
|
|
743
|
+
H("div", Re, [
|
|
744
|
+
I(D(z[m(s)]) + " ", 1),
|
|
745
|
+
t.extra ? (o(), c(F, {
|
|
752
746
|
key: 0,
|
|
753
747
|
i: z
|
|
754
748
|
}, null, 8, ["i"])) : y("", !0)
|
|
755
749
|
])
|
|
756
750
|
]))), 128))
|
|
757
751
|
], 16, Fe)), [
|
|
758
|
-
[M,
|
|
752
|
+
[M, V]
|
|
759
753
|
]);
|
|
760
754
|
};
|
|
761
755
|
}
|
|
762
756
|
});
|
|
763
|
-
const Ge = /* @__PURE__ */ w(
|
|
757
|
+
const Ge = /* @__PURE__ */ w(Ue, [["__scopeId", "data-v-fa74e9b9"]]), Ne = { key: 1 }, Ee = /* @__PURE__ */ k({
|
|
764
758
|
__name: "Descriptions",
|
|
765
759
|
props: {
|
|
766
760
|
formData: {
|
|
@@ -773,7 +767,7 @@ const Ge = /* @__PURE__ */ w(Re, [["__scopeId", "data-v-38672162"]]), Ne = { key
|
|
|
773
767
|
}
|
|
774
768
|
},
|
|
775
769
|
setup(e) {
|
|
776
|
-
const
|
|
770
|
+
const n = e, t = (a, l) => {
|
|
777
771
|
const { i: s, render: i, formData: r } = a;
|
|
778
772
|
return i({
|
|
779
773
|
row: r,
|
|
@@ -781,24 +775,24 @@ const Ge = /* @__PURE__ */ w(Re, [["__scopeId", "data-v-38672162"]]), Ne = { key
|
|
|
781
775
|
});
|
|
782
776
|
};
|
|
783
777
|
return (a, l) => {
|
|
784
|
-
const s =
|
|
785
|
-
return
|
|
778
|
+
const s = d("el-descriptions-item"), i = d("el-descriptions");
|
|
779
|
+
return o(), c(i, b({
|
|
786
780
|
column: 1,
|
|
787
781
|
border: "",
|
|
788
782
|
class: "form-width"
|
|
789
|
-
},
|
|
783
|
+
}, n), {
|
|
790
784
|
default: f(() => [
|
|
791
|
-
(
|
|
785
|
+
(o(!0), S(L, null, $(n.formItem, (r, _) => (o(), c(s, b({
|
|
792
786
|
key: r.prop,
|
|
793
787
|
label: r.label
|
|
794
788
|
}, r.descriptionsItemProps), {
|
|
795
789
|
default: f(() => [
|
|
796
|
-
r.render ? (
|
|
790
|
+
r.render ? (o(), c(t, {
|
|
797
791
|
key: 0,
|
|
798
792
|
i: _,
|
|
799
793
|
render: r.render,
|
|
800
794
|
formData: e.formData
|
|
801
|
-
}, null, 8, ["i", "render", "formData"])) : (
|
|
795
|
+
}, null, 8, ["i", "render", "formData"])) : (o(), S("span", Ne, D(e.formData[r.prop]), 1))
|
|
802
796
|
]),
|
|
803
797
|
_: 2
|
|
804
798
|
}, 1040, ["label"]))), 128))
|