@ximatai/muyun-web-app 0.26.18 → 0.26.19
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/{BusinessActivityLogView-CNW817Sf.js → BusinessActivityLogView-DudCmeKP.js} +2 -2
- package/dist/BusinessLogListDrawer-CVUvUG48.js +864 -0
- package/dist/{CodeConfigurationView-DU8tjPMt.js → CodeConfigurationView-ZjVgaZkD.js} +450 -450
- package/dist/{ConfigurationTranslationView-CbBt5s1q.js → ConfigurationTranslationView-Dl757QMl.js} +38 -38
- package/dist/{LoginAuditLogView-CZF1Jfq_.js → LoginAuditLogView-Cj3PMvN5.js} +2 -2
- package/dist/ModuleActionManagementView-BuhQrVA3.js +755 -0
- package/dist/{ModuleGovernanceView-CcwGyO3x.js → ModuleGovernanceView-C3RxdgQN.js} +2243 -2243
- package/dist/{RequestErrorLogView-DpudZrC2.js → RequestErrorLogView-tmjMOeLE.js} +2 -2
- package/dist/{RoleDetailWorkspaceView-DNMGsAJC.js → RoleDetailWorkspaceView-OhpBChaT.js} +518 -518
- package/dist/{RuntimeLogView-444BL_xs.js → RuntimeLogView-BkkgHcF0.js} +64 -64
- package/dist/{WorkflowAdministrationView-C-VIjvwB.js → WorkflowAdministrationView-DOhA_5-M.js} +139 -139
- package/dist/WorkflowConfigurationView-Bnjdrkdx.js +980 -0
- package/dist/{WorkflowWorkbenchView-Gr02dbBc.js → WorkflowWorkbenchView-Cf6yiofx.js} +222 -222
- package/dist/{codeConfiguration-ChJ6ktRR.js → codeConfiguration-DERwCY-U.js} +44 -44
- package/dist/index.css +1 -1
- package/dist/index.js +421 -430
- package/dist/moduleMenuWorkspace-DPmYGkS_.js +626 -0
- package/dist/platform-components-wRXbnwMr.js +30434 -0
- package/dist/{platform-workbench-BhZPARiH.js → platform-workbench-Cm_0kmTT.js} +5169 -5149
- package/dist/types/app/executeBusinessNotificationRecordAction.d.ts +7 -0
- package/dist/types/dynamic-page-runtime/composables/useModulePageDetailExtensionRuntime.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/modulePageEnhancementState.d.ts +5 -0
- package/dist/types/dynamic-page-runtime/modulePageEnhancements.d.ts +4 -0
- package/dist/types/platform-admin-runtime/workflow/ModuleWorkflowDrawer.vue.d.ts +7 -0
- package/dist/types/platform-components/BusinessNotificationPanel.vue.d.ts +5 -3
- package/dist/types/platform-components/FormulaExpressionEditor.vue.d.ts +5 -0
- package/dist/types/platform-components/RecordAdaptiveDetailPanel.vue.d.ts +28 -0
- package/dist/types/platform-components/RecordQueryListSurface.vue.d.ts +4 -0
- package/dist/types/platform-components/WorkflowBusinessTaskEditor.vue.d.ts +2 -0
- package/dist/types/platform-components/WorkflowDesignProperties.vue.d.ts +2 -6
- package/dist/types/platform-components/WorkflowDiagram.vue.d.ts +32 -1
- package/dist/types/platform-components/formulaExpressionTokens.d.ts +2 -0
- package/dist/types/platform-components/formulaExpressionTools.d.ts +6 -0
- package/dist/types/platform-components/index.d.ts +3 -0
- package/dist/types/platform-components/useWorkflowDesignHistory.d.ts +14 -0
- package/dist/types/platform-components/useWorkspaceDetailSurface.d.ts +3 -0
- package/dist/types/platform-components/workflowDesignClipboard.d.ts +7 -0
- package/dist/types/platform-components/workflowPresentation.d.ts +4 -0
- package/dist/types/views/WorkflowConfigurationView.vue.d.ts +1 -0
- package/dist/types/views/WorkflowDefinitionSettings.vue.d.ts +35 -0
- package/dist/types/views/WorkflowSelectionFields.vue.d.ts +2 -4
- package/dist/types/views/useWorkflowConfigurationContext.d.ts +49 -0
- package/dist/types/views/workflowConfigurationWorkspaceView.d.ts +2 -0
- package/dist/types/vue-ui-antdv/components/UiIcon.vue.d.ts +1 -1
- package/dist/types/vue-ui-antdv/components/UiRadioGroup.vue.d.ts +4 -0
- package/dist/types/vue-ui-antdv/components/UiSidePanel.vue.d.ts +5 -0
- package/dist/types/vue-ui-antdv/index.d.ts +1 -0
- package/dist/types/vue-ui-antdv/overlayLayers.d.ts +5 -0
- package/dist/types/vue-ui-antdv/types.d.ts +2 -0
- package/dist/types/web-contracts/index.d.ts +4 -0
- package/dist/types/web-contracts/workflow.d.ts +16 -8
- package/dist/types/web-core/businessNotifications.d.ts +3 -1
- package/dist/types/web-core/workflow.d.ts +13 -1
- package/dist/useWorkflowConfigurationContext-BE_UjKgk.js +66 -0
- package/dist/{workspaceViews-DeBqozVb.js → workspaceViews-D37OpJ7g.js} +1516 -936
- package/package.json +1 -1
- package/dist/BusinessLogListDrawer-YiJxOlnD.js +0 -864
- package/dist/ModuleActionManagementView-CaiXH1l_.js +0 -755
- package/dist/WorkflowConfigurationView-DLFY2x7V.js +0 -1110
- package/dist/moduleMenuWorkspace-B8DKwC3L.js +0 -626
- package/dist/platform-components-5AE0j2_3.js +0 -29879
|
@@ -0,0 +1,864 @@
|
|
|
1
|
+
import { A as e, Cn as t, En as n, Ft as r, Ha as i, Ln as a, Mn as o, Ra as s, Sn as c, Tn as l, Va as u, Xn as ee, aa as te, ar as d, ga as ne, gn as f, ia as re, j as p, nr as m, q as h, ra as g, un as _, xn as v, ya as ie, zr as ae } from "./platform-components-wRXbnwMr.js";
|
|
2
|
+
import { Fragment as y, computed as b, createBlock as x, createCommentVNode as S, createElementBlock as C, createElementVNode as w, createTextVNode as T, createVNode as E, defineComponent as D, normalizeClass as O, openBlock as k, ref as A, renderList as j, shallowRef as M, toDisplayString as N, unref as P, withCtx as F } from "vue";
|
|
3
|
+
//#region src/views/businessLogClient.ts
|
|
4
|
+
var I = {
|
|
5
|
+
activity: "/platform.business_activity_log",
|
|
6
|
+
"request-error": "/platform.request_error_log",
|
|
7
|
+
login: "/iam.login_audit_log"
|
|
8
|
+
};
|
|
9
|
+
function oe(e, t) {
|
|
10
|
+
let n = I[t];
|
|
11
|
+
return {
|
|
12
|
+
async detail(t) {
|
|
13
|
+
return V(await e.request({ path: `${n}/${encodeURIComponent(t)}` }));
|
|
14
|
+
},
|
|
15
|
+
async operatorCandidates(t) {
|
|
16
|
+
return L(await e.request({
|
|
17
|
+
method: "POST",
|
|
18
|
+
path: `${n}/operator-candidates/query`,
|
|
19
|
+
body: {
|
|
20
|
+
keyword: t.keyword,
|
|
21
|
+
selectedIds: t.selectedIds,
|
|
22
|
+
tenantId: t.tenantId,
|
|
23
|
+
organizationId: t.organizationId,
|
|
24
|
+
departmentId: t.departmentId,
|
|
25
|
+
page: {
|
|
26
|
+
pageNum: t.pageNum ?? 1,
|
|
27
|
+
pageSize: t.pageSize ?? 20
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}));
|
|
31
|
+
},
|
|
32
|
+
...t === "activity" ? {
|
|
33
|
+
actionStatistics: async (t) => U(await e.request({
|
|
34
|
+
method: "POST",
|
|
35
|
+
path: `${n}/statistics/actions`,
|
|
36
|
+
body: t
|
|
37
|
+
})),
|
|
38
|
+
pageAccessStatistics: async (t) => U(await e.request({
|
|
39
|
+
method: "POST",
|
|
40
|
+
path: `${n}/statistics/page-access`,
|
|
41
|
+
body: t
|
|
42
|
+
}))
|
|
43
|
+
} : {},
|
|
44
|
+
...t === "request-error" ? { diagnostic: async (t) => {
|
|
45
|
+
let r = await e.request({ path: `${n}/${encodeURIComponent(t)}/diagnostic` });
|
|
46
|
+
return q(q(r).diagnostic ?? r);
|
|
47
|
+
} } : {}
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
function L(e) {
|
|
51
|
+
let t = q(e);
|
|
52
|
+
return {
|
|
53
|
+
records: B(t.records),
|
|
54
|
+
selectedRecords: B(t.selectedRecords),
|
|
55
|
+
total: Y(t.total),
|
|
56
|
+
navigation: R(t.navigation)
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
function R(e) {
|
|
60
|
+
let t = q(e);
|
|
61
|
+
if (Object.keys(t).length) return {
|
|
62
|
+
showTenantNavigation: X(t.showTenantNavigation) === !0,
|
|
63
|
+
tenants: z(t.tenants),
|
|
64
|
+
organizations: z(t.organizations),
|
|
65
|
+
departments: z(t.departments)
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
function z(e) {
|
|
69
|
+
return Array.isArray(e) ? e.flatMap((e) => {
|
|
70
|
+
let t = q(e), n = J(t.id);
|
|
71
|
+
return n ? [{
|
|
72
|
+
id: n,
|
|
73
|
+
title: J(t.title) ?? n,
|
|
74
|
+
tenantId: J(t.tenantId),
|
|
75
|
+
organizationId: J(t.organizationId)
|
|
76
|
+
}] : [];
|
|
77
|
+
}) : [];
|
|
78
|
+
}
|
|
79
|
+
function B(e) {
|
|
80
|
+
if (!Array.isArray(e)) return [];
|
|
81
|
+
let t = [];
|
|
82
|
+
for (let n of e) {
|
|
83
|
+
let e = q(n), r = J(e.id);
|
|
84
|
+
if (!r) continue;
|
|
85
|
+
let i = {
|
|
86
|
+
id: r,
|
|
87
|
+
title: J(e.title) ?? r
|
|
88
|
+
};
|
|
89
|
+
[
|
|
90
|
+
"account",
|
|
91
|
+
"employeeName",
|
|
92
|
+
"organizationId",
|
|
93
|
+
"organizationName",
|
|
94
|
+
"departmentId",
|
|
95
|
+
"departmentName"
|
|
96
|
+
].forEach((t) => {
|
|
97
|
+
let n = J(e[t]);
|
|
98
|
+
n && (i[t] = n);
|
|
99
|
+
}), t.push(i);
|
|
100
|
+
}
|
|
101
|
+
return t;
|
|
102
|
+
}
|
|
103
|
+
function V(e) {
|
|
104
|
+
let t = q(e), n = q(t.event ?? t.record ?? e);
|
|
105
|
+
return {
|
|
106
|
+
...n,
|
|
107
|
+
eventId: J(n.eventId ?? n.id) ?? "",
|
|
108
|
+
eventType: J(n.eventType ?? n.type) ?? "",
|
|
109
|
+
occurredAt: J(n.occurredAt),
|
|
110
|
+
capturedAt: J(n.capturedAt),
|
|
111
|
+
traceId: J(n.traceId),
|
|
112
|
+
tenantId: J(n.tenantId),
|
|
113
|
+
operatorId: J(n.operatorId),
|
|
114
|
+
operatorOrganizationId: J(n.operatorOrganizationId),
|
|
115
|
+
operatorIdentity: K(n),
|
|
116
|
+
moduleAlias: J(n.moduleAlias),
|
|
117
|
+
actionCode: J(n.actionCode),
|
|
118
|
+
entityAlias: J(n.entityAlias ?? q(n.details).entityAlias),
|
|
119
|
+
recordId: J(n.recordId ?? q(n.details).recordId),
|
|
120
|
+
mutationSource: J(n.mutationSource ?? q(n.details).mutationSource),
|
|
121
|
+
outcome: J(n.outcome ?? n.result ?? q(n.details).outcome),
|
|
122
|
+
loginAccount: H(n, q(n.details)),
|
|
123
|
+
summary: W(n, q(n.details)),
|
|
124
|
+
details: ce(n.details)
|
|
125
|
+
};
|
|
126
|
+
}
|
|
127
|
+
function H(e, t) {
|
|
128
|
+
return J(e.loginAccount) ?? J(t.confirmedAccount) ?? J(t.claimedAccount);
|
|
129
|
+
}
|
|
130
|
+
function U(e) {
|
|
131
|
+
let t = q(e);
|
|
132
|
+
return Array.isArray(t.pages) ? {
|
|
133
|
+
items: t.pages.map((e) => {
|
|
134
|
+
let t = q(e);
|
|
135
|
+
return {
|
|
136
|
+
key: J(t.pageKey) ?? "unknown-page",
|
|
137
|
+
title: J(t.pageKey) ?? "未知页面",
|
|
138
|
+
...J(t.pageKey) ? {} : { titleSource: s("platform.log.statistic.unknown-page") },
|
|
139
|
+
count: Y(t.accessCount)
|
|
140
|
+
};
|
|
141
|
+
}),
|
|
142
|
+
complete: X(t.complete)
|
|
143
|
+
} : {
|
|
144
|
+
items: [
|
|
145
|
+
["executionCount", "执行次数"],
|
|
146
|
+
["successCount", "成功次数"],
|
|
147
|
+
["failureCount", "失败次数"],
|
|
148
|
+
["rejectedCount", "拒绝次数"],
|
|
149
|
+
["knownDurationCount", "含耗时记录数"],
|
|
150
|
+
["totalDurationMillis", "累计耗时(毫秒)"],
|
|
151
|
+
["knownAffectedRecordCount", "含影响数记录数"],
|
|
152
|
+
["totalAffectedRecordCount", "累计影响记录数"]
|
|
153
|
+
].map(([e, n]) => ({
|
|
154
|
+
key: e,
|
|
155
|
+
title: n,
|
|
156
|
+
titleSource: s(`platform.log.statistic.${e}`),
|
|
157
|
+
count: Y(t[e])
|
|
158
|
+
})),
|
|
159
|
+
complete: X(t.complete)
|
|
160
|
+
};
|
|
161
|
+
}
|
|
162
|
+
function se(e, t) {
|
|
163
|
+
let n = e.titleSource;
|
|
164
|
+
return n?.sourceKind === "CODE" && n.sourceId.startsWith("platform.log.statistic.") && u(n, e.title) ? t.t(n.sourceId, n.originalText) : e.title;
|
|
165
|
+
}
|
|
166
|
+
function W(e, t) {
|
|
167
|
+
return J(e.summary ?? e.message ?? e.description) ?? G(t.message) ?? G(t.responseSummary) ?? J(t.reasonCode) ?? J(t.failureStage) ?? J(t.pageKey) ?? J(t.errorCode) ?? J(t.authenticationMethod);
|
|
168
|
+
}
|
|
169
|
+
function G(e) {
|
|
170
|
+
return J(e) ?? J(q(e).value);
|
|
171
|
+
}
|
|
172
|
+
function K(e) {
|
|
173
|
+
let t = q(e.operatorIdentity), n = J(t.employeeName), r = J(t.username), i = J(t.organizationId), a = J(t.organizationName), o = J(t.departmentId), s = J(t.departmentName);
|
|
174
|
+
return n || r || i || a || o || s ? {
|
|
175
|
+
employeeName: n,
|
|
176
|
+
username: r,
|
|
177
|
+
organizationId: i,
|
|
178
|
+
organizationName: a,
|
|
179
|
+
departmentId: o,
|
|
180
|
+
departmentName: s
|
|
181
|
+
} : void 0;
|
|
182
|
+
}
|
|
183
|
+
function q(e) {
|
|
184
|
+
return typeof e == "object" && e && !Array.isArray(e) ? e : {};
|
|
185
|
+
}
|
|
186
|
+
function ce(e) {
|
|
187
|
+
let t = q(e);
|
|
188
|
+
return Object.keys(t).length > 0 ? t : void 0;
|
|
189
|
+
}
|
|
190
|
+
function J(e) {
|
|
191
|
+
return typeof e == "string" && e.length > 0 ? e : void 0;
|
|
192
|
+
}
|
|
193
|
+
function Y(e) {
|
|
194
|
+
return typeof e == "number" && Number.isFinite(e) ? e : 0;
|
|
195
|
+
}
|
|
196
|
+
function X(e) {
|
|
197
|
+
return typeof e == "boolean" ? e : void 0;
|
|
198
|
+
}
|
|
199
|
+
//#endregion
|
|
200
|
+
//#region src/views/businessLogRetentionClient.ts
|
|
201
|
+
function le(e) {
|
|
202
|
+
let t = "/platform.business_log_retention";
|
|
203
|
+
return {
|
|
204
|
+
async policies() {
|
|
205
|
+
let n = await e.request({ path: `${t}/policies` });
|
|
206
|
+
return Array.isArray(n) ? n : [];
|
|
207
|
+
},
|
|
208
|
+
async update(n) {
|
|
209
|
+
return await e.request({
|
|
210
|
+
method: "POST",
|
|
211
|
+
path: `${t}/policies/${n.eventType}`,
|
|
212
|
+
body: {
|
|
213
|
+
automaticCleanupEnabled: n.automaticCleanupEnabled,
|
|
214
|
+
retentionDays: n.retentionDays,
|
|
215
|
+
version: n.version
|
|
216
|
+
}
|
|
217
|
+
});
|
|
218
|
+
},
|
|
219
|
+
async purge(n, r) {
|
|
220
|
+
return await e.request({
|
|
221
|
+
method: "POST",
|
|
222
|
+
path: `${t}/policies/${n}/purge`,
|
|
223
|
+
body: { retentionDays: r }
|
|
224
|
+
});
|
|
225
|
+
}
|
|
226
|
+
};
|
|
227
|
+
}
|
|
228
|
+
//#endregion
|
|
229
|
+
//#region src/views/BusinessLogRetentionControl.vue?vue&type=script&setup=true&lang.ts
|
|
230
|
+
var ue = {
|
|
231
|
+
key: 3,
|
|
232
|
+
class: "business-log-retention-control__policies"
|
|
233
|
+
}, de = { key: 0 }, fe = { class: "business-log-retention-control__automatic-cleanup" }, pe = { class: "business-log-retention-control__content" }, me = { class: "business-log-retention-control__retention-days" }, he = { class: "business-log-retention-control__retention-row" }, ge = {
|
|
234
|
+
key: 0,
|
|
235
|
+
class: "business-log-retention-control__validation"
|
|
236
|
+
}, Z = /*#__PURE__*/ d(/* @__PURE__ */ D({
|
|
237
|
+
name: "BusinessLogRetentionControl",
|
|
238
|
+
__name: "BusinessLogRetentionControl",
|
|
239
|
+
props: { eventTypes: {} },
|
|
240
|
+
setup(e) {
|
|
241
|
+
let s = i(), u = e, d = ae({
|
|
242
|
+
moduleAlias: "platform.business_log_retention",
|
|
243
|
+
runtimeAccess: "VIEW"
|
|
244
|
+
}), f = le(d.http), p = A(!1), h = A([]), D = A({}), O = A(!1), I = M(), oe = b(() => I.value ? ve(I.value) : void 0), L = A(), R = A(), z = b(() => d.can("viewRetentionPolicies") === !0), B = b(() => d.can("configureRetentionPolicy") === !0), V = b(() => d.can("purgeExpiredLogs") === !0), H = b(() => L.value !== void 0 || R.value !== void 0), U = b(() => {
|
|
245
|
+
let e = new Set(u.eventTypes);
|
|
246
|
+
return h.value.filter((t) => e.has(t.eventType));
|
|
247
|
+
}), se = b(() => U.value.some(Y));
|
|
248
|
+
async function W() {
|
|
249
|
+
z.value && (p.value = !0, await G());
|
|
250
|
+
}
|
|
251
|
+
async function G() {
|
|
252
|
+
O.value = !0, I.value = void 0;
|
|
253
|
+
try {
|
|
254
|
+
let e = await f.policies(), t = new Set(u.eventTypes), n = e.filter((e) => t.has(e.eventType));
|
|
255
|
+
h.value = n.map((e) => ({ ...e })), D.value = Object.fromEntries(n.map((e) => [e.eventType, { ...e }]));
|
|
256
|
+
} catch (e) {
|
|
257
|
+
I.value = _e(e), _(e, {
|
|
258
|
+
language: s,
|
|
259
|
+
source: "business-log-retention",
|
|
260
|
+
phase: "load"
|
|
261
|
+
});
|
|
262
|
+
} finally {
|
|
263
|
+
O.value = !1;
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
async function K() {
|
|
267
|
+
return H.value ? (v(s.t("platform.screen.BusinessLogRetentionControl.a-cleanup-operation-is-in-progress-please-wait", "自动清理操作正在执行,请稍候。")), !1) : !se.value || t({
|
|
268
|
+
title: s.t("platform.screen.BusinessLogRetentionControl.discard-unsaved-cleanup-settings", "放弃未保存的自动清理设置?"),
|
|
269
|
+
content: s.t("platform.screen.BusinessLogRetentionControl.unsaved-changes-to-automatic-cleanup-and-retention-days-will-be", "关闭后,本次未保存的自动清理和保留天数修改将丢失。")
|
|
270
|
+
}, s);
|
|
271
|
+
}
|
|
272
|
+
async function q(e) {
|
|
273
|
+
if (Z(e.retentionDays) && Y(e) && !H.value) {
|
|
274
|
+
L.value = e.eventType;
|
|
275
|
+
try {
|
|
276
|
+
J(await f.update(e)), c(s.t("platform.screen.BusinessLogRetentionControl.cleanup-settings-saved-for-value", "{value1}自动清理设置已保存", { value1: Q(e.eventType) }));
|
|
277
|
+
} catch (e) {
|
|
278
|
+
_(e, {
|
|
279
|
+
language: s,
|
|
280
|
+
source: "business-log-retention",
|
|
281
|
+
phase: "action"
|
|
282
|
+
});
|
|
283
|
+
} finally {
|
|
284
|
+
L.value = void 0;
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
async function ce(e) {
|
|
289
|
+
if (Z(e.retentionDays) && !H.value && await t({
|
|
290
|
+
title: s.t("platform.screen.BusinessLogRetentionControl.clean-up-value-now", "立即清理{value1}", { value1: Q(e.eventType) }),
|
|
291
|
+
content: s.t("platform.screen.BusinessLogRetentionControl.logs-strictly-older-than-value-days-will-be-deleted-this", "将删除严格早于 {value1} 天的日志。本次清理不会保存对保留天数的修改,且操作不可恢复。", { value1: e.retentionDays }),
|
|
292
|
+
requiredText: s.t("platform.screen.BusinessLogRetentionControl.clean-up-value", "清理{value1}", { value1: Q(e.eventType) }),
|
|
293
|
+
danger: !0
|
|
294
|
+
}, s)) {
|
|
295
|
+
R.value = e.eventType;
|
|
296
|
+
try {
|
|
297
|
+
let t = await f.purge(e.eventType, e.retentionDays);
|
|
298
|
+
if (t.result.status === "ALREADY_RUNNING") {
|
|
299
|
+
v(s.t("platform.screen.BusinessLogRetentionControl.a-log-cleanup-task-is-already-running-this-request-was", "已有日志清理任务正在运行,本次未执行。"));
|
|
300
|
+
return;
|
|
301
|
+
}
|
|
302
|
+
c(t.result.status === "BATCH_LIMIT_REACHED" ? s.t("platform.screen.BusinessLogRetentionControl.deleted-value-records-in-this-run-remaining-records-will-be", "本轮已清理 {value1} 条,剩余数据将在后续批次继续处理", { value1: t.result.deletedCount }) : s.t("platform.screen.BusinessLogRetentionControl.deleted-value-records-from-value", "已清理 {value1} 条{value2}", {
|
|
303
|
+
value1: t.result.deletedCount,
|
|
304
|
+
value2: Q(e.eventType)
|
|
305
|
+
}));
|
|
306
|
+
} catch (e) {
|
|
307
|
+
_(e, {
|
|
308
|
+
language: s,
|
|
309
|
+
source: "business-log-retention",
|
|
310
|
+
phase: "action"
|
|
311
|
+
});
|
|
312
|
+
} finally {
|
|
313
|
+
R.value = void 0;
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
function J(e) {
|
|
318
|
+
D.value = {
|
|
319
|
+
...D.value,
|
|
320
|
+
[e.eventType]: { ...e }
|
|
321
|
+
}, h.value = h.value.map((t) => t.eventType === e.eventType ? { ...e } : t);
|
|
322
|
+
}
|
|
323
|
+
function Y(e) {
|
|
324
|
+
let t = D.value[e.eventType];
|
|
325
|
+
return !t || t.retentionDays !== e.retentionDays || t.automaticCleanupEnabled !== e.automaticCleanupEnabled;
|
|
326
|
+
}
|
|
327
|
+
function X(e, t) {
|
|
328
|
+
e.retentionDays = Number(t);
|
|
329
|
+
}
|
|
330
|
+
function Z(e) {
|
|
331
|
+
return Number.isInteger(e) && e >= 1 && e <= 36500;
|
|
332
|
+
}
|
|
333
|
+
function Q(e) {
|
|
334
|
+
return {
|
|
335
|
+
LOGIN: s.t("platform.screen.BusinessLogRetentionControl.login-audit-logs", "登录日志"),
|
|
336
|
+
ACTION: s.t("platform.screen.BusinessLogRetentionControl.action-logs", "动作日志"),
|
|
337
|
+
REQUEST_ERROR: s.t("platform.screen.BusinessLogRetentionControl.error-logs", "异常日志"),
|
|
338
|
+
PAGE_ACCESS: s.t("platform.screen.BusinessLogRetentionControl.page-access-logs", "页面访问日志")
|
|
339
|
+
}[e];
|
|
340
|
+
}
|
|
341
|
+
function _e(e) {
|
|
342
|
+
return e instanceof Error ? e : new g(re(s, "platform.screen.BusinessLogRetentionControl.failed-to-load-automatic-cleanup-settings", "自动清理设置加载失败。"));
|
|
343
|
+
}
|
|
344
|
+
function ve(e) {
|
|
345
|
+
return e instanceof g ? te(e, s) : ie(ne(e), s);
|
|
346
|
+
}
|
|
347
|
+
return (e, t) => (k(), C(y, null, [z.value ? (k(), x(P(m), {
|
|
348
|
+
key: 0,
|
|
349
|
+
onClick: W
|
|
350
|
+
}, {
|
|
351
|
+
default: F(() => [T(N(P(s).t("platform.screen.BusinessLogRetentionControl.automatic-cleanup", "自动清理")), 1)]),
|
|
352
|
+
_: 1
|
|
353
|
+
})) : S("v-if", !0), E(P(r), {
|
|
354
|
+
open: p.value,
|
|
355
|
+
title: P(s).t("platform.screen.BusinessLogRetentionControl.automatic-cleanup", "自动清理"),
|
|
356
|
+
subtitle: P(s).t("platform.screen.BusinessLogRetentionControl.configure-automatic-cleanup-and-retention-for-the-current-log-type", "配置当前日志类型的自动清理和保留期限。"),
|
|
357
|
+
width: "standard",
|
|
358
|
+
scope: "viewport",
|
|
359
|
+
"before-close": K,
|
|
360
|
+
onClose: t[0] ||= (e) => p.value = !1
|
|
361
|
+
}, {
|
|
362
|
+
default: F(() => [O.value ? (k(), x(P(n), {
|
|
363
|
+
key: 0,
|
|
364
|
+
tip: P(s).t("platform.screen.BusinessLogRetentionControl.loading-automatic-cleanup-settings", "加载自动清理设置")
|
|
365
|
+
}, null, 8, ["tip"])) : oe.value ? (k(), x(P(l), {
|
|
366
|
+
key: 1,
|
|
367
|
+
title: P(s).t("platform.screen.BusinessLogRetentionControl.automatic-cleanup-settings-unavailable", "自动清理设置不可用"),
|
|
368
|
+
message: oe.value
|
|
369
|
+
}, null, 8, ["title", "message"])) : U.value.length === 0 ? (k(), x(P(o), {
|
|
370
|
+
key: 2,
|
|
371
|
+
description: P(s).t("platform.screen.BusinessLogRetentionControl.no-automatic-cleanup-settings-available", "暂无可管理的自动清理设置")
|
|
372
|
+
}, null, 8, ["description"])) : (k(), C("section", ue, [(k(!0), C(y, null, j(U.value, (e) => (k(), C("article", { key: e.eventType }, [
|
|
373
|
+
w("header", null, [w("div", null, [w("h3", null, N(Q(e.eventType)), 1), e.updatedAt ? (k(), C("small", de, [T(N(P(s).t("platform.screen.BusinessLogRetentionControl.last-updated", "最近更新:")) + N(e.updatedAt), 1), e.updatedBy ? (k(), C(y, { key: 0 }, [T(" · " + N(e.updatedBy), 1)], 64)) : S("v-if", !0)])) : S("v-if", !0)]), w("label", fe, [w("span", null, N(P(s).t("platform.screen.BusinessLogRetentionControl.automatic-cleanup", "自动清理")), 1), E(P(a), {
|
|
374
|
+
checked: e.automaticCleanupEnabled,
|
|
375
|
+
"onUpdate:checked": (t) => e.automaticCleanupEnabled = t,
|
|
376
|
+
disabled: !B.value || H.value,
|
|
377
|
+
"checked-text": P(s).t("platform.screen.WorkflowWorkbenchView.enabled", "启用"),
|
|
378
|
+
"unchecked-text": P(s).t("platform.screen.WorkflowWorkbenchView.disabled", "停用")
|
|
379
|
+
}, null, 8, [
|
|
380
|
+
"checked",
|
|
381
|
+
"onUpdate:checked",
|
|
382
|
+
"disabled",
|
|
383
|
+
"checked-text",
|
|
384
|
+
"unchecked-text"
|
|
385
|
+
])])]),
|
|
386
|
+
w("div", pe, [w("label", me, [
|
|
387
|
+
w("span", null, N(P(s).t("platform.screen.BusinessLogRetentionControl.retention-days", "保留天数")), 1),
|
|
388
|
+
w("span", he, [E(P(ee), {
|
|
389
|
+
value: e.retentionDays,
|
|
390
|
+
type: "number",
|
|
391
|
+
disabled: !B.value || H.value,
|
|
392
|
+
"aria-label": P(s).t("platform.screen.BusinessLogRetentionControl.retention-days-for-value", "{value1}保留天数", { value1: Q(e.eventType) }),
|
|
393
|
+
"onUpdate:value": (t) => X(e, t)
|
|
394
|
+
}, null, 8, [
|
|
395
|
+
"value",
|
|
396
|
+
"disabled",
|
|
397
|
+
"aria-label",
|
|
398
|
+
"onUpdate:value"
|
|
399
|
+
]), V.value ? (k(), x(P(m), {
|
|
400
|
+
key: 0,
|
|
401
|
+
intent: "danger",
|
|
402
|
+
disabled: H.value || !Z(e.retentionDays),
|
|
403
|
+
loading: R.value === e.eventType,
|
|
404
|
+
onClick: (t) => ce(e)
|
|
405
|
+
}, {
|
|
406
|
+
default: F(() => [T(N(P(s).t("platform.screen.BusinessLogRetentionControl.clean-up-now", "立即清理")), 1)]),
|
|
407
|
+
_: 1
|
|
408
|
+
}, 8, [
|
|
409
|
+
"disabled",
|
|
410
|
+
"loading",
|
|
411
|
+
"onClick"
|
|
412
|
+
])) : S("v-if", !0)]),
|
|
413
|
+
Z(e.retentionDays) ? S("v-if", !0) : (k(), C("small", ge, N(P(s).t("platform.screen.BusinessLogRetentionControl.enter-an-integer-from-1-to-36500", "请输入 1 至 36500 之间的整数。")), 1))
|
|
414
|
+
])]),
|
|
415
|
+
w("footer", null, [B.value ? (k(), x(P(m), {
|
|
416
|
+
key: 0,
|
|
417
|
+
emphasis: "primary",
|
|
418
|
+
disabled: H.value || !Z(e.retentionDays) || !Y(e),
|
|
419
|
+
loading: L.value === e.eventType,
|
|
420
|
+
onClick: (t) => q(e)
|
|
421
|
+
}, {
|
|
422
|
+
default: F(() => [T(N(P(s).t("platform.action.save", "保存")), 1)]),
|
|
423
|
+
_: 1
|
|
424
|
+
}, 8, [
|
|
425
|
+
"disabled",
|
|
426
|
+
"loading",
|
|
427
|
+
"onClick"
|
|
428
|
+
])) : S("v-if", !0)])
|
|
429
|
+
]))), 128))]))]),
|
|
430
|
+
_: 1
|
|
431
|
+
}, 8, [
|
|
432
|
+
"open",
|
|
433
|
+
"title",
|
|
434
|
+
"subtitle"
|
|
435
|
+
])], 64));
|
|
436
|
+
}
|
|
437
|
+
}), [["__scopeId", "data-v-88f9267c"]]), Q = {
|
|
438
|
+
key: 2,
|
|
439
|
+
class: "business-log-list__detail"
|
|
440
|
+
}, _e = {
|
|
441
|
+
key: 4,
|
|
442
|
+
class: "business-log-list__diagnostic"
|
|
443
|
+
}, ve = {
|
|
444
|
+
key: 1,
|
|
445
|
+
class: "business-log-list__detail"
|
|
446
|
+
}, ye = {
|
|
447
|
+
key: 0,
|
|
448
|
+
class: "business-log-list__hint"
|
|
449
|
+
}, be = {
|
|
450
|
+
key: 1,
|
|
451
|
+
class: "business-log-list__detail"
|
|
452
|
+
}, xe = /*#__PURE__*/ d(/* @__PURE__ */ D({
|
|
453
|
+
name: "BusinessLogListDrawer",
|
|
454
|
+
__name: "BusinessLogListDrawer",
|
|
455
|
+
props: {
|
|
456
|
+
surface: {},
|
|
457
|
+
moduleAlias: {},
|
|
458
|
+
title: {}
|
|
459
|
+
},
|
|
460
|
+
setup(t) {
|
|
461
|
+
let a = i(), s = t, c = ae({ moduleAlias: s.moduleAlias }), u = oe(c.http, s.surface), ee = {
|
|
462
|
+
get title() {
|
|
463
|
+
return a.t("platform.screen.BusinessLogListDrawer.select-an-operator", "选择操作用户");
|
|
464
|
+
},
|
|
465
|
+
get placeholder() {
|
|
466
|
+
return a.t("platform.screen.UserPicker.searchPlaceholder", "按账号或用户 ID 搜索");
|
|
467
|
+
},
|
|
468
|
+
get searchPlaceholder() {
|
|
469
|
+
return a.t("platform.screen.UserPicker.searchPlaceholder", "按账号或用户 ID 搜索");
|
|
470
|
+
},
|
|
471
|
+
mode: "dialog",
|
|
472
|
+
columns: p,
|
|
473
|
+
provider: e({
|
|
474
|
+
sourceIdentity: {
|
|
475
|
+
targetModuleAlias: "iam.user",
|
|
476
|
+
source: {
|
|
477
|
+
kind: "businessPurpose",
|
|
478
|
+
id: `${s.moduleAlias}:operators`
|
|
479
|
+
}
|
|
480
|
+
},
|
|
481
|
+
searchPage: async ({ keyword: e, pageNum: t, pageSize: n, scope: r }) => {
|
|
482
|
+
let i = await u.operatorCandidates({
|
|
483
|
+
keyword: e,
|
|
484
|
+
pageNum: t,
|
|
485
|
+
pageSize: n,
|
|
486
|
+
...r
|
|
487
|
+
});
|
|
488
|
+
return {
|
|
489
|
+
records: i.records,
|
|
490
|
+
total: i.total,
|
|
491
|
+
navigation: i.navigation
|
|
492
|
+
};
|
|
493
|
+
},
|
|
494
|
+
resolveUsers: async (e) => (await u.operatorCandidates({ selectedIds: e })).selectedRecords
|
|
495
|
+
})
|
|
496
|
+
}, d = A(), v = A(!1), D = M(), I = b(() => D.value ? Le(D.value) : void 0), L = A(), R = A(!1), z = M(), B = b(() => z.value ? Le(z.value) : void 0), V = A(!1), H = A(), U = A(), W = A(!1), G = M(), K = b(() => G.value ? Le(G.value) : void 0), q = A(), ce = b(() => Ie.value[s.surface]), J = b(() => s.surface === "activity"), Y = b(() => s.surface === "request-error"), X = b(() => ({
|
|
497
|
+
login: ["LOGIN"],
|
|
498
|
+
activity: ["ACTION", "PAGE_ACCESS"],
|
|
499
|
+
"request-error": ["REQUEST_ERROR"]
|
|
500
|
+
})[s.surface]), le = b(() => c.can("viewInternalDiagnostic") === !0), ue = b(() => ce.value.columns), de = b(() => d.value ? Oe(d.value) : []), fe = b(() => Ne(L.value)), pe = b(() => [...ke(a.t("platform.workflow-task-editor.business-action", "业务动作"), H.value), ...ke(a.t("platform.screen.BusinessLogListDrawer.page-access", "页面访问"), U.value)]), me = b(() => H.value?.complete === !1 || U.value?.complete === !1);
|
|
501
|
+
async function he(e) {
|
|
502
|
+
let t = e, n = t.eventId;
|
|
503
|
+
if (n) {
|
|
504
|
+
d.value = t, D.value = void 0, L.value = void 0, z.value = void 0, v.value = !0;
|
|
505
|
+
try {
|
|
506
|
+
d.value = await u.detail(n);
|
|
507
|
+
} catch (e) {
|
|
508
|
+
D.value = Fe(e), _(e, {
|
|
509
|
+
language: a,
|
|
510
|
+
source: "business-log-detail",
|
|
511
|
+
phase: "load"
|
|
512
|
+
});
|
|
513
|
+
} finally {
|
|
514
|
+
v.value = !1;
|
|
515
|
+
}
|
|
516
|
+
}
|
|
517
|
+
}
|
|
518
|
+
async function ge() {
|
|
519
|
+
if (J.value && !W.value) {
|
|
520
|
+
V.value = !0, W.value = !0, G.value = void 0;
|
|
521
|
+
try {
|
|
522
|
+
let e = q.value ?? Ce(), [t, n] = await Promise.all([u.actionStatistics?.(e), u.pageAccessStatistics?.(e)]);
|
|
523
|
+
H.value = t, U.value = n;
|
|
524
|
+
} catch (e) {
|
|
525
|
+
G.value = Fe(e), _(e, {
|
|
526
|
+
language: a,
|
|
527
|
+
source: "business-log-statistics",
|
|
528
|
+
phase: "load"
|
|
529
|
+
});
|
|
530
|
+
} finally {
|
|
531
|
+
W.value = !1;
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
}
|
|
535
|
+
async function xe() {
|
|
536
|
+
let e = d.value?.eventId;
|
|
537
|
+
if (u.diagnostic && e && !R.value) {
|
|
538
|
+
R.value = !0, z.value = void 0;
|
|
539
|
+
try {
|
|
540
|
+
L.value = await u.diagnostic(e);
|
|
541
|
+
} catch (e) {
|
|
542
|
+
z.value = Fe(e), _(e, {
|
|
543
|
+
language: a,
|
|
544
|
+
source: "business-log-diagnostic",
|
|
545
|
+
phase: "load"
|
|
546
|
+
});
|
|
547
|
+
} finally {
|
|
548
|
+
R.value = !1;
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
}
|
|
552
|
+
function Se(e) {
|
|
553
|
+
q.value = e, H.value = void 0, U.value = void 0;
|
|
554
|
+
}
|
|
555
|
+
function Ce() {
|
|
556
|
+
return {
|
|
557
|
+
page: {
|
|
558
|
+
pageNum: 1,
|
|
559
|
+
pageSize: 50
|
|
560
|
+
},
|
|
561
|
+
conditions: []
|
|
562
|
+
};
|
|
563
|
+
}
|
|
564
|
+
function we(e) {
|
|
565
|
+
return e.name === "operatorId" ? ee : void 0;
|
|
566
|
+
}
|
|
567
|
+
function Te(e, t) {
|
|
568
|
+
switch (e) {
|
|
569
|
+
case "outcome": return De(t.outcome);
|
|
570
|
+
case "mutationSource": return Ee(t.mutationSource);
|
|
571
|
+
case "employeeName": return t.operatorIdentity?.employeeName ?? "—";
|
|
572
|
+
case "username": return t.operatorIdentity?.username ?? t.operatorId ?? "—";
|
|
573
|
+
case "loginAccount": return Ae(t) ?? "—";
|
|
574
|
+
case "organizationName": return t.operatorIdentity?.organizationName ?? "—";
|
|
575
|
+
case "departmentName": return t.operatorIdentity?.departmentName ?? "—";
|
|
576
|
+
case "errorCode": return $(t.details?.errorCode) ?? "—";
|
|
577
|
+
case "httpStatus": return $(t.details?.httpStatus) ?? "—";
|
|
578
|
+
default: return Pe(t[e]);
|
|
579
|
+
}
|
|
580
|
+
}
|
|
581
|
+
function Ee(e) {
|
|
582
|
+
return {
|
|
583
|
+
BUSINESS: a.t("platform.screen.BusinessLogListDrawer.business-data-write", "业务写入"),
|
|
584
|
+
ACTION: a.t("platform.workflow-task-editor.business-action", "业务动作"),
|
|
585
|
+
SYSTEM: a.t("platform.screen.BusinessLogListDrawer.system-processing", "系统处理"),
|
|
586
|
+
WRITE_BACK: a.t("platform.screen.BusinessLogListDrawer.platform-write-back", "平台回写")
|
|
587
|
+
}[e ?? ""] ?? e ?? "—";
|
|
588
|
+
}
|
|
589
|
+
function De(e) {
|
|
590
|
+
return {
|
|
591
|
+
SUCCESS: a.t("platform.screen.BusinessLogListDrawer.success", "成功"),
|
|
592
|
+
FAILURE: a.t("platform.screen.BusinessLogListDrawer.failure", "失败"),
|
|
593
|
+
REJECTED: a.t("platform.screen.BusinessLogListDrawer.rejected", "拒绝")
|
|
594
|
+
}[e ?? ""] ?? e ?? "—";
|
|
595
|
+
}
|
|
596
|
+
function Oe(e) {
|
|
597
|
+
return [
|
|
598
|
+
[a.t("platform.screen.BusinessLogListDrawer.occurred-at", "发生时间"), e.occurredAt],
|
|
599
|
+
[a.t("platform.screen.BusinessLogListDrawer.event-type", "事件类型"), e.eventType],
|
|
600
|
+
[a.t("platform.screen.BusinessLogListDrawer.outcome", "结果"), e.outcome],
|
|
601
|
+
[a.t("platform.user-picker.column.employee-name", "职员姓名"), e.operatorIdentity?.employeeName],
|
|
602
|
+
[a.t("platform.screen.BusinessLogListDrawer.operator", "操作用户"), e.operatorIdentity?.username ?? e.operatorId],
|
|
603
|
+
[a.t("platform.screen.CurrentUserProfileDialog.sign-in-account", "登录账号"), Ae(e)],
|
|
604
|
+
[a.t("platform.screen.BusinessLogListDrawer.user-id", "用户 ID"), e.operatorId],
|
|
605
|
+
[a.t("platform.user-picker.axis.organization", "机构"), e.operatorIdentity?.organizationName],
|
|
606
|
+
[a.t("platform.screen.BusinessLogListDrawer.organization-id", "机构 ID"), e.operatorIdentity?.organizationId ?? e.operatorOrganizationId],
|
|
607
|
+
[a.t("platform.user-picker.axis.department", "部门"), e.operatorIdentity?.departmentName],
|
|
608
|
+
[a.t("platform.screen.BusinessLogListDrawer.department-id", "部门 ID"), e.operatorIdentity?.departmentId],
|
|
609
|
+
[a.t("platform.screen.WorkflowWorkbenchView.business-module", "业务模块"), e.moduleAlias],
|
|
610
|
+
[a.t("platform.governance.tab.actions", "动作"), e.actionCode],
|
|
611
|
+
[a.t("platform.screen.BusinessLogListDrawer.entity", "实体"), e.entityAlias],
|
|
612
|
+
[a.t("platform.screen.BusinessLogListDrawer.record-id", "记录 ID"), e.recordId],
|
|
613
|
+
[a.t("platform.screen.BusinessLogListDrawer.change-source", "变更来源"), Ee(e.mutationSource)],
|
|
614
|
+
[a.t("platform.screen.BusinessLogListDrawer.trace-id", "追踪 ID"), e.traceId],
|
|
615
|
+
...Ne(e.details, [
|
|
616
|
+
"outcome",
|
|
617
|
+
"entityAlias",
|
|
618
|
+
"recordId",
|
|
619
|
+
"mutationSource"
|
|
620
|
+
]).map((e) => [e.key, e.value])
|
|
621
|
+
].filter(([, e]) => e != null && e !== "").map(([e, t]) => ({
|
|
622
|
+
key: e,
|
|
623
|
+
value: Pe(t)
|
|
624
|
+
}));
|
|
625
|
+
}
|
|
626
|
+
function ke(e, t) {
|
|
627
|
+
return (t?.items ?? []).map((t) => ({
|
|
628
|
+
key: `${e}:${t.key}`,
|
|
629
|
+
kind: e,
|
|
630
|
+
title: se(t, a),
|
|
631
|
+
count: t.count
|
|
632
|
+
}));
|
|
633
|
+
}
|
|
634
|
+
function Ae(e) {
|
|
635
|
+
if (e.eventType === "LOGIN") return e.loginAccount ?? $(e.details?.confirmedAccount) ?? $(e.details?.claimedAccount);
|
|
636
|
+
}
|
|
637
|
+
function je() {
|
|
638
|
+
return [{
|
|
639
|
+
key: "detail",
|
|
640
|
+
title: a.t("platform.screen.PageCompositionEditor.details", "详情"),
|
|
641
|
+
primary: !0,
|
|
642
|
+
iconName: "eye"
|
|
643
|
+
}];
|
|
644
|
+
}
|
|
645
|
+
function Me(e, t) {
|
|
646
|
+
e.key === "detail" && he(t);
|
|
647
|
+
}
|
|
648
|
+
function Ne(e, t = []) {
|
|
649
|
+
let n = new Set(t);
|
|
650
|
+
return Object.entries(e ?? {}).filter(([e]) => !n.has(e)).map(([e, t]) => ({
|
|
651
|
+
key: e,
|
|
652
|
+
value: Pe(t)
|
|
653
|
+
}));
|
|
654
|
+
}
|
|
655
|
+
function $(e) {
|
|
656
|
+
return typeof e == "string" || typeof e == "number" ? String(e) : void 0;
|
|
657
|
+
}
|
|
658
|
+
function Pe(e) {
|
|
659
|
+
return e == null || e === "" ? "—" : typeof e == "string" ? e : JSON.stringify(e, null, 2);
|
|
660
|
+
}
|
|
661
|
+
function Fe(e) {
|
|
662
|
+
return e instanceof Error ? e : new g(re(a, "platform.screen.BusinessLogListDrawer.the-request-did-not-complete-try-again-later", "请求未完成,请稍后重试。"));
|
|
663
|
+
}
|
|
664
|
+
let Ie = b(() => ({
|
|
665
|
+
login: { columns: [
|
|
666
|
+
{
|
|
667
|
+
key: "outcome",
|
|
668
|
+
title: a.t("platform.screen.BusinessLogListDrawer.outcome", "结果"),
|
|
669
|
+
width: "96px"
|
|
670
|
+
},
|
|
671
|
+
{
|
|
672
|
+
key: "occurredAt",
|
|
673
|
+
title: a.t("platform.screen.BusinessLogListDrawer.occurred-at", "发生时间"),
|
|
674
|
+
width: "176px"
|
|
675
|
+
},
|
|
676
|
+
{
|
|
677
|
+
key: "loginAccount",
|
|
678
|
+
title: a.t("platform.screen.CurrentUserProfileDialog.sign-in-account", "登录账号"),
|
|
679
|
+
width: "200px"
|
|
680
|
+
}
|
|
681
|
+
] },
|
|
682
|
+
activity: { columns: [
|
|
683
|
+
{
|
|
684
|
+
key: "outcome",
|
|
685
|
+
title: a.t("platform.screen.BusinessLogListDrawer.outcome", "结果"),
|
|
686
|
+
width: "96px"
|
|
687
|
+
},
|
|
688
|
+
{
|
|
689
|
+
key: "occurredAt",
|
|
690
|
+
title: a.t("platform.screen.BusinessLogListDrawer.occurred-at", "发生时间"),
|
|
691
|
+
width: "176px"
|
|
692
|
+
},
|
|
693
|
+
{
|
|
694
|
+
key: "username",
|
|
695
|
+
title: a.t("platform.screen.BusinessLogListDrawer.operator", "操作用户"),
|
|
696
|
+
width: "160px"
|
|
697
|
+
},
|
|
698
|
+
{
|
|
699
|
+
key: "moduleAlias",
|
|
700
|
+
title: a.t("platform.screen.WorkflowWorkbenchView.business-module", "业务模块"),
|
|
701
|
+
width: "190px"
|
|
702
|
+
},
|
|
703
|
+
{
|
|
704
|
+
key: "actionCode",
|
|
705
|
+
title: a.t("platform.governance.tab.actions", "动作"),
|
|
706
|
+
width: "150px"
|
|
707
|
+
},
|
|
708
|
+
{
|
|
709
|
+
key: "recordId",
|
|
710
|
+
title: a.t("platform.screen.BusinessLogListDrawer.record-id", "记录 ID"),
|
|
711
|
+
width: "170px"
|
|
712
|
+
},
|
|
713
|
+
{
|
|
714
|
+
key: "mutationSource",
|
|
715
|
+
title: a.t("platform.screen.BusinessLogListDrawer.change-source", "变更来源"),
|
|
716
|
+
width: "120px"
|
|
717
|
+
}
|
|
718
|
+
] },
|
|
719
|
+
"request-error": { columns: [
|
|
720
|
+
{
|
|
721
|
+
key: "occurredAt",
|
|
722
|
+
title: a.t("platform.screen.BusinessLogListDrawer.occurred-at", "发生时间"),
|
|
723
|
+
width: "176px"
|
|
724
|
+
},
|
|
725
|
+
{
|
|
726
|
+
key: "moduleAlias",
|
|
727
|
+
title: a.t("platform.screen.WorkflowWorkbenchView.business-module", "业务模块"),
|
|
728
|
+
width: "190px"
|
|
729
|
+
},
|
|
730
|
+
{
|
|
731
|
+
key: "errorCode",
|
|
732
|
+
title: a.t("platform.screen.BusinessLogListDrawer.error-code", "错误码"),
|
|
733
|
+
width: "150px"
|
|
734
|
+
},
|
|
735
|
+
{
|
|
736
|
+
key: "httpStatus",
|
|
737
|
+
title: a.t("platform.screen.BusinessLogListDrawer.http-status", "HTTP 状态"),
|
|
738
|
+
width: "112px"
|
|
739
|
+
},
|
|
740
|
+
{
|
|
741
|
+
key: "summary",
|
|
742
|
+
title: a.t("platform.screen.BusinessLogListDrawer.error-summary", "错误摘要"),
|
|
743
|
+
width: "260px"
|
|
744
|
+
}
|
|
745
|
+
] }
|
|
746
|
+
}));
|
|
747
|
+
function Le(e) {
|
|
748
|
+
return e instanceof g ? te(e, a) : ie(ne(e), a);
|
|
749
|
+
}
|
|
750
|
+
return (e, i) => (k(), C(y, null, [
|
|
751
|
+
E(P(h), {
|
|
752
|
+
class: "business-log-list",
|
|
753
|
+
context: P(c),
|
|
754
|
+
title: t.title,
|
|
755
|
+
columns: ue.value,
|
|
756
|
+
"row-key": "eventId",
|
|
757
|
+
"show-recycle-bin": !1,
|
|
758
|
+
"page-size": 50,
|
|
759
|
+
"page-size-options": [
|
|
760
|
+
20,
|
|
761
|
+
50,
|
|
762
|
+
100
|
|
763
|
+
],
|
|
764
|
+
"reference-picker-of": we,
|
|
765
|
+
"empty-description": P(a).t("platform.screen.BusinessLogListDrawer.no-logs-match-the-criteria", "暂无符合条件的日志"),
|
|
766
|
+
"row-actions-of": je,
|
|
767
|
+
"row-actions-title": P(a).t("platform.screen.RecordPermissionDialog.operation", "操作"),
|
|
768
|
+
"action-column-width": "88px",
|
|
769
|
+
onRecordActivate: he,
|
|
770
|
+
onRowAction: Me,
|
|
771
|
+
onQueried: Se
|
|
772
|
+
}, {
|
|
773
|
+
operations: F(() => [J.value ? (k(), x(P(m), {
|
|
774
|
+
key: 0,
|
|
775
|
+
loading: W.value,
|
|
776
|
+
onClick: ge
|
|
777
|
+
}, {
|
|
778
|
+
default: F(() => [T(N(P(a).t("platform.screen.BusinessLogListDrawer.usage-statistics", "使用统计")), 1)]),
|
|
779
|
+
_: 1
|
|
780
|
+
}, 8, ["loading"])) : S("v-if", !0), E(Z, { "event-types": X.value }, null, 8, ["event-types"])]),
|
|
781
|
+
cell: F(({ column: e, record: t }) => [e.key === "occurredAt" ? (k(), x(P(f), {
|
|
782
|
+
key: 0,
|
|
783
|
+
value: t.occurredAt
|
|
784
|
+
}, null, 8, ["value"])) : (k(), C("span", {
|
|
785
|
+
key: 1,
|
|
786
|
+
class: O({ "business-log-list__summary": e.key === "summary" })
|
|
787
|
+
}, N(Te(e.key, t)), 3))]),
|
|
788
|
+
_: 1
|
|
789
|
+
}, 8, [
|
|
790
|
+
"context",
|
|
791
|
+
"title",
|
|
792
|
+
"columns",
|
|
793
|
+
"empty-description",
|
|
794
|
+
"row-actions-title"
|
|
795
|
+
]),
|
|
796
|
+
E(P(r), {
|
|
797
|
+
open: !!d.value,
|
|
798
|
+
title: P(a).t("platform.screen.BusinessLogListDrawer.value-details", "{value1}详情", { value1: t.title }),
|
|
799
|
+
"render-mode": "inline",
|
|
800
|
+
subtitle: d.value ? d.value.operatorIdentity?.employeeName ?? d.value.operatorIdentity?.username ?? d.value.operatorId : void 0,
|
|
801
|
+
"close-on-outside": !0,
|
|
802
|
+
onClose: i[0] ||= (e) => d.value = void 0
|
|
803
|
+
}, {
|
|
804
|
+
default: F(() => [v.value ? (k(), x(P(n), {
|
|
805
|
+
key: 0,
|
|
806
|
+
tip: P(a).t("platform.screen.BusinessLogListDrawer.loading-details", "加载详情")
|
|
807
|
+
}, null, 8, ["tip"])) : I.value ? (k(), x(P(l), {
|
|
808
|
+
key: 1,
|
|
809
|
+
title: P(a).t("platform.screen.BusinessLogListDrawer.failed-to-load-log-details", "日志详情加载失败"),
|
|
810
|
+
message: I.value
|
|
811
|
+
}, null, 8, ["title", "message"])) : d.value ? (k(), C("dl", Q, [(k(!0), C(y, null, j(de.value, (e) => (k(), C(y, { key: e.key }, [w("dt", null, N(e.key), 1), w("dd", null, [w("pre", null, N(e.value), 1)])], 64))), 128))])) : (k(), x(P(o), {
|
|
812
|
+
key: 3,
|
|
813
|
+
description: P(a).t("platform.screen.BusinessLogListDrawer.no-log-selected", "未选择日志")
|
|
814
|
+
}, null, 8, ["description"])), Y.value && d.value && le.value ? (k(), C("section", _e, [
|
|
815
|
+
E(P(m), {
|
|
816
|
+
loading: R.value,
|
|
817
|
+
onClick: xe
|
|
818
|
+
}, {
|
|
819
|
+
default: F(() => [T(N(P(a).t("platform.screen.BusinessLogListDrawer.view-internal-diagnostics", "查看内部诊断")), 1)]),
|
|
820
|
+
_: 1
|
|
821
|
+
}, 8, ["loading"]),
|
|
822
|
+
w("small", null, N(P(a).t("platform.screen.BusinessLogListDrawer.only-administrators-with-platform-wide-scope-can-view-this-information", "仅具备平台范围的管理员可查看。")), 1),
|
|
823
|
+
B.value ? (k(), x(P(l), {
|
|
824
|
+
key: 0,
|
|
825
|
+
title: P(a).t("platform.screen.BusinessLogListDrawer.internal-diagnostics-unavailable", "内部诊断不可用"),
|
|
826
|
+
message: B.value
|
|
827
|
+
}, null, 8, ["title", "message"])) : L.value ? (k(), C("dl", ve, [(k(!0), C(y, null, j(fe.value, (e) => (k(), C(y, { key: e.key }, [w("dt", null, N(e.key), 1), w("dd", null, [w("pre", null, N(e.value), 1)])], 64))), 128))])) : S("v-if", !0)
|
|
828
|
+
])) : S("v-if", !0)]),
|
|
829
|
+
_: 1
|
|
830
|
+
}, 8, [
|
|
831
|
+
"open",
|
|
832
|
+
"title",
|
|
833
|
+
"subtitle"
|
|
834
|
+
]),
|
|
835
|
+
E(P(r), {
|
|
836
|
+
open: V.value,
|
|
837
|
+
title: P(a).t("platform.screen.BusinessLogListDrawer.business-activity-usage-statistics", "业务活动使用统计"),
|
|
838
|
+
"render-mode": "inline",
|
|
839
|
+
subtitle: P(a).t("platform.screen.BusinessLogListDrawer.statistics-follow-the-current-query-criteria-and-the-signed-in", "统计口径遵循当前标准查询条件与登录账号的数据范围。"),
|
|
840
|
+
"close-on-outside": !0,
|
|
841
|
+
onClose: i[1] ||= (e) => V.value = !1
|
|
842
|
+
}, {
|
|
843
|
+
default: F(() => [W.value ? (k(), x(P(n), {
|
|
844
|
+
key: 0,
|
|
845
|
+
tip: P(a).t("platform.screen.BusinessLogListDrawer.loading-usage-statistics", "加载使用统计")
|
|
846
|
+
}, null, 8, ["tip"])) : K.value ? (k(), x(P(l), {
|
|
847
|
+
key: 1,
|
|
848
|
+
title: P(a).t("platform.screen.BusinessLogListDrawer.failed-to-load-usage-statistics", "使用统计加载失败"),
|
|
849
|
+
message: K.value
|
|
850
|
+
}, null, 8, ["title", "message"])) : (k(), C(y, { key: 2 }, [me.value ? (k(), C("p", ye, N(P(a).t("platform.screen.BusinessLogListDrawer.these-statistics-cover-only-the-most-recent-accessible-logs", "当前统计只覆盖可读取的最近日志。")), 1)) : S("v-if", !0), pe.value.length > 0 ? (k(), C("dl", be, [(k(!0), C(y, null, j(pe.value, (e) => (k(), C(y, { key: e.key }, [w("dt", null, N(e.kind) + " · " + N(e.title), 1), w("dd", null, N(e.count), 1)], 64))), 128))])) : (k(), x(P(o), {
|
|
851
|
+
key: 2,
|
|
852
|
+
description: P(a).t("platform.screen.BusinessLogListDrawer.no-business-activity-available-for-statistics", "暂无可统计的业务活动")
|
|
853
|
+
}, null, 8, ["description"]))], 64))]),
|
|
854
|
+
_: 1
|
|
855
|
+
}, 8, [
|
|
856
|
+
"open",
|
|
857
|
+
"title",
|
|
858
|
+
"subtitle"
|
|
859
|
+
])
|
|
860
|
+
], 64));
|
|
861
|
+
}
|
|
862
|
+
}), [["__scopeId", "data-v-daa601a0"]]);
|
|
863
|
+
//#endregion
|
|
864
|
+
export { xe as t };
|