@chase-shao/vue-component-lib 1.2.71 → 1.2.72
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/dist/components/data-gen/views/CreateView.vue.d.ts +18 -18
- package/dist/components/data-gen/views/UpdateView.vue.d.ts +18 -18
- package/dist/components/data-gen/widgets/CheckBox.vue.d.ts +4 -4
- package/dist/components/data-gen/widgets/FileUpload.vue.d.ts +4 -4
- package/dist/components/data-gen/widgets/InputNumber.vue.d.ts +4 -4
- package/dist/components/data-gen/widgets/InputText.vue.d.ts +4 -4
- package/dist/components/data-gen/widgets/TextArea.vue.d.ts +4 -4
- package/dist/components/data-gen/widgets/index.vue.d.ts +8 -8
- package/dist/index.cjs.js +1 -1
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +238 -227
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref as g, defineComponent as G, mergeModels as re, useModel as
|
|
1
|
+
import { ref as g, getCurrentInstance as me, defineComponent as G, mergeModels as re, useModel as be, resolveComponent as S, createBlock as L, openBlock as u, onMounted as de, computed as X, withCtx as p, createElementBlock as V, Fragment as K, renderList as z, createVNode as R, nextTick as rt, createTextVNode as q, useTemplateRef as De, createElementVNode as T, createCommentVNode as se, toDisplayString as J, resolveDynamicComponent as Pe, renderSlot as ue, inject as ge, reactive as Me, normalizeStyle as it, normalizeClass as lt, unref as Te, onActivated as ct } from "vue";
|
|
2
2
|
import ut from "axios";
|
|
3
3
|
import { defineStore as dt } from "pinia";
|
|
4
4
|
import { Modal as ft } from "@arco-design/web-vue";
|
|
@@ -15,7 +15,7 @@ const mt = dt("main", () => ({
|
|
|
15
15
|
for (; e[t] === null; )
|
|
16
16
|
await gt(100);
|
|
17
17
|
return e[t];
|
|
18
|
-
},
|
|
18
|
+
}, we = (e) => {
|
|
19
19
|
const t = `0${e}`;
|
|
20
20
|
return t.substring(t.length - 2);
|
|
21
21
|
}, ke = (e, t = "yyyy-MM-dd hh:mm:ss") => {
|
|
@@ -25,15 +25,15 @@ const mt = dt("main", () => ({
|
|
|
25
25
|
const a = new Date(e), o = [
|
|
26
26
|
["yyyy", a.getFullYear()],
|
|
27
27
|
["yy", a.getFullYear().toString().substring(2)],
|
|
28
|
-
["MM",
|
|
28
|
+
["MM", we(a.getMonth() + 1)],
|
|
29
29
|
["M", a.getMonth() + 1],
|
|
30
|
-
["dd",
|
|
30
|
+
["dd", we(a.getDate())],
|
|
31
31
|
["d", a.getDate()],
|
|
32
|
-
["hh",
|
|
32
|
+
["hh", we(a.getHours())],
|
|
33
33
|
["h", a.getHours()],
|
|
34
|
-
["mm",
|
|
34
|
+
["mm", we(a.getMinutes())],
|
|
35
35
|
["m", a.getMinutes()],
|
|
36
|
-
["ss",
|
|
36
|
+
["ss", we(a.getSeconds())],
|
|
37
37
|
["s", a.getSeconds()]
|
|
38
38
|
];
|
|
39
39
|
for (const [n, c] of o)
|
|
@@ -55,6 +55,7 @@ function wt(e) {
|
|
|
55
55
|
function Be() {
|
|
56
56
|
return Fe;
|
|
57
57
|
}
|
|
58
|
+
const yt = me();
|
|
58
59
|
function qe() {
|
|
59
60
|
const e = Be();
|
|
60
61
|
return {
|
|
@@ -62,15 +63,26 @@ function qe() {
|
|
|
62
63
|
appSecret: e.appSecret || void 0 || ""
|
|
63
64
|
};
|
|
64
65
|
}
|
|
66
|
+
function bt(e) {
|
|
67
|
+
if (!e?.data?.statusCode)
|
|
68
|
+
return e;
|
|
69
|
+
switch (e.data.statusCode) {
|
|
70
|
+
case 1:
|
|
71
|
+
return e.data.data = e.data.result, e.data;
|
|
72
|
+
case 0:
|
|
73
|
+
default:
|
|
74
|
+
return yt?.appContext.config.globalProperties.$notification.error(e.data.msg), null;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
65
77
|
function Ye() {
|
|
66
|
-
const { apiBase: e } = qe()
|
|
67
|
-
return ut.create({
|
|
78
|
+
const { apiBase: e } = qe(), t = ut.create({
|
|
68
79
|
baseURL: e,
|
|
69
80
|
timeout: 20 * 1e3,
|
|
70
81
|
// 20s
|
|
71
82
|
// headers: { 'Content-Type': 'application/json' },
|
|
72
83
|
withCredentials: !0
|
|
73
84
|
});
|
|
85
|
+
return t.interceptors.response.use(bt), t;
|
|
74
86
|
}
|
|
75
87
|
const Je = async () => {
|
|
76
88
|
const { apiBase: e, appSecret: t } = qe(), a = Ye(), o = mt();
|
|
@@ -98,31 +110,31 @@ const Je = async () => {
|
|
|
98
110
|
}, O = [];
|
|
99
111
|
for (let e = 0; e < 256; ++e)
|
|
100
112
|
O.push((e + 256).toString(16).slice(1));
|
|
101
|
-
function
|
|
113
|
+
function ht(e, t = 0) {
|
|
102
114
|
return (O[e[t + 0]] + O[e[t + 1]] + O[e[t + 2]] + O[e[t + 3]] + "-" + O[e[t + 4]] + O[e[t + 5]] + "-" + O[e[t + 6]] + O[e[t + 7]] + "-" + O[e[t + 8]] + O[e[t + 9]] + "-" + O[e[t + 10]] + O[e[t + 11]] + O[e[t + 12]] + O[e[t + 13]] + O[e[t + 14]] + O[e[t + 15]]).toLowerCase();
|
|
103
115
|
}
|
|
104
116
|
let Ne;
|
|
105
|
-
const
|
|
106
|
-
function
|
|
117
|
+
const kt = new Uint8Array(16);
|
|
118
|
+
function Ct() {
|
|
107
119
|
if (!Ne) {
|
|
108
120
|
if (typeof crypto > "u" || !crypto.getRandomValues)
|
|
109
121
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
110
122
|
Ne = crypto.getRandomValues.bind(crypto);
|
|
111
123
|
}
|
|
112
|
-
return Ne(
|
|
124
|
+
return Ne(kt);
|
|
113
125
|
}
|
|
114
|
-
const
|
|
126
|
+
const Vt = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), je = { randomUUID: Vt };
|
|
115
127
|
function Xe(e, t, a) {
|
|
116
128
|
if (je.randomUUID && !e)
|
|
117
129
|
return je.randomUUID();
|
|
118
130
|
e = e || {};
|
|
119
|
-
const o = e.random ?? e.rng?.() ??
|
|
131
|
+
const o = e.random ?? e.rng?.() ?? Ct();
|
|
120
132
|
if (o.length < 16)
|
|
121
133
|
throw new Error("Random bytes length must be >= 16");
|
|
122
|
-
return o[6] = o[6] & 15 | 64, o[8] = o[8] & 63 | 128,
|
|
134
|
+
return o[6] = o[6] & 15 | 64, o[8] = o[8] & 63 | 128, ht(o);
|
|
123
135
|
}
|
|
124
136
|
var Z = /* @__PURE__ */ ((e) => (e[e.Submit = 0] = "Submit", e[e.Link = 1] = "Link", e))(Z || {}), pe = /* @__PURE__ */ ((e) => (e[e.Create = 0] = "Create", e[e.Update = 1] = "Update", e[e.Details = 2] = "Details", e[e.List = 3] = "List", e))(pe || {});
|
|
125
|
-
function
|
|
137
|
+
function St(e, t, a) {
|
|
126
138
|
const o = {
|
|
127
139
|
pageType: "",
|
|
128
140
|
fields: {},
|
|
@@ -202,9 +214,9 @@ function Ct(e, t, a) {
|
|
|
202
214
|
}
|
|
203
215
|
const Ce = async (e, t, a, o) => {
|
|
204
216
|
const c = await (await j()).get(`/General/${t}/${e}/page`, { params: o });
|
|
205
|
-
return
|
|
217
|
+
return St(c?.data, e, a);
|
|
206
218
|
}, Qe = async (e, t, a) => (await (await j()).post(`/${t}/${e}/button/List`, null, { params: a }))?.data;
|
|
207
|
-
async function
|
|
219
|
+
async function xt(e, t) {
|
|
208
220
|
const o = await (await j()).post(`/General/${e}/list`, t);
|
|
209
221
|
return {
|
|
210
222
|
data: o.data.data,
|
|
@@ -224,51 +236,51 @@ async function Vt(e, t) {
|
|
|
224
236
|
// ),
|
|
225
237
|
};
|
|
226
238
|
}
|
|
227
|
-
async function
|
|
239
|
+
async function $t(e, t, a) {
|
|
228
240
|
return (await (await j()).post(a, t, {
|
|
229
241
|
params: {
|
|
230
242
|
className: e
|
|
231
243
|
}
|
|
232
244
|
})).data;
|
|
233
245
|
}
|
|
234
|
-
async function
|
|
246
|
+
async function It(e, t, a, o) {
|
|
235
247
|
const n = await j(), c = He(o, t);
|
|
236
248
|
return (await n.put(c, a))?.data;
|
|
237
249
|
}
|
|
238
250
|
function He(e, t) {
|
|
239
251
|
return e.replace(/{WorkflowId}/g, t);
|
|
240
252
|
}
|
|
241
|
-
function
|
|
253
|
+
function At(e, t) {
|
|
242
254
|
return e.replace(/{ApproverEmail}/g, encodeURIComponent(t));
|
|
243
255
|
}
|
|
244
|
-
function
|
|
256
|
+
function Tt(e, t) {
|
|
245
257
|
return e.replace(/{WorkFlowReason}/g, encodeURIComponent(t));
|
|
246
258
|
}
|
|
247
|
-
function
|
|
259
|
+
function Ut(e, t) {
|
|
248
260
|
return e.replace(/{Status}/g, t);
|
|
249
261
|
}
|
|
250
|
-
function
|
|
262
|
+
function Nt(e, t) {
|
|
251
263
|
return e.replace(/{IfTriggerGlobal_RandP_Approval}/g, t);
|
|
252
264
|
}
|
|
253
|
-
function
|
|
265
|
+
function Lt(e, t) {
|
|
254
266
|
return e.replace(/{ClassName}/g, encodeURIComponent(t));
|
|
255
267
|
}
|
|
256
|
-
async function
|
|
268
|
+
async function Rt(e, t, a, o, n, c, r, i) {
|
|
257
269
|
const s = await j();
|
|
258
270
|
let l = He(c, t);
|
|
259
|
-
return l =
|
|
271
|
+
return l = At(l, a), l = Tt(l, o), l = Ut(l, r), l = Nt(l, i), l = Lt(l, e), (await s.put(l, n))?.data;
|
|
260
272
|
}
|
|
261
|
-
async function
|
|
273
|
+
async function Ft(e, t) {
|
|
262
274
|
const n = (await (await j()).get(e, { params: { value: t } }))?.data;
|
|
263
275
|
return Object.entries(n).map(([c, r]) => ({
|
|
264
276
|
value: c,
|
|
265
277
|
label: r
|
|
266
278
|
}));
|
|
267
279
|
}
|
|
268
|
-
async function
|
|
280
|
+
async function Dt(e, t) {
|
|
269
281
|
return (await (await j()).get(`/General/${e}/${t}/process`))?.data;
|
|
270
282
|
}
|
|
271
|
-
function
|
|
283
|
+
function Pt(e) {
|
|
272
284
|
return {
|
|
273
285
|
uid: e.id ?? Xe(),
|
|
274
286
|
name: e.attachmentName ?? "unknown",
|
|
@@ -278,23 +290,23 @@ function Ft(e) {
|
|
|
278
290
|
async function Ze(e, t) {
|
|
279
291
|
return (await (await j()).get(`/General/${e}/${t}/upload/get`))?.data.reduce((c, r) => {
|
|
280
292
|
const { category: i } = r;
|
|
281
|
-
return c[i] || (c[i] = []), c[i].push(
|
|
293
|
+
return c[i] || (c[i] = []), c[i].push(Pt(r)), c;
|
|
282
294
|
}, {});
|
|
283
295
|
}
|
|
284
|
-
async function
|
|
296
|
+
async function Mt(e, t) {
|
|
285
297
|
return (await j()).post(`/General/${e}/${t}/delete/attachment`);
|
|
286
298
|
}
|
|
287
|
-
async function
|
|
299
|
+
async function Bt() {
|
|
288
300
|
const t = await (await j()).get("/Grading/dropdown/approvers");
|
|
289
301
|
return Object.entries(t?.data).map(([a, o]) => ({
|
|
290
302
|
label: a,
|
|
291
303
|
value: o
|
|
292
304
|
}));
|
|
293
305
|
}
|
|
294
|
-
async function
|
|
306
|
+
async function Ht(e, t) {
|
|
295
307
|
return await (await j()).post(`Grading/AssignComments/${e}/${encodeURIComponent(t)}`);
|
|
296
308
|
}
|
|
297
|
-
async function
|
|
309
|
+
async function Kt(e, t, a) {
|
|
298
310
|
return await (await j()).post(`Grading/AddComments/${e}/${encodeURIComponent(t)}`, a, {
|
|
299
311
|
headers: { "Content-Type": "application/json;charset=UTF-8" }
|
|
300
312
|
});
|
|
@@ -305,25 +317,25 @@ async function Oe(e) {
|
|
|
305
317
|
async function Le(e) {
|
|
306
318
|
return (await (await j()).get(`Grading/GetAssociator/${e}`))?.data;
|
|
307
319
|
}
|
|
308
|
-
async function
|
|
320
|
+
async function Et(e) {
|
|
309
321
|
return await (await j()).delete(`Grading/DeleteAssociator/${e}`);
|
|
310
322
|
}
|
|
311
|
-
async function
|
|
323
|
+
async function zt(e, t = null) {
|
|
312
324
|
const o = await (await j()).post(e, t, {
|
|
313
325
|
responseType: "blob"
|
|
314
326
|
});
|
|
315
327
|
_t(o?.data, "WorkflowData.xlsx");
|
|
316
328
|
}
|
|
317
|
-
const
|
|
329
|
+
const ve = (e, t) => {
|
|
318
330
|
let a = "";
|
|
319
331
|
return { res: e.every((n) => {
|
|
320
|
-
const c =
|
|
332
|
+
const c = jt(n, t);
|
|
321
333
|
return c || (a = n.errorMessage), c;
|
|
322
334
|
}), errorMessages: a };
|
|
323
|
-
},
|
|
335
|
+
}, jt = (e, t) => {
|
|
324
336
|
const { ruleName: a, ruleParameter: o } = e;
|
|
325
|
-
return
|
|
326
|
-
},
|
|
337
|
+
return Ot[a](o, t);
|
|
338
|
+
}, Ot = {
|
|
327
339
|
Regex: (e, t) => new RegExp(e).test(t),
|
|
328
340
|
Required: (e, t) => !!t
|
|
329
341
|
}, Ge = /* @__PURE__ */ G({
|
|
@@ -341,7 +353,7 @@ const ge = (e, t) => {
|
|
|
341
353
|
}),
|
|
342
354
|
emits: /* @__PURE__ */ re(["update:modelValue", "change", "error", "input"], ["update:modelValue"]),
|
|
343
355
|
setup(e, { expose: t, emit: a }) {
|
|
344
|
-
const o = e, n = a, c =
|
|
356
|
+
const o = e, n = a, c = be(e, "modelValue"), r = (l) => ve(o.validations, l), i = (l) => {
|
|
345
357
|
n("input", l);
|
|
346
358
|
}, s = (l) => {
|
|
347
359
|
const _ = r(l);
|
|
@@ -366,7 +378,7 @@ const ge = (e, t) => {
|
|
|
366
378
|
}, null, 8, ["modelValue", "disabled"]);
|
|
367
379
|
};
|
|
368
380
|
}
|
|
369
|
-
}),
|
|
381
|
+
}), Gt = /* @__PURE__ */ G({
|
|
370
382
|
__name: "InputNumber",
|
|
371
383
|
props: /* @__PURE__ */ re({
|
|
372
384
|
fieldKey: {},
|
|
@@ -381,13 +393,13 @@ const ge = (e, t) => {
|
|
|
381
393
|
}),
|
|
382
394
|
emits: /* @__PURE__ */ re(["update:modelValue", "change", "error", "input"], ["update:modelValue"]),
|
|
383
395
|
setup(e, { expose: t, emit: a }) {
|
|
384
|
-
const o = e, n = a, c =
|
|
396
|
+
const o = e, n = a, c = be(e, "modelValue"), r = g(100), i = g(1);
|
|
385
397
|
de(() => {
|
|
386
398
|
o.validations && o.validations.forEach((d) => {
|
|
387
399
|
d.ruleName === "Max" && (r.value = d.ruleParameter), d.ruleName === "Min" && (i.value = d.ruleParameter);
|
|
388
400
|
});
|
|
389
401
|
});
|
|
390
|
-
const s = (d) =>
|
|
402
|
+
const s = (d) => ve(o.validations, d), l = (d) => {
|
|
391
403
|
n("input", d);
|
|
392
404
|
}, _ = (d) => {
|
|
393
405
|
const h = s(d);
|
|
@@ -428,7 +440,7 @@ const ge = (e, t) => {
|
|
|
428
440
|
}),
|
|
429
441
|
emits: /* @__PURE__ */ re(["update:modelValue", "change"], ["update:modelValue"]),
|
|
430
442
|
setup(e, { expose: t, emit: a }) {
|
|
431
|
-
const o = e, n = a, c = g(!1), r = g(o.config.options ?? []), i =
|
|
443
|
+
const o = e, n = a, c = g(!1), r = g(o.config.options ?? []), i = be(e, "modelValue"), s = (d) => ve(o.validations, d);
|
|
432
444
|
X(() => {
|
|
433
445
|
const d = {};
|
|
434
446
|
return o.triggers && o.triggers.length > 0 && o.triggers.forEach((h) => {
|
|
@@ -439,7 +451,7 @@ const ge = (e, t) => {
|
|
|
439
451
|
};
|
|
440
452
|
}), d;
|
|
441
453
|
}), de(async () => {
|
|
442
|
-
o.config.dataSourceProvider && (r.value = await
|
|
454
|
+
o.config.dataSourceProvider && (r.value = await Ft(o.config.dataSourceProvider));
|
|
443
455
|
});
|
|
444
456
|
const _ = (d) => {
|
|
445
457
|
n("update:modelValue", d);
|
|
@@ -462,7 +474,6 @@ const ge = (e, t) => {
|
|
|
462
474
|
loading: c.value,
|
|
463
475
|
"filter-option": !0,
|
|
464
476
|
"allow-search": !0,
|
|
465
|
-
disabled: d.config.readonly,
|
|
466
477
|
onChange: _
|
|
467
478
|
}, {
|
|
468
479
|
default: p(() => [
|
|
@@ -473,10 +484,10 @@ const ge = (e, t) => {
|
|
|
473
484
|
}, null, 8, ["value", "label"]))), 128))
|
|
474
485
|
]),
|
|
475
486
|
_: 1
|
|
476
|
-
}, 8, ["modelValue", "loading"
|
|
487
|
+
}, 8, ["modelValue", "loading"]);
|
|
477
488
|
};
|
|
478
489
|
}
|
|
479
|
-
}),
|
|
490
|
+
}), Wt = /* @__PURE__ */ G({
|
|
480
491
|
__name: "Cascader",
|
|
481
492
|
props: {
|
|
482
493
|
modelValue: {},
|
|
@@ -521,7 +532,7 @@ const ge = (e, t) => {
|
|
|
521
532
|
});
|
|
522
533
|
};
|
|
523
534
|
}
|
|
524
|
-
}),
|
|
535
|
+
}), qt = /* @__PURE__ */ G({
|
|
525
536
|
__name: "FileUpload",
|
|
526
537
|
props: {
|
|
527
538
|
className: {},
|
|
@@ -541,7 +552,7 @@ const ge = (e, t) => {
|
|
|
541
552
|
Authorization: `Bearer ${m}`
|
|
542
553
|
};
|
|
543
554
|
});
|
|
544
|
-
const r = (m) =>
|
|
555
|
+
const r = (m) => ve(o.validations, m), s = Be().apiBase, l = g(null), _ = g("");
|
|
545
556
|
function d(m, k, E) {
|
|
546
557
|
return m.replace(/{WorkflowId}/g, k).replace(/{ClassName}/g, E);
|
|
547
558
|
}
|
|
@@ -604,7 +615,7 @@ const ge = (e, t) => {
|
|
|
604
615
|
}, 8, ["default-file-list", "action", "limit", "headers"]);
|
|
605
616
|
};
|
|
606
617
|
}
|
|
607
|
-
}),
|
|
618
|
+
}), Yt = /* @__PURE__ */ G({
|
|
608
619
|
__name: "TextArea",
|
|
609
620
|
props: {
|
|
610
621
|
fieldKey: {},
|
|
@@ -616,7 +627,7 @@ const ge = (e, t) => {
|
|
|
616
627
|
},
|
|
617
628
|
emits: ["update:modelValue", "change", "error", "input"],
|
|
618
629
|
setup(e, { expose: t, emit: a }) {
|
|
619
|
-
const o = e, n = a, c = (s) =>
|
|
630
|
+
const o = e, n = a, c = (s) => ve(o.validations, s), r = (s) => {
|
|
620
631
|
n("update:modelValue", s), n("input", s);
|
|
621
632
|
}, i = (s) => {
|
|
622
633
|
n("update:modelValue", s);
|
|
@@ -642,7 +653,7 @@ const ge = (e, t) => {
|
|
|
642
653
|
}, null, 8, ["model-value", "disabled"]);
|
|
643
654
|
};
|
|
644
655
|
}
|
|
645
|
-
}),
|
|
656
|
+
}), Jt = /* @__PURE__ */ G({
|
|
646
657
|
__name: "CheckBox",
|
|
647
658
|
props: /* @__PURE__ */ re({
|
|
648
659
|
fieldKey: {},
|
|
@@ -657,7 +668,7 @@ const ge = (e, t) => {
|
|
|
657
668
|
}),
|
|
658
669
|
emits: /* @__PURE__ */ re(["update:modelValue", "change", "error", "input"], ["update:modelValue"]),
|
|
659
670
|
setup(e, { expose: t, emit: a }) {
|
|
660
|
-
const o = e, n = a, c =
|
|
671
|
+
const o = e, n = a, c = be(e, "modelValue"), r = (s) => ve(o.validations, s), i = (s) => {
|
|
661
672
|
const l = r(s);
|
|
662
673
|
n("error", l.res ? "" : l.errorMessages), o.triggers && o.triggers.length > 0 && o.triggers.forEach((_) => {
|
|
663
674
|
_.event === "change" && n(_.event, _.handlerName, s);
|
|
@@ -685,13 +696,13 @@ const ge = (e, t) => {
|
|
|
685
696
|
}, 8, ["modelValue", "disabled"]);
|
|
686
697
|
};
|
|
687
698
|
}
|
|
688
|
-
}),
|
|
699
|
+
}), Xt = { class: "title" }, Qt = {
|
|
689
700
|
key: 0,
|
|
690
701
|
class: "required"
|
|
691
|
-
},
|
|
702
|
+
}, Zt = {
|
|
692
703
|
key: 0,
|
|
693
704
|
class: "err-msg"
|
|
694
|
-
},
|
|
705
|
+
}, eo = /* @__PURE__ */ G({
|
|
695
706
|
__name: "index",
|
|
696
707
|
props: /* @__PURE__ */ re({
|
|
697
708
|
config: {},
|
|
@@ -707,24 +718,24 @@ const ge = (e, t) => {
|
|
|
707
718
|
}),
|
|
708
719
|
emits: /* @__PURE__ */ re(["update:modelValue", "change", "error"], ["update:modelValue"]),
|
|
709
720
|
setup(e, { expose: t, emit: a }) {
|
|
710
|
-
const o = e, n = a, c =
|
|
721
|
+
const o = e, n = a, c = be(e, "modelValue"), r = De("widgetRef"), i = X(() => {
|
|
711
722
|
switch (o.config?.widget?.widget) {
|
|
712
723
|
case "TextBox":
|
|
713
724
|
return Ge;
|
|
714
725
|
case "Number":
|
|
715
|
-
return
|
|
726
|
+
return Gt;
|
|
716
727
|
case "SelectList":
|
|
717
728
|
return We;
|
|
718
729
|
case "Cascade":
|
|
719
|
-
return
|
|
730
|
+
return Wt;
|
|
720
731
|
case "File":
|
|
721
|
-
return
|
|
732
|
+
return qt;
|
|
722
733
|
case "TextArea":
|
|
723
|
-
return
|
|
734
|
+
return Yt;
|
|
724
735
|
case "DropDown":
|
|
725
736
|
return We;
|
|
726
737
|
case "CheckBox":
|
|
727
|
-
return
|
|
738
|
+
return Jt;
|
|
728
739
|
default:
|
|
729
740
|
return Ge;
|
|
730
741
|
}
|
|
@@ -750,9 +761,9 @@ const ge = (e, t) => {
|
|
|
750
761
|
return o?.config?.widget?.title;
|
|
751
762
|
}
|
|
752
763
|
}), (h, x) => (u(), V("div", null, [
|
|
753
|
-
T("div",
|
|
764
|
+
T("div", Xt, [
|
|
754
765
|
q(J(o?.config?.widget?.title) + " ", 1),
|
|
755
|
-
o.config.validations.length ? (u(), V("span",
|
|
766
|
+
o.config.validations.length ? (u(), V("span", Qt, "*")) : se("", !0)
|
|
756
767
|
]),
|
|
757
768
|
T("div", null, [
|
|
758
769
|
(u(), L(Pe(i.value), {
|
|
@@ -768,16 +779,16 @@ const ge = (e, t) => {
|
|
|
768
779
|
onError: l,
|
|
769
780
|
onChange: _
|
|
770
781
|
}, null, 40, ["modelValue", "field-key", "config", "validations", "triggers", "class-name"])),
|
|
771
|
-
s.value.length > 0 ? (u(), V("div",
|
|
782
|
+
s.value.length > 0 ? (u(), V("div", Zt, J(s.value), 1)) : se("", !0)
|
|
772
783
|
])
|
|
773
784
|
]));
|
|
774
785
|
}
|
|
775
|
-
}),
|
|
786
|
+
}), _e = (e, t) => {
|
|
776
787
|
const a = e.__vccOpts || e;
|
|
777
788
|
for (const [o, n] of t)
|
|
778
789
|
a[o] = n;
|
|
779
790
|
return a;
|
|
780
|
-
}, Ke = /* @__PURE__ */
|
|
791
|
+
}, Ke = /* @__PURE__ */ _e(eo, [["__scopeId", "data-v-1022c8cb"]]), to = /* @__PURE__ */ G({
|
|
781
792
|
__name: "SubmitButton",
|
|
782
793
|
props: {
|
|
783
794
|
url: {},
|
|
@@ -804,7 +815,7 @@ const ge = (e, t) => {
|
|
|
804
815
|
}, 8, ["loading"]);
|
|
805
816
|
};
|
|
806
817
|
}
|
|
807
|
-
}),
|
|
818
|
+
}), oo = /* @__PURE__ */ G({
|
|
808
819
|
__name: "DetailLink",
|
|
809
820
|
props: {
|
|
810
821
|
url: {},
|
|
@@ -827,7 +838,7 @@ const ge = (e, t) => {
|
|
|
827
838
|
});
|
|
828
839
|
};
|
|
829
840
|
}
|
|
830
|
-
}),
|
|
841
|
+
}), ye = /* @__PURE__ */ G({
|
|
831
842
|
__name: "index",
|
|
832
843
|
props: {
|
|
833
844
|
config: {},
|
|
@@ -842,10 +853,10 @@ const ge = (e, t) => {
|
|
|
842
853
|
const c = X(() => {
|
|
843
854
|
switch (a.config.location) {
|
|
844
855
|
case "InOperation":
|
|
845
|
-
return
|
|
856
|
+
return to;
|
|
846
857
|
case "InTable":
|
|
847
858
|
default:
|
|
848
|
-
return
|
|
859
|
+
return oo;
|
|
849
860
|
}
|
|
850
861
|
}), r = X(() => a.config.widget === Z.Submit ? a.config.requestUrl ?? "" : a.config.widget === Z.Link ? a.config.redirectUrl ?? "" : ""), i = X(() => a.config.redirectType ?? "Details");
|
|
851
862
|
return (s, l) => (u(), L(Pe(c.value), {
|
|
@@ -862,22 +873,22 @@ const ge = (e, t) => {
|
|
|
862
873
|
}
|
|
863
874
|
}), et = Symbol("library-router");
|
|
864
875
|
function Ve() {
|
|
865
|
-
const e =
|
|
876
|
+
const e = ge(et, null);
|
|
866
877
|
return e || pt();
|
|
867
878
|
}
|
|
868
879
|
const tt = Symbol("library-triggers");
|
|
869
880
|
function Ee() {
|
|
870
|
-
const e =
|
|
881
|
+
const e = ge(tt, null);
|
|
871
882
|
return e || {};
|
|
872
883
|
}
|
|
873
|
-
const
|
|
884
|
+
const no = Symbol("library-pinia"), ot = Symbol("library-bpmStore"), nt = Symbol("library-svrStore");
|
|
874
885
|
function Se() {
|
|
875
|
-
return
|
|
886
|
+
return ge(ot, null);
|
|
876
887
|
}
|
|
877
888
|
function xe() {
|
|
878
|
-
return
|
|
889
|
+
return ge(nt, null);
|
|
879
890
|
}
|
|
880
|
-
const
|
|
891
|
+
const ao = { class: "top-bar" }, so = { class: "banner-info" }, ro = { class: "page-title" }, io = { class: "page-subtitle" }, lo = { class: "avatar-wrapper" }, co = { class: "user-email" }, uo = /* @__PURE__ */ G({
|
|
881
892
|
__name: "TopBar",
|
|
882
893
|
props: {
|
|
883
894
|
title: {},
|
|
@@ -887,15 +898,15 @@ const oo = { class: "top-bar" }, no = { class: "banner-info" }, ao = { class: "p
|
|
|
887
898
|
setup(e) {
|
|
888
899
|
return (t, a) => {
|
|
889
900
|
const o = S("a-avatar"), n = S("a-popover");
|
|
890
|
-
return u(), V("div",
|
|
891
|
-
T("div",
|
|
892
|
-
T("div",
|
|
893
|
-
T("div",
|
|
901
|
+
return u(), V("div", ao, [
|
|
902
|
+
T("div", so, [
|
|
903
|
+
T("div", ro, J(t.title), 1),
|
|
904
|
+
T("div", io, J(t.subTitle), 1)
|
|
894
905
|
]),
|
|
895
|
-
T("div",
|
|
906
|
+
T("div", lo, [
|
|
896
907
|
R(n, { trigger: "click" }, {
|
|
897
908
|
content: p(() => [
|
|
898
|
-
T("div",
|
|
909
|
+
T("div", co, J(t.email), 1)
|
|
899
910
|
]),
|
|
900
911
|
default: p(() => [
|
|
901
912
|
R(o, {
|
|
@@ -915,7 +926,7 @@ const oo = { class: "top-bar" }, no = { class: "banner-info" }, ao = { class: "p
|
|
|
915
926
|
]);
|
|
916
927
|
};
|
|
917
928
|
}
|
|
918
|
-
}), $e = /* @__PURE__ */
|
|
929
|
+
}), $e = /* @__PURE__ */ _e(uo, [["__scopeId", "data-v-c0457235"]]);
|
|
919
930
|
function ze(e) {
|
|
920
931
|
const t = Be(), a = [];
|
|
921
932
|
if (t.fieldsGroup) {
|
|
@@ -927,16 +938,16 @@ function ze(e) {
|
|
|
927
938
|
return n.length && a.push({ name: "未分组字段", fields: n }), a;
|
|
928
939
|
}
|
|
929
940
|
}
|
|
930
|
-
const
|
|
941
|
+
const fo = { class: "page-container" }, po = { class: "page-body" }, mo = { class: "form-card" }, go = { class: "form-fields-vertical" }, vo = { class: "form-fields" }, _o = {
|
|
931
942
|
key: 0,
|
|
932
943
|
class: "form-content"
|
|
933
|
-
},
|
|
944
|
+
}, wo = { class: "page-footer" }, yo = { class: "action-container" }, bo = { class: "action-buttons" }, ho = /* @__PURE__ */ G({
|
|
934
945
|
__name: "CreateView",
|
|
935
946
|
props: {
|
|
936
947
|
className: {}
|
|
937
948
|
},
|
|
938
949
|
setup(e) {
|
|
939
|
-
const t = Se(), a = xe(), o = Ve(), n = Ee(), c = De("dataWidgets"), r =
|
|
950
|
+
const t = Se(), a = xe(), o = Ve(), n = Ee(), c = De("dataWidgets"), r = me(), i = e, s = g({
|
|
940
951
|
pageType: "",
|
|
941
952
|
fields: {},
|
|
942
953
|
globalValidations: [],
|
|
@@ -946,13 +957,13 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
946
957
|
}
|
|
947
958
|
}), l = g([]), _ = g({});
|
|
948
959
|
function d($) {
|
|
949
|
-
return $ ? Object.entries($).map(([v,
|
|
960
|
+
return $ ? Object.entries($).map(([v, I]) => ({
|
|
950
961
|
fieldKey: v,
|
|
951
|
-
...
|
|
962
|
+
...I
|
|
952
963
|
})).filter((v) => v.widget && v.widget.widget !== "Hidden").filter((v) => !ne.value.includes(v.fieldKey)) : [];
|
|
953
964
|
}
|
|
954
965
|
function h($) {
|
|
955
|
-
return $ ? Object.entries($).filter(([v,
|
|
966
|
+
return $ ? Object.entries($).filter(([v, I]) => I.dependent).reduce((v, [I, y]) => (v[I] = y.dependent, v), {}) : [];
|
|
956
967
|
}
|
|
957
968
|
const x = X(() => s.value?.actions ? [...s.value.actions].reverse() : []), m = Me({}), k = g(!1);
|
|
958
969
|
de(async () => {
|
|
@@ -972,7 +983,7 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
972
983
|
function E() {
|
|
973
984
|
return a()?.userInfo?.email_address ?? "";
|
|
974
985
|
}
|
|
975
|
-
async function ee($, U, v,
|
|
986
|
+
async function ee($, U, v, I, y) {
|
|
976
987
|
switch (U) {
|
|
977
988
|
case Z.Submit:
|
|
978
989
|
let D = !0;
|
|
@@ -983,13 +994,13 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
983
994
|
return;
|
|
984
995
|
}
|
|
985
996
|
k.value = !0;
|
|
986
|
-
const te = await
|
|
997
|
+
const te = await $t(i.className, { ...m, ..._.value }, v);
|
|
987
998
|
k.value = !1, c.value?.forEach((ae) => {
|
|
988
999
|
ae?.submit && ae.submit(te.toString());
|
|
989
1000
|
}), r?.appContext.config.globalProperties.$notification.success(`Your grading request has been submitted, ID is ${te.toString()}.`), o.push({ name: "Details", params: { workflowId: te.toString() } });
|
|
990
1001
|
break;
|
|
991
1002
|
case Z.Link:
|
|
992
|
-
|
|
1003
|
+
I === "List" && o.push({ name: "List", params: { className: i.className } });
|
|
993
1004
|
break;
|
|
994
1005
|
default:
|
|
995
1006
|
console.warn("Unknown action type:", U);
|
|
@@ -1008,28 +1019,28 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1008
1019
|
}
|
|
1009
1020
|
const B = X(() => ze(l.value));
|
|
1010
1021
|
return ($, U) => {
|
|
1011
|
-
const v = S("a-card"),
|
|
1012
|
-
return u(), V("div",
|
|
1022
|
+
const v = S("a-card"), I = S("a-spin");
|
|
1023
|
+
return u(), V("div", fo, [
|
|
1013
1024
|
R($e, {
|
|
1014
1025
|
title: s.value.banner.title,
|
|
1015
1026
|
subTitle: s.value.banner.subTitle,
|
|
1016
1027
|
email: E()
|
|
1017
1028
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1018
|
-
T("div",
|
|
1019
|
-
R(
|
|
1029
|
+
T("div", po, [
|
|
1030
|
+
R(I, {
|
|
1020
1031
|
loading: k.value,
|
|
1021
1032
|
class: "form-container"
|
|
1022
1033
|
}, {
|
|
1023
1034
|
default: p(() => [
|
|
1024
|
-
T("div",
|
|
1025
|
-
T("div",
|
|
1035
|
+
T("div", mo, [
|
|
1036
|
+
T("div", go, [
|
|
1026
1037
|
(u(!0), V(K, null, z(B.value, (y) => (u(), L(v, {
|
|
1027
1038
|
key: y.name,
|
|
1028
1039
|
title: y.name,
|
|
1029
1040
|
style: { "margin-bottom": "24px" }
|
|
1030
1041
|
}, {
|
|
1031
1042
|
default: p(() => [
|
|
1032
|
-
T("div",
|
|
1043
|
+
T("div", vo, [
|
|
1033
1044
|
(u(!0), V(K, null, z(y.fields, (D) => (u(), L(Ke, {
|
|
1034
1045
|
key: D.fieldKey,
|
|
1035
1046
|
ref_for: !0,
|
|
@@ -1047,7 +1058,7 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1047
1058
|
_: 2
|
|
1048
1059
|
}, 1032, ["title"]))), 128))
|
|
1049
1060
|
]),
|
|
1050
|
-
$.$slots.content ? (u(), V("div",
|
|
1061
|
+
$.$slots.content ? (u(), V("div", _o, [
|
|
1051
1062
|
ue($.$slots, "content", {}, void 0, !0)
|
|
1052
1063
|
])) : se("", !0)
|
|
1053
1064
|
])
|
|
@@ -1055,11 +1066,11 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1055
1066
|
_: 3
|
|
1056
1067
|
}, 8, ["loading"])
|
|
1057
1068
|
]),
|
|
1058
|
-
T("div",
|
|
1059
|
-
T("div",
|
|
1069
|
+
T("div", wo, [
|
|
1070
|
+
T("div", yo, [
|
|
1060
1071
|
ue($.$slots, "action", {}, void 0, !0),
|
|
1061
|
-
T("div",
|
|
1062
|
-
(u(!0), V(K, null, z(x.value, (y) => (u(), L(
|
|
1072
|
+
T("div", bo, [
|
|
1073
|
+
(u(!0), V(K, null, z(x.value, (y) => (u(), L(ye, {
|
|
1063
1074
|
key: y.Title,
|
|
1064
1075
|
loading: k.value,
|
|
1065
1076
|
config: y,
|
|
@@ -1072,17 +1083,17 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1072
1083
|
]);
|
|
1073
1084
|
};
|
|
1074
1085
|
}
|
|
1075
|
-
}),
|
|
1086
|
+
}), ko = /* @__PURE__ */ _e(ho, [["__scopeId", "data-v-f3f47e02"]]), Co = { class: "page-container" }, Vo = { class: "page-body" }, So = { class: "form-card" }, xo = { class: "form-fields-vertical" }, $o = { class: "form-fields" }, Io = {
|
|
1076
1087
|
key: 0,
|
|
1077
1088
|
class: "form-content"
|
|
1078
|
-
},
|
|
1089
|
+
}, Ao = { class: "page-footer" }, To = { class: "action-container" }, Uo = { class: "action-buttons" }, No = /* @__PURE__ */ G({
|
|
1079
1090
|
__name: "UpdateView",
|
|
1080
1091
|
props: {
|
|
1081
1092
|
className: {},
|
|
1082
1093
|
workflowId: {}
|
|
1083
1094
|
},
|
|
1084
1095
|
setup(e) {
|
|
1085
|
-
const t = Ve(), a = Ee(), o = xe(), n = Se(), c = De("dataWidgets"), r =
|
|
1096
|
+
const t = Ve(), a = Ee(), o = xe(), n = Se(), c = De("dataWidgets"), r = me(), i = e, s = g({
|
|
1086
1097
|
pageType: "",
|
|
1087
1098
|
fields: {},
|
|
1088
1099
|
globalValidations: [],
|
|
@@ -1098,7 +1109,7 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1098
1109
|
})).filter((U) => U.widget && U.widget.widget !== "Hidden").filter((U) => !oe.value.includes(U.fieldKey)) : [];
|
|
1099
1110
|
}
|
|
1100
1111
|
function h(B) {
|
|
1101
|
-
return B ? Object.entries(B).filter(([U, v]) => v.dependent).reduce((U, [v,
|
|
1112
|
+
return B ? Object.entries(B).filter(([U, v]) => v.dependent).reduce((U, [v, I]) => (U[v] = I.dependent, U), {}) : [];
|
|
1102
1113
|
}
|
|
1103
1114
|
const x = X(() => s.value?.actions ? [...s.value.actions].reverse() : []), m = Me({}), k = g(!1);
|
|
1104
1115
|
de(async () => {
|
|
@@ -1110,15 +1121,15 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1110
1121
|
});
|
|
1111
1122
|
const B = await Qe(pe.Update, i.className, { workflowId: i.workflowId, email: E() }), $ = await Ze(i.className, i.workflowId);
|
|
1112
1123
|
s.value.actions = s.value.actions?.filter((v) => {
|
|
1113
|
-
const
|
|
1114
|
-
return
|
|
1124
|
+
const I = B.find((y) => y.button === v.title);
|
|
1125
|
+
return I ? I.isShow : !0;
|
|
1115
1126
|
});
|
|
1116
1127
|
const U = s.value.fields.requestType.modelValue;
|
|
1117
1128
|
a.Test?.(U, oe), l.value = d(s.value.fields), _.value = h(s.value.fields);
|
|
1118
1129
|
for (const v in s.value.fields) {
|
|
1119
1130
|
if (s.value.fields[v].widget?.widget === "File") {
|
|
1120
|
-
const
|
|
1121
|
-
|
|
1131
|
+
const I = l.value.find((y) => y.fieldKey === v);
|
|
1132
|
+
I && I.widget && (I.widget.files = $[v] ?? [], I.widget.removeFile = (y) => Mt(i.className, y));
|
|
1122
1133
|
}
|
|
1123
1134
|
m[v] = s.value.fields[v].modelValue;
|
|
1124
1135
|
}
|
|
@@ -1127,7 +1138,7 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1127
1138
|
function E() {
|
|
1128
1139
|
return o()?.userInfo?.email_address ?? "";
|
|
1129
1140
|
}
|
|
1130
|
-
async function ee(B, $, U, v,
|
|
1141
|
+
async function ee(B, $, U, v, I) {
|
|
1131
1142
|
switch ($) {
|
|
1132
1143
|
case Z.Submit:
|
|
1133
1144
|
let y = !0;
|
|
@@ -1137,7 +1148,7 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1137
1148
|
r?.appContext.config.globalProperties.$message.error("form validation failed, please check the input fields");
|
|
1138
1149
|
return;
|
|
1139
1150
|
}
|
|
1140
|
-
k.value = !0, await
|
|
1151
|
+
k.value = !0, await It(i.className, i.workflowId, { ...m, ..._.value }, U), k.value = !1, c.value?.forEach((D) => {
|
|
1141
1152
|
D?.submit && D.submit(i.workflowId);
|
|
1142
1153
|
}), r?.appContext.config.globalProperties.$notification.success(`Your grading request has been submitted, ID is ${i.workflowId}.`);
|
|
1143
1154
|
break;
|
|
@@ -1155,28 +1166,28 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1155
1166
|
const le = X(() => ze(l.value));
|
|
1156
1167
|
return (B, $) => {
|
|
1157
1168
|
const U = S("a-card"), v = S("a-spin");
|
|
1158
|
-
return u(), V("div",
|
|
1169
|
+
return u(), V("div", Co, [
|
|
1159
1170
|
R($e, {
|
|
1160
1171
|
title: s.value.banner.title,
|
|
1161
1172
|
subTitle: s.value.banner.subTitle,
|
|
1162
1173
|
email: E()
|
|
1163
1174
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1164
|
-
T("div",
|
|
1175
|
+
T("div", Vo, [
|
|
1165
1176
|
R(v, {
|
|
1166
1177
|
loading: k.value,
|
|
1167
1178
|
class: "form-container"
|
|
1168
1179
|
}, {
|
|
1169
1180
|
default: p(() => [
|
|
1170
|
-
T("div",
|
|
1171
|
-
T("div",
|
|
1172
|
-
(u(!0), V(K, null, z(le.value, (
|
|
1173
|
-
key:
|
|
1174
|
-
title:
|
|
1181
|
+
T("div", So, [
|
|
1182
|
+
T("div", xo, [
|
|
1183
|
+
(u(!0), V(K, null, z(le.value, (I) => (u(), L(U, {
|
|
1184
|
+
key: I.name,
|
|
1185
|
+
title: I.name,
|
|
1175
1186
|
style: { "margin-bottom": "24px" }
|
|
1176
1187
|
}, {
|
|
1177
1188
|
default: p(() => [
|
|
1178
|
-
T("div",
|
|
1179
|
-
(u(!0), V(K, null, z(
|
|
1189
|
+
T("div", $o, [
|
|
1190
|
+
(u(!0), V(K, null, z(I.fields, (y) => (u(), L(Ke, {
|
|
1180
1191
|
key: y.fieldKey,
|
|
1181
1192
|
ref_for: !0,
|
|
1182
1193
|
ref: "dataWidgets",
|
|
@@ -1193,7 +1204,7 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1193
1204
|
_: 2
|
|
1194
1205
|
}, 1032, ["title"]))), 128))
|
|
1195
1206
|
]),
|
|
1196
|
-
B.$slots.content ? (u(), V("div",
|
|
1207
|
+
B.$slots.content ? (u(), V("div", Io, [
|
|
1197
1208
|
ue(B.$slots, "content", {}, void 0, !0)
|
|
1198
1209
|
])) : se("", !0)
|
|
1199
1210
|
])
|
|
@@ -1201,16 +1212,16 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1201
1212
|
_: 3
|
|
1202
1213
|
}, 8, ["loading"])
|
|
1203
1214
|
]),
|
|
1204
|
-
T("div",
|
|
1205
|
-
T("div",
|
|
1215
|
+
T("div", Ao, [
|
|
1216
|
+
T("div", To, [
|
|
1206
1217
|
ue(B.$slots, "action", {}, void 0, !0),
|
|
1207
|
-
T("div",
|
|
1208
|
-
(u(!0), V(K, null, z(x.value, (
|
|
1209
|
-
key:
|
|
1218
|
+
T("div", Uo, [
|
|
1219
|
+
(u(!0), V(K, null, z(x.value, (I) => (u(), L(ye, {
|
|
1220
|
+
key: I.Title,
|
|
1210
1221
|
loading: k.value,
|
|
1211
|
-
config:
|
|
1222
|
+
config: I,
|
|
1212
1223
|
class: "action-button",
|
|
1213
|
-
onClick: (...y) => ee(
|
|
1224
|
+
onClick: (...y) => ee(I, ...y)
|
|
1214
1225
|
}, null, 8, ["loading", "config", "onClick"]))), 128))
|
|
1215
1226
|
])
|
|
1216
1227
|
])
|
|
@@ -1218,24 +1229,24 @@ const co = { class: "page-container" }, uo = { class: "page-body" }, fo = { clas
|
|
|
1218
1229
|
]);
|
|
1219
1230
|
};
|
|
1220
1231
|
}
|
|
1221
|
-
}),
|
|
1222
|
-
function
|
|
1223
|
-
return
|
|
1232
|
+
}), Lo = /* @__PURE__ */ _e(No, [["__scopeId", "data-v-8d95324e"]]), at = Symbol("library-custom-comp");
|
|
1233
|
+
function Ro() {
|
|
1234
|
+
return ge(at, null);
|
|
1224
1235
|
}
|
|
1225
|
-
const
|
|
1236
|
+
const Fo = Symbol("ArcoConfigProvider"), Do = "arco", Po = "$arco", Mo = (e) => {
|
|
1226
1237
|
var t, a, o;
|
|
1227
|
-
const n =
|
|
1228
|
-
return `${(o = (a = c?.prefixCls) != null ? a : (t = n?.appContext.config.globalProperties[
|
|
1229
|
-
},
|
|
1230
|
-
function
|
|
1231
|
-
return
|
|
1238
|
+
const n = me(), c = ge(Fo, void 0);
|
|
1239
|
+
return `${(o = (a = c?.prefixCls) != null ? a : (t = n?.appContext.config.globalProperties[Po]) == null ? void 0 : t.classPrefix) != null ? o : Do}-${e}`;
|
|
1240
|
+
}, Bo = Object.prototype.toString;
|
|
1241
|
+
function Ho(e) {
|
|
1242
|
+
return Bo.call(e) === "[object Number]" && e === e;
|
|
1232
1243
|
}
|
|
1233
|
-
var
|
|
1244
|
+
var Ko = (e, t) => {
|
|
1234
1245
|
for (const [a, o] of t)
|
|
1235
1246
|
e[a] = o;
|
|
1236
1247
|
return e;
|
|
1237
1248
|
};
|
|
1238
|
-
const
|
|
1249
|
+
const Eo = G({
|
|
1239
1250
|
name: "IconDownload",
|
|
1240
1251
|
props: {
|
|
1241
1252
|
size: {
|
|
@@ -1262,9 +1273,9 @@ const Ho = G({
|
|
|
1262
1273
|
click: (e) => !0
|
|
1263
1274
|
},
|
|
1264
1275
|
setup(e, { emit: t }) {
|
|
1265
|
-
const a =
|
|
1276
|
+
const a = Mo("icon"), o = X(() => [a, `${a}-download`, { [`${a}-spin`]: e.spin }]), n = X(() => {
|
|
1266
1277
|
const r = {};
|
|
1267
|
-
return e.size && (r.fontSize =
|
|
1278
|
+
return e.size && (r.fontSize = Ho(e.size) ? `${e.size}px` : e.size), e.rotate && (r.transform = `rotate(${e.rotate}deg)`), r;
|
|
1268
1279
|
});
|
|
1269
1280
|
return {
|
|
1270
1281
|
cls: o,
|
|
@@ -1274,8 +1285,8 @@ const Ho = G({
|
|
|
1274
1285
|
}
|
|
1275
1286
|
};
|
|
1276
1287
|
}
|
|
1277
|
-
}),
|
|
1278
|
-
function
|
|
1288
|
+
}), zo = ["stroke-width", "stroke-linecap", "stroke-linejoin"];
|
|
1289
|
+
function jo(e, t, a, o, n, c) {
|
|
1279
1290
|
return u(), V("svg", {
|
|
1280
1291
|
viewBox: "0 0 48 48",
|
|
1281
1292
|
fill: "none",
|
|
@@ -1289,32 +1300,32 @@ function Eo(e, t, a, o, n, c) {
|
|
|
1289
1300
|
onClick: t[0] || (t[0] = (...r) => e.onClick && e.onClick(...r))
|
|
1290
1301
|
}, t[1] || (t[1] = [
|
|
1291
1302
|
T("path", { d: "m33.072 22.071-9.07 9.071-9.072-9.07M24 5v26m16 4v6H8v-6" }, null, -1)
|
|
1292
|
-
]), 14,
|
|
1303
|
+
]), 14, zo);
|
|
1293
1304
|
}
|
|
1294
|
-
var Re = /* @__PURE__ */
|
|
1295
|
-
const
|
|
1305
|
+
var Re = /* @__PURE__ */ Ko(Eo, [["render", jo]]);
|
|
1306
|
+
const Oo = Object.assign(Re, {
|
|
1296
1307
|
install: (e, t) => {
|
|
1297
1308
|
var a;
|
|
1298
1309
|
const o = (a = t?.iconPrefix) != null ? a : "";
|
|
1299
1310
|
e.component(o + Re.name, Re);
|
|
1300
1311
|
}
|
|
1301
|
-
}),
|
|
1312
|
+
}), Go = { class: "page-container" }, Wo = { class: "page-body" }, qo = { class: "detail-card" }, Yo = { class: "form-fields-vertical" }, Jo = { class: "detail-fields" }, Xo = { class: "detail-field" }, Qo = { class: "field-label" }, Zo = {
|
|
1302
1313
|
key: 1,
|
|
1303
1314
|
class: "field-value"
|
|
1304
|
-
},
|
|
1315
|
+
}, en = {
|
|
1305
1316
|
key: 2,
|
|
1306
1317
|
class: "detail-field-wrapper"
|
|
1307
|
-
},
|
|
1318
|
+
}, tn = { class: "detail-field" }, on = {
|
|
1308
1319
|
key: 0,
|
|
1309
1320
|
class: "detail-content"
|
|
1310
|
-
},
|
|
1321
|
+
}, nn = { class: "page-footer" }, an = { class: "action-container" }, sn = { class: "action-buttons" }, rn = /* @__PURE__ */ G({
|
|
1311
1322
|
__name: "DetailView",
|
|
1312
1323
|
props: {
|
|
1313
1324
|
className: {},
|
|
1314
1325
|
workflowId: {}
|
|
1315
1326
|
},
|
|
1316
1327
|
setup(e) {
|
|
1317
|
-
const t = xe(), a = Se(), o = Ee(), n = Ve(), c =
|
|
1328
|
+
const t = xe(), a = Se(), o = Ee(), n = Ve(), c = Ro(), r = me(), i = e, s = g({
|
|
1318
1329
|
pageType: "",
|
|
1319
1330
|
fields: {},
|
|
1320
1331
|
globalValidations: [],
|
|
@@ -1380,7 +1391,7 @@ const zo = Object.assign(Re, {
|
|
|
1380
1391
|
workflowId: i.workflowId
|
|
1381
1392
|
});
|
|
1382
1393
|
const b = await Ze(i.className, i.workflowId);
|
|
1383
|
-
ae.value = await
|
|
1394
|
+
ae.value = await Bt(), D.value = await Oe(i.workflowId), fe.value = await Le(i.workflowId), le();
|
|
1384
1395
|
const f = s.value.fields.requestType.modelValue;
|
|
1385
1396
|
o.Test?.(f, B), l.value = _(s.value.fields);
|
|
1386
1397
|
for (const C in s.value.fields)
|
|
@@ -1388,7 +1399,7 @@ const zo = Object.assign(Re, {
|
|
|
1388
1399
|
const Y = l.value.find((N) => N.fieldKey === C);
|
|
1389
1400
|
Y && Y.widget && (Y.widget.files = b[C] ?? []);
|
|
1390
1401
|
}
|
|
1391
|
-
const H = await
|
|
1402
|
+
const H = await Dt(i.className, i.workflowId);
|
|
1392
1403
|
k.value = m(H, 0), x.value = !1;
|
|
1393
1404
|
}
|
|
1394
1405
|
de($);
|
|
@@ -1398,14 +1409,14 @@ const zo = Object.assign(Re, {
|
|
|
1398
1409
|
function v() {
|
|
1399
1410
|
return t()?.userInfo?.email_address ?? "";
|
|
1400
1411
|
}
|
|
1401
|
-
async function
|
|
1412
|
+
async function I(b, f, H, C, Y) {
|
|
1402
1413
|
try {
|
|
1403
1414
|
switch (f) {
|
|
1404
1415
|
case Z.Submit:
|
|
1405
1416
|
const { reason: N, ifGlobal: ie } = await U(Y, { isGlobal: E.value });
|
|
1406
1417
|
x.value = !0;
|
|
1407
1418
|
const P = Y === "Approve" ? "100" : "-1";
|
|
1408
|
-
await
|
|
1419
|
+
await Rt(i.className, i.workflowId, v(), N, [Number(i.workflowId)], H, P, ie), x.value = !1;
|
|
1409
1420
|
const Q = Y === "Approve" ? "approve success!" : "approve reject!";
|
|
1410
1421
|
r?.appContext.config.globalProperties.$notification.success(Q), $();
|
|
1411
1422
|
break;
|
|
@@ -1419,14 +1430,14 @@ const zo = Object.assign(Re, {
|
|
|
1419
1430
|
}
|
|
1420
1431
|
}
|
|
1421
1432
|
const y = g(""), D = g([]), te = g(""), ae = g([]), fe = g([]);
|
|
1422
|
-
async function
|
|
1433
|
+
async function Ie() {
|
|
1423
1434
|
if (!te.value) {
|
|
1424
1435
|
r?.appContext.config.globalProperties.$message.error("Please select an approver");
|
|
1425
1436
|
return;
|
|
1426
1437
|
}
|
|
1427
1438
|
await w("Confirm Assign Approver", "Do you want to assign the selected approver?");
|
|
1428
1439
|
try {
|
|
1429
|
-
await
|
|
1440
|
+
await Ht(i.workflowId, te.value), fe.value = await Le(i.workflowId), le(), r?.appContext.config.globalProperties.$notification.success("Assign Approver clicked!");
|
|
1430
1441
|
} catch (b) {
|
|
1431
1442
|
if (b.status === 409) {
|
|
1432
1443
|
r?.appContext.config.globalProperties.$notification.error("This user is already an associator");
|
|
@@ -1448,14 +1459,14 @@ const zo = Object.assign(Re, {
|
|
|
1448
1459
|
});
|
|
1449
1460
|
});
|
|
1450
1461
|
}
|
|
1451
|
-
async function
|
|
1462
|
+
async function A(b) {
|
|
1452
1463
|
try {
|
|
1453
1464
|
await w("Confirm Delete Associator", "Do you want to delete this associator?");
|
|
1454
1465
|
} catch {
|
|
1455
1466
|
return;
|
|
1456
1467
|
}
|
|
1457
1468
|
try {
|
|
1458
|
-
await
|
|
1469
|
+
await Et(String(b)), fe.value = await Le(i.workflowId), r?.appContext.config.globalProperties.$notification.success("Associator deleted successfully!");
|
|
1459
1470
|
} catch {
|
|
1460
1471
|
r?.appContext.config.globalProperties.$notification.error("Failed to delete associator");
|
|
1461
1472
|
}
|
|
@@ -1465,58 +1476,58 @@ const zo = Object.assign(Re, {
|
|
|
1465
1476
|
r?.appContext.config.globalProperties.$message.error("Comment cannot be empty");
|
|
1466
1477
|
return;
|
|
1467
1478
|
}
|
|
1468
|
-
await
|
|
1479
|
+
await Kt(i.workflowId, v(), y.value), y.value = "", D.value = await Oe(i.workflowId), r?.appContext.config.globalProperties.$notification.success("Add Comment clicked!");
|
|
1469
1480
|
}
|
|
1470
1481
|
return (b, f) => {
|
|
1471
1482
|
const H = S("a-link"), C = S("a-space"), Y = S("a-card"), N = S("a-option"), ie = S("a-select"), P = S("a-button"), Q = S("a-list-item"), W = S("a-list"), he = S("a-textarea"), st = S("a-spin");
|
|
1472
|
-
return u(), V("div",
|
|
1483
|
+
return u(), V("div", Go, [
|
|
1473
1484
|
R($e, {
|
|
1474
1485
|
title: s.value.banner.title,
|
|
1475
1486
|
subTitle: s.value.banner.subTitle,
|
|
1476
1487
|
email: v()
|
|
1477
1488
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1478
|
-
T("div",
|
|
1489
|
+
T("div", Wo, [
|
|
1479
1490
|
R(st, {
|
|
1480
1491
|
loading: x.value,
|
|
1481
1492
|
class: "detail-container"
|
|
1482
1493
|
}, {
|
|
1483
1494
|
default: p(() => [
|
|
1484
|
-
T("div",
|
|
1495
|
+
T("div", qo, [
|
|
1485
1496
|
(u(), L(Pe(Te(c).Steps), { steps: k.value }, null, 8, ["steps"])),
|
|
1486
|
-
T("div",
|
|
1497
|
+
T("div", Yo, [
|
|
1487
1498
|
(u(!0), V(K, null, z(d.value, (M) => (u(), L(Y, {
|
|
1488
1499
|
key: M.name,
|
|
1489
1500
|
title: M.name,
|
|
1490
1501
|
style: { "margin-bottom": "24px" }
|
|
1491
1502
|
}, {
|
|
1492
1503
|
default: p(() => [
|
|
1493
|
-
T("div",
|
|
1504
|
+
T("div", Jo, [
|
|
1494
1505
|
(u(!0), V(K, null, z(M.fields, (ce) => (u(), V("div", {
|
|
1495
1506
|
key: ce.fieldKey,
|
|
1496
1507
|
class: "detail-field-wrapper"
|
|
1497
1508
|
}, [
|
|
1498
|
-
T("div",
|
|
1499
|
-
T("div",
|
|
1500
|
-
ce.widget?.widget === "File" ? (u(!0), V(K, { key: 0 }, z(ce.widget.files, (
|
|
1509
|
+
T("div", Xo, [
|
|
1510
|
+
T("div", Qo, J(ce.widget?.title), 1),
|
|
1511
|
+
ce.widget?.widget === "File" ? (u(!0), V(K, { key: 0 }, z(ce.widget.files, (Ae) => (u(), V("div", {
|
|
1501
1512
|
class: "field-value",
|
|
1502
|
-
key:
|
|
1513
|
+
key: Ae.id
|
|
1503
1514
|
}, [
|
|
1504
1515
|
R(C, null, {
|
|
1505
1516
|
default: p(() => [
|
|
1506
|
-
q(J(
|
|
1517
|
+
q(J(Ae.name) + " ", 1),
|
|
1507
1518
|
R(H, {
|
|
1508
|
-
href:
|
|
1519
|
+
href: Ae.url,
|
|
1509
1520
|
target: "_blank"
|
|
1510
1521
|
}, {
|
|
1511
1522
|
default: p(() => [
|
|
1512
|
-
R(Te(
|
|
1523
|
+
R(Te(Oo), { style: { color: "#7A00E6" } })
|
|
1513
1524
|
]),
|
|
1514
1525
|
_: 2
|
|
1515
1526
|
}, 1032, ["href"])
|
|
1516
1527
|
]),
|
|
1517
1528
|
_: 2
|
|
1518
1529
|
}, 1024)
|
|
1519
|
-
]))), 128)) : (u(), V("div",
|
|
1530
|
+
]))), 128)) : (u(), V("div", Zo, J(ce.fieldValue), 1))
|
|
1520
1531
|
])
|
|
1521
1532
|
]))), 128))
|
|
1522
1533
|
])
|
|
@@ -1544,7 +1555,7 @@ const zo = Object.assign(Re, {
|
|
|
1544
1555
|
}, 8, ["modelValue"]),
|
|
1545
1556
|
R(P, {
|
|
1546
1557
|
type: "primary",
|
|
1547
|
-
onClick:
|
|
1558
|
+
onClick: Ie
|
|
1548
1559
|
}, {
|
|
1549
1560
|
default: p(() => f[2] || (f[2] = [
|
|
1550
1561
|
q("Assign for comment", -1)
|
|
@@ -1567,7 +1578,7 @@ const zo = Object.assign(Re, {
|
|
|
1567
1578
|
R(P, {
|
|
1568
1579
|
type: "text",
|
|
1569
1580
|
status: "danger",
|
|
1570
|
-
onClick: (ce) =>
|
|
1581
|
+
onClick: (ce) => A(M.id)
|
|
1571
1582
|
}, {
|
|
1572
1583
|
default: p(() => f[4] || (f[4] = [
|
|
1573
1584
|
q(" Delete ", -1)
|
|
@@ -1584,8 +1595,8 @@ const zo = Object.assign(Re, {
|
|
|
1584
1595
|
]),
|
|
1585
1596
|
_: 1
|
|
1586
1597
|
})) : se("", !0),
|
|
1587
|
-
ne.value ? (u(), V("div",
|
|
1588
|
-
T("div",
|
|
1598
|
+
ne.value ? (u(), V("div", en, [
|
|
1599
|
+
T("div", tn, [
|
|
1589
1600
|
f[6] || (f[6] = T("div", { class: "field-label" }, "Comment", -1)),
|
|
1590
1601
|
R(he, {
|
|
1591
1602
|
modelValue: y.value,
|
|
@@ -1620,7 +1631,7 @@ const zo = Object.assign(Re, {
|
|
|
1620
1631
|
_: 1
|
|
1621
1632
|
})) : se("", !0)
|
|
1622
1633
|
]),
|
|
1623
|
-
b.$slots.content ? (u(), V("div",
|
|
1634
|
+
b.$slots.content ? (u(), V("div", on, [
|
|
1624
1635
|
ue(b.$slots, "content", {}, void 0, !0)
|
|
1625
1636
|
])) : se("", !0)
|
|
1626
1637
|
])
|
|
@@ -1628,16 +1639,16 @@ const zo = Object.assign(Re, {
|
|
|
1628
1639
|
_: 3
|
|
1629
1640
|
}, 8, ["loading"])
|
|
1630
1641
|
]),
|
|
1631
|
-
T("div",
|
|
1632
|
-
T("div",
|
|
1642
|
+
T("div", nn, [
|
|
1643
|
+
T("div", an, [
|
|
1633
1644
|
ue(b.$slots, "action", {}, void 0, !0),
|
|
1634
|
-
T("div",
|
|
1635
|
-
(u(!0), V(K, null, z(h.value, (M) => (u(), L(
|
|
1645
|
+
T("div", sn, [
|
|
1646
|
+
(u(!0), V(K, null, z(h.value, (M) => (u(), L(ye, {
|
|
1636
1647
|
key: M.Title,
|
|
1637
1648
|
loading: x.value,
|
|
1638
1649
|
config: M,
|
|
1639
1650
|
class: "action-button",
|
|
1640
|
-
onClick: (...ce) =>
|
|
1651
|
+
onClick: (...ce) => I(M, ...ce)
|
|
1641
1652
|
}, null, 8, ["loading", "config", "onClick"]))), 128))
|
|
1642
1653
|
])
|
|
1643
1654
|
])
|
|
@@ -1645,14 +1656,14 @@ const zo = Object.assign(Re, {
|
|
|
1645
1656
|
]);
|
|
1646
1657
|
};
|
|
1647
1658
|
}
|
|
1648
|
-
}),
|
|
1659
|
+
}), ln = /* @__PURE__ */ _e(rn, [["__scopeId", "data-v-50190ec4"]]), cn = { class: "list-container" }, un = { class: "query-title" }, dn = /* @__PURE__ */ G({
|
|
1649
1660
|
name: "ListView",
|
|
1650
1661
|
__name: "ListView",
|
|
1651
1662
|
props: {
|
|
1652
1663
|
className: {}
|
|
1653
1664
|
},
|
|
1654
1665
|
setup(e) {
|
|
1655
|
-
const t = xe(), a = Se(), o = Ve(), n =
|
|
1666
|
+
const t = xe(), a = Se(), o = Ve(), n = me(), c = e, r = g(), i = Me({
|
|
1656
1667
|
current: 1,
|
|
1657
1668
|
total: 0,
|
|
1658
1669
|
pageSize: 10,
|
|
@@ -1662,8 +1673,8 @@ const zo = Object.assign(Re, {
|
|
|
1662
1673
|
filters: []
|
|
1663
1674
|
});
|
|
1664
1675
|
function s() {
|
|
1665
|
-
const w = Object.entries(
|
|
1666
|
-
key:
|
|
1676
|
+
const w = Object.entries(I.value).filter(([, { value: A }]) => A && A !== "").map(([A, { value: F, operator: b }]) => ({
|
|
1677
|
+
key: A,
|
|
1667
1678
|
value: F,
|
|
1668
1679
|
operator: b
|
|
1669
1680
|
// 根据实际需要调整操作符
|
|
@@ -1683,7 +1694,7 @@ const zo = Object.assign(Re, {
|
|
|
1683
1694
|
// 只设置横向滚动
|
|
1684
1695
|
// 移除 y 属性,让表格高度自适应
|
|
1685
1696
|
})), _ = (w) => {
|
|
1686
|
-
const
|
|
1697
|
+
const A = Object.entries(w).filter(([, F]) => F.widget?.column).map(([F, b], f) => ({
|
|
1687
1698
|
title: b.widget.title,
|
|
1688
1699
|
dataIndex: F.charAt(0).toLowerCase() + F.slice(1),
|
|
1689
1700
|
order: b.order,
|
|
@@ -1695,7 +1706,7 @@ const zo = Object.assign(Re, {
|
|
|
1695
1706
|
resizable: !0
|
|
1696
1707
|
// 启用列宽调整
|
|
1697
1708
|
})).sort((F, b) => F.order - b.order);
|
|
1698
|
-
|
|
1709
|
+
A.push({
|
|
1699
1710
|
title: "Actions",
|
|
1700
1711
|
slotName: "optional",
|
|
1701
1712
|
align: "center",
|
|
@@ -1703,10 +1714,10 @@ const zo = Object.assign(Re, {
|
|
|
1703
1714
|
minWidth: 200,
|
|
1704
1715
|
fixed: "right",
|
|
1705
1716
|
resizable: !1
|
|
1706
|
-
}), h.value =
|
|
1717
|
+
}), h.value = A;
|
|
1707
1718
|
}, d = g([]), h = g([]), x = g(!0), m = g(!0), k = g(), E = async () => {
|
|
1708
1719
|
m.value = !0;
|
|
1709
|
-
const w = await
|
|
1720
|
+
const w = await xt(c.className, s());
|
|
1710
1721
|
d.value = w.data, i.total = w.totalCount, m.value = !1;
|
|
1711
1722
|
}, ee = g(!1);
|
|
1712
1723
|
de(async () => {
|
|
@@ -1722,7 +1733,7 @@ const zo = Object.assign(Re, {
|
|
|
1722
1733
|
}, ne = (w) => {
|
|
1723
1734
|
i.pageSize = w, E();
|
|
1724
1735
|
};
|
|
1725
|
-
function le(w,
|
|
1736
|
+
function le(w, A, F, b, f) {
|
|
1726
1737
|
switch (w) {
|
|
1727
1738
|
case Z.Link:
|
|
1728
1739
|
o.push({ name: F, params: { workflowId: f } });
|
|
@@ -1731,10 +1742,10 @@ const zo = Object.assign(Re, {
|
|
|
1731
1742
|
console.warn("Unknown action type:", w);
|
|
1732
1743
|
}
|
|
1733
1744
|
}
|
|
1734
|
-
function B(w,
|
|
1745
|
+
function B(w, A, F) {
|
|
1735
1746
|
switch (w) {
|
|
1736
1747
|
case Z.Submit:
|
|
1737
|
-
|
|
1748
|
+
zt(A, { filters: [{ key: "approverList", value: $(), operator: 2 }] }), n?.appContext.config.globalProperties.$notification.success("submit success!");
|
|
1738
1749
|
break;
|
|
1739
1750
|
case Z.Link:
|
|
1740
1751
|
o.push({ name: F });
|
|
@@ -1746,37 +1757,37 @@ const zo = Object.assign(Re, {
|
|
|
1746
1757
|
function $() {
|
|
1747
1758
|
return t()?.userInfo?.email_address ?? "";
|
|
1748
1759
|
}
|
|
1749
|
-
function U(w,
|
|
1750
|
-
return typeof w != "string" || w.indexOf("{currentUserEmail}") === -1 ? w : w.replace(/{currentUserEmail}/g,
|
|
1760
|
+
function U(w, A) {
|
|
1761
|
+
return typeof w != "string" || w.indexOf("{currentUserEmail}") === -1 ? w : w.replace(/{currentUserEmail}/g, A);
|
|
1751
1762
|
}
|
|
1752
1763
|
function v(w) {
|
|
1753
|
-
const
|
|
1754
|
-
i.filters =
|
|
1764
|
+
const A = r.value?.tabs?.find((F) => F.key === w)?.filters;
|
|
1765
|
+
i.filters = A?.map((F) => ({
|
|
1755
1766
|
...F,
|
|
1756
1767
|
value: U(F.value, $())
|
|
1757
1768
|
})) || [], E();
|
|
1758
1769
|
}
|
|
1759
|
-
const
|
|
1770
|
+
const I = g({}), y = g([]);
|
|
1760
1771
|
function D(w) {
|
|
1761
1772
|
if (!w) return [];
|
|
1762
|
-
y.value = Object.entries(w).filter(([,
|
|
1773
|
+
y.value = Object.entries(w).filter(([, A]) => A.isFiltered).map(([A, F]) => ({ fieldKey: A, fieldConfig: F }));
|
|
1763
1774
|
}
|
|
1764
1775
|
const te = () => {
|
|
1765
1776
|
const w = {};
|
|
1766
|
-
y.value.forEach(({ fieldKey:
|
|
1767
|
-
w[
|
|
1768
|
-
}),
|
|
1777
|
+
y.value.forEach(({ fieldKey: A, fieldConfig: F }) => {
|
|
1778
|
+
w[A] = {}, w[A].value = F.modelValue, w[A].operator = F.operator;
|
|
1779
|
+
}), I.value = w;
|
|
1769
1780
|
}, ae = () => {
|
|
1770
1781
|
i.current = 1, E();
|
|
1771
1782
|
}, fe = () => {
|
|
1772
1783
|
r.value && te(), ae();
|
|
1773
1784
|
};
|
|
1774
|
-
function
|
|
1775
|
-
return !(w.location !== "InTable" || w.title === "Update" && (
|
|
1785
|
+
function Ie(w, A) {
|
|
1786
|
+
return !(w.location !== "InTable" || w.title === "Update" && (A.status === 100 || A.status === -1));
|
|
1776
1787
|
}
|
|
1777
|
-
return (w,
|
|
1788
|
+
return (w, A) => {
|
|
1778
1789
|
const F = S("a-space"), b = S("a-col"), f = S("a-button"), H = S("a-row"), C = S("a-card"), Y = S("a-tab-pane"), N = S("a-tabs"), ie = S("a-table");
|
|
1779
|
-
return u(), V("div",
|
|
1790
|
+
return u(), V("div", cn, [
|
|
1780
1791
|
R($e, {
|
|
1781
1792
|
title: r.value?.banner.title ?? "",
|
|
1782
1793
|
subTitle: r.value?.banner.subTitle ?? "",
|
|
@@ -1784,14 +1795,14 @@ const zo = Object.assign(Re, {
|
|
|
1784
1795
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1785
1796
|
R(C, null, {
|
|
1786
1797
|
default: p(() => [
|
|
1787
|
-
T("div",
|
|
1788
|
-
|
|
1798
|
+
T("div", un, [
|
|
1799
|
+
A[0] || (A[0] = T("h3", null, "Search Conditions", -1)),
|
|
1789
1800
|
R(F, { size: "medium" }, {
|
|
1790
1801
|
default: p(() => [
|
|
1791
1802
|
(u(!0), V(K, null, z(k.value, (P) => (u(), V(K, {
|
|
1792
1803
|
key: P.title
|
|
1793
1804
|
}, [
|
|
1794
|
-
P.location === "InOperation" ? (u(), L(
|
|
1805
|
+
P.location === "InOperation" ? (u(), L(ye, {
|
|
1795
1806
|
key: 0,
|
|
1796
1807
|
config: P,
|
|
1797
1808
|
onClick: B
|
|
@@ -1812,8 +1823,8 @@ const zo = Object.assign(Re, {
|
|
|
1812
1823
|
R(Ke, {
|
|
1813
1824
|
name: P.fieldKey,
|
|
1814
1825
|
config: P.fieldConfig,
|
|
1815
|
-
modelValue:
|
|
1816
|
-
"onUpdate:modelValue": (Q) =>
|
|
1826
|
+
modelValue: I.value[P.fieldKey].value,
|
|
1827
|
+
"onUpdate:modelValue": (Q) => I.value[P.fieldKey].value = Q,
|
|
1817
1828
|
class: "form-field"
|
|
1818
1829
|
}, null, 8, ["name", "config", "modelValue", "onUpdate:modelValue"])
|
|
1819
1830
|
]),
|
|
@@ -1831,7 +1842,7 @@ const zo = Object.assign(Re, {
|
|
|
1831
1842
|
size: "medium",
|
|
1832
1843
|
onClick: ae
|
|
1833
1844
|
}, {
|
|
1834
|
-
default: p(() =>
|
|
1845
|
+
default: p(() => A[1] || (A[1] = [
|
|
1835
1846
|
q(" Search ", -1)
|
|
1836
1847
|
])),
|
|
1837
1848
|
_: 1,
|
|
@@ -1841,7 +1852,7 @@ const zo = Object.assign(Re, {
|
|
|
1841
1852
|
size: "medium",
|
|
1842
1853
|
onClick: fe
|
|
1843
1854
|
}, {
|
|
1844
|
-
default: p(() =>
|
|
1855
|
+
default: p(() => A[2] || (A[2] = [
|
|
1845
1856
|
q(" Reset ", -1)
|
|
1846
1857
|
])),
|
|
1847
1858
|
_: 1,
|
|
@@ -1896,7 +1907,7 @@ const zo = Object.assign(Re, {
|
|
|
1896
1907
|
(u(!0), V(K, null, z(k.value, (Q) => (u(), V(K, {
|
|
1897
1908
|
key: Q.title
|
|
1898
1909
|
}, [
|
|
1899
|
-
|
|
1910
|
+
Ie(Q, P) ? (u(), L(ye, {
|
|
1900
1911
|
key: 0,
|
|
1901
1912
|
config: Q,
|
|
1902
1913
|
size: "small",
|
|
@@ -1912,12 +1923,12 @@ const zo = Object.assign(Re, {
|
|
|
1912
1923
|
]);
|
|
1913
1924
|
};
|
|
1914
1925
|
}
|
|
1915
|
-
}),
|
|
1926
|
+
}), fn = /* @__PURE__ */ _e(dn, [["__scopeId", "data-v-32799bcf"]]), wn = {
|
|
1916
1927
|
install(e, t = {}) {
|
|
1917
|
-
t.config && wt(t.config), t.router && e.provide(et, t.router), t.pinia && e.provide(
|
|
1928
|
+
t.config && wt(t.config), t.router && e.provide(et, t.router), t.pinia && e.provide(no, t.pinia), t.useBpmStore && e.provide(ot, t.useBpmStore), t.useSvrStore && e.provide(nt, t.useSvrStore), t.triggers && e.provide(tt, t.triggers), t.customComps && e.provide(at, t.customComps), e.component("CreateView", ko), e.component("UpdateView", Lo), e.component("DetailView", ln), e.component("ListView", fn);
|
|
1918
1929
|
}
|
|
1919
1930
|
};
|
|
1920
1931
|
export {
|
|
1921
|
-
|
|
1932
|
+
wn as default
|
|
1922
1933
|
};
|
|
1923
1934
|
//# sourceMappingURL=index.es.js.map
|