@chase-shao/vue-component-lib 1.2.89 → 1.2.90
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/ToolTip.vue.d.ts +7 -0
- 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.css +1 -1
- package/dist/index.es.js +617 -592
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/dist/services/dataGen.d.ts +6 -0
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref as m, getCurrentInstance as pe, defineComponent as
|
|
1
|
+
import { ref as m, getCurrentInstance as pe, defineComponent as E, mergeModels as le, useModel as we, resolveComponent as C, createBlock as F, openBlock as d, onMounted as ue, computed as G, withCtx as k, createElementBlock as h, Fragment as O, renderList as M, createVNode as N, nextTick as dt, createTextVNode as ne, inject as me, normalizeStyle as Ye, normalizeClass as Qe, createElementVNode as b, createCommentVNode as oe, toDisplayString as Q, useTemplateRef as He, resolveDynamicComponent as Le, renderSlot as de, reactive as ut, onActivated as ft } from "vue";
|
|
2
2
|
import pt from "axios";
|
|
3
3
|
import { defineStore as mt } from "pinia";
|
|
4
4
|
import { Modal as gt } from "@arco-design/web-vue";
|
|
@@ -48,12 +48,12 @@ const vt = mt("main", () => ({
|
|
|
48
48
|
const e = document.createElement("a"), o = window.URL.createObjectURL(a);
|
|
49
49
|
e.href = o, e.download = n, e.click(), window.URL.revokeObjectURL(o);
|
|
50
50
|
};
|
|
51
|
-
let
|
|
51
|
+
let Fe = {};
|
|
52
52
|
function wt(t) {
|
|
53
|
-
|
|
53
|
+
Fe = { ...Fe, ...t };
|
|
54
54
|
}
|
|
55
55
|
function Re() {
|
|
56
|
-
return
|
|
56
|
+
return Fe;
|
|
57
57
|
}
|
|
58
58
|
const kt = pe();
|
|
59
59
|
function Je() {
|
|
@@ -97,7 +97,7 @@ const Ze = async () => {
|
|
|
97
97
|
e.token = void 0;
|
|
98
98
|
}, (o.data?.expireSeconds ?? 3600) * 1e3), o?.data?.token;
|
|
99
99
|
});
|
|
100
|
-
},
|
|
100
|
+
}, K = async () => {
|
|
101
101
|
const t = await Ze(), n = Xe();
|
|
102
102
|
return n.defaults.headers.common.Authorization = `Bearer ${t}`, n;
|
|
103
103
|
}, Ne = {
|
|
@@ -107,11 +107,11 @@ const Ze = async () => {
|
|
|
107
107
|
ApproverEmail: (t) => t.svrStore()?.userInfo?.email_address ?? "test.email@dataGetter.ts",
|
|
108
108
|
ApproverPositionCode: (t) => t.bpmStore()?.positionCode ?? 999,
|
|
109
109
|
RejectReason: () => "Test Reject Reason"
|
|
110
|
-
},
|
|
110
|
+
}, W = [];
|
|
111
111
|
for (let t = 0; t < 256; ++t)
|
|
112
|
-
|
|
112
|
+
W.push((t + 256).toString(16).slice(1));
|
|
113
113
|
function St(t, n = 0) {
|
|
114
|
-
return (
|
|
114
|
+
return (W[t[n + 0]] + W[t[n + 1]] + W[t[n + 2]] + W[t[n + 3]] + "-" + W[t[n + 4]] + W[t[n + 5]] + "-" + W[t[n + 6]] + W[t[n + 7]] + "-" + W[t[n + 8]] + W[t[n + 9]] + "-" + W[t[n + 10]] + W[t[n + 11]] + W[t[n + 12]] + W[t[n + 13]] + W[t[n + 14]] + W[t[n + 15]]).toLowerCase();
|
|
115
115
|
}
|
|
116
116
|
let Ue;
|
|
117
117
|
const xt = new Uint8Array(16);
|
|
@@ -123,7 +123,7 @@ function At() {
|
|
|
123
123
|
}
|
|
124
124
|
return Ue(xt);
|
|
125
125
|
}
|
|
126
|
-
const
|
|
126
|
+
const Tt = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), ze = { randomUUID: Tt };
|
|
127
127
|
function et(t, n, a) {
|
|
128
128
|
if (ze.randomUUID && !t)
|
|
129
129
|
return ze.randomUUID();
|
|
@@ -133,8 +133,8 @@ function et(t, n, a) {
|
|
|
133
133
|
throw new Error("Random bytes length must be >= 16");
|
|
134
134
|
return e[6] = e[6] & 15 | 64, e[8] = e[8] & 63 | 128, St(e);
|
|
135
135
|
}
|
|
136
|
-
var
|
|
137
|
-
function
|
|
136
|
+
var J = /* @__PURE__ */ ((t) => (t[t.Submit = 0] = "Submit", t[t.Link = 1] = "Link", t[t.Button = 2] = "Button", t))(J || {}), fe = /* @__PURE__ */ ((t) => (t[t.Create = 0] = "Create", t[t.Update = 1] = "Update", t[t.Details = 2] = "Details", t[t.List = 3] = "List", t[t.ReCreate = 5] = "ReCreate", t))(fe || {});
|
|
137
|
+
function Vt(t, n, a) {
|
|
138
138
|
const e = {
|
|
139
139
|
pageType: "",
|
|
140
140
|
fields: {},
|
|
@@ -174,14 +174,14 @@ function It(t, n, a) {
|
|
|
174
174
|
redirectUrl: o.redirectUrl,
|
|
175
175
|
redirectType: o.redirectType,
|
|
176
176
|
title: o.title,
|
|
177
|
-
widget: o.widget === "Link" ?
|
|
177
|
+
widget: o.widget === "Link" ? J.Link : o.widget === "Submit" ? J.Submit : J.Button,
|
|
178
178
|
location: o.location,
|
|
179
179
|
attributeType: o.attributeType,
|
|
180
180
|
readonly: o.readonly,
|
|
181
181
|
eventName: o.eventName
|
|
182
182
|
});
|
|
183
183
|
}
|
|
184
|
-
} else o.attributeType === "Banner" && (e.banner.title = o.title, n === 0 || n === 5 ? e.banner.subTitle = o.subTitle : e.banner.subTitle =
|
|
184
|
+
} else o.attributeType === "Banner" && (e.banner.title = o.title, n === 0 || n === 5 ? e.banner.subTitle = o.subTitle : e.banner.subTitle = $e(o.subTitle, t.workflowId.propertyValue));
|
|
185
185
|
}), e.tabs && (e.tabs = e.tabs.sort((o, l) => o.order - l.order)), Object.entries(t).forEach(([o, l]) => {
|
|
186
186
|
if (o === "__ClassAttributes" || o === "className" || o === "id" || o === "deleteFlag" || o === "status" || o === "workFlowReason" || n !== 3 && o === "workflowId")
|
|
187
187
|
return;
|
|
@@ -204,10 +204,10 @@ function It(t, n, a) {
|
|
|
204
204
|
break;
|
|
205
205
|
}
|
|
206
206
|
o === "onBehalf" && n === 0 && (s.modelValue = Ne.CurrentUserEmail(a)), (n === 1 || n === 5) && (o === "directReports" || o === "employeesInTheTeam") && s.modelValue && (s.modelValue = Number(s.modelValue)), c?.forEach((r) => {
|
|
207
|
-
r.order || r.Order ? s.order = r.order ?? r.Order : r.attributeType === "UIControl" ? s.widget = {
|
|
207
|
+
r.order || r.Order ? s.order = r.order ?? r.Order : r.attributeType === "UIControl" ? (r.outputText = r.outputText ? JSON.parse(r.outputText) : [], s.widget = {
|
|
208
208
|
...r,
|
|
209
209
|
column: !0
|
|
210
|
-
} : r.attributeType === "UIValidationControl" && n !== 3 ? s.widget?.widget !== "CheckBox" && s.validations.push(r) : r.attributeType === "UIListed" ? s.widget = {
|
|
210
|
+
}) : r.attributeType === "UIValidationControl" && n !== 3 ? s.widget?.widget !== "CheckBox" && s.validations.push(r) : r.attributeType === "UIListed" ? s.widget = {
|
|
211
211
|
...r,
|
|
212
212
|
column: !0
|
|
213
213
|
} : r.attributeType === "UIFiltered" ? (s.isFiltered = !0, s.operator = r.operatorType) : r.dependentType ? s.dependent = Ne[r.dependentType] ? Ne[r.dependentType](a) : "" : r.eventType === "Change" && s.triggers?.push({
|
|
@@ -218,11 +218,11 @@ function It(t, n, a) {
|
|
|
218
218
|
}), e;
|
|
219
219
|
}
|
|
220
220
|
const Ke = async (t, n, a, e) => {
|
|
221
|
-
const l = await (await
|
|
222
|
-
return
|
|
223
|
-
},
|
|
221
|
+
const l = await (await K()).get(`/General/${n}/${t}/page`, { params: e });
|
|
222
|
+
return Vt(l?.data, t, a);
|
|
223
|
+
}, It = async (t, n, a) => (await (await K()).post(`/${n}/${t}/button/List`, null, { params: a }))?.data;
|
|
224
224
|
async function Pt(t, n) {
|
|
225
|
-
const e = await (await
|
|
225
|
+
const e = await (await K()).post(`/General/${t}/list`, n);
|
|
226
226
|
return {
|
|
227
227
|
data: e.data.data,
|
|
228
228
|
totalCount: e.data.totalCount
|
|
@@ -242,50 +242,50 @@ async function Pt(t, n) {
|
|
|
242
242
|
};
|
|
243
243
|
}
|
|
244
244
|
async function Nt(t, n, a) {
|
|
245
|
-
return (await (await
|
|
245
|
+
return (await (await K()).post(a, n, {
|
|
246
246
|
params: {
|
|
247
247
|
className: t
|
|
248
248
|
}
|
|
249
249
|
})).data;
|
|
250
250
|
}
|
|
251
251
|
async function Ut(t, n, a, e) {
|
|
252
|
-
const o = await
|
|
252
|
+
const o = await K(), l = $e(e, n);
|
|
253
253
|
return (await o.put(l, a))?.data;
|
|
254
254
|
}
|
|
255
|
-
function
|
|
255
|
+
function $e(t, n) {
|
|
256
256
|
return t.replace(/{WorkflowId}/g, n);
|
|
257
257
|
}
|
|
258
258
|
function Dt(t, n) {
|
|
259
259
|
return t.replace(/{ApproverEmail}/g, encodeURIComponent(n));
|
|
260
260
|
}
|
|
261
|
-
function
|
|
261
|
+
function Bt(t, n) {
|
|
262
262
|
return t.replace(/{WorkFlowReason}/g, encodeURIComponent(n));
|
|
263
263
|
}
|
|
264
|
-
function
|
|
264
|
+
function Ft(t, n) {
|
|
265
265
|
return t.replace(/{Status}/g, n);
|
|
266
266
|
}
|
|
267
|
-
function
|
|
267
|
+
function Ht(t, n) {
|
|
268
268
|
return t.replace(/{IfTriggerGlobal_RandP_Approval}/g, n);
|
|
269
269
|
}
|
|
270
270
|
function Lt(t, n) {
|
|
271
271
|
return t.replace(/{ClassName}/g, encodeURIComponent(n));
|
|
272
272
|
}
|
|
273
273
|
async function Rt(t, n, a, e, o, l, s, c) {
|
|
274
|
-
const i = await
|
|
275
|
-
let r =
|
|
276
|
-
return r = Dt(r, a), r =
|
|
274
|
+
const i = await K();
|
|
275
|
+
let r = $e(l, n);
|
|
276
|
+
return r = Dt(r, a), r = Bt(r, e), r = Ft(r, s), r = Ht(r, c), r = Lt(r, t), (await i.put(r, o))?.data;
|
|
277
277
|
}
|
|
278
|
-
async function
|
|
279
|
-
const o = (await (await
|
|
278
|
+
async function $t(t, n) {
|
|
279
|
+
const o = (await (await K()).get(t, { params: { value: n } }))?.data;
|
|
280
280
|
return Object.entries(o).map(([l, s]) => ({
|
|
281
281
|
value: l,
|
|
282
282
|
label: s
|
|
283
283
|
}));
|
|
284
284
|
}
|
|
285
285
|
async function Ot(t, n) {
|
|
286
|
-
return (await (await
|
|
286
|
+
return (await (await K()).get(`/General/${t}/${n}/process`))?.data;
|
|
287
287
|
}
|
|
288
|
-
function
|
|
288
|
+
function jt(t) {
|
|
289
289
|
return {
|
|
290
290
|
uid: t.id ?? et(),
|
|
291
291
|
name: t.attachmentName ?? "unknown",
|
|
@@ -293,40 +293,40 @@ function $t(t) {
|
|
|
293
293
|
};
|
|
294
294
|
}
|
|
295
295
|
async function Mt(t, n) {
|
|
296
|
-
return (await (await
|
|
296
|
+
return (await (await K()).get(`/General/${t}/${n}/upload/get`))?.data.reduce((l, s) => {
|
|
297
297
|
const { category: c } = s;
|
|
298
|
-
return l[c] || (l[c] = []), l[c].push(
|
|
298
|
+
return l[c] || (l[c] = []), l[c].push(jt(s)), l;
|
|
299
299
|
}, {});
|
|
300
300
|
}
|
|
301
301
|
async function Et(t, n) {
|
|
302
|
-
return (await
|
|
302
|
+
return (await K()).post(`/General/${t}/${n}/delete/attachment`);
|
|
303
303
|
}
|
|
304
304
|
async function zt() {
|
|
305
|
-
const n = await (await
|
|
305
|
+
const n = await (await K()).get("/Grading/dropdown/approvers");
|
|
306
306
|
return Object.entries(n?.data).map(([a, e]) => ({
|
|
307
307
|
label: a,
|
|
308
308
|
value: e
|
|
309
309
|
}));
|
|
310
310
|
}
|
|
311
311
|
async function Kt(t, n) {
|
|
312
|
-
return await (await
|
|
312
|
+
return await (await K()).post(`Grading/AssignComments/${t}/${encodeURIComponent(n)}`);
|
|
313
313
|
}
|
|
314
314
|
async function Wt(t, n, a) {
|
|
315
|
-
return await (await
|
|
315
|
+
return await (await K()).post(`Grading/AddComments/${t}/${encodeURIComponent(n)}`, a, {
|
|
316
316
|
headers: { "Content-Type": "application/json;charset=UTF-8" }
|
|
317
317
|
});
|
|
318
318
|
}
|
|
319
319
|
async function Gt(t) {
|
|
320
|
-
return (await (await
|
|
320
|
+
return (await (await K()).get(`Grading/GetComments/${t}`))?.data;
|
|
321
321
|
}
|
|
322
322
|
async function qt(t) {
|
|
323
|
-
return (await (await
|
|
323
|
+
return (await (await K()).get(`Grading/GetAssociator/${t}`))?.data;
|
|
324
324
|
}
|
|
325
|
-
async function
|
|
326
|
-
return await (await
|
|
325
|
+
async function Yt(t) {
|
|
326
|
+
return await (await K()).delete(`Grading/DeleteAssociator/${t}`);
|
|
327
327
|
}
|
|
328
|
-
async function
|
|
329
|
-
const e = await (await
|
|
328
|
+
async function Qt(t, n = null) {
|
|
329
|
+
const e = await (await K()).post(t, n, {
|
|
330
330
|
responseType: "blob"
|
|
331
331
|
});
|
|
332
332
|
yt(e?.data, "WorkflowData.xlsx");
|
|
@@ -343,7 +343,7 @@ const ge = (t, n) => {
|
|
|
343
343
|
}, Xt = {
|
|
344
344
|
Regex: (t, n) => new RegExp(t).test(n),
|
|
345
345
|
Required: (t, n) => !!n
|
|
346
|
-
}, Zt = /* @__PURE__ */
|
|
346
|
+
}, Zt = /* @__PURE__ */ E({
|
|
347
347
|
__name: "InputText",
|
|
348
348
|
props: /* @__PURE__ */ le({
|
|
349
349
|
fieldKey: {},
|
|
@@ -375,15 +375,15 @@ const ge = (t, n) => {
|
|
|
375
375
|
const r = { props: e, emits: o, model: l, validate: s, inputHandler: c, changeHandler: i };
|
|
376
376
|
return Object.defineProperty(r, "__isScriptSetup", { enumerable: !1, value: !0 }), r;
|
|
377
377
|
}
|
|
378
|
-
}),
|
|
378
|
+
}), q = (t, n) => {
|
|
379
379
|
const a = t.__vccOpts || t;
|
|
380
380
|
for (const [e, o] of n)
|
|
381
381
|
a[e] = o;
|
|
382
382
|
return a;
|
|
383
383
|
};
|
|
384
384
|
function en(t, n, a, e, o, l) {
|
|
385
|
-
const s =
|
|
386
|
-
return d(),
|
|
385
|
+
const s = C("AInput");
|
|
386
|
+
return d(), F(s, {
|
|
387
387
|
modelValue: e.model,
|
|
388
388
|
"onUpdate:modelValue": n[0] || (n[0] = (c) => e.model = c),
|
|
389
389
|
"allow-clear": "",
|
|
@@ -392,7 +392,7 @@ function en(t, n, a, e, o, l) {
|
|
|
392
392
|
onChange: e.changeHandler
|
|
393
393
|
}, null, 8, ["modelValue", "disabled"]);
|
|
394
394
|
}
|
|
395
|
-
const We = /* @__PURE__ */
|
|
395
|
+
const We = /* @__PURE__ */ q(Zt, [["render", en], ["__file", "InputText.vue"]]), tn = /* @__PURE__ */ E({
|
|
396
396
|
__name: "InputNumber",
|
|
397
397
|
props: /* @__PURE__ */ le({
|
|
398
398
|
fieldKey: {},
|
|
@@ -416,9 +416,9 @@ const We = /* @__PURE__ */ J(Zt, [["render", en], ["__file", "InputText.vue"]]),
|
|
|
416
416
|
const i = (_) => ge(e.validations, _), r = (_) => {
|
|
417
417
|
o("input", _);
|
|
418
418
|
}, u = (_) => {
|
|
419
|
-
const
|
|
420
|
-
o("error",
|
|
421
|
-
|
|
419
|
+
const S = i(_);
|
|
420
|
+
o("error", S.res ? "" : S.errorMessages), e.triggers && e.triggers.length > 0 && e.triggers.forEach((f) => {
|
|
421
|
+
f.event === "change" && o(f.event, f.handlerName, _);
|
|
422
422
|
});
|
|
423
423
|
};
|
|
424
424
|
n({
|
|
@@ -432,8 +432,8 @@ const We = /* @__PURE__ */ J(Zt, [["render", en], ["__file", "InputText.vue"]]),
|
|
|
432
432
|
}
|
|
433
433
|
});
|
|
434
434
|
function nn(t, n, a, e, o, l) {
|
|
435
|
-
const s =
|
|
436
|
-
return d(),
|
|
435
|
+
const s = C("AInputNumber");
|
|
436
|
+
return d(), F(s, {
|
|
437
437
|
modelValue: e.model,
|
|
438
438
|
"onUpdate:modelValue": n[0] || (n[0] = (c) => e.model = c),
|
|
439
439
|
clearable: "",
|
|
@@ -443,7 +443,7 @@ function nn(t, n, a, e, o, l) {
|
|
|
443
443
|
onChange: e.changeHandler
|
|
444
444
|
}, null, 8, ["modelValue", "disabled", "min"]);
|
|
445
445
|
}
|
|
446
|
-
const on = /* @__PURE__ */
|
|
446
|
+
const on = /* @__PURE__ */ q(tn, [["render", nn], ["__file", "InputNumber.vue"]]), an = /* @__PURE__ */ E({
|
|
447
447
|
__name: "SelectList",
|
|
448
448
|
props: /* @__PURE__ */ le({
|
|
449
449
|
fieldKey: {},
|
|
@@ -458,30 +458,30 @@ const on = /* @__PURE__ */ J(tn, [["render", nn], ["__file", "InputNumber.vue"]]
|
|
|
458
458
|
}),
|
|
459
459
|
emits: /* @__PURE__ */ le(["update:modelValue", "change"], ["update:modelValue"]),
|
|
460
460
|
setup(t, { expose: n, emit: a }) {
|
|
461
|
-
const e = t, o = a, l = m(!1), s = m(e.config.options ?? []), c = we(t, "modelValue"), i = (
|
|
462
|
-
const
|
|
463
|
-
return e.triggers && e.triggers.length > 0 && e.triggers.forEach((
|
|
464
|
-
|
|
465
|
-
o(
|
|
466
|
-
const
|
|
467
|
-
o("error",
|
|
461
|
+
const e = t, o = a, l = m(!1), s = m(e.config.options ?? []), c = we(t, "modelValue"), i = (S) => ge(e.validations, S), r = G(() => {
|
|
462
|
+
const S = {};
|
|
463
|
+
return e.triggers && e.triggers.length > 0 && e.triggers.forEach((f) => {
|
|
464
|
+
S[f.event] = (p) => {
|
|
465
|
+
o(f.event, f.handlerName, p);
|
|
466
|
+
const T = i(p);
|
|
467
|
+
o("error", T.res ? "" : T.errorMessages);
|
|
468
468
|
};
|
|
469
|
-
}),
|
|
469
|
+
}), S;
|
|
470
470
|
}), u = async () => {
|
|
471
|
-
e.config.dataSourceProvider && (s.value = await
|
|
471
|
+
e.config.dataSourceProvider && (s.value = await $t(e.config.dataSourceProvider));
|
|
472
472
|
};
|
|
473
473
|
ue(u);
|
|
474
|
-
const g = (
|
|
475
|
-
o("update:modelValue",
|
|
476
|
-
const
|
|
477
|
-
o("error",
|
|
478
|
-
|
|
474
|
+
const g = (S) => {
|
|
475
|
+
o("update:modelValue", S);
|
|
476
|
+
const f = i(S);
|
|
477
|
+
o("error", f.res ? "" : f.errorMessages), e.triggers && e.triggers.length > 0 && e.triggers.forEach((p) => {
|
|
478
|
+
p.event === "change" && o(p.event, p.handlerName, S);
|
|
479
479
|
});
|
|
480
480
|
};
|
|
481
481
|
n({
|
|
482
482
|
validate() {
|
|
483
|
-
const
|
|
484
|
-
return o("error",
|
|
483
|
+
const S = i(e.modelValue);
|
|
484
|
+
return o("error", S.res ? "" : S.errorMessages), S.res;
|
|
485
485
|
}
|
|
486
486
|
});
|
|
487
487
|
const _ = { props: e, emits: o, loading: l, _options: s, model: c, validate: i, eventHandlers: r, loadOptions: u, changeHandler: g };
|
|
@@ -489,8 +489,8 @@ const on = /* @__PURE__ */ J(tn, [["render", nn], ["__file", "InputNumber.vue"]]
|
|
|
489
489
|
}
|
|
490
490
|
});
|
|
491
491
|
function rn(t, n, a, e, o, l) {
|
|
492
|
-
const s =
|
|
493
|
-
return d(),
|
|
492
|
+
const s = C("AOption"), c = C("ASelect");
|
|
493
|
+
return d(), F(c, {
|
|
494
494
|
"allow-clear": "",
|
|
495
495
|
modelValue: e.model,
|
|
496
496
|
"onUpdate:modelValue": n[0] || (n[0] = (i) => e.model = i),
|
|
@@ -500,8 +500,8 @@ function rn(t, n, a, e, o, l) {
|
|
|
500
500
|
disabled: e.props.config.readonly,
|
|
501
501
|
onChange: e.changeHandler
|
|
502
502
|
}, {
|
|
503
|
-
default:
|
|
504
|
-
(d(!0), h(
|
|
503
|
+
default: k(() => [
|
|
504
|
+
(d(!0), h(O, null, M(e._options, (i) => (d(), F(s, {
|
|
505
505
|
key: i.value,
|
|
506
506
|
value: i.value,
|
|
507
507
|
label: i.label
|
|
@@ -510,7 +510,7 @@ function rn(t, n, a, e, o, l) {
|
|
|
510
510
|
_: 1
|
|
511
511
|
}, 8, ["modelValue", "loading", "disabled"]);
|
|
512
512
|
}
|
|
513
|
-
const Ge = /* @__PURE__ */
|
|
513
|
+
const Ge = /* @__PURE__ */ q(an, [["render", rn], ["__file", "SelectList.vue"]]), sn = /* @__PURE__ */ E({
|
|
514
514
|
__name: "Cascader",
|
|
515
515
|
props: {
|
|
516
516
|
modelValue: {},
|
|
@@ -525,7 +525,7 @@ const Ge = /* @__PURE__ */ J(an, [["render", rn], ["__file", "SelectList.vue"]])
|
|
|
525
525
|
if (e.config) {
|
|
526
526
|
const r = e.config.dataSourceProvider;
|
|
527
527
|
if (r) {
|
|
528
|
-
const g = await (await
|
|
528
|
+
const g = await (await K()).get(r);
|
|
529
529
|
l.value = g.data;
|
|
530
530
|
}
|
|
531
531
|
}
|
|
@@ -541,13 +541,13 @@ const Ge = /* @__PURE__ */ J(an, [["render", rn], ["__file", "SelectList.vue"]])
|
|
|
541
541
|
}
|
|
542
542
|
});
|
|
543
543
|
function ln(t, n, a, e, o, l) {
|
|
544
|
-
const s =
|
|
545
|
-
return d(),
|
|
544
|
+
const s = C("ACascader"), c = C("ASpace");
|
|
545
|
+
return d(), F(c, {
|
|
546
546
|
direction: "vertical",
|
|
547
547
|
size: "large"
|
|
548
548
|
}, {
|
|
549
|
-
default:
|
|
550
|
-
|
|
549
|
+
default: k(() => [
|
|
550
|
+
N(s, {
|
|
551
551
|
"field-names": e.fieldNames,
|
|
552
552
|
"model-value": a.modelValue,
|
|
553
553
|
options: e._options,
|
|
@@ -559,7 +559,7 @@ function ln(t, n, a, e, o, l) {
|
|
|
559
559
|
_: 1
|
|
560
560
|
});
|
|
561
561
|
}
|
|
562
|
-
const cn = /* @__PURE__ */
|
|
562
|
+
const cn = /* @__PURE__ */ q(sn, [["render", ln], ["__file", "Cascader.vue"]]), dn = /* @__PURE__ */ E({
|
|
563
563
|
__name: "FileUpload",
|
|
564
564
|
props: {
|
|
565
565
|
className: {},
|
|
@@ -574,66 +574,66 @@ const cn = /* @__PURE__ */ J(sn, [["render", ln], ["__file", "Cascader.vue"]]),
|
|
|
574
574
|
setup(t, { expose: n, emit: a }) {
|
|
575
575
|
const e = t, o = a, l = m({});
|
|
576
576
|
ue(async () => {
|
|
577
|
-
const
|
|
577
|
+
const x = await Ze();
|
|
578
578
|
l.value = {
|
|
579
|
-
Authorization: `Bearer ${
|
|
579
|
+
Authorization: `Bearer ${x}`
|
|
580
580
|
};
|
|
581
581
|
});
|
|
582
|
-
const s = (
|
|
583
|
-
function g(
|
|
584
|
-
return
|
|
582
|
+
const s = (x) => ge(e.validations, x), c = Re(), i = c.apiBase, r = m(null), u = m("");
|
|
583
|
+
function g(x, y, w) {
|
|
584
|
+
return x.replace(/{WorkflowId}/g, y).replace(/{ClassName}/g, w);
|
|
585
585
|
}
|
|
586
|
-
const _ =
|
|
586
|
+
const _ = G(() => {
|
|
587
587
|
if (e.config.uploadURL) {
|
|
588
|
-
const
|
|
589
|
-
return g(
|
|
588
|
+
const x = i + e.config.uploadURL;
|
|
589
|
+
return g(x, u.value, e.className);
|
|
590
590
|
}
|
|
591
591
|
return "";
|
|
592
|
-
}),
|
|
593
|
-
|
|
592
|
+
}), S = (x) => {
|
|
593
|
+
x.stopPropagation(), r.value.submit();
|
|
594
594
|
};
|
|
595
|
-
function
|
|
596
|
-
const { file:
|
|
597
|
-
return new Promise((
|
|
595
|
+
function f(x) {
|
|
596
|
+
const { file: y, name: w } = x, V = w ?? y.name;
|
|
597
|
+
return new Promise((A, D) => {
|
|
598
598
|
gt.confirm({
|
|
599
599
|
title: "Confirm Delete",
|
|
600
|
-
content: `Are you sure you want to delete ${
|
|
600
|
+
content: `Are you sure you want to delete ${V}?`,
|
|
601
601
|
async onOk() {
|
|
602
|
-
if (
|
|
603
|
-
return await e.config.removeFile(
|
|
604
|
-
|
|
602
|
+
if (x.status !== "init" && e.config.removeFile)
|
|
603
|
+
return await e.config.removeFile(x.uid), A(!0);
|
|
604
|
+
A(!0);
|
|
605
605
|
},
|
|
606
|
-
onCancel: () =>
|
|
606
|
+
onCancel: () => D("cancel")
|
|
607
607
|
});
|
|
608
608
|
});
|
|
609
609
|
}
|
|
610
|
-
const
|
|
611
|
-
|
|
612
|
-
}, ee = (
|
|
613
|
-
|
|
614
|
-
},
|
|
615
|
-
|
|
610
|
+
const p = m(null), T = m(null), X = (x) => {
|
|
611
|
+
p.value && (p.value(x), p.value = null, T.value = null);
|
|
612
|
+
}, ee = (x) => {
|
|
613
|
+
T.value && (T.value(x), p.value = null, T.value = null);
|
|
614
|
+
}, j = m([]), Z = (x) => {
|
|
615
|
+
j.value = x.filter((y) => y.status === "init");
|
|
616
616
|
};
|
|
617
617
|
n({
|
|
618
|
-
submit(
|
|
619
|
-
return new Promise((
|
|
620
|
-
r.value ? (e.config.uploadURL && (u.value =
|
|
618
|
+
submit(x) {
|
|
619
|
+
return new Promise((y, w) => {
|
|
620
|
+
r.value ? (e.config.uploadURL && (u.value = x), p.value = y, T.value = w, j.value.length ? dt(() => {
|
|
621
621
|
r.value?.submit();
|
|
622
|
-
}) :
|
|
622
|
+
}) : y(x)) : y(x);
|
|
623
623
|
});
|
|
624
624
|
},
|
|
625
625
|
validate() {
|
|
626
|
-
const
|
|
627
|
-
return o("error",
|
|
626
|
+
const x = e.config.files ?? [], y = [...j.value, ...x].length > 0 ? "hasFile" : "", w = s(y);
|
|
627
|
+
return o("error", w.res ? "" : w.errorMessages), w.res;
|
|
628
628
|
}
|
|
629
629
|
});
|
|
630
|
-
const ae = { props: e, emits: o, headers: l, validate: s, config: c, ApiBase: i, uploadRef: r, id: u, replaceIdAndClassName: g, action: _, submit:
|
|
630
|
+
const ae = { props: e, emits: o, headers: l, validate: s, config: c, ApiBase: i, uploadRef: r, id: u, replaceIdAndClassName: g, action: _, submit: S, onBeforeRemove: f, uploadPromiseResolve: p, uploadPromiseReject: T, handleUploadSuccess: X, handleUploadError: ee, readyFiles: j, onChange: Z };
|
|
631
631
|
return Object.defineProperty(ae, "__isScriptSetup", { enumerable: !1, value: !0 }), ae;
|
|
632
632
|
}
|
|
633
633
|
});
|
|
634
634
|
function un(t, n, a, e, o, l) {
|
|
635
|
-
const s =
|
|
636
|
-
return d(),
|
|
635
|
+
const s = C("a-button"), c = C("a-upload");
|
|
636
|
+
return d(), F(c, {
|
|
637
637
|
ref: "uploadRef",
|
|
638
638
|
"default-file-list": e.props.config.files,
|
|
639
639
|
action: e.action,
|
|
@@ -646,11 +646,11 @@ function un(t, n, a, e, o, l) {
|
|
|
646
646
|
onSuccess: e.handleUploadSuccess,
|
|
647
647
|
onError: e.handleUploadError
|
|
648
648
|
}, {
|
|
649
|
-
"start-icon":
|
|
650
|
-
"upload-button":
|
|
651
|
-
|
|
652
|
-
default:
|
|
653
|
-
|
|
649
|
+
"start-icon": k(() => n[0] || (n[0] = [])),
|
|
650
|
+
"upload-button": k(() => [
|
|
651
|
+
N(s, { type: "primary" }, {
|
|
652
|
+
default: k(() => n[1] || (n[1] = [
|
|
653
|
+
ne("Select File", -1)
|
|
654
654
|
])),
|
|
655
655
|
_: 1,
|
|
656
656
|
__: [1]
|
|
@@ -659,7 +659,7 @@ function un(t, n, a, e, o, l) {
|
|
|
659
659
|
_: 1
|
|
660
660
|
}, 8, ["default-file-list", "action", "limit", "headers"]);
|
|
661
661
|
}
|
|
662
|
-
const fn = /* @__PURE__ */
|
|
662
|
+
const fn = /* @__PURE__ */ q(dn, [["render", un], ["__file", "FileUpload.vue"]]), pn = /* @__PURE__ */ E({
|
|
663
663
|
__name: "TextArea",
|
|
664
664
|
props: {
|
|
665
665
|
fieldKey: {},
|
|
@@ -691,8 +691,8 @@ const fn = /* @__PURE__ */ J(dn, [["render", un], ["__file", "FileUpload.vue"]])
|
|
|
691
691
|
}
|
|
692
692
|
});
|
|
693
693
|
function mn(t, n, a, e, o, l) {
|
|
694
|
-
const s =
|
|
695
|
-
return d(),
|
|
694
|
+
const s = C("ATextarea");
|
|
695
|
+
return d(), F(s, {
|
|
696
696
|
"model-value": e.props.modelValue,
|
|
697
697
|
placeholder: "Please enter something",
|
|
698
698
|
"allow-clear": "",
|
|
@@ -701,7 +701,7 @@ function mn(t, n, a, e, o, l) {
|
|
|
701
701
|
onChange: e.changeHandler
|
|
702
702
|
}, null, 8, ["model-value", "disabled"]);
|
|
703
703
|
}
|
|
704
|
-
const gn = /* @__PURE__ */
|
|
704
|
+
const gn = /* @__PURE__ */ q(pn, [["render", mn], ["__file", "TextArea.vue"]]), _n = /* @__PURE__ */ E({
|
|
705
705
|
__name: "CheckBox",
|
|
706
706
|
props: /* @__PURE__ */ le({
|
|
707
707
|
fieldKey: {},
|
|
@@ -733,22 +733,22 @@ const gn = /* @__PURE__ */ J(pn, [["render", mn], ["__file", "TextArea.vue"]]),
|
|
|
733
733
|
}
|
|
734
734
|
});
|
|
735
735
|
function vn(t, n, a, e, o, l) {
|
|
736
|
-
const s =
|
|
737
|
-
return d(),
|
|
736
|
+
const s = C("ACheckbox");
|
|
737
|
+
return d(), F(s, {
|
|
738
738
|
modelValue: e.model,
|
|
739
739
|
"onUpdate:modelValue": n[0] || (n[0] = (c) => e.model = c),
|
|
740
740
|
clearable: "",
|
|
741
741
|
disabled: e.props.readonly || e.props.config.Readonly,
|
|
742
742
|
onChange: e.changeHandler
|
|
743
743
|
}, {
|
|
744
|
-
default:
|
|
745
|
-
|
|
744
|
+
default: k(() => n[1] || (n[1] = [
|
|
745
|
+
ne("Yes", -1)
|
|
746
746
|
])),
|
|
747
747
|
_: 1,
|
|
748
748
|
__: [1]
|
|
749
749
|
}, 8, ["modelValue", "disabled"]);
|
|
750
750
|
}
|
|
751
|
-
const bn = /* @__PURE__ */
|
|
751
|
+
const bn = /* @__PURE__ */ q(_n, [["render", vn], ["__file", "CheckBox.vue"]]), hn = Symbol("ArcoConfigProvider"), yn = "arco", wn = "$arco", tt = (t) => {
|
|
752
752
|
var n, a, e;
|
|
753
753
|
const o = pe(), l = me(hn, void 0);
|
|
754
754
|
return `${(e = (a = l?.prefixCls) != null ? a : (n = o?.appContext.config.globalProperties[wn]) == null ? void 0 : n.classPrefix) != null ? e : yn}-${t}`;
|
|
@@ -761,7 +761,7 @@ var ot = (t, n) => {
|
|
|
761
761
|
t[a] = e;
|
|
762
762
|
return t;
|
|
763
763
|
};
|
|
764
|
-
const Cn =
|
|
764
|
+
const Cn = E({
|
|
765
765
|
name: "IconQuestionCircle",
|
|
766
766
|
props: {
|
|
767
767
|
size: {
|
|
@@ -788,7 +788,7 @@ const Cn = K({
|
|
|
788
788
|
click: (t) => !0
|
|
789
789
|
},
|
|
790
790
|
setup(t, { emit: n }) {
|
|
791
|
-
const a = tt("icon"), e =
|
|
791
|
+
const a = tt("icon"), e = G(() => [a, `${a}-question-circle`, { [`${a}-spin`]: t.spin }]), o = G(() => {
|
|
792
792
|
const s = {};
|
|
793
793
|
return t.size && (s.fontSize = nt(t.size) ? `${t.size}px` : t.size), t.rotate && (s.transform = `rotate(${t.rotate}deg)`), s;
|
|
794
794
|
});
|
|
@@ -807,25 +807,25 @@ function xn(t, n, a, e, o, l) {
|
|
|
807
807
|
fill: "none",
|
|
808
808
|
xmlns: "http://www.w3.org/2000/svg",
|
|
809
809
|
stroke: "currentColor",
|
|
810
|
-
class:
|
|
811
|
-
style:
|
|
810
|
+
class: Qe(t.cls),
|
|
811
|
+
style: Ye(t.innerStyle),
|
|
812
812
|
"stroke-width": t.strokeWidth,
|
|
813
813
|
"stroke-linecap": t.strokeLinecap,
|
|
814
814
|
"stroke-linejoin": t.strokeLinejoin,
|
|
815
815
|
onClick: n[0] || (n[0] = (...s) => t.onClick && t.onClick(...s))
|
|
816
816
|
}, n[1] || (n[1] = [
|
|
817
|
-
|
|
818
|
-
|
|
817
|
+
b("path", { d: "M42 24c0 9.941-8.059 18-18 18S6 33.941 6 24 14.059 6 24 6s18 8.059 18 18Z" }, null, -1),
|
|
818
|
+
b("path", { d: "M24.006 31v4.008m0-6.008L24 28c0-3 3-4 4.78-6.402C30.558 19.195 28.288 15 23.987 15c-4.014 0-5.382 2.548-5.388 4.514v.465" }, null, -1)
|
|
819
819
|
]), 14, Sn);
|
|
820
820
|
}
|
|
821
821
|
var De = /* @__PURE__ */ ot(Cn, [["render", xn]]);
|
|
822
|
-
const
|
|
822
|
+
const An = Object.assign(De, {
|
|
823
823
|
install: (t, n) => {
|
|
824
824
|
var a;
|
|
825
825
|
const e = (a = n?.iconPrefix) != null ? a : "";
|
|
826
826
|
t.component(e + De.name, De);
|
|
827
827
|
}
|
|
828
|
-
}),
|
|
828
|
+
}), Tn = E({
|
|
829
829
|
name: "IconDownload",
|
|
830
830
|
props: {
|
|
831
831
|
size: {
|
|
@@ -852,7 +852,7 @@ const at = Object.assign(De, {
|
|
|
852
852
|
click: (t) => !0
|
|
853
853
|
},
|
|
854
854
|
setup(t, { emit: n }) {
|
|
855
|
-
const a = tt("icon"), e =
|
|
855
|
+
const a = tt("icon"), e = G(() => [a, `${a}-download`, { [`${a}-spin`]: t.spin }]), o = G(() => {
|
|
856
856
|
const s = {};
|
|
857
857
|
return t.size && (s.fontSize = nt(t.size) ? `${t.size}px` : t.size), t.rotate && (s.transform = `rotate(${t.rotate}deg)`), s;
|
|
858
858
|
});
|
|
@@ -871,24 +871,70 @@ function In(t, n, a, e, o, l) {
|
|
|
871
871
|
fill: "none",
|
|
872
872
|
xmlns: "http://www.w3.org/2000/svg",
|
|
873
873
|
stroke: "currentColor",
|
|
874
|
-
class:
|
|
875
|
-
style:
|
|
874
|
+
class: Qe(t.cls),
|
|
875
|
+
style: Ye(t.innerStyle),
|
|
876
876
|
"stroke-width": t.strokeWidth,
|
|
877
877
|
"stroke-linecap": t.strokeLinecap,
|
|
878
878
|
"stroke-linejoin": t.strokeLinejoin,
|
|
879
879
|
onClick: n[0] || (n[0] = (...s) => t.onClick && t.onClick(...s))
|
|
880
880
|
}, n[1] || (n[1] = [
|
|
881
|
-
|
|
881
|
+
b("path", { d: "m33.072 22.071-9.07 9.071-9.072-9.07M24 5v26m16 4v6H8v-6" }, null, -1)
|
|
882
882
|
]), 14, Vn);
|
|
883
883
|
}
|
|
884
|
-
var
|
|
885
|
-
const
|
|
884
|
+
var Be = /* @__PURE__ */ ot(Tn, [["render", In]]);
|
|
885
|
+
const Pn = Object.assign(Be, {
|
|
886
886
|
install: (t, n) => {
|
|
887
887
|
var a;
|
|
888
888
|
const e = (a = n?.iconPrefix) != null ? a : "";
|
|
889
|
-
t.component(e +
|
|
889
|
+
t.component(e + Be.name, Be);
|
|
890
|
+
}
|
|
891
|
+
}), Nn = /* @__PURE__ */ E({
|
|
892
|
+
__name: "ToolTip",
|
|
893
|
+
props: {
|
|
894
|
+
isVisible: { type: Boolean },
|
|
895
|
+
outputText: {}
|
|
896
|
+
},
|
|
897
|
+
setup(t, { expose: n }) {
|
|
898
|
+
n();
|
|
899
|
+
const e = { props: t, get IconQuestionCircle() {
|
|
900
|
+
return An;
|
|
901
|
+
} };
|
|
902
|
+
return Object.defineProperty(e, "__isScriptSetup", { enumerable: !1, value: !0 }), e;
|
|
890
903
|
}
|
|
891
|
-
}),
|
|
904
|
+
}), Un = { class: "list-unstyled" }, Dn = { class: "list-style-square" };
|
|
905
|
+
function Bn(t, n, a, e, o, l) {
|
|
906
|
+
const s = C("a-tooltip");
|
|
907
|
+
return e.props.isVisible ? (d(), F(s, {
|
|
908
|
+
key: 0,
|
|
909
|
+
"background-color": "#7A00E6"
|
|
910
|
+
}, {
|
|
911
|
+
content: k(() => [
|
|
912
|
+
(d(!0), h(O, null, M(e.props.outputText, (c) => (d(), h("ul", {
|
|
913
|
+
key: c.title,
|
|
914
|
+
class: "list-unstyled"
|
|
915
|
+
}, [
|
|
916
|
+
b("li", null, [
|
|
917
|
+
b("b", null, Q(c.title), 1),
|
|
918
|
+
b("ul", Un, [
|
|
919
|
+
(d(!0), h(O, null, M(c.items, (i) => (d(), h("li", {
|
|
920
|
+
key: i.title
|
|
921
|
+
}, [
|
|
922
|
+
b("u", null, Q(i.title), 1),
|
|
923
|
+
b("ul", Dn, [
|
|
924
|
+
(d(!0), h(O, null, M(i.items, (r) => (d(), h("li", null, Q(r), 1))), 256))
|
|
925
|
+
])
|
|
926
|
+
]))), 128))
|
|
927
|
+
])
|
|
928
|
+
])
|
|
929
|
+
]))), 128))
|
|
930
|
+
]),
|
|
931
|
+
default: k(() => [
|
|
932
|
+
N(e.IconQuestionCircle, { class: "icon" })
|
|
933
|
+
]),
|
|
934
|
+
_: 1
|
|
935
|
+
})) : oe("", !0);
|
|
936
|
+
}
|
|
937
|
+
const at = /* @__PURE__ */ q(Nn, [["render", Bn], ["__scopeId", "data-v-24e35b0b"], ["__file", "ToolTip.vue"]]), Fn = /* @__PURE__ */ E({
|
|
892
938
|
__name: "index",
|
|
893
939
|
props: /* @__PURE__ */ le({
|
|
894
940
|
config: {},
|
|
@@ -904,7 +950,7 @@ const Tn = Object.assign(He, {
|
|
|
904
950
|
}),
|
|
905
951
|
emits: /* @__PURE__ */ le(["update:modelValue", "change", "error"], ["update:modelValue"]),
|
|
906
952
|
setup(t, { expose: n, emit: a }) {
|
|
907
|
-
const e = t, o = a, l = we(t, "modelValue"), s =
|
|
953
|
+
const e = t, o = a, l = we(t, "modelValue"), s = He("widgetRef"), c = G(() => {
|
|
908
954
|
switch (e.config?.widget?.widget) {
|
|
909
955
|
case "TextBox":
|
|
910
956
|
return We;
|
|
@@ -925,23 +971,23 @@ const Tn = Object.assign(He, {
|
|
|
925
971
|
default:
|
|
926
972
|
return We;
|
|
927
973
|
}
|
|
928
|
-
}), i = m(""), r = (
|
|
929
|
-
i.value =
|
|
930
|
-
}, u = (
|
|
931
|
-
o("change",
|
|
974
|
+
}), i = m(""), r = (f) => {
|
|
975
|
+
i.value = f;
|
|
976
|
+
}, u = (f, p) => {
|
|
977
|
+
o("change", f, p);
|
|
932
978
|
};
|
|
933
979
|
function g() {
|
|
934
980
|
return e.config?.widget?.widget === "File";
|
|
935
981
|
}
|
|
936
|
-
function _(
|
|
937
|
-
return
|
|
982
|
+
function _(f) {
|
|
983
|
+
return f === "OtherInformationText" ? "Other Information" : f === "Other Information" ? "" : f;
|
|
938
984
|
}
|
|
939
985
|
n({
|
|
940
986
|
isFileUpload() {
|
|
941
987
|
return e.config?.widget?.widget === "File";
|
|
942
988
|
},
|
|
943
|
-
submit(
|
|
944
|
-
return g() ? s.value.submit(
|
|
989
|
+
submit(f) {
|
|
990
|
+
return g() ? s.value.submit(f) : Promise.resolve(f);
|
|
945
991
|
},
|
|
946
992
|
validate() {
|
|
947
993
|
return s.value?.validate();
|
|
@@ -950,42 +996,31 @@ const Tn = Object.assign(He, {
|
|
|
950
996
|
return e?.config?.widget?.title;
|
|
951
997
|
}
|
|
952
998
|
});
|
|
953
|
-
const
|
|
954
|
-
|
|
955
|
-
} };
|
|
956
|
-
return Object.defineProperty(x, "__isScriptSetup", { enumerable: !1, value: !0 }), x;
|
|
999
|
+
const S = { props: e, emits: o, model: l, widgetRef: s, curComp: c, errMsg: i, errHandler: r, changeHandler: u, isFileUpload: g, formatTitle: _, ToolTip: at };
|
|
1000
|
+
return Object.defineProperty(S, "__isScriptSetup", { enumerable: !1, value: !0 }), S;
|
|
957
1001
|
}
|
|
958
|
-
}),
|
|
1002
|
+
}), Hn = { class: "title" }, Ln = {
|
|
959
1003
|
key: 0,
|
|
960
1004
|
class: "required"
|
|
961
|
-
},
|
|
1005
|
+
}, Rn = {
|
|
962
1006
|
key: 0,
|
|
963
1007
|
class: "err-msg"
|
|
964
1008
|
};
|
|
965
|
-
function
|
|
966
|
-
const s = k("a-tooltip");
|
|
1009
|
+
function $n(t, n, a, e, o, l) {
|
|
967
1010
|
return d(), h("div", null, [
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
e.props.config.validations.length ? (d(), h("span",
|
|
971
|
-
e.
|
|
972
|
-
|
|
973
|
-
"
|
|
974
|
-
},
|
|
975
|
-
content: y(() => [
|
|
976
|
-
(d(!0), h($, null, z(e.props.config.widget.outputText, (c) => (d(), h("div", null, X(c), 1))), 256))
|
|
977
|
-
]),
|
|
978
|
-
default: y(() => [
|
|
979
|
-
U(e.IconQuestionCircle, { class: "icon" })
|
|
980
|
-
]),
|
|
981
|
-
_: 1
|
|
982
|
-
})) : ne("", !0)
|
|
1011
|
+
b("div", Hn, [
|
|
1012
|
+
ne(Q(e.formatTitle(e.props?.config?.widget?.title)) + " ", 1),
|
|
1013
|
+
e.props.config.validations.length ? (d(), h("span", Ln, "*")) : oe("", !0),
|
|
1014
|
+
N(e.ToolTip, {
|
|
1015
|
+
"is-visible": e.props.config.widget?.isVisible ?? !1,
|
|
1016
|
+
"output-text": e.props.config.widget?.outputText ?? []
|
|
1017
|
+
}, null, 8, ["is-visible", "output-text"])
|
|
983
1018
|
]),
|
|
984
|
-
|
|
985
|
-
(d(),
|
|
1019
|
+
b("div", null, [
|
|
1020
|
+
(d(), F(Le(e.curComp), {
|
|
986
1021
|
ref: "widgetRef",
|
|
987
1022
|
modelValue: e.model,
|
|
988
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
1023
|
+
"onUpdate:modelValue": n[0] || (n[0] = (s) => e.model = s),
|
|
989
1024
|
"field-key": e.props.fieldKey,
|
|
990
1025
|
config: e.props.config.widget,
|
|
991
1026
|
validations: e.props.config.validations,
|
|
@@ -994,11 +1029,11 @@ function Hn(t, n, a, e, o, l) {
|
|
|
994
1029
|
onError: e.errHandler,
|
|
995
1030
|
onChange: e.changeHandler
|
|
996
1031
|
}, null, 40, ["modelValue", "field-key", "config", "validations", "triggers", "class-name"])),
|
|
997
|
-
e.errMsg.length > 0 ? (d(), h("div",
|
|
1032
|
+
e.errMsg.length > 0 ? (d(), h("div", Rn, Q(e.errMsg), 1)) : oe("", !0)
|
|
998
1033
|
])
|
|
999
1034
|
]);
|
|
1000
1035
|
}
|
|
1001
|
-
const Oe = /* @__PURE__ */
|
|
1036
|
+
const Oe = /* @__PURE__ */ q(Fn, [["render", $n], ["__scopeId", "data-v-30216d05"], ["__file", "index.vue"]]), On = /* @__PURE__ */ E({
|
|
1002
1037
|
__name: "SubmitButton",
|
|
1003
1038
|
props: {
|
|
1004
1039
|
url: {},
|
|
@@ -1016,20 +1051,20 @@ const Oe = /* @__PURE__ */ J(Pn, [["render", Hn], ["__scopeId", "data-v-9e5e8c37
|
|
|
1016
1051
|
return Object.defineProperty(s, "__isScriptSetup", { enumerable: !1, value: !0 }), s;
|
|
1017
1052
|
}
|
|
1018
1053
|
});
|
|
1019
|
-
function
|
|
1020
|
-
const s =
|
|
1021
|
-
return d(),
|
|
1054
|
+
function jn(t, n, a, e, o, l) {
|
|
1055
|
+
const s = C("AButton");
|
|
1056
|
+
return d(), F(s, {
|
|
1022
1057
|
loading: a.loading,
|
|
1023
1058
|
type: "primary",
|
|
1024
1059
|
onClick: e.clickHandler
|
|
1025
1060
|
}, {
|
|
1026
|
-
default:
|
|
1061
|
+
default: k(() => [
|
|
1027
1062
|
de(t.$slots, "default")
|
|
1028
1063
|
]),
|
|
1029
1064
|
_: 3
|
|
1030
1065
|
}, 8, ["loading"]);
|
|
1031
1066
|
}
|
|
1032
|
-
const qe = /* @__PURE__ */
|
|
1067
|
+
const qe = /* @__PURE__ */ q(On, [["render", jn], ["__file", "SubmitButton.vue"]]), Mn = /* @__PURE__ */ E({
|
|
1033
1068
|
__name: "DetailLink",
|
|
1034
1069
|
props: {
|
|
1035
1070
|
url: {},
|
|
@@ -1047,16 +1082,16 @@ const qe = /* @__PURE__ */ J(Bn, [["render", Fn], ["__file", "SubmitButton.vue"]
|
|
|
1047
1082
|
return Object.defineProperty(s, "__isScriptSetup", { enumerable: !1, value: !0 }), s;
|
|
1048
1083
|
}
|
|
1049
1084
|
});
|
|
1050
|
-
function
|
|
1051
|
-
const s =
|
|
1052
|
-
return d(),
|
|
1053
|
-
default:
|
|
1085
|
+
function En(t, n, a, e, o, l) {
|
|
1086
|
+
const s = C("ALink");
|
|
1087
|
+
return d(), F(s, { onClick: e.clickHandler }, {
|
|
1088
|
+
default: k(() => [
|
|
1054
1089
|
de(t.$slots, "default")
|
|
1055
1090
|
]),
|
|
1056
1091
|
_: 3
|
|
1057
1092
|
});
|
|
1058
1093
|
}
|
|
1059
|
-
const
|
|
1094
|
+
const zn = /* @__PURE__ */ q(Mn, [["render", En], ["__file", "DetailLink.vue"]]), Kn = /* @__PURE__ */ E({
|
|
1060
1095
|
__name: "index",
|
|
1061
1096
|
props: {
|
|
1062
1097
|
config: {},
|
|
@@ -1069,50 +1104,50 @@ const jn = /* @__PURE__ */ J(Ln, [["render", Rn], ["__file", "DetailLink.vue"]])
|
|
|
1069
1104
|
function l(u, g) {
|
|
1070
1105
|
o("click", e.config.widget, u, g, e.config.title);
|
|
1071
1106
|
}
|
|
1072
|
-
const s =
|
|
1107
|
+
const s = G(() => {
|
|
1073
1108
|
switch (e.config.location) {
|
|
1074
1109
|
case "InOperation":
|
|
1075
1110
|
return qe;
|
|
1076
1111
|
case "InTable":
|
|
1077
|
-
return
|
|
1112
|
+
return zn;
|
|
1078
1113
|
default:
|
|
1079
1114
|
return qe;
|
|
1080
1115
|
}
|
|
1081
|
-
}), c =
|
|
1116
|
+
}), c = G(() => e.config.widget === J.Submit ? e.config.requestUrl ?? "" : e.config.widget === J.Link ? e.config.redirectUrl ?? "" : ""), i = G(() => e.config.redirectType ?? "Details"), r = { props: e, emits: o, clickHandler: l, curComp: s, curUrl: c, redirectType: i };
|
|
1082
1117
|
return Object.defineProperty(r, "__isScriptSetup", { enumerable: !1, value: !0 }), r;
|
|
1083
1118
|
}
|
|
1084
1119
|
});
|
|
1085
|
-
function
|
|
1086
|
-
return d(),
|
|
1120
|
+
function Wn(t, n, a, e, o, l) {
|
|
1121
|
+
return d(), F(Le(e.curComp), {
|
|
1087
1122
|
url: e.curUrl,
|
|
1088
1123
|
"redirect-type": e.redirectType,
|
|
1089
1124
|
loading: a.loading,
|
|
1090
1125
|
onClick: e.clickHandler
|
|
1091
1126
|
}, {
|
|
1092
|
-
default:
|
|
1093
|
-
|
|
1127
|
+
default: k(() => [
|
|
1128
|
+
ne(Q(e.props.config.title), 1)
|
|
1094
1129
|
]),
|
|
1095
1130
|
_: 1
|
|
1096
1131
|
}, 8, ["url", "redirect-type", "loading"]);
|
|
1097
1132
|
}
|
|
1098
|
-
const xe = /* @__PURE__ */
|
|
1133
|
+
const xe = /* @__PURE__ */ q(Kn, [["render", Wn], ["__file", "index.vue"]]), rt = Symbol("library-router");
|
|
1099
1134
|
function Ae() {
|
|
1100
1135
|
const t = me(rt, null);
|
|
1101
1136
|
return t || _t();
|
|
1102
1137
|
}
|
|
1103
1138
|
const st = Symbol("library-triggers");
|
|
1104
|
-
function
|
|
1139
|
+
function je() {
|
|
1105
1140
|
const t = me(st, null);
|
|
1106
1141
|
return t || {};
|
|
1107
1142
|
}
|
|
1108
|
-
const
|
|
1109
|
-
function
|
|
1143
|
+
const Gn = Symbol("library-pinia"), it = Symbol("library-bpmStore"), lt = Symbol("library-svrStore");
|
|
1144
|
+
function Te() {
|
|
1110
1145
|
return me(it, null);
|
|
1111
1146
|
}
|
|
1112
|
-
function
|
|
1147
|
+
function Ve() {
|
|
1113
1148
|
return me(lt, null);
|
|
1114
1149
|
}
|
|
1115
|
-
const
|
|
1150
|
+
const qn = /* @__PURE__ */ E({
|
|
1116
1151
|
__name: "TopBar",
|
|
1117
1152
|
props: {
|
|
1118
1153
|
title: {},
|
|
@@ -1124,27 +1159,27 @@ const En = /* @__PURE__ */ K({
|
|
|
1124
1159
|
const a = {};
|
|
1125
1160
|
return Object.defineProperty(a, "__isScriptSetup", { enumerable: !1, value: !0 }), a;
|
|
1126
1161
|
}
|
|
1127
|
-
}),
|
|
1128
|
-
function
|
|
1129
|
-
const s =
|
|
1130
|
-
return d(), h("div",
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1162
|
+
}), Yn = { class: "top-bar" }, Qn = { class: "banner-info" }, Jn = { class: "page-title" }, Xn = { class: "page-subtitle" }, Zn = { class: "avatar-wrapper" }, eo = { class: "user-email" };
|
|
1163
|
+
function to(t, n, a, e, o, l) {
|
|
1164
|
+
const s = C("a-avatar"), c = C("a-popover");
|
|
1165
|
+
return d(), h("div", Yn, [
|
|
1166
|
+
b("div", Qn, [
|
|
1167
|
+
b("div", Jn, Q(a.title), 1),
|
|
1168
|
+
b("div", Xn, Q(a.subTitle), 1)
|
|
1134
1169
|
]),
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
content:
|
|
1138
|
-
|
|
1170
|
+
b("div", Zn, [
|
|
1171
|
+
N(c, { trigger: "click" }, {
|
|
1172
|
+
content: k(() => [
|
|
1173
|
+
b("div", eo, Q(a.email), 1)
|
|
1139
1174
|
]),
|
|
1140
|
-
default:
|
|
1141
|
-
|
|
1175
|
+
default: k(() => [
|
|
1176
|
+
N(s, {
|
|
1142
1177
|
size: 48,
|
|
1143
1178
|
autoFixFontSize: "",
|
|
1144
1179
|
style: { cursor: "pointer", background: "#165DFF", color: "#fff" }
|
|
1145
1180
|
}, {
|
|
1146
|
-
default:
|
|
1147
|
-
|
|
1181
|
+
default: k(() => [
|
|
1182
|
+
ne(Q(a.email.charAt(0).toUpperCase()), 1)
|
|
1148
1183
|
]),
|
|
1149
1184
|
_: 1
|
|
1150
1185
|
})
|
|
@@ -1154,7 +1189,7 @@ function Yn(t, n, a, e, o, l) {
|
|
|
1154
1189
|
])
|
|
1155
1190
|
]);
|
|
1156
1191
|
}
|
|
1157
|
-
const
|
|
1192
|
+
const Ie = /* @__PURE__ */ q(qn, [["render", to], ["__scopeId", "data-v-c0457235"], ["__file", "TopBar.vue"]]);
|
|
1158
1193
|
function Me(t) {
|
|
1159
1194
|
const n = Re(), a = [];
|
|
1160
1195
|
if (n.fieldsGroup) {
|
|
@@ -1163,7 +1198,7 @@ function Me(t) {
|
|
|
1163
1198
|
s.length && a.push({ name: l.name, fields: s });
|
|
1164
1199
|
});
|
|
1165
1200
|
const e = n.fieldsGroup.flatMap((l) => l.keys), o = t.filter((l) => !e.includes(l.fieldKey));
|
|
1166
|
-
return o.length && a.push({ name: "Grading Review History (
|
|
1201
|
+
return o.length && a.push({ name: "Grading Review History (For example: re-submit the grading request)", fields: o }), a;
|
|
1167
1202
|
}
|
|
1168
1203
|
}
|
|
1169
1204
|
class Pe {
|
|
@@ -1208,7 +1243,7 @@ class Se {
|
|
|
1208
1243
|
return this.opt ? Ke(this.pageActionType, this.className, this.store, this.opt) : Ke(this.pageActionType, this.className, this.store);
|
|
1209
1244
|
}
|
|
1210
1245
|
getBtnList() {
|
|
1211
|
-
return
|
|
1246
|
+
return It(this.pageActionType, this.className, { workflowId: this.getWorkflowId(), email: this.getApproverEmail() });
|
|
1212
1247
|
}
|
|
1213
1248
|
getFiles() {
|
|
1214
1249
|
return this.getWorkflowId() ? Mt(this.className, this.getWorkflowId()) : Promise.resolve({});
|
|
@@ -1235,10 +1270,10 @@ class Se {
|
|
|
1235
1270
|
return Wt(this.getWorkflowId(), this.getApproverEmail(), n);
|
|
1236
1271
|
}
|
|
1237
1272
|
deleteAssociator(n) {
|
|
1238
|
-
return
|
|
1273
|
+
return Yt(n);
|
|
1239
1274
|
}
|
|
1240
1275
|
}
|
|
1241
|
-
const
|
|
1276
|
+
const no = /* @__PURE__ */ E({
|
|
1242
1277
|
__name: "CreateView",
|
|
1243
1278
|
props: {
|
|
1244
1279
|
className: {},
|
|
@@ -1246,7 +1281,7 @@ const Jn = /* @__PURE__ */ K({
|
|
|
1246
1281
|
},
|
|
1247
1282
|
setup(t, { expose: n }) {
|
|
1248
1283
|
n();
|
|
1249
|
-
const a =
|
|
1284
|
+
const a = Te(), e = Ve(), o = Ae(), l = je(), s = He("dataWidgets"), c = pe(), i = t, r = m({
|
|
1250
1285
|
pageType: "",
|
|
1251
1286
|
fields: {},
|
|
1252
1287
|
globalValidations: [],
|
|
@@ -1255,103 +1290,103 @@ const Jn = /* @__PURE__ */ K({
|
|
|
1255
1290
|
subTitle: ""
|
|
1256
1291
|
}
|
|
1257
1292
|
}), u = m([]), g = m({});
|
|
1258
|
-
function _(
|
|
1259
|
-
return
|
|
1260
|
-
fieldKey:
|
|
1261
|
-
...
|
|
1262
|
-
})).filter((
|
|
1293
|
+
function _(w) {
|
|
1294
|
+
return w ? Object.entries(w).map(([A, D]) => ({
|
|
1295
|
+
fieldKey: A,
|
|
1296
|
+
...D
|
|
1297
|
+
})).filter((A) => A.widget && A.widget.widget !== "Hidden").filter((A) => !Z.value.includes(A.fieldKey)) : [];
|
|
1263
1298
|
}
|
|
1264
|
-
function
|
|
1265
|
-
return
|
|
1299
|
+
function S(w) {
|
|
1300
|
+
return w ? Object.entries(w).filter(([A, D]) => D.dependent).reduce((A, [D, $]) => (A[D] = $.dependent, A), {}) : [];
|
|
1266
1301
|
}
|
|
1267
|
-
const
|
|
1302
|
+
const f = G(() => r.value?.actions ? [...r.value.actions].reverse() : []), p = m({}), T = m(!1);
|
|
1268
1303
|
ue(async () => {
|
|
1269
|
-
|
|
1270
|
-
const
|
|
1271
|
-
r.value = await
|
|
1272
|
-
for (const
|
|
1273
|
-
if (r.value.fields[
|
|
1274
|
-
const
|
|
1275
|
-
|
|
1304
|
+
T.value = !0;
|
|
1305
|
+
const w = new Pe().setWorkflowId(i.workflowId).setClassName(i.className).setStore({ svrStore: e, bpmStore: a }).build();
|
|
1306
|
+
r.value = await w.getPageData(), u.value = _(r.value.fields), g.value = S(r.value.fields);
|
|
1307
|
+
for (const V in r.value.fields) {
|
|
1308
|
+
if (r.value.fields[V].widget?.widget === "File") {
|
|
1309
|
+
const A = u.value.find((D) => D.fieldKey === V);
|
|
1310
|
+
A && A.widget && (A.widget.files = []);
|
|
1276
1311
|
}
|
|
1277
|
-
|
|
1312
|
+
p.value[V] = r.value.fields[V].modelValue;
|
|
1278
1313
|
}
|
|
1279
|
-
|
|
1314
|
+
T.value = !1;
|
|
1280
1315
|
});
|
|
1281
|
-
function
|
|
1316
|
+
function X() {
|
|
1282
1317
|
return e()?.userInfo?.email_address ?? "";
|
|
1283
1318
|
}
|
|
1284
|
-
async function ee(
|
|
1285
|
-
switch (
|
|
1286
|
-
case
|
|
1319
|
+
async function ee(w, V, A, D, $) {
|
|
1320
|
+
switch (V) {
|
|
1321
|
+
case J.Submit:
|
|
1287
1322
|
let L = !0;
|
|
1288
|
-
if (s.value?.forEach((
|
|
1289
|
-
|
|
1323
|
+
if (s.value?.forEach((Y) => {
|
|
1324
|
+
Y?.validate && (Y.validate() || (L = !1));
|
|
1290
1325
|
}), !L) {
|
|
1291
1326
|
c?.appContext.config.globalProperties.$message.error("form validation failed, please check the input fields");
|
|
1292
1327
|
return;
|
|
1293
1328
|
}
|
|
1294
|
-
|
|
1329
|
+
T.value = !0;
|
|
1295
1330
|
try {
|
|
1296
|
-
const
|
|
1297
|
-
await Promise.all(se),
|
|
1331
|
+
const Y = await Nt(i.className, { ...p.value, ...g.value }, A), se = s.value?.map((ie) => ie?.submit ? ie.submit(Y.toString()) : Promise.resolve()) || [];
|
|
1332
|
+
await Promise.all(se), T.value = !1, c?.appContext.config.globalProperties.$notification.success(`Your grading request has been submitted, ID is ${Y.toString()}.`), o.push({ name: "Details", params: { workflowId: Y.toString() } });
|
|
1298
1333
|
} catch {
|
|
1299
|
-
c?.appContext.config.globalProperties.$notification.error("Failed to submit your grading request"),
|
|
1334
|
+
c?.appContext.config.globalProperties.$notification.error("Failed to submit your grading request"), T.value = !1;
|
|
1300
1335
|
}
|
|
1301
1336
|
break;
|
|
1302
|
-
case
|
|
1337
|
+
case J.Link:
|
|
1303
1338
|
try {
|
|
1304
|
-
await l[
|
|
1305
|
-
} catch (
|
|
1306
|
-
console.error("Error in link action trigger:",
|
|
1339
|
+
await l[w.eventName || ""]?.(p.value, Z), o.push({ name: D, params: { className: i.className } });
|
|
1340
|
+
} catch (Y) {
|
|
1341
|
+
console.error("Error in link action trigger:", Y);
|
|
1307
1342
|
}
|
|
1308
1343
|
break;
|
|
1309
1344
|
default:
|
|
1310
|
-
console.warn("Unknown action type:",
|
|
1345
|
+
console.warn("Unknown action type:", V);
|
|
1311
1346
|
}
|
|
1312
1347
|
}
|
|
1313
|
-
const
|
|
1348
|
+
const j = [
|
|
1314
1349
|
"jobScpope",
|
|
1315
1350
|
"currentWorkdayId",
|
|
1316
1351
|
"originalGrade",
|
|
1317
1352
|
"jobTitlePrevious",
|
|
1318
1353
|
"jobAttachmentPrevious",
|
|
1319
1354
|
"positionId"
|
|
1320
|
-
], Z = m(
|
|
1321
|
-
function ae(
|
|
1322
|
-
l[
|
|
1355
|
+
], Z = m(j);
|
|
1356
|
+
function ae(w, V) {
|
|
1357
|
+
l[w]?.({ fieldValue: V, hiddenFields: Z, formData: p }), r.value && (u.value = _(r.value.fields));
|
|
1323
1358
|
}
|
|
1324
|
-
const
|
|
1325
|
-
return Object.defineProperty(
|
|
1359
|
+
const x = G(() => Me(u.value)), y = { bpmStore: a, svrStore: e, router: o, triggers: l, dataWidgetsRefs: s, instance: c, props: i, pageData: r, _fields: u, _dependent: g, genField: _, genDependentField: S, reversedActions: f, _data: p, loading: T, getApproverEmail: X, clickHandler: ee, newHiddenFields: j, hiddenFields: Z, changeHandler: ae, groupedFields: x, DataWidgets: Oe, ActionButton: xe, TopBar: Ie };
|
|
1360
|
+
return Object.defineProperty(y, "__isScriptSetup", { enumerable: !1, value: !0 }), y;
|
|
1326
1361
|
}
|
|
1327
|
-
}),
|
|
1362
|
+
}), oo = { class: "page-container" }, ao = { class: "page-body" }, ro = { class: "form-card" }, so = { class: "form-fields-vertical" }, io = { class: "form-fields" }, lo = {
|
|
1328
1363
|
key: 0,
|
|
1329
1364
|
class: "form-content"
|
|
1330
|
-
},
|
|
1331
|
-
function
|
|
1332
|
-
const s =
|
|
1333
|
-
return d(), h("div",
|
|
1334
|
-
|
|
1365
|
+
}, co = { class: "page-footer" }, uo = { class: "action-container" }, fo = { class: "action-buttons" };
|
|
1366
|
+
function po(t, n, a, e, o, l) {
|
|
1367
|
+
const s = C("a-card"), c = C("a-spin");
|
|
1368
|
+
return d(), h("div", oo, [
|
|
1369
|
+
N(e.TopBar, {
|
|
1335
1370
|
title: e.pageData.banner.title,
|
|
1336
1371
|
subTitle: e.pageData.banner.subTitle,
|
|
1337
1372
|
email: e.getApproverEmail()
|
|
1338
1373
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1339
|
-
|
|
1340
|
-
|
|
1374
|
+
b("div", ao, [
|
|
1375
|
+
N(c, {
|
|
1341
1376
|
loading: e.loading,
|
|
1342
1377
|
class: "form-container"
|
|
1343
1378
|
}, {
|
|
1344
|
-
default:
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
(d(!0), h(
|
|
1379
|
+
default: k(() => [
|
|
1380
|
+
b("div", ro, [
|
|
1381
|
+
b("div", so, [
|
|
1382
|
+
(d(!0), h(O, null, M(e.groupedFields, (i) => (d(), F(s, {
|
|
1348
1383
|
key: i.name,
|
|
1349
1384
|
title: i.name,
|
|
1350
1385
|
style: { "margin-bottom": "24px" }
|
|
1351
1386
|
}, {
|
|
1352
|
-
default:
|
|
1353
|
-
|
|
1354
|
-
(d(!0), h(
|
|
1387
|
+
default: k(() => [
|
|
1388
|
+
b("div", io, [
|
|
1389
|
+
(d(!0), h(O, null, M(i.fields, (r) => (d(), F(e.DataWidgets, {
|
|
1355
1390
|
key: r.fieldKey,
|
|
1356
1391
|
ref_for: !0,
|
|
1357
1392
|
ref: "dataWidgets",
|
|
@@ -1368,19 +1403,19 @@ function io(t, n, a, e, o, l) {
|
|
|
1368
1403
|
_: 2
|
|
1369
1404
|
}, 1032, ["title"]))), 128))
|
|
1370
1405
|
]),
|
|
1371
|
-
t.$slots.content ? (d(), h("div",
|
|
1406
|
+
t.$slots.content ? (d(), h("div", lo, [
|
|
1372
1407
|
de(t.$slots, "content", {}, void 0, !0)
|
|
1373
|
-
])) :
|
|
1408
|
+
])) : oe("", !0)
|
|
1374
1409
|
])
|
|
1375
1410
|
]),
|
|
1376
1411
|
_: 3
|
|
1377
1412
|
}, 8, ["loading"])
|
|
1378
1413
|
]),
|
|
1379
|
-
|
|
1380
|
-
|
|
1414
|
+
b("div", co, [
|
|
1415
|
+
b("div", uo, [
|
|
1381
1416
|
de(t.$slots, "action", {}, void 0, !0),
|
|
1382
|
-
|
|
1383
|
-
(d(!0), h(
|
|
1417
|
+
b("div", fo, [
|
|
1418
|
+
(d(!0), h(O, null, M(e.reversedActions, (i) => (d(), F(e.ActionButton, {
|
|
1384
1419
|
key: i.title,
|
|
1385
1420
|
loading: e.loading,
|
|
1386
1421
|
config: i,
|
|
@@ -1392,7 +1427,7 @@ function io(t, n, a, e, o, l) {
|
|
|
1392
1427
|
])
|
|
1393
1428
|
]);
|
|
1394
1429
|
}
|
|
1395
|
-
const
|
|
1430
|
+
const mo = /* @__PURE__ */ q(no, [["render", po], ["__scopeId", "data-v-2fce8732"], ["__file", "CreateView.vue"]]), go = /* @__PURE__ */ E({
|
|
1396
1431
|
__name: "UpdateView",
|
|
1397
1432
|
props: {
|
|
1398
1433
|
className: {},
|
|
@@ -1400,7 +1435,7 @@ const lo = /* @__PURE__ */ J(Jn, [["render", io], ["__scopeId", "data-v-2fce8732
|
|
|
1400
1435
|
},
|
|
1401
1436
|
setup(t, { expose: n }) {
|
|
1402
1437
|
n();
|
|
1403
|
-
const a = Ae(), e =
|
|
1438
|
+
const a = Ae(), e = je(), o = Ve(), l = Te(), s = He("dataWidgets"), c = pe(), i = t, r = m({
|
|
1404
1439
|
pageType: "",
|
|
1405
1440
|
fields: {},
|
|
1406
1441
|
globalValidations: [],
|
|
@@ -1409,102 +1444,102 @@ const lo = /* @__PURE__ */ J(Jn, [["render", io], ["__scopeId", "data-v-2fce8732
|
|
|
1409
1444
|
subTitle: ""
|
|
1410
1445
|
}
|
|
1411
1446
|
}), u = m([]), g = m({});
|
|
1412
|
-
function _(
|
|
1413
|
-
return
|
|
1414
|
-
fieldKey:
|
|
1415
|
-
...
|
|
1416
|
-
})).filter((
|
|
1447
|
+
function _(y) {
|
|
1448
|
+
return y ? Object.entries(y).map(([V, A]) => ({
|
|
1449
|
+
fieldKey: V,
|
|
1450
|
+
...A
|
|
1451
|
+
})).filter((V) => V.widget && V.widget.widget !== "Hidden").filter((V) => !j.value.includes(V.fieldKey)) : [];
|
|
1417
1452
|
}
|
|
1418
|
-
function
|
|
1419
|
-
return
|
|
1453
|
+
function S(y) {
|
|
1454
|
+
return y ? Object.entries(y).filter(([V, A]) => A.dependent).reduce((V, [A, D]) => (V[A] = D.dependent, V), {}) : [];
|
|
1420
1455
|
}
|
|
1421
|
-
const
|
|
1456
|
+
const f = G(() => r.value?.actions ? [...r.value.actions].reverse() : []), p = m({}), T = m(!1);
|
|
1422
1457
|
ue(async () => {
|
|
1423
|
-
|
|
1424
|
-
const
|
|
1425
|
-
r.value = await
|
|
1426
|
-
const
|
|
1427
|
-
r.value.actions = r.value.actions?.filter((
|
|
1428
|
-
const
|
|
1429
|
-
return
|
|
1458
|
+
T.value = !0;
|
|
1459
|
+
const y = new Pe().setPageActionType(fe.Update).setClassName(i.className).setStore({ svrStore: o, bpmStore: l }).setWorkflowId(i.workflowId).build();
|
|
1460
|
+
r.value = await y.getPageData();
|
|
1461
|
+
const w = await y.getBtnList(), V = await y.getFiles();
|
|
1462
|
+
r.value.actions = r.value.actions?.filter((D) => {
|
|
1463
|
+
const $ = w.find((L) => L.button === D.title);
|
|
1464
|
+
return $ ? $.isShow : !0;
|
|
1430
1465
|
});
|
|
1431
|
-
const
|
|
1432
|
-
e.Test?.({ fieldValue:
|
|
1433
|
-
for (const
|
|
1434
|
-
if (r.value.fields[
|
|
1435
|
-
const
|
|
1436
|
-
|
|
1466
|
+
const A = r.value.fields.requestType.modelValue;
|
|
1467
|
+
e.Test?.({ fieldValue: A, hiddenFields: j, formData: p }), u.value = _(r.value.fields), g.value = S(r.value.fields);
|
|
1468
|
+
for (const D in r.value.fields) {
|
|
1469
|
+
if (r.value.fields[D].widget?.widget === "File") {
|
|
1470
|
+
const $ = u.value.find((L) => L.fieldKey === D);
|
|
1471
|
+
$ && $.widget && ($.widget.files = V[D] ?? [], $.widget.removeFile = (L) => y.removeFile(L));
|
|
1437
1472
|
}
|
|
1438
|
-
|
|
1473
|
+
p.value[D] = r.value.fields[D].modelValue;
|
|
1439
1474
|
}
|
|
1440
|
-
|
|
1475
|
+
T.value = !1;
|
|
1441
1476
|
});
|
|
1442
|
-
function
|
|
1477
|
+
function X() {
|
|
1443
1478
|
return o()?.userInfo?.email_address ?? "";
|
|
1444
1479
|
}
|
|
1445
|
-
async function ee(
|
|
1446
|
-
switch (
|
|
1447
|
-
case
|
|
1448
|
-
let
|
|
1480
|
+
async function ee(y, w, V, A, D) {
|
|
1481
|
+
switch (w) {
|
|
1482
|
+
case J.Submit:
|
|
1483
|
+
let $ = !0;
|
|
1449
1484
|
if (s.value?.forEach((L) => {
|
|
1450
|
-
L?.validate && (L.validate() || (
|
|
1451
|
-
}),
|
|
1485
|
+
L?.validate && (L.validate() || ($ = !1));
|
|
1486
|
+
}), !$) {
|
|
1452
1487
|
c?.appContext.config.globalProperties.$message.error("form validation failed, please check the input fields");
|
|
1453
1488
|
return;
|
|
1454
1489
|
}
|
|
1455
|
-
|
|
1490
|
+
T.value = !0;
|
|
1456
1491
|
try {
|
|
1457
|
-
const L = await Ut(i.className, i.workflowId, { ...
|
|
1458
|
-
await Promise.all(
|
|
1492
|
+
const L = await Ut(i.className, i.workflowId, { ...p.value, ...g.value }, V), Y = s.value?.map((se) => se?.submit ? se.submit(L.toString()) : Promise.resolve()) || [];
|
|
1493
|
+
await Promise.all(Y), T.value = !1, c?.appContext.config.globalProperties.$notification.success(`Your grading request has been submitted, ID is ${L.toString()}.`);
|
|
1459
1494
|
} catch {
|
|
1460
|
-
c?.appContext.config.globalProperties.$notification.error("Failed to submit your grading request"),
|
|
1495
|
+
c?.appContext.config.globalProperties.$notification.error("Failed to submit your grading request"), T.value = !1;
|
|
1461
1496
|
}
|
|
1462
1497
|
break;
|
|
1463
|
-
case
|
|
1498
|
+
case J.Link:
|
|
1464
1499
|
try {
|
|
1465
|
-
await e[
|
|
1500
|
+
await e[y.eventName || ""]?.(p.value, j), a.push({ name: A, params: { className: i.className } });
|
|
1466
1501
|
} catch {
|
|
1467
1502
|
}
|
|
1468
1503
|
break;
|
|
1469
1504
|
default:
|
|
1470
|
-
console.warn("Unknown action type:",
|
|
1505
|
+
console.warn("Unknown action type:", w);
|
|
1471
1506
|
}
|
|
1472
1507
|
}
|
|
1473
|
-
const
|
|
1474
|
-
function Z(
|
|
1475
|
-
e[
|
|
1508
|
+
const j = m([]);
|
|
1509
|
+
function Z(y, w) {
|
|
1510
|
+
e[y]?.({ fieldValue: w, hiddenFields: j, formData: p }), r.value && (u.value = _(r.value.fields));
|
|
1476
1511
|
}
|
|
1477
|
-
const ae =
|
|
1478
|
-
return Object.defineProperty(
|
|
1512
|
+
const ae = G(() => Me(u.value)), x = { router: a, triggers: e, svrStore: o, bpmStore: l, dataWidgetsRefs: s, instance: c, props: i, pageData: r, _fields: u, _dependent: g, genField: _, genDependentField: S, reversedActions: f, _data: p, loading: T, getApproverEmail: X, clickHandler: ee, hiddenFields: j, changeHandler: Z, groupedFields: ae, DataWidgets: Oe, ActionButton: xe, TopBar: Ie };
|
|
1513
|
+
return Object.defineProperty(x, "__isScriptSetup", { enumerable: !1, value: !0 }), x;
|
|
1479
1514
|
}
|
|
1480
|
-
}),
|
|
1515
|
+
}), _o = { class: "page-container" }, vo = { class: "page-body" }, bo = { class: "form-card" }, ho = { class: "form-fields-vertical" }, yo = { class: "form-fields" }, wo = {
|
|
1481
1516
|
key: 0,
|
|
1482
1517
|
class: "form-content"
|
|
1483
|
-
},
|
|
1484
|
-
function
|
|
1485
|
-
const s =
|
|
1486
|
-
return d(), h("div",
|
|
1487
|
-
|
|
1518
|
+
}, ko = { class: "page-footer" }, Co = { class: "action-container" }, So = { class: "action-buttons" };
|
|
1519
|
+
function xo(t, n, a, e, o, l) {
|
|
1520
|
+
const s = C("a-card"), c = C("a-spin");
|
|
1521
|
+
return d(), h("div", _o, [
|
|
1522
|
+
N(e.TopBar, {
|
|
1488
1523
|
title: e.pageData.banner.title,
|
|
1489
1524
|
subTitle: e.pageData.banner.subTitle,
|
|
1490
1525
|
email: e.getApproverEmail()
|
|
1491
1526
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1492
|
-
|
|
1493
|
-
|
|
1527
|
+
b("div", vo, [
|
|
1528
|
+
N(c, {
|
|
1494
1529
|
loading: e.loading,
|
|
1495
1530
|
class: "form-container"
|
|
1496
1531
|
}, {
|
|
1497
|
-
default:
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
(d(!0), h(
|
|
1532
|
+
default: k(() => [
|
|
1533
|
+
b("div", bo, [
|
|
1534
|
+
b("div", ho, [
|
|
1535
|
+
(d(!0), h(O, null, M(e.groupedFields, (i) => (d(), F(s, {
|
|
1501
1536
|
key: i.name,
|
|
1502
1537
|
title: i.name,
|
|
1503
1538
|
style: { "margin-bottom": "24px" }
|
|
1504
1539
|
}, {
|
|
1505
|
-
default:
|
|
1506
|
-
|
|
1507
|
-
(d(!0), h(
|
|
1540
|
+
default: k(() => [
|
|
1541
|
+
b("div", yo, [
|
|
1542
|
+
(d(!0), h(O, null, M(i.fields, (r) => (d(), F(e.DataWidgets, {
|
|
1508
1543
|
key: r.fieldKey,
|
|
1509
1544
|
ref_for: !0,
|
|
1510
1545
|
ref: "dataWidgets",
|
|
@@ -1521,19 +1556,19 @@ function yo(t, n, a, e, o, l) {
|
|
|
1521
1556
|
_: 2
|
|
1522
1557
|
}, 1032, ["title"]))), 128))
|
|
1523
1558
|
]),
|
|
1524
|
-
t.$slots.content ? (d(), h("div",
|
|
1559
|
+
t.$slots.content ? (d(), h("div", wo, [
|
|
1525
1560
|
de(t.$slots, "content", {}, void 0, !0)
|
|
1526
|
-
])) :
|
|
1561
|
+
])) : oe("", !0)
|
|
1527
1562
|
])
|
|
1528
1563
|
]),
|
|
1529
1564
|
_: 3
|
|
1530
1565
|
}, 8, ["loading"])
|
|
1531
1566
|
]),
|
|
1532
|
-
|
|
1533
|
-
|
|
1567
|
+
b("div", ko, [
|
|
1568
|
+
b("div", Co, [
|
|
1534
1569
|
de(t.$slots, "action", {}, void 0, !0),
|
|
1535
|
-
|
|
1536
|
-
(d(!0), h(
|
|
1570
|
+
b("div", So, [
|
|
1571
|
+
(d(!0), h(O, null, M(e.reversedActions, (i) => (d(), F(e.ActionButton, {
|
|
1537
1572
|
key: i.title,
|
|
1538
1573
|
loading: e.loading,
|
|
1539
1574
|
config: i,
|
|
@@ -1545,11 +1580,11 @@ function yo(t, n, a, e, o, l) {
|
|
|
1545
1580
|
])
|
|
1546
1581
|
]);
|
|
1547
1582
|
}
|
|
1548
|
-
const
|
|
1549
|
-
function
|
|
1583
|
+
const Ao = /* @__PURE__ */ q(go, [["render", xo], ["__scopeId", "data-v-a0ee3911"], ["__file", "UpdateView.vue"]]), ct = Symbol("library-custom-comp");
|
|
1584
|
+
function To() {
|
|
1550
1585
|
return me(ct, null);
|
|
1551
1586
|
}
|
|
1552
|
-
const
|
|
1587
|
+
const Vo = /* @__PURE__ */ E({
|
|
1553
1588
|
__name: "DetailView",
|
|
1554
1589
|
props: {
|
|
1555
1590
|
className: {},
|
|
@@ -1557,7 +1592,7 @@ const Co = /* @__PURE__ */ K({
|
|
|
1557
1592
|
},
|
|
1558
1593
|
setup(t, { expose: n }) {
|
|
1559
1594
|
n();
|
|
1560
|
-
const a =
|
|
1595
|
+
const a = Ve(), e = Te(), o = je(), l = Ae(), s = To(), c = pe(), i = t;
|
|
1561
1596
|
let r;
|
|
1562
1597
|
const u = m({
|
|
1563
1598
|
pageType: "",
|
|
@@ -1568,15 +1603,15 @@ const Co = /* @__PURE__ */ K({
|
|
|
1568
1603
|
subTitle: ""
|
|
1569
1604
|
}
|
|
1570
1605
|
}), g = m([]);
|
|
1571
|
-
function _(
|
|
1572
|
-
return
|
|
1573
|
-
fieldKey:
|
|
1606
|
+
function _(I) {
|
|
1607
|
+
return I ? Object.entries(I).map(([z, P]) => (typeof P.modelValue == "boolean" ? P.fieldValue = P.modelValue ? "Yes" : "No" : P.fieldValue = P.modelValue, {
|
|
1608
|
+
fieldKey: z,
|
|
1574
1609
|
...P
|
|
1575
|
-
})).filter((
|
|
1610
|
+
})).filter((z) => z.widget && z.widget.widget !== "Hidden").filter((z) => !y.value.includes(z.fieldKey)) : [];
|
|
1576
1611
|
}
|
|
1577
|
-
const
|
|
1578
|
-
const
|
|
1579
|
-
return
|
|
1612
|
+
const S = G(() => Me(g.value)), f = G(() => u.value?.actions ? [...u.value.actions].reverse() : []), p = m(!0), T = (I, H) => {
|
|
1613
|
+
const z = I.findIndex((P) => P.isCurrent);
|
|
1614
|
+
return I.map((P, re) => {
|
|
1580
1615
|
const B = {
|
|
1581
1616
|
id: P.id,
|
|
1582
1617
|
title: "",
|
|
@@ -1588,7 +1623,7 @@ const Co = /* @__PURE__ */ K({
|
|
|
1588
1623
|
};
|
|
1589
1624
|
B.title = P.workflowProcessApprovers[0]?.name;
|
|
1590
1625
|
const be = P.workflowProcessApprovers[P.workflowProcessApprovers.length - 1], ke = P.workflowHistorys[P.workflowHistorys.length - 1], he = ke?.workflowHistoryApprovers[ke?.workflowHistoryApprovers?.length - 1];
|
|
1591
|
-
if (be && he && be?.email?.toLowerCase() !== he?.approverEmail?.toLowerCase() && (B.title = `${he.name}`, B.proxy = `Proxy: ${be.name}`), P.sort > 1 ? B.sub = "Approver Role: " + P.nodeName.replace("Submit", "").replace("Approve", "") : B.sub = "Submit Application", P.isCurrent &&
|
|
1626
|
+
if (be && he && be?.email?.toLowerCase() !== he?.approverEmail?.toLowerCase() && (B.title = `${he.name}`, B.proxy = `Proxy: ${be.name}`), P.sort > 1 ? B.sub = "Approver Role: " + P.nodeName.replace("Submit", "").replace("Approve", "") : B.sub = "Submit Application", P.isCurrent && H !== -1)
|
|
1592
1627
|
B.desc = "In Approval", B.status = 1;
|
|
1593
1628
|
else {
|
|
1594
1629
|
const te = P.workflowHistorys[P.workflowHistorys.length - 1];
|
|
@@ -1603,98 +1638,98 @@ const Co = /* @__PURE__ */ K({
|
|
|
1603
1638
|
const Ee = te.workflowHistoryApprovers[0];
|
|
1604
1639
|
B.status = 3, B.desc = Ee?.reason ? `Rejected reason: ${Ee.reason}` : "Rejected";
|
|
1605
1640
|
}
|
|
1606
|
-
else re <
|
|
1641
|
+
else re < z || z === -1 ? (B.status = 0, B.desc = "Skipped") : (B.status = 0, B.desc = "Pending Approval");
|
|
1607
1642
|
te && te.status;
|
|
1608
1643
|
}
|
|
1609
1644
|
return B;
|
|
1610
1645
|
});
|
|
1611
|
-
},
|
|
1612
|
-
async function
|
|
1613
|
-
const
|
|
1614
|
-
u.value.actions = u.value.actions?.filter((
|
|
1615
|
-
const
|
|
1616
|
-
return
|
|
1617
|
-
}), ee.value =
|
|
1646
|
+
}, X = m([]), ee = m(!1), j = m(!1), Z = m(!1), ae = m(!1);
|
|
1647
|
+
async function x() {
|
|
1648
|
+
const I = await r.getBtnList();
|
|
1649
|
+
u.value.actions = u.value.actions?.filter((H) => {
|
|
1650
|
+
const z = I.find((P) => P.button === H.title);
|
|
1651
|
+
return z ? z.isShow : !0;
|
|
1652
|
+
}), ee.value = I.find((H) => H.button === "IsGlobal")?.isShow ?? !1, j.value = I.find((H) => H.button === "AssignButton")?.isShow ?? !1, Z.value = I.find((H) => H.button === "AssignList")?.isShow ?? !1, ae.value = I.find((H) => H.button === "AddCommentsButton")?.isShow ?? !1;
|
|
1618
1653
|
}
|
|
1619
|
-
const
|
|
1620
|
-
async function
|
|
1621
|
-
|
|
1622
|
-
const
|
|
1623
|
-
se.value = await r.getApprovers(), L.value = await r.getCommentsHistory(), ie.value = await r.getAssociator(),
|
|
1624
|
-
const
|
|
1625
|
-
o.Test?.({ fieldValue:
|
|
1654
|
+
const y = m([]);
|
|
1655
|
+
async function w() {
|
|
1656
|
+
p.value = !0, r = new Pe().setPageActionType(fe.Details).setClassName(i.className).setStore({ svrStore: a, bpmStore: e }).setWorkflowId(i.workflowId).build(), u.value = await r.getPageData();
|
|
1657
|
+
const I = await r.getFiles();
|
|
1658
|
+
se.value = await r.getApprovers(), L.value = await r.getCommentsHistory(), ie.value = await r.getAssociator(), x();
|
|
1659
|
+
const H = u.value.fields.requestType.modelValue;
|
|
1660
|
+
o.Test?.({ fieldValue: H, hiddenFields: y }), g.value = _(u.value.fields);
|
|
1626
1661
|
for (const P in u.value.fields)
|
|
1627
1662
|
if (u.value.fields[P].widget?.widget === "File") {
|
|
1628
1663
|
const re = g.value.find((B) => B.fieldKey === P);
|
|
1629
|
-
re && re.widget && (re.widget.files =
|
|
1664
|
+
re && re.widget && (re.widget.files = I[P] ?? []);
|
|
1630
1665
|
}
|
|
1631
|
-
const
|
|
1632
|
-
|
|
1666
|
+
const z = await r.getProcess();
|
|
1667
|
+
X.value = T(z, 0), p.value = !1;
|
|
1633
1668
|
}
|
|
1634
|
-
ue(
|
|
1635
|
-
async function I
|
|
1636
|
-
return o[
|
|
1669
|
+
ue(w);
|
|
1670
|
+
async function V(I, H) {
|
|
1671
|
+
return o[I]?.(H);
|
|
1637
1672
|
}
|
|
1638
|
-
function
|
|
1673
|
+
function A() {
|
|
1639
1674
|
return a()?.userInfo?.email_address ?? "";
|
|
1640
1675
|
}
|
|
1641
|
-
async function
|
|
1676
|
+
async function D(I, H, z, P, re) {
|
|
1642
1677
|
try {
|
|
1643
|
-
switch (
|
|
1644
|
-
case
|
|
1645
|
-
const { reason: B, ifGlobal: be } = await
|
|
1646
|
-
|
|
1678
|
+
switch (H) {
|
|
1679
|
+
case J.Submit:
|
|
1680
|
+
const { reason: B, ifGlobal: be } = await V(re, { isGlobal: ee.value });
|
|
1681
|
+
p.value = !0;
|
|
1647
1682
|
const ke = re === "Approve" ? "100" : "-1";
|
|
1648
|
-
await Rt(i.className, i.workflowId,
|
|
1683
|
+
await Rt(i.className, i.workflowId, A(), B, [Number(i.workflowId)], z, ke, be), p.value = !1;
|
|
1649
1684
|
const he = re === "Approve" ? `Request ID ${i.workflowId} has been approved.` : `Request ID ${i.workflowId} has been rejected.`;
|
|
1650
|
-
c?.appContext.config.globalProperties.$notification.success(he),
|
|
1685
|
+
c?.appContext.config.globalProperties.$notification.success(he), w();
|
|
1651
1686
|
break;
|
|
1652
|
-
case
|
|
1687
|
+
case J.Link:
|
|
1653
1688
|
try {
|
|
1654
|
-
await o[
|
|
1689
|
+
await o[I.eventName || ""]?.(), l.push({ name: P, params: { className: i.className, workflowId: i.workflowId } });
|
|
1655
1690
|
} catch (te) {
|
|
1656
1691
|
console.error("Error in link action trigger:", te);
|
|
1657
1692
|
}
|
|
1658
1693
|
break;
|
|
1659
|
-
case
|
|
1660
|
-
await o[
|
|
1694
|
+
case J.Button:
|
|
1695
|
+
await o[I.eventName || ""]?.({
|
|
1661
1696
|
approvers: se,
|
|
1662
1697
|
associators: ie,
|
|
1663
|
-
isShowAssignSelect:
|
|
1698
|
+
isShowAssignSelect: j,
|
|
1664
1699
|
isShowAssignList: Z,
|
|
1665
1700
|
assignCallback: _e,
|
|
1666
|
-
deleteAssociatorCallback:
|
|
1701
|
+
deleteAssociatorCallback: U
|
|
1667
1702
|
});
|
|
1668
1703
|
break;
|
|
1669
1704
|
default:
|
|
1670
|
-
console.warn("Unknown action type:",
|
|
1705
|
+
console.warn("Unknown action type:", H);
|
|
1671
1706
|
}
|
|
1672
1707
|
} catch {
|
|
1673
1708
|
}
|
|
1674
1709
|
}
|
|
1675
|
-
const
|
|
1676
|
-
async function _e(
|
|
1677
|
-
if (!
|
|
1710
|
+
const $ = m(""), L = m([]), Y = m(""), se = m([]), ie = m([]);
|
|
1711
|
+
async function _e(I) {
|
|
1712
|
+
if (!I) {
|
|
1678
1713
|
c?.appContext.config.globalProperties.$message.error("Please select an approver");
|
|
1679
1714
|
return;
|
|
1680
1715
|
}
|
|
1681
1716
|
await v("Confirm Assign Approver", "Do you want to assign the selected approver?");
|
|
1682
1717
|
try {
|
|
1683
|
-
await r.assignApprover(
|
|
1684
|
-
} catch (
|
|
1685
|
-
if (
|
|
1718
|
+
await r.assignApprover(I), ie.value = await r.getAssociator(), x(), c?.appContext.config.globalProperties.$notification.success("Assign Approver clicked!");
|
|
1719
|
+
} catch (H) {
|
|
1720
|
+
if (H.status === 409) {
|
|
1686
1721
|
c?.appContext.config.globalProperties.$notification.error("This user is already an associator");
|
|
1687
1722
|
return;
|
|
1688
1723
|
}
|
|
1689
1724
|
c?.appContext.config.globalProperties.$notification.error("Failed to assign approver");
|
|
1690
1725
|
}
|
|
1691
1726
|
}
|
|
1692
|
-
async function v(
|
|
1693
|
-
const { Modal:
|
|
1727
|
+
async function v(I, H) {
|
|
1728
|
+
const { Modal: z } = await import("@arco-design/web-vue");
|
|
1694
1729
|
return new Promise((P, re) => {
|
|
1695
|
-
|
|
1696
|
-
title:
|
|
1697
|
-
content:
|
|
1730
|
+
z.confirm({
|
|
1731
|
+
title: I,
|
|
1732
|
+
content: H,
|
|
1698
1733
|
okText: "OK",
|
|
1699
1734
|
cancelText: "Cancel",
|
|
1700
1735
|
onOk: () => P(!0),
|
|
@@ -1702,186 +1737,176 @@ const Co = /* @__PURE__ */ K({
|
|
|
1702
1737
|
});
|
|
1703
1738
|
});
|
|
1704
1739
|
}
|
|
1705
|
-
async function
|
|
1740
|
+
async function U(I) {
|
|
1706
1741
|
try {
|
|
1707
1742
|
await v("Confirm Delete Associator", "Do you want to delete this associator?");
|
|
1708
1743
|
} catch {
|
|
1709
1744
|
return;
|
|
1710
1745
|
}
|
|
1711
1746
|
try {
|
|
1712
|
-
await r.deleteAssociator(
|
|
1747
|
+
await r.deleteAssociator(I.toString()), ie.value = await r.getAssociator(), c?.appContext.config.globalProperties.$notification.success("Associator deleted successfully!");
|
|
1713
1748
|
} catch {
|
|
1714
1749
|
c?.appContext.config.globalProperties.$notification.error("Failed to delete associator");
|
|
1715
1750
|
}
|
|
1716
1751
|
}
|
|
1717
1752
|
async function R() {
|
|
1718
|
-
if (
|
|
1753
|
+
if (!$.value.trim()) {
|
|
1719
1754
|
c?.appContext.config.globalProperties.$message.error("Comment cannot be empty");
|
|
1720
1755
|
return;
|
|
1721
1756
|
}
|
|
1722
|
-
await r.addComments(
|
|
1757
|
+
await r.addComments($.value.trim()), $.value = "", L.value = await r.getCommentsHistory(), c?.appContext.config.globalProperties.$notification.success("Add Comment clicked!");
|
|
1723
1758
|
}
|
|
1724
|
-
function ce(
|
|
1725
|
-
return
|
|
1759
|
+
function ce(I) {
|
|
1760
|
+
return I ? I === "OtherInformationText" ? "Other Information" : I === "Other Information" ? "" : I : "";
|
|
1726
1761
|
}
|
|
1727
1762
|
const ve = { svrStore: a, bpmStore: e, triggers: o, router: l, customComps: s, instance: c, props: i, get page() {
|
|
1728
1763
|
return r;
|
|
1729
|
-
}, set page(
|
|
1730
|
-
r =
|
|
1731
|
-
}, pageData: u, _fields: g, genField: _, groupedFields:
|
|
1732
|
-
return
|
|
1733
|
-
}, TopBar:
|
|
1764
|
+
}, set page(I) {
|
|
1765
|
+
r = I;
|
|
1766
|
+
}, pageData: u, _fields: g, genField: _, groupedFields: S, reversedActions: f, loading: p, mapWorkflowSteps: T, steps: X, isGlobal: ee, isShowAssignSelect: j, isShowAssignList: Z, isShowCommentTextArea: ae, reloadButtonList: x, hiddenFields: y, load: w, triggerFn: V, getApproverEmail: A, clickHandler: D, comment: $, commentsHistory: L, selectedApprover: Y, approvers: se, associators: ie, onAssignApprover: _e, confirmDialog: v, onDeleteAssociator: U, onAddComment: R, formatTitle: ce, ActionButton: xe, get IconDownload() {
|
|
1767
|
+
return Pn;
|
|
1768
|
+
}, TopBar: Ie, get formatDate() {
|
|
1734
1769
|
return Ce;
|
|
1735
|
-
},
|
|
1736
|
-
return at;
|
|
1737
|
-
} };
|
|
1770
|
+
}, ToolTip: at };
|
|
1738
1771
|
return Object.defineProperty(ve, "__isScriptSetup", { enumerable: !1, value: !0 }), ve;
|
|
1739
1772
|
}
|
|
1740
|
-
}),
|
|
1773
|
+
}), Io = { class: "page-container" }, Po = { class: "page-body" }, No = { class: "detail-card" }, Uo = { class: "form-fields-vertical" }, Do = { class: "detail-fields" }, Bo = { class: "detail-field" }, Fo = { class: "field-label" }, Ho = {
|
|
1741
1774
|
key: 1,
|
|
1742
1775
|
class: "field-value"
|
|
1743
|
-
},
|
|
1776
|
+
}, Lo = {
|
|
1744
1777
|
key: 2,
|
|
1745
1778
|
class: "detail-field-wrapper"
|
|
1746
|
-
},
|
|
1779
|
+
}, Ro = { class: "detail-field" }, $o = {
|
|
1747
1780
|
key: 0,
|
|
1748
1781
|
class: "detail-content"
|
|
1749
|
-
},
|
|
1750
|
-
function
|
|
1751
|
-
const s =
|
|
1752
|
-
|
|
1753
|
-
const
|
|
1754
|
-
return d(), h("div",
|
|
1755
|
-
|
|
1782
|
+
}, Oo = { class: "page-footer" }, jo = { class: "action-container" }, Mo = { class: "action-buttons" };
|
|
1783
|
+
function Eo(t, n, a, e, o, l) {
|
|
1784
|
+
const s = C("a-link"), c = C("a-space"), i = C("a-card");
|
|
1785
|
+
C("a-option"), C("a-select");
|
|
1786
|
+
const r = C("a-button"), u = C("a-list-item"), g = C("a-list"), _ = C("a-textarea"), S = C("a-spin");
|
|
1787
|
+
return d(), h("div", Io, [
|
|
1788
|
+
N(e.TopBar, {
|
|
1756
1789
|
title: e.pageData.banner.title,
|
|
1757
1790
|
subTitle: e.pageData.banner.subTitle,
|
|
1758
1791
|
email: e.getApproverEmail()
|
|
1759
1792
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
1760
|
-
|
|
1761
|
-
|
|
1793
|
+
b("div", Po, [
|
|
1794
|
+
N(S, {
|
|
1762
1795
|
loading: e.loading,
|
|
1763
1796
|
class: "detail-container"
|
|
1764
1797
|
}, {
|
|
1765
|
-
default:
|
|
1766
|
-
|
|
1767
|
-
(d(),
|
|
1768
|
-
|
|
1769
|
-
(d(!0), h(
|
|
1798
|
+
default: k(() => [
|
|
1799
|
+
b("div", No, [
|
|
1800
|
+
(d(), F(Le(e.customComps.Steps), { steps: e.steps }, null, 8, ["steps"])),
|
|
1801
|
+
b("div", Uo, [
|
|
1802
|
+
(d(!0), h(O, null, M(e.groupedFields, (f) => (d(), F(i, {
|
|
1770
1803
|
key: f.name,
|
|
1771
1804
|
title: f.name,
|
|
1772
1805
|
style: { "margin-bottom": "24px" }
|
|
1773
1806
|
}, {
|
|
1774
|
-
default:
|
|
1775
|
-
|
|
1776
|
-
(d(!0), h(
|
|
1777
|
-
key:
|
|
1807
|
+
default: k(() => [
|
|
1808
|
+
b("div", Do, [
|
|
1809
|
+
(d(!0), h(O, null, M(f.fields, (p) => (d(), h("div", {
|
|
1810
|
+
key: p.fieldKey,
|
|
1778
1811
|
class: "detail-field-wrapper"
|
|
1779
1812
|
}, [
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
"
|
|
1786
|
-
},
|
|
1787
|
-
content: y(() => [
|
|
1788
|
-
(d(!0), h($, null, z(b.widget?.outputText, (j) => (d(), h("div", { key: j }, X(j), 1))), 128))
|
|
1789
|
-
]),
|
|
1790
|
-
default: y(() => [
|
|
1791
|
-
U(e.IconQuestionCircle, { class: "icon" })
|
|
1792
|
-
]),
|
|
1793
|
-
_: 2
|
|
1794
|
-
}, 1024)) : ne("", !0)
|
|
1813
|
+
b("div", Bo, [
|
|
1814
|
+
b("div", Fo, [
|
|
1815
|
+
ne(Q(e.formatTitle(p.widget?.title)) + " ", 1),
|
|
1816
|
+
N(e.ToolTip, {
|
|
1817
|
+
"is-visible": p.widget?.isVisible ?? !1,
|
|
1818
|
+
"output-text": p.widget?.outputText ?? []
|
|
1819
|
+
}, null, 8, ["is-visible", "output-text"])
|
|
1795
1820
|
]),
|
|
1796
|
-
|
|
1821
|
+
p.widget?.widget === "File" ? (d(!0), h(O, { key: 0 }, M(p.widget.files, (T) => (d(), h("div", {
|
|
1797
1822
|
class: "field-value",
|
|
1798
|
-
key:
|
|
1823
|
+
key: T.id
|
|
1799
1824
|
}, [
|
|
1800
|
-
|
|
1801
|
-
default:
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
href:
|
|
1825
|
+
N(c, null, {
|
|
1826
|
+
default: k(() => [
|
|
1827
|
+
ne(Q(T.name) + " ", 1),
|
|
1828
|
+
N(s, {
|
|
1829
|
+
href: T.url,
|
|
1805
1830
|
target: "_blank"
|
|
1806
1831
|
}, {
|
|
1807
|
-
default:
|
|
1808
|
-
|
|
1832
|
+
default: k(() => [
|
|
1833
|
+
N(e.IconDownload, { style: { color: "#7A00E6" } })
|
|
1809
1834
|
]),
|
|
1810
1835
|
_: 2
|
|
1811
1836
|
}, 1032, ["href"])
|
|
1812
1837
|
]),
|
|
1813
1838
|
_: 2
|
|
1814
1839
|
}, 1024)
|
|
1815
|
-
]))), 128)) : (d(), h("div",
|
|
1840
|
+
]))), 128)) : (d(), h("div", Ho, Q(p.fieldValue), 1))
|
|
1816
1841
|
])
|
|
1817
1842
|
]))), 128))
|
|
1818
1843
|
])
|
|
1819
1844
|
]),
|
|
1820
1845
|
_: 2
|
|
1821
1846
|
}, 1032, ["title"]))), 128)),
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
e.isShowCommentTextArea ? (d(), h("div",
|
|
1825
|
-
|
|
1826
|
-
n[6] || (n[6] =
|
|
1827
|
-
|
|
1847
|
+
oe("", !0),
|
|
1848
|
+
oe("", !0),
|
|
1849
|
+
e.isShowCommentTextArea ? (d(), h("div", Lo, [
|
|
1850
|
+
b("div", Ro, [
|
|
1851
|
+
n[6] || (n[6] = b("div", { class: "field-label" }, "Comment", -1)),
|
|
1852
|
+
N(_, {
|
|
1828
1853
|
modelValue: e.comment,
|
|
1829
1854
|
"onUpdate:modelValue": n[1] || (n[1] = (f) => e.comment = f)
|
|
1830
1855
|
}, null, 8, ["modelValue"]),
|
|
1831
|
-
|
|
1856
|
+
N(r, {
|
|
1832
1857
|
type: "primary",
|
|
1833
1858
|
onClick: e.onAddComment
|
|
1834
1859
|
}, {
|
|
1835
|
-
default:
|
|
1836
|
-
|
|
1860
|
+
default: k(() => n[5] || (n[5] = [
|
|
1861
|
+
ne("Add Comment", -1)
|
|
1837
1862
|
])),
|
|
1838
1863
|
_: 1,
|
|
1839
1864
|
__: [5]
|
|
1840
1865
|
})
|
|
1841
1866
|
])
|
|
1842
|
-
])) :
|
|
1843
|
-
e.commentsHistory.length ? (d(),
|
|
1844
|
-
header:
|
|
1845
|
-
|
|
1867
|
+
])) : oe("", !0),
|
|
1868
|
+
e.commentsHistory.length ? (d(), F(g, { key: 3 }, {
|
|
1869
|
+
header: k(() => n[7] || (n[7] = [
|
|
1870
|
+
ne(" Comments History ", -1)
|
|
1846
1871
|
])),
|
|
1847
|
-
default:
|
|
1848
|
-
(d(!0), h(
|
|
1872
|
+
default: k(() => [
|
|
1873
|
+
(d(!0), h(O, null, M(e.commentsHistory, (f) => (d(), F(u, {
|
|
1849
1874
|
key: f.associator
|
|
1850
1875
|
}, {
|
|
1851
|
-
default:
|
|
1852
|
-
|
|
1876
|
+
default: k(() => [
|
|
1877
|
+
ne(Q(f.associator) + ": " + Q(f.comments) + " (" + Q(e.formatDate(f.createdAt)) + ") ", 1)
|
|
1853
1878
|
]),
|
|
1854
1879
|
_: 2
|
|
1855
1880
|
}, 1024))), 128))
|
|
1856
1881
|
]),
|
|
1857
1882
|
_: 1
|
|
1858
|
-
})) :
|
|
1883
|
+
})) : oe("", !0)
|
|
1859
1884
|
]),
|
|
1860
|
-
t.$slots.content ? (d(), h("div",
|
|
1885
|
+
t.$slots.content ? (d(), h("div", $o, [
|
|
1861
1886
|
de(t.$slots, "content", {}, void 0, !0)
|
|
1862
|
-
])) :
|
|
1887
|
+
])) : oe("", !0)
|
|
1863
1888
|
])
|
|
1864
1889
|
]),
|
|
1865
1890
|
_: 3
|
|
1866
1891
|
}, 8, ["loading"])
|
|
1867
1892
|
]),
|
|
1868
|
-
|
|
1869
|
-
|
|
1893
|
+
b("div", Oo, [
|
|
1894
|
+
b("div", jo, [
|
|
1870
1895
|
de(t.$slots, "action", {}, void 0, !0),
|
|
1871
|
-
|
|
1872
|
-
(d(!0), h(
|
|
1896
|
+
b("div", Mo, [
|
|
1897
|
+
(d(!0), h(O, null, M(e.reversedActions, (f) => (d(), F(e.ActionButton, {
|
|
1873
1898
|
key: f.title,
|
|
1874
1899
|
loading: e.loading,
|
|
1875
1900
|
config: f,
|
|
1876
1901
|
class: "action-button",
|
|
1877
|
-
onClick: (...
|
|
1902
|
+
onClick: (...p) => e.clickHandler(f, ...p)
|
|
1878
1903
|
}, null, 8, ["loading", "config", "onClick"]))), 128))
|
|
1879
1904
|
])
|
|
1880
1905
|
])
|
|
1881
1906
|
])
|
|
1882
1907
|
]);
|
|
1883
1908
|
}
|
|
1884
|
-
const
|
|
1909
|
+
const zo = /* @__PURE__ */ q(Vo, [["render", Eo], ["__scopeId", "data-v-c382c4fa"], ["__file", "DetailView.vue"]]), Ko = /* @__PURE__ */ E({
|
|
1885
1910
|
name: "ListView",
|
|
1886
1911
|
__name: "ListView",
|
|
1887
1912
|
props: {
|
|
@@ -1889,7 +1914,7 @@ const jo = /* @__PURE__ */ J(Co, [["render", Ro], ["__scopeId", "data-v-f3f30431
|
|
|
1889
1914
|
},
|
|
1890
1915
|
setup(t, { expose: n }) {
|
|
1891
1916
|
n();
|
|
1892
|
-
const a =
|
|
1917
|
+
const a = Ve(), e = Te(), o = Ae(), l = pe(), s = t, c = m(), i = ut({
|
|
1893
1918
|
current: 1,
|
|
1894
1919
|
total: 0,
|
|
1895
1920
|
pageSize: 10,
|
|
@@ -1899,8 +1924,8 @@ const jo = /* @__PURE__ */ J(Co, [["render", Ro], ["__scopeId", "data-v-f3f30431
|
|
|
1899
1924
|
filters: []
|
|
1900
1925
|
});
|
|
1901
1926
|
function r() {
|
|
1902
|
-
const v = Object.entries(
|
|
1903
|
-
key:
|
|
1927
|
+
const v = Object.entries(A.value).filter(([, { value: U }]) => U && U !== "").map(([U, { value: R, operator: ce }]) => ({
|
|
1928
|
+
key: U,
|
|
1904
1929
|
value: R,
|
|
1905
1930
|
operator: ce
|
|
1906
1931
|
// 根据实际需要调整操作符
|
|
@@ -1915,12 +1940,12 @@ const jo = /* @__PURE__ */ J(Co, [["render", Ro], ["__scopeId", "data-v-f3f30431
|
|
|
1915
1940
|
}]
|
|
1916
1941
|
};
|
|
1917
1942
|
}
|
|
1918
|
-
const u =
|
|
1919
|
-
x:
|
|
1943
|
+
const u = G(() => ({
|
|
1944
|
+
x: S.value.length * 150 + 250
|
|
1920
1945
|
// 只设置横向滚动
|
|
1921
1946
|
// 移除 y 属性,让表格高度自适应
|
|
1922
1947
|
})), g = (v) => {
|
|
1923
|
-
const
|
|
1948
|
+
const U = Object.entries(v).filter(([, R]) => R.widget?.column).map(([R, ce], ve) => ({
|
|
1924
1949
|
title: ce.widget.title,
|
|
1925
1950
|
dataIndex: R.charAt(0).toLowerCase() + R.slice(1),
|
|
1926
1951
|
order: ce.order,
|
|
@@ -1932,7 +1957,7 @@ const jo = /* @__PURE__ */ J(Co, [["render", Ro], ["__scopeId", "data-v-f3f30431
|
|
|
1932
1957
|
resizable: !0
|
|
1933
1958
|
// 启用列宽调整
|
|
1934
1959
|
})).sort((R, ce) => R.order - ce.order);
|
|
1935
|
-
|
|
1960
|
+
U.push({
|
|
1936
1961
|
title: "Actions",
|
|
1937
1962
|
slotName: "optional",
|
|
1938
1963
|
align: "center",
|
|
@@ -1940,149 +1965,149 @@ const jo = /* @__PURE__ */ J(Co, [["render", Ro], ["__scopeId", "data-v-f3f30431
|
|
|
1940
1965
|
minWidth: 200,
|
|
1941
1966
|
fixed: "right",
|
|
1942
1967
|
resizable: !1
|
|
1943
|
-
}),
|
|
1944
|
-
}, _ = m([]),
|
|
1945
|
-
|
|
1968
|
+
}), S.value = U;
|
|
1969
|
+
}, _ = m([]), S = m([]), f = m(!0), p = m(!0), T = m(), X = async () => {
|
|
1970
|
+
p.value = !0;
|
|
1946
1971
|
const v = await Pt(s.className, r());
|
|
1947
|
-
_.value = v.data, i.total = v.totalCount,
|
|
1972
|
+
_.value = v.data, i.total = v.totalCount, p.value = !1;
|
|
1948
1973
|
}, ee = m(!1);
|
|
1949
1974
|
ue(async () => {
|
|
1950
|
-
|
|
1975
|
+
f.value = !0;
|
|
1951
1976
|
const v = new Pe().setPageActionType(fe.List).setClassName(s.className).setStore({ svrStore: a, bpmStore: e }).build();
|
|
1952
|
-
c.value = await v.getPageData(), g(c.value.fields),
|
|
1977
|
+
c.value = await v.getPageData(), g(c.value.fields), $(c.value.fields), L(), V(c.value?.tabs?.[0]?.key || ""), T.value = c.value.actions, f.value = !1, ee.value = !0;
|
|
1953
1978
|
}), ft(() => {
|
|
1954
|
-
ee.value &&
|
|
1979
|
+
ee.value && X();
|
|
1955
1980
|
});
|
|
1956
|
-
const
|
|
1957
|
-
i.current = v,
|
|
1981
|
+
const j = (v) => {
|
|
1982
|
+
i.current = v, X();
|
|
1958
1983
|
}, Z = (v) => {
|
|
1959
|
-
i.pageSize = v,
|
|
1984
|
+
i.pageSize = v, X();
|
|
1960
1985
|
};
|
|
1961
|
-
function ae(v,
|
|
1986
|
+
function ae(v, U, R, ce, ve) {
|
|
1962
1987
|
switch (v) {
|
|
1963
|
-
case
|
|
1988
|
+
case J.Link:
|
|
1964
1989
|
o.push({ name: R, params: { workflowId: ve } });
|
|
1965
1990
|
break;
|
|
1966
1991
|
default:
|
|
1967
1992
|
console.warn("Unknown action type:", v);
|
|
1968
1993
|
}
|
|
1969
1994
|
}
|
|
1970
|
-
function
|
|
1995
|
+
function x(v, U, R) {
|
|
1971
1996
|
switch (v) {
|
|
1972
|
-
case
|
|
1973
|
-
|
|
1997
|
+
case J.Submit:
|
|
1998
|
+
Qt(U, { filters: [{ key: "approverList", value: y(), operator: 2 }] }), l?.appContext.config.globalProperties.$notification.success("submit success!");
|
|
1974
1999
|
break;
|
|
1975
|
-
case
|
|
2000
|
+
case J.Link:
|
|
1976
2001
|
o.push({ name: R });
|
|
1977
2002
|
break;
|
|
1978
2003
|
default:
|
|
1979
2004
|
console.warn("Unknown action type:", v);
|
|
1980
2005
|
}
|
|
1981
2006
|
}
|
|
1982
|
-
function
|
|
2007
|
+
function y() {
|
|
1983
2008
|
return a()?.userInfo?.email_address ?? "";
|
|
1984
2009
|
}
|
|
1985
|
-
function
|
|
1986
|
-
return typeof v != "string" || v.indexOf("{currentUserEmail}") === -1 ? v : v.replace(/{currentUserEmail}/g,
|
|
2010
|
+
function w(v, U) {
|
|
2011
|
+
return typeof v != "string" || v.indexOf("{currentUserEmail}") === -1 ? v : v.replace(/{currentUserEmail}/g, U);
|
|
1987
2012
|
}
|
|
1988
|
-
function
|
|
1989
|
-
const
|
|
1990
|
-
i.filters =
|
|
2013
|
+
function V(v) {
|
|
2014
|
+
const U = c.value?.tabs?.find((R) => R.key === v)?.filters;
|
|
2015
|
+
i.filters = U?.map((R) => ({
|
|
1991
2016
|
...R,
|
|
1992
|
-
value:
|
|
1993
|
-
})) || [], i.current = 1,
|
|
2017
|
+
value: w(R.value, y())
|
|
2018
|
+
})) || [], i.current = 1, X();
|
|
1994
2019
|
}
|
|
1995
|
-
const
|
|
1996
|
-
function
|
|
2020
|
+
const A = m({}), D = m([]);
|
|
2021
|
+
function $(v) {
|
|
1997
2022
|
if (!v) return [];
|
|
1998
|
-
|
|
2023
|
+
D.value = Object.entries(v).filter(([, U]) => U.isFiltered).map(([U, R]) => ({ fieldKey: U, fieldConfig: R }));
|
|
1999
2024
|
}
|
|
2000
2025
|
const L = () => {
|
|
2001
2026
|
const v = {};
|
|
2002
|
-
|
|
2003
|
-
v[
|
|
2004
|
-
}),
|
|
2005
|
-
},
|
|
2006
|
-
i.current = 1,
|
|
2027
|
+
D.value.forEach(({ fieldKey: U, fieldConfig: R }) => {
|
|
2028
|
+
v[U] = {}, v[U].value = R.modelValue, v[U].operator = R.operator;
|
|
2029
|
+
}), A.value = v;
|
|
2030
|
+
}, Y = () => {
|
|
2031
|
+
i.current = 1, X();
|
|
2007
2032
|
}, se = () => {
|
|
2008
|
-
c.value && L(),
|
|
2033
|
+
c.value && L(), Y();
|
|
2009
2034
|
};
|
|
2010
|
-
function ie(v,
|
|
2011
|
-
return !(v.location !== "InTable" || v.title === "Update" && (
|
|
2035
|
+
function ie(v, U) {
|
|
2036
|
+
return !(v.location !== "InTable" || v.title === "Update" && (U.status === 100 || U.status === -1));
|
|
2012
2037
|
}
|
|
2013
|
-
const _e = { svrStore: a, bpmStore: e, router: o, instance: l, props: s, pageData: c, paging: i, createListParams: r, scroll: u, mapColumns: g, _data: _, _columns:
|
|
2038
|
+
const _e = { svrStore: a, bpmStore: e, router: o, instance: l, props: s, pageData: c, paging: i, createListParams: r, scroll: u, mapColumns: g, _data: _, _columns: S, loadingPage: f, loadingTable: p, actions: T, loadData: X, mounted: ee, pageChangeHandler: j, pageSizeChangeHandler: Z, clickHandler: ae, createHandler: x, getApproverEmail: y, replaceEmail: w, tabHandler: V, searchForm: A, searchableFields: D, mapSearchableFields: $, initSearchForm: L, handleSearch: Y, handleReset: se, judgeHiddenActions: ie, ActionButton: xe, DataWidgets: Oe, TopBar: Ie };
|
|
2014
2039
|
return Object.defineProperty(_e, "__isScriptSetup", { enumerable: !1, value: !0 }), _e;
|
|
2015
2040
|
}
|
|
2016
|
-
}),
|
|
2017
|
-
function
|
|
2018
|
-
const s =
|
|
2019
|
-
return d(), h("div",
|
|
2020
|
-
|
|
2041
|
+
}), Wo = { class: "list-container" }, Go = { class: "query-title" };
|
|
2042
|
+
function qo(t, n, a, e, o, l) {
|
|
2043
|
+
const s = C("a-space"), c = C("a-col"), i = C("a-button"), r = C("a-row"), u = C("a-card"), g = C("a-tab-pane"), _ = C("a-tabs"), S = C("a-table");
|
|
2044
|
+
return d(), h("div", Wo, [
|
|
2045
|
+
N(e.TopBar, {
|
|
2021
2046
|
title: e.pageData?.banner.title ?? "",
|
|
2022
2047
|
subTitle: e.pageData?.banner.subTitle ?? "",
|
|
2023
2048
|
email: e.getApproverEmail()
|
|
2024
2049
|
}, null, 8, ["title", "subTitle", "email"]),
|
|
2025
|
-
|
|
2026
|
-
default:
|
|
2027
|
-
|
|
2028
|
-
n[0] || (n[0] =
|
|
2029
|
-
|
|
2030
|
-
default:
|
|
2031
|
-
(d(!0), h(
|
|
2032
|
-
key:
|
|
2050
|
+
N(u, null, {
|
|
2051
|
+
default: k(() => [
|
|
2052
|
+
b("div", Go, [
|
|
2053
|
+
n[0] || (n[0] = b("h3", null, "Search Conditions", -1)),
|
|
2054
|
+
N(s, { size: "medium" }, {
|
|
2055
|
+
default: k(() => [
|
|
2056
|
+
(d(!0), h(O, null, M(e.actions, (f) => (d(), h(O, {
|
|
2057
|
+
key: f.title
|
|
2033
2058
|
}, [
|
|
2034
|
-
|
|
2059
|
+
f.location === "InOperation" ? (d(), F(e.ActionButton, {
|
|
2035
2060
|
key: 0,
|
|
2036
|
-
config:
|
|
2061
|
+
config: f,
|
|
2037
2062
|
onClick: e.createHandler
|
|
2038
|
-
}, null, 8, ["config"])) :
|
|
2063
|
+
}, null, 8, ["config"])) : oe("", !0)
|
|
2039
2064
|
], 64))), 128))
|
|
2040
2065
|
]),
|
|
2041
2066
|
_: 1
|
|
2042
2067
|
})
|
|
2043
2068
|
]),
|
|
2044
|
-
|
|
2045
|
-
default:
|
|
2046
|
-
(d(!0), h(
|
|
2047
|
-
key:
|
|
2069
|
+
N(r, { gutter: [24, 20] }, {
|
|
2070
|
+
default: k(() => [
|
|
2071
|
+
(d(!0), h(O, null, M(e.searchableFields, (f) => (d(), F(c, {
|
|
2072
|
+
key: f.fieldKey,
|
|
2048
2073
|
span: 6,
|
|
2049
2074
|
class: "search-col"
|
|
2050
2075
|
}, {
|
|
2051
|
-
default:
|
|
2052
|
-
|
|
2053
|
-
name:
|
|
2054
|
-
config:
|
|
2055
|
-
modelValue: e.searchForm[
|
|
2056
|
-
"onUpdate:modelValue": (
|
|
2076
|
+
default: k(() => [
|
|
2077
|
+
N(e.DataWidgets, {
|
|
2078
|
+
name: f.fieldKey,
|
|
2079
|
+
config: f.fieldConfig,
|
|
2080
|
+
modelValue: e.searchForm[f.fieldKey].value,
|
|
2081
|
+
"onUpdate:modelValue": (p) => e.searchForm[f.fieldKey].value = p,
|
|
2057
2082
|
class: "form-field"
|
|
2058
2083
|
}, null, 8, ["name", "config", "modelValue", "onUpdate:modelValue"])
|
|
2059
2084
|
]),
|
|
2060
2085
|
_: 2
|
|
2061
2086
|
}, 1024))), 128)),
|
|
2062
|
-
|
|
2087
|
+
N(c, {
|
|
2063
2088
|
span: 6,
|
|
2064
2089
|
class: "search-col form-buttons"
|
|
2065
2090
|
}, {
|
|
2066
|
-
default:
|
|
2067
|
-
|
|
2068
|
-
default:
|
|
2069
|
-
|
|
2091
|
+
default: k(() => [
|
|
2092
|
+
N(s, { size: "medium" }, {
|
|
2093
|
+
default: k(() => [
|
|
2094
|
+
N(i, {
|
|
2070
2095
|
type: "primary",
|
|
2071
2096
|
size: "medium",
|
|
2072
2097
|
onClick: e.handleSearch
|
|
2073
2098
|
}, {
|
|
2074
|
-
default:
|
|
2075
|
-
|
|
2099
|
+
default: k(() => n[1] || (n[1] = [
|
|
2100
|
+
ne(" Search ", -1)
|
|
2076
2101
|
])),
|
|
2077
2102
|
_: 1,
|
|
2078
2103
|
__: [1]
|
|
2079
2104
|
}),
|
|
2080
|
-
|
|
2105
|
+
N(i, {
|
|
2081
2106
|
size: "medium",
|
|
2082
2107
|
onClick: e.handleReset
|
|
2083
2108
|
}, {
|
|
2084
|
-
default:
|
|
2085
|
-
|
|
2109
|
+
default: k(() => n[2] || (n[2] = [
|
|
2110
|
+
ne(" Reset ", -1)
|
|
2086
2111
|
])),
|
|
2087
2112
|
_: 1,
|
|
2088
2113
|
__: [2]
|
|
@@ -2099,19 +2124,19 @@ function Eo(t, n, a, e, o, l) {
|
|
|
2099
2124
|
]),
|
|
2100
2125
|
_: 1
|
|
2101
2126
|
}),
|
|
2102
|
-
|
|
2127
|
+
N(_, {
|
|
2103
2128
|
size: "large",
|
|
2104
2129
|
onTabClick: e.tabHandler
|
|
2105
2130
|
}, {
|
|
2106
|
-
default:
|
|
2107
|
-
(d(!0), h(
|
|
2108
|
-
key:
|
|
2109
|
-
title:
|
|
2131
|
+
default: k(() => [
|
|
2132
|
+
(d(!0), h(O, null, M(e.pageData?.tabs, (f) => (d(), F(g, {
|
|
2133
|
+
key: f.key,
|
|
2134
|
+
title: f.title
|
|
2110
2135
|
}, null, 8, ["title"]))), 128))
|
|
2111
2136
|
]),
|
|
2112
2137
|
_: 1
|
|
2113
2138
|
}),
|
|
2114
|
-
|
|
2139
|
+
N(S, {
|
|
2115
2140
|
columns: e._columns,
|
|
2116
2141
|
data: e._data,
|
|
2117
2142
|
stripe: "",
|
|
@@ -2130,18 +2155,18 @@ function Eo(t, n, a, e, o, l) {
|
|
|
2130
2155
|
onPageChange: e.pageChangeHandler,
|
|
2131
2156
|
onPageSizeChange: e.pageSizeChangeHandler
|
|
2132
2157
|
}, {
|
|
2133
|
-
optional:
|
|
2134
|
-
|
|
2135
|
-
default:
|
|
2136
|
-
(d(!0), h(
|
|
2137
|
-
key:
|
|
2158
|
+
optional: k(({ record: f }) => [
|
|
2159
|
+
N(s, { size: "small" }, {
|
|
2160
|
+
default: k(() => [
|
|
2161
|
+
(d(!0), h(O, null, M(e.actions, (p) => (d(), h(O, {
|
|
2162
|
+
key: p.title
|
|
2138
2163
|
}, [
|
|
2139
|
-
e.judgeHiddenActions(
|
|
2164
|
+
e.judgeHiddenActions(p, f) ? (d(), F(e.ActionButton, {
|
|
2140
2165
|
key: 0,
|
|
2141
|
-
config:
|
|
2166
|
+
config: p,
|
|
2142
2167
|
size: "small",
|
|
2143
|
-
onClick: (...
|
|
2144
|
-
}, null, 8, ["config", "onClick"])) :
|
|
2168
|
+
onClick: (...T) => e.clickHandler(...T, f.workflowId)
|
|
2169
|
+
}, null, 8, ["config", "onClick"])) : oe("", !0)
|
|
2145
2170
|
], 64))), 128))
|
|
2146
2171
|
]),
|
|
2147
2172
|
_: 2
|
|
@@ -2151,12 +2176,12 @@ function Eo(t, n, a, e, o, l) {
|
|
|
2151
2176
|
}, 8, ["columns", "data", "pagination", "loading", "scroll"])
|
|
2152
2177
|
]);
|
|
2153
2178
|
}
|
|
2154
|
-
const
|
|
2179
|
+
const Yo = /* @__PURE__ */ q(Ko, [["render", qo], ["__scopeId", "data-v-639f4f42"], ["__file", "ListView.vue"]]), ta = {
|
|
2155
2180
|
install(t, n = {}) {
|
|
2156
|
-
n.config && wt(n.config), n.router && t.provide(rt, n.router), n.pinia && t.provide(
|
|
2181
|
+
n.config && wt(n.config), n.router && t.provide(rt, n.router), n.pinia && t.provide(Gn, n.pinia), n.useBpmStore && t.provide(it, n.useBpmStore), n.useSvrStore && t.provide(lt, n.useSvrStore), n.triggers && t.provide(st, n.triggers), n.customComps && t.provide(ct, n.customComps), t.component("CreateView", mo), t.component("UpdateView", Ao), t.component("DetailView", zo), t.component("ListView", Yo);
|
|
2157
2182
|
}
|
|
2158
2183
|
};
|
|
2159
2184
|
export {
|
|
2160
|
-
|
|
2185
|
+
ta as default
|
|
2161
2186
|
};
|
|
2162
2187
|
//# sourceMappingURL=index.es.js.map
|