@ximatai/muyun-web-app 0.26.21 → 0.26.23

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.
Files changed (39) hide show
  1. package/dist/{BusinessActivityLogView-6L75GZVc.js → BusinessActivityLogView-IWGZiPLo.js} +2 -2
  2. package/dist/{BusinessLogListDrawer-C4iFnkE7.js → BusinessLogListDrawer-UCsg6psI.js} +85 -85
  3. package/dist/{CodeConfigurationView-D7sqbNCg.js → CodeConfigurationView-Calkazua.js} +532 -532
  4. package/dist/{ConfigurationTranslationView-ta82REbn.js → ConfigurationTranslationView-fZrlRAMy.js} +24 -24
  5. package/dist/{LoginAuditLogView-B_RQ9JIX.js → LoginAuditLogView-B6J7t__0.js} +2 -2
  6. package/dist/ModuleActionManagementView-BZ89Woex.js +755 -0
  7. package/dist/{ModuleGovernanceView-Cl6tkZ6M.js → ModuleGovernanceView-D8ONs78K.js} +1892 -1892
  8. package/dist/{RequestErrorLogView-BJDO3Scn.js → RequestErrorLogView-poMgx4_6.js} +2 -2
  9. package/dist/RoleDetailWorkspaceView-6Bs1eKbm.js +1435 -0
  10. package/dist/{RuntimeLogView-jP9ceuJD.js → RuntimeLogView-Co-Z86bt.js} +41 -41
  11. package/dist/WorkflowAdministrationView-D7QpRHDp.js +650 -0
  12. package/dist/{WorkflowConfigurationView-Dh6BKQm5.js → WorkflowConfigurationView-mSyL_-We.js} +32 -32
  13. package/dist/{WorkflowWorkbenchView-BvPNKbuV.js → WorkflowWorkbenchView-DBMh3ycN.js} +224 -224
  14. package/dist/{codeConfiguration-DhCBKbkc.js → codeConfiguration-D1zrxzoW.js} +44 -44
  15. package/dist/index.css +1 -1
  16. package/dist/index.js +524 -550
  17. package/dist/moduleMenuWorkspace-lIVrTaOB.js +626 -0
  18. package/dist/{platform-components-i2ONyZ8r.js → platform-components-D0T03KGl.js} +2815 -2913
  19. package/dist/{platform-workbench-DhaREttd.js → platform-workbench-CobObbuz.js} +2770 -2745
  20. package/dist/record-read.js +2 -0
  21. package/dist/recordReadEntry-CxDHM44F.js +152 -0
  22. package/dist/types/consumer/recordRead.d.ts +6 -0
  23. package/dist/types/dynamic-page-runtime/ModulePageBusinessSession.d.ts +4 -0
  24. package/dist/types/dynamic-page-runtime/ModulePageHostRuntime.vue.d.ts +8 -0
  25. package/dist/types/dynamic-page-runtime/ModulePageRecordContent.vue.d.ts +2 -0
  26. package/dist/types/dynamic-page-runtime/ModuleRecordDetailActions.vue.d.ts +2 -0
  27. package/dist/types/dynamic-page-runtime/RecordFormSurface.vue.d.ts +2 -0
  28. package/dist/types/dynamic-page-runtime/useModulePageSession.d.ts +2 -0
  29. package/dist/types/platform-components/RecordFormFields.vue.d.ts +10 -8
  30. package/dist/types/platform-components/useBusinessCodeForm.d.ts +1 -0
  31. package/dist/types/platform-workbench/useAssistantConversation.d.ts +3 -0
  32. package/dist/types/web-contracts/operation.d.ts +2 -0
  33. package/dist/{useWorkflowConfigurationContext-B_NxZFyz.js → useWorkflowConfigurationContext-BkcNPU2H.js} +8 -8
  34. package/dist/{workspaceViews-MTwNg_aQ.js → workspaceViews-BtqO8rU0.js} +355 -355
  35. package/package.json +5 -1
  36. package/dist/ModuleActionManagementView-DtGF3NC_.js +0 -755
  37. package/dist/RoleDetailWorkspaceView-C0Ab3PEp.js +0 -1435
  38. package/dist/WorkflowAdministrationView-BmNJQYtq.js +0 -650
  39. package/dist/moduleMenuWorkspace-BbVmNKZn.js +0 -626
@@ -0,0 +1,650 @@
1
+ import { D as e, y as t } from "./platform-workbench-CobObbuz.js";
2
+ import { $a as n, An as r, Ar as i, Ht as a, Kr as ee, Kt as o, Mn as s, Mr as te, Ur as c, Ya as ne, _n as l, d as u, er as re, f as ie, fr as ae, gt as oe, it as se, ja as d, jr as ce, kn as le, m as ue, or as de, p as f, rr as fe, sn as p, ur as m } from "./platform-components-D0T03KGl.js";
3
+ import { Fragment as pe, computed as h, createBlock as g, createCommentVNode as _, createElementBlock as v, createElementVNode as y, createTextVNode as b, createVNode as x, defineComponent as S, openBlock as C, ref as w, renderList as me, toDisplayString as T, unref as E, watch as he, withCtx as D } from "vue";
4
+ //#region src/views/WorkflowAdministrationView.vue?vue&type=script&setup=true&lang.ts
5
+ var ge = { class: "workflow-admin" }, _e = { key: 1 }, ve = { class: "workflow-query-fields" }, ye = {
6
+ key: 0,
7
+ class: "workflow-field"
8
+ }, be = { class: "workflow-field" }, xe = {
9
+ key: 1,
10
+ class: "workflow-field"
11
+ }, Se = { class: "workflow-field" }, Ce = { class: "workflow-query-controls" }, we = { key: 2 }, Te = {
12
+ key: 1,
13
+ class: "workflow-empty-tasks"
14
+ }, Ee = { class: "workflow-map" }, De = { key: 0 }, Oe = { class: "workflow-field" }, O = /*#__PURE__*/ ae(/* @__PURE__ */ S({
15
+ name: "WorkflowAdministrationView",
16
+ __name: "WorkflowAdministrationView",
17
+ setup(ae) {
18
+ let S = ne();
19
+ function O(e) {
20
+ return ue(e, S);
21
+ }
22
+ let k = ee({ moduleAlias: "platform.workflow_admin" }), A = t(), j = w(), M = w(""), N = w(""), P = w("running"), F = w(1), I = w(!1), L = w(!1), R = w(""), z = w(""), B = w({}), V = h(() => Object.fromEntries(Object.entries(B.value).map(([e, t]) => [e, d(t.title, t.titleText, S)]))), H = h(() => j.value ? n(k.http, { "X-MuYun-Tenant-Id": j.value }) : k.http), ke = c({
23
+ http: k.http,
24
+ language: S,
25
+ moduleAlias: "iam.tenant",
26
+ runtimeAccess: "REFERENCE"
27
+ }), U = w([]), W = w([]), G = w(), K = w([]), q = w([]), J = w(), Y = w(""), X = w(), Z = h(() => ce(H.value)), Q = 0, Ae = 0;
28
+ e(async (e) => {
29
+ let t = new Set(e.changes.filter((e) => e.type === "configuration-translations-changed").map((e) => e.moduleAlias)), n = G.value, r = !L.value && U.value.some((e) => t.has(e.moduleAlias)), i = n && t.has(n.instance.moduleAlias), a = Object.keys(B.value).some((e) => t.has(e));
30
+ if (!r && !i && !a) return;
31
+ let ee = ++Ae, o = Q, s = L.value, c = J.value, ne = A?.value?.userId;
32
+ try {
33
+ let [e, t, l, u] = await Promise.all([
34
+ r ? Z.value.instances({
35
+ moduleAlias: M.value || void 0,
36
+ recordId: N.value || void 0,
37
+ instanceStatus: P.value,
38
+ page: {
39
+ pageNum: F.value,
40
+ pageSize: 30
41
+ }
42
+ }) : void 0,
43
+ i && c ? Z.value.bundle(c, s) : void 0,
44
+ i && c ? Z.value.events(c, s) : void 0,
45
+ a ? te(H.value).workbenchModules() : void 0
46
+ ]);
47
+ if (ee !== Ae || o !== Q || c !== J.value || s !== L.value || ne !== A?.value?.userId || (u && (B.value = Object.fromEntries(Object.entries(B.value).map(([e, t]) => {
48
+ let n = u.modules[e]?.titleText;
49
+ return [e, f(t.titleText, n) ? {
50
+ ...t,
51
+ titleText: n
52
+ } : t];
53
+ }))), e && (U.value = U.value.map((t) => {
54
+ let n = e.find((e) => e.instanceId === t.instanceId && e.workflowVersionId === t.workflowVersionId);
55
+ return {
56
+ ...t,
57
+ activeNodeLabels: t.activeNodeLabels?.map((e) => {
58
+ let t = n?.activeNodeLabels?.find((t) => t.nodeKey === e.nodeKey);
59
+ return f(e.titleText, t?.titleText) ? {
60
+ ...e,
61
+ titleText: t?.titleText
62
+ } : e;
63
+ })
64
+ };
65
+ })), !n || !t || G.value?.instance.id !== n.instance.id)) return;
66
+ G.value = ie(G.value, t), K.value = K.value.map((e) => {
67
+ let n = t.nodes.find((t) => t.id === e.nodeInstanceId && t.nodeKey === e.nodeKey);
68
+ return f(e.nodeTitleText, n?.nodeTitleText) ? {
69
+ ...e,
70
+ nodeTitleText: n?.nodeTitleText
71
+ } : e;
72
+ }), q.value = q.value.map((e) => {
73
+ let t = l?.find((t) => t.id === e.id);
74
+ return f(e.messageText, t?.messageText) ? {
75
+ ...e,
76
+ messageText: t?.messageText
77
+ } : e;
78
+ });
79
+ } catch (e) {
80
+ l(e, {
81
+ source: "workflow-text-resources",
82
+ phase: "load"
83
+ });
84
+ }
85
+ });
86
+ async function je() {
87
+ I.value || X.value && !await $() || await Me();
88
+ }
89
+ async function Me() {
90
+ let e = ++Q;
91
+ I.value = !0, R.value = "", J.value = void 0, G.value = void 0, K.value = [], q.value = [], X.value = void 0;
92
+ try {
93
+ if (L.value) {
94
+ if (!M.value.trim()) {
95
+ W.value = [];
96
+ return;
97
+ }
98
+ let t = await Z.value.history({
99
+ moduleAlias: M.value,
100
+ recordId: N.value || void 0,
101
+ page: {
102
+ pageNum: F.value,
103
+ pageSize: 30
104
+ }
105
+ });
106
+ e === Q && (W.value = t);
107
+ } else {
108
+ let t = await Z.value.instances({
109
+ moduleAlias: M.value || void 0,
110
+ recordId: N.value || void 0,
111
+ instanceStatus: P.value,
112
+ page: {
113
+ pageNum: F.value,
114
+ pageSize: 30
115
+ }
116
+ });
117
+ e === Q && (U.value = t);
118
+ }
119
+ } catch (t) {
120
+ if (e !== Q) return;
121
+ R.value = S.t("platform.screen.WorkflowAdministrationView.load-failed", "流程加载失败,请重试。"), U.value = [], W.value = [], l(t, {
122
+ source: "workflow-admin",
123
+ phase: "load"
124
+ });
125
+ } finally {
126
+ e === Q && (I.value = !1);
127
+ }
128
+ }
129
+ async function Ne(e) {
130
+ if (I.value || X.value && !await $()) return;
131
+ let t = ++Q;
132
+ I.value = !0, J.value = e, X.value = void 0, G.value = void 0, K.value = [], q.value = [], z.value = "";
133
+ try {
134
+ let [n, r] = await Promise.all([Z.value.bundle(e, L.value), Z.value.events(e, L.value)]), i = L.value || n.instance?.instanceStatus !== "running" ? [] : await Z.value.activeTasks(e);
135
+ if (t !== Q) return;
136
+ G.value = n, q.value = r, K.value = i;
137
+ } catch (e) {
138
+ if (t !== Q) return;
139
+ z.value = S.t("platform.screen.WorkflowAdministrationView.detail-load-failed", "流程详情加载失败,请重试。"), l(e, {
140
+ source: "workflow-admin",
141
+ phase: "load"
142
+ });
143
+ } finally {
144
+ t === Q && (I.value = !1);
145
+ }
146
+ }
147
+ async function Pe(e = !1) {
148
+ I.value || X.value && !await $() || (X.value = void 0, e && (M.value = "", N.value = "", P.value = "running"), F.value === 1 ? await Me() : F.value = 1);
149
+ }
150
+ async function Fe() {
151
+ if (!I.value && X.value && J.value && Y.value.trim()) {
152
+ I.value = !0;
153
+ try {
154
+ if (!await r({
155
+ title: S.t("platform.screen.WorkflowAdministrationView.confirm-action-title", "确认{operation}?", { operation: Ve(X.value.code) }),
156
+ content: S.t("platform.screen.WorkflowAdministrationView.confirm-action-content", "{impact} 原因:{reason}", {
157
+ impact: He(X.value.code),
158
+ reason: Y.value.trim()
159
+ }),
160
+ danger: !0,
161
+ okText: S.t("platform.screen.WorkflowAdministrationView.confirm-execute", "确认执行")
162
+ }, S)) return;
163
+ await Z.value.execute(J.value, X.value.code, Y.value, X.value.taskId), le(S.t("platform.screen.WorkflowAdministrationView.operation-completed", "运维操作已完成并记录审计")), await Me();
164
+ } catch (e) {
165
+ l(e, {
166
+ source: "workflow-admin",
167
+ phase: "action"
168
+ });
169
+ } finally {
170
+ I.value = !1;
171
+ }
172
+ }
173
+ }
174
+ he(j, async (e, t, n) => {
175
+ let r = !0;
176
+ n(() => {
177
+ r = !1;
178
+ }), B.value = {}, M.value = "", N.value = "", F.value = 1;
179
+ try {
180
+ let e = await te(H.value).workbenchModules();
181
+ r && (B.value = e.modules ?? {});
182
+ } catch (e) {
183
+ r && l(e, {
184
+ source: "workflow-module-titles",
185
+ phase: "load"
186
+ });
187
+ }
188
+ }, { immediate: !0 }), he([
189
+ j,
190
+ L,
191
+ F
192
+ ], () => void je(), { immediate: !0 });
193
+ let Ie = h(() => L.value ? W.value.map((e) => ({
194
+ ...e,
195
+ id: e.id,
196
+ moduleTitle: V.value[e.moduleAlias] ?? e.moduleAlias,
197
+ status: O(e.instanceStatus),
198
+ active: O("archived"),
199
+ assignees: "—",
200
+ starter: e.startedByTitle ?? "—",
201
+ started: Be(e.startedAt)
202
+ })) : U.value.map((e) => ({
203
+ ...e,
204
+ id: e.instanceId,
205
+ moduleTitle: V.value[e.moduleAlias] ?? e.moduleAlias,
206
+ status: O(e.instanceStatus),
207
+ approval: O(e.approvalStatus),
208
+ active: e.activeNodeLabels?.length ? e.activeNodeLabels.map((e) => d(e.title, e.titleText, S)).join("、") : e.activeNodeTitles.join("、"),
209
+ assignees: e.currentAssigneeTitles.join("、"),
210
+ starter: e.startedByTitle,
211
+ urgency: O(e.overtimeStatus)
212
+ }))), Le = h(() => [
213
+ {
214
+ key: "moduleTitle",
215
+ title: S.t("platform.screen.WorkflowAdministrationView.business-module", "业务模块"),
216
+ dataIndex: "moduleTitle",
217
+ width: 160
218
+ },
219
+ {
220
+ key: "versionNo",
221
+ title: S.t("platform.screen.WorkflowAdministrationView.workflow-version", "流程版本"),
222
+ dataIndex: "versionNo",
223
+ width: 100
224
+ },
225
+ {
226
+ key: "status",
227
+ title: S.t("platform.screen.WorkflowAdministrationView.status", "状态"),
228
+ dataIndex: "status",
229
+ width: 100
230
+ },
231
+ {
232
+ key: "active",
233
+ title: S.t("platform.screen.WorkflowAdministrationView.current-node", "当前节点"),
234
+ dataIndex: "active",
235
+ width: 180
236
+ },
237
+ {
238
+ key: "assignees",
239
+ title: S.t("platform.screen.WorkflowAdministrationView.processors", "办理人"),
240
+ dataIndex: "assignees",
241
+ width: 180
242
+ },
243
+ {
244
+ key: "starter",
245
+ title: S.t("platform.screen.WorkflowAdministrationView.submitter", "发起人"),
246
+ dataIndex: "starter",
247
+ width: 110
248
+ },
249
+ {
250
+ key: "recordId",
251
+ title: S.t("platform.screen.WorkflowAdministrationView.record-id", "业务记录标识"),
252
+ dataIndex: "recordId",
253
+ width: 220
254
+ }
255
+ ]), Re = h(() => [{
256
+ key: "nodeTitle",
257
+ title: S.t("platform.screen.WorkflowAdministrationView.node", "节点"),
258
+ dataIndex: "nodeTitle"
259
+ }, {
260
+ key: "assigneeTitle",
261
+ title: S.t("platform.screen.WorkflowAdministrationView.processors", "办理人"),
262
+ dataIndex: "assigneeTitle"
263
+ }]), ze = h(() => [...G.value?.instance?.instanceStatus === "running" ? [{
264
+ key: "forceTerminate",
265
+ title: S.t("platform.screen.WorkflowAdministrationView.terminate", "终止流程"),
266
+ danger: !0
267
+ }] : [], {
268
+ key: "reset",
269
+ title: S.t("platform.screen.WorkflowAdministrationView.reset-approval", "重置业务审批"),
270
+ danger: !0
271
+ }]);
272
+ function Be(e) {
273
+ return e ? new Date(e).toLocaleString("zh-CN", { hour12: !1 }) : "—";
274
+ }
275
+ function Ve(e) {
276
+ return e === "forceApprove" ? S.t("platform.screen.WorkflowAdministrationView.force-process", "强制办理") : e === "reset" ? S.t("platform.screen.WorkflowAdministrationView.reset-approval", "重置业务审批") : S.t("platform.screen.WorkflowAdministrationView.terminate", "终止流程");
277
+ }
278
+ function He(e) {
279
+ return e === "forceApprove" ? S.t("platform.screen.WorkflowAdministrationView.force-impact", "将替代原办理人推进当前任务,可能触发后续业务动作。") : e === "reset" ? S.t("platform.screen.WorkflowAdministrationView.reset-impact", "将归档当前流程并清除业务审批状态,允许重新发起。") : S.t("platform.screen.WorkflowAdministrationView.terminate-impact", "将终止当前流程并取消未完成任务。");
280
+ }
281
+ function Ue(e, t) {
282
+ X.value = {
283
+ code: e,
284
+ taskId: t
285
+ }, Y.value = "";
286
+ }
287
+ i(() => S.t("platform.screen.WorkflowAdministrationView.workflow-administration", "工作流运维"), () => !!(X.value && Y.value.trim()), () => I.value);
288
+ async function $() {
289
+ if (I.value) return !1;
290
+ let e = X.value, t = Q;
291
+ return (!Y.value.trim() || await r({
292
+ title: S.t("platform.screen.WorkflowAdministrationView.discard-operation", "放弃未执行的运维操作?"),
293
+ danger: !0,
294
+ okText: S.t("platform.screen.WorkflowAdministrationView.discard", "放弃填写")
295
+ }, S)) && !I.value && t === Q && e === X.value;
296
+ }
297
+ async function We() {
298
+ return !X.value && !I.value;
299
+ }
300
+ function Ge(e) {
301
+ return e.title ?? e.id ?? "";
302
+ }
303
+ return (e, t) => (C(), v("section", ge, [
304
+ x(E(oe), {
305
+ tabs: [{
306
+ key: "current",
307
+ title: E(S).t("platform.screen.WorkflowAdministrationView.current-instances", "当前实例")
308
+ }, {
309
+ key: "history",
310
+ title: E(S).t("platform.screen.WorkflowAdministrationView.history", "历史归档")
311
+ }],
312
+ "active-key": L.value ? "history" : "current",
313
+ label: E(S).t("platform.screen.WorkflowAdministrationView.workflow-administration-scope", "工作流运维范围"),
314
+ disabled: I.value || !!X.value,
315
+ "onUpdate:activeKey": t[0] ||= (e) => {
316
+ L.value = e === "history", F.value = 1;
317
+ }
318
+ }, null, 8, [
319
+ "tabs",
320
+ "active-key",
321
+ "label",
322
+ "disabled"
323
+ ]),
324
+ R.value ? (C(), g(E(s), {
325
+ key: 0,
326
+ title: E(S).t("platform.screen.WorkflowAdministrationView.unable-to-load-workflows", "无法加载流程"),
327
+ message: R.value
328
+ }, null, 8, ["title", "message"])) : _("v-if", !0),
329
+ L.value && !M.value ? (C(), v("p", _e, T(E(S).t("platform.screen.WorkflowAdministrationView.select-a-business-module-to-view-archived", "选择业务模块后查看归档流程。")), 1)) : _("v-if", !0),
330
+ x(E(o), {
331
+ title: E(S).t("platform.screen.WorkflowAdministrationView.workflow-administration", "工作流运维"),
332
+ subtitle: E(S).t("platform.screen.WorkflowAdministrationView.a-reason-is-required-for-exception-handling-all-operations-are", "异常处理需要明确原因,所有操作记录审计"),
333
+ columns: Le.value,
334
+ rows: Ie.value,
335
+ "clickable-rows": "",
336
+ "selected-row-key": J.value,
337
+ pageable: !0,
338
+ "total-known": !1,
339
+ total: (F.value - 1) * 30 + Ie.value.length,
340
+ pages: F.value + +(Ie.value.length === 30),
341
+ "page-num": F.value,
342
+ "page-size": 30,
343
+ "page-size-options": [30],
344
+ "pagination-disabled": I.value || !!X.value,
345
+ onRowClick: t[7] ||= (e) => Ne(String(e.id)),
346
+ onPageChange: t[8] ||= (e) => F.value = e
347
+ }, {
348
+ operations: D(() => [x(E(m), {
349
+ loading: I.value,
350
+ onClick: je
351
+ }, {
352
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.refresh", "刷新")), 1)]),
353
+ _: 1
354
+ }, 8, ["loading"])]),
355
+ conditions: D(() => [y("div", ve, [
356
+ E(A)?.system ? (C(), v("label", ye, [x(E(p), null, {
357
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.business-tenant", "业务租户")), 1)]),
358
+ _: 1
359
+ }), x(E(se), {
360
+ value: j.value,
361
+ "onUpdate:value": t[1] ||= (e) => j.value = e,
362
+ context: E(ke),
363
+ disabled: I.value || !!X.value,
364
+ "title-of": Ge,
365
+ mode: "list"
366
+ }, null, 8, [
367
+ "value",
368
+ "context",
369
+ "disabled"
370
+ ])])) : _("v-if", !0),
371
+ y("label", be, [x(E(p), { required: L.value }, {
372
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.business-module", "业务模块")), 1)]),
373
+ _: 1
374
+ }, 8, ["required"]), x(E(de), {
375
+ value: M.value,
376
+ "onUpdate:value": t[2] ||= (e) => M.value = e,
377
+ disabled: I.value || !!X.value,
378
+ "show-search": "",
379
+ options: Object.entries(V.value).map(([e, t]) => ({
380
+ value: e,
381
+ label: t
382
+ })),
383
+ placeholder: L.value ? E(S).t("platform.screen.WorkflowAdministrationView.select-a-business-module", "请选择业务模块") : E(S).t("platform.screen.WorkflowWorkbenchView.all-business-modules", "全部业务模块")
384
+ }, null, 8, [
385
+ "value",
386
+ "disabled",
387
+ "options",
388
+ "placeholder"
389
+ ])]),
390
+ L.value ? _("v-if", !0) : (C(), v("label", xe, [x(E(p), null, {
391
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.workflow-status", "流程状态")), 1)]),
392
+ _: 1
393
+ }), x(E(de), {
394
+ value: P.value,
395
+ "onUpdate:value": t[3] ||= (e) => P.value = e,
396
+ disabled: I.value || !!X.value,
397
+ options: [
398
+ {
399
+ value: "running",
400
+ label: E(S).t("platform.workflow.running", "进行中")
401
+ },
402
+ {
403
+ value: "completed",
404
+ label: E(S).t("platform.workflow.completed", "已完成")
405
+ },
406
+ {
407
+ value: "rejected",
408
+ label: E(S).t("platform.workflow.rejected", "已驳回")
409
+ },
410
+ {
411
+ value: "revoked",
412
+ label: E(S).t("platform.workflow.revoked", "已撤回")
413
+ },
414
+ {
415
+ value: "terminated",
416
+ label: E(S).t("platform.workflow.terminated", "已终止")
417
+ }
418
+ ]
419
+ }, null, 8, [
420
+ "value",
421
+ "disabled",
422
+ "options"
423
+ ])])),
424
+ y("label", Se, [b(T(E(S).t("platform.screen.WorkflowAdministrationView.business-record-identifier", "业务记录标识")), 1), x(E(fe), {
425
+ value: N.value,
426
+ "onUpdate:value": t[4] ||= (e) => N.value = e,
427
+ disabled: I.value || !!X.value,
428
+ placeholder: E(S).t("platform.screen.WorkflowAdministrationView.locate-a-specific-business-issue", "精确定位异常业务")
429
+ }, null, 8, [
430
+ "value",
431
+ "disabled",
432
+ "placeholder"
433
+ ])]),
434
+ y("div", Ce, [x(E(m), {
435
+ disabled: I.value || L.value && !M.value,
436
+ onClick: t[5] ||= (e) => Pe()
437
+ }, {
438
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.search", "查询")), 1)]),
439
+ _: 1
440
+ }, 8, ["disabled"]), x(E(m), {
441
+ disabled: I.value,
442
+ onClick: t[6] ||= (e) => Pe(!0)
443
+ }, {
444
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.reset", "重置")), 1)]),
445
+ _: 1
446
+ }, 8, ["disabled"])])
447
+ ])]),
448
+ _: 1
449
+ }, 8, [
450
+ "title",
451
+ "subtitle",
452
+ "columns",
453
+ "rows",
454
+ "selected-row-key",
455
+ "total",
456
+ "pages",
457
+ "page-num",
458
+ "pagination-disabled"
459
+ ]),
460
+ x(E(a), {
461
+ open: !!J.value,
462
+ title: E(S).t("platform.screen.WorkflowAdministrationView.workflow-administration-details", "流程运维详情"),
463
+ subtitle: G.value ? E(S).t("platform.screen.WorkflowAdministrationView.instance-title", "{module} · {status} · 版本 {version}", {
464
+ module: V.value[G.value.instance.moduleAlias] ?? G.value.instance.moduleAlias,
465
+ status: O(G.value.instance.instanceStatus),
466
+ version: G.value.instance.versionNo
467
+ }) : void 0,
468
+ width: "extraWide",
469
+ "before-close": We,
470
+ onClose: t[11] ||= (e) => J.value = void 0
471
+ }, {
472
+ operation: D(() => [G.value && !L.value ? (C(!0), v(pe, { key: 0 }, me(ze.value, (e) => (C(), g(E(m), {
473
+ key: e.key,
474
+ danger: e.danger,
475
+ disabled: I.value || !!X.value,
476
+ onClick: (t) => Ue(e.key)
477
+ }, {
478
+ default: D(() => [b(T(e.title), 1)]),
479
+ _: 2
480
+ }, 1032, [
481
+ "danger",
482
+ "disabled",
483
+ "onClick"
484
+ ]))), 128)) : _("v-if", !0), x(E(m), {
485
+ disabled: I.value || !!X.value,
486
+ onClick: t[10] ||= (e) => J.value = void 0
487
+ }, {
488
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.close-details", "关闭详情")), 1)]),
489
+ _: 1
490
+ }, 8, ["disabled"])]),
491
+ default: D(() => [
492
+ z.value ? (C(), g(E(s), {
493
+ key: 0,
494
+ title: E(S).t("platform.screen.WorkflowAdministrationView.unable-to-load-details", "无法加载详情"),
495
+ message: z.value
496
+ }, null, 8, ["title", "message"])) : _("v-if", !0),
497
+ z.value ? (C(), g(E(m), {
498
+ key: 1,
499
+ onClick: t[9] ||= (e) => Ne(J.value)
500
+ }, {
501
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.retry", "重试")), 1)]),
502
+ _: 1
503
+ })) : _("v-if", !0),
504
+ I.value ? (C(), v("p", we, T(E(S).t("platform.screen.WorkflowAdministrationView.loading", "正在加载…")), 1)) : _("v-if", !0),
505
+ G.value ? (C(), v(pe, { key: 3 }, [
506
+ !L.value && K.value.length ? (C(), g(E(o), {
507
+ key: 0,
508
+ embedded: "",
509
+ title: E(S).t("platform.screen.WorkflowAdministrationView.current-pending-tasks", "当前待办"),
510
+ columns: Re.value,
511
+ rows: K.value.map((e) => ({
512
+ ...e,
513
+ id: e.taskId,
514
+ nodeTitle: E(d)(e.nodeTitle, e.nodeTitleText, E(S))
515
+ })),
516
+ pageable: !1,
517
+ "fill-height": !1,
518
+ "show-action-column": !0
519
+ }, {
520
+ rowActions: D(({ record: e }) => [e.canForceApprove ? (C(), g(E(m), {
521
+ key: 0,
522
+ danger: "",
523
+ disabled: I.value || !!X.value,
524
+ onClick: (t) => Ue("forceApprove", String(e.taskId))
525
+ }, {
526
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.force-processing", "强制办理")), 1)]),
527
+ _: 1
528
+ }, 8, ["disabled", "onClick"])) : _("v-if", !0)]),
529
+ _: 1
530
+ }, 8, [
531
+ "title",
532
+ "columns",
533
+ "rows"
534
+ ])) : _("v-if", !0),
535
+ !L.value && !K.value.length ? (C(), v("p", Te, T(E(S).t("platform.screen.WorkflowAdministrationView.there-are-no-pending-tasks", "当前没有待办任务")), 1)) : _("v-if", !0),
536
+ y("details", Ee, [y("summary", null, T(E(S).t("platform.screen.WorkflowAdministrationView.view-workflow-diagram", "查看流程图")), 1), x(E(u), {
537
+ presentation: "detail",
538
+ nodes: G.value.nodes,
539
+ routes: G.value.routes,
540
+ "layout-json": G.value.layoutJson,
541
+ "semantic-json": G.value.semanticJson
542
+ }, null, 8, [
543
+ "nodes",
544
+ "routes",
545
+ "layout-json",
546
+ "semantic-json"
547
+ ])]),
548
+ x(E(o), {
549
+ embedded: "",
550
+ title: E(S).t("platform.screen.WorkflowAdministrationView.administration-audit", "运维审计"),
551
+ columns: [
552
+ {
553
+ key: "occurred",
554
+ title: E(S).t("platform.screen.WorkflowAdministrationView.time", "时间"),
555
+ dataIndex: "occurred",
556
+ width: 170
557
+ },
558
+ {
559
+ key: "action",
560
+ title: E(S).t("platform.screen.WorkflowAdministrationView.operation", "操作"),
561
+ dataIndex: "action",
562
+ width: 120
563
+ },
564
+ {
565
+ key: "operatorTitle",
566
+ title: E(S).t("platform.screen.WorkflowAdministrationView.operator", "操作人"),
567
+ dataIndex: "operatorTitle",
568
+ width: 110
569
+ },
570
+ {
571
+ key: "message",
572
+ title: E(S).t("platform.screen.WorkflowAdministrationView.audit-reason", "原因与审计"),
573
+ dataIndex: "message"
574
+ }
575
+ ],
576
+ rows: q.value.map((e) => ({
577
+ ...e,
578
+ action: O(e.actionCode ?? e.eventType),
579
+ message: E(d)(e.message ?? "", e.messageText, E(S)),
580
+ occurred: Be(e.occurredAt)
581
+ })),
582
+ "fill-height": !1,
583
+ pageable: !1
584
+ }, null, 8, [
585
+ "title",
586
+ "columns",
587
+ "rows"
588
+ ])
589
+ ], 64)) : _("v-if", !0)
590
+ ]),
591
+ _: 1
592
+ }, 8, [
593
+ "open",
594
+ "title",
595
+ "subtitle"
596
+ ]),
597
+ x(E(a), {
598
+ open: !!X.value,
599
+ title: Ve(X.value?.code ?? ""),
600
+ "before-close": $,
601
+ onClose: t[14] ||= (e) => X.value = void 0
602
+ }, {
603
+ operation: D(() => [x(E(m), {
604
+ type: "primary",
605
+ danger: "",
606
+ loading: I.value,
607
+ disabled: !Y.value.trim(),
608
+ onClick: Fe
609
+ }, {
610
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.confirm-operation", "确认操作")), 1)]),
611
+ _: 1
612
+ }, 8, ["loading", "disabled"]), x(E(m), {
613
+ disabled: I.value,
614
+ onClick: t[13] ||= (e) => {
615
+ $().then((e) => {
616
+ e && (X.value = void 0);
617
+ });
618
+ }
619
+ }, {
620
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.cancel", "取消")), 1)]),
621
+ _: 1
622
+ }, 8, ["disabled"])]),
623
+ default: D(() => [
624
+ G.value ? (C(), v("p", De, T(E(S).t("platform.screen.WorkflowAdministrationView.operation-record", "业务:{module} · 记录 {record}", {
625
+ module: V.value[G.value.instance.moduleAlias] ?? G.value.instance.moduleAlias,
626
+ record: G.value.instance.recordId
627
+ })), 1)) : _("v-if", !0),
628
+ y("p", null, T(He(X.value?.code ?? "")), 1),
629
+ y("p", null, T(E(S).t("platform.screen.WorkflowAdministrationView.operation-version-warning", "当前流程版本:{version}。操作成功后不可直接撤销,并记录操作人、时间和原因。", { version: G.value?.instance.versionNo ?? E(S).t("platform.screen.WorkflowAdministrationView.unknown-version", "未知") })), 1),
630
+ y("label", Oe, [x(E(p), { required: "" }, {
631
+ default: D(() => [b(T(E(S).t("platform.screen.WorkflowAdministrationView.administration-reason", "运维原因")), 1)]),
632
+ _: 1
633
+ }), x(E(re), {
634
+ value: Y.value,
635
+ "onUpdate:value": t[12] ||= (e) => Y.value = e,
636
+ disabled: I.value,
637
+ "aria-label": E(S).t("platform.screen.WorkflowAdministrationView.administration-reason", "运维原因")
638
+ }, null, 8, [
639
+ "value",
640
+ "disabled",
641
+ "aria-label"
642
+ ])])
643
+ ]),
644
+ _: 1
645
+ }, 8, ["open", "title"])
646
+ ]));
647
+ }
648
+ }), [["__scopeId", "data-v-0ecf9f7e"]]);
649
+ //#endregion
650
+ export { O as default };