@ximatai/muyun-web-app 0.26.13 → 0.26.15
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-UC4rH4Fn.js → BusinessActivityLogView-DVzrZW1X.js} +1 -1
- package/dist/BusinessLogListDrawer-D-R3wnWr.js +825 -0
- package/dist/{LoginAuditLogView-Cjrp8MKX.js → LoginAuditLogView-BP1eaEPw.js} +1 -1
- package/dist/{ModuleActionManagementView-Dkb35QXc.js → ModuleActionManagementView-D17iKVQv.js} +214 -196
- package/dist/{ModuleGovernanceView-Dx43QvGf.js → ModuleGovernanceView-LkWCtops.js} +13509 -8472
- package/dist/{RequestErrorLogView-WnGvMWiF.js → RequestErrorLogView-LzN94-Tk.js} +1 -1
- package/dist/{RoleDetailWorkspaceView-DPDb_QOn.js → RoleDetailWorkspaceView-BXA-bzFu.js} +173 -164
- package/dist/{RuntimeLogView-BRl4ZDkU.js → RuntimeLogView-DUpu2q2w.js} +48 -81
- package/dist/index.css +1 -1
- package/dist/index.js +562 -497
- package/dist/moduleGovernanceWorkspaceView-COjWtJMr.js +639 -0
- package/dist/{platform-components-1cvOeHmo.js → platform-components-Hs3DrTqE.js} +5260 -3344
- package/dist/platform-workbench-C-kE-Yqq.js +19755 -0
- package/dist/{http-B0TC0pJB.js → sse-Q1wa3p_k.js} +34 -4
- package/dist/types/app/CurrentUserProfileDialog.vue.d.ts +1 -1
- package/dist/types/app/useWorkbenchMenuRefresh.d.ts +4 -0
- package/dist/types/app/workbenchMenuRefresh.d.ts +14 -0
- package/dist/types/consumer/AppWorkbenchShell.vue.d.ts +4 -2
- package/dist/types/dynamic-page-runtime/ManagedDetailRelationInlineSurface.vue.d.ts +3 -3
- package/dist/types/dynamic-page-runtime/ModuleDataExchangeSurface.vue.d.ts +17 -0
- package/dist/types/dynamic-page-runtime/ModulePageBusinessSession.d.ts +712 -22
- package/dist/types/dynamic-page-runtime/ModulePageDetailRelations.vue.d.ts +3 -2
- package/dist/types/dynamic-page-runtime/ModulePageHostRuntime.vue.d.ts +782 -60
- package/dist/types/dynamic-page-runtime/ModulePageListExpansionSurface.vue.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/ModulePageListRelationExpansion.vue.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/ModulePageListRelationExpansions.vue.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/ModulePageRecordContent.vue.d.ts +5 -2
- package/dist/types/dynamic-page-runtime/ModuleRecordDetailActions.vue.d.ts +6 -0
- package/dist/types/dynamic-page-runtime/PageNavigatorExplorer.vue.d.ts +9 -7
- package/dist/types/dynamic-page-runtime/RecordFormSurface.vue.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/assistantBusinessScope.d.ts +3 -0
- package/dist/types/dynamic-page-runtime/assistantQueryCapabilities.d.ts +34 -0
- package/dist/types/dynamic-page-runtime/assistantRecordEditorPolicy.d.ts +6 -0
- package/dist/types/dynamic-page-runtime/composables/useModulePageFormContributionRuntime.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/composables/useModulePageListSession.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/composables/useNavigatorRuntime.d.ts +94 -4
- package/dist/types/dynamic-page-runtime/composables/useRecordEditingSession.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/formComputeCoordinator.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/index.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/modulePageAssistantScope.d.ts +20 -0
- package/dist/types/dynamic-page-runtime/modulePageAssistantSurface.d.ts +6 -0
- package/dist/types/dynamic-page-runtime/recordCreationReadiness.d.ts +17 -0
- package/dist/types/dynamic-page-runtime/recordDisplayProjection.d.ts +59 -0
- package/dist/types/dynamic-page-runtime/recordFormAssistantCapabilities.d.ts +59 -0
- package/dist/types/dynamic-page-runtime/recordFormDraftAccess.d.ts +33 -0
- package/dist/types/dynamic-page-runtime/recordMutationPayload.d.ts +2 -2
- package/dist/types/dynamic-page-runtime/recordReferenceDisplay.d.ts +8 -0
- package/dist/types/dynamic-page-runtime/recordSaveRecovery.d.ts +12 -0
- package/dist/types/dynamic-page-runtime/relationDraftAssistantCapabilities.d.ts +9 -0
- package/dist/types/dynamic-page-runtime/relationDraftController.d.ts +23 -0
- package/dist/types/dynamic-page-runtime/relationFormComputeCoordinator.d.ts +1 -0
- package/dist/types/dynamic-page-runtime/useModulePageSession.d.ts +404 -12
- package/dist/types/dynamic-page-runtime/useTenantScopeController.d.ts +1 -0
- package/dist/types/formula/FormulaRuntime.d.ts +3 -1
- package/dist/types/platform-admin-runtime/backendHttp.d.ts +5 -1
- package/dist/types/platform-admin-runtime/module-menu/ModuleMenuEditor.vue.d.ts +17 -0
- package/dist/types/platform-admin-runtime/module-menu/ModuleMenuGovernanceSurface.vue.d.ts +6 -0
- package/dist/types/platform-admin-runtime/module-menu/moduleMenuClient.d.ts +6 -2
- package/dist/types/platform-admin-runtime/module-menu/moduleMenuReceiptStore.d.ts +5 -0
- package/dist/types/platform-admin-runtime/module-menu/moduleMenuSession.d.ts +61 -0
- package/dist/types/platform-admin-runtime/module-menu/moduleMenuWorkspace.d.ts +180 -0
- package/dist/types/platform-admin-runtime/workspaceViewSessions.d.ts +1 -1
- package/dist/types/platform-components/CrudRecordListExplorer.vue.d.ts +11 -7
- package/dist/types/platform-components/DictionaryPicker.vue.d.ts +2 -0
- package/dist/types/platform-components/FileTransferUploader.vue.d.ts +1 -1
- package/dist/types/platform-components/ManagementPanelHeader.vue.d.ts +6 -4
- package/dist/types/platform-components/ManagementTabs.vue.d.ts +20 -0
- package/dist/types/platform-components/ObjectPickerInput.vue.d.ts +2 -0
- package/dist/types/platform-components/QueryValueEditor.vue.d.ts +1 -1
- package/dist/types/platform-components/RecordDetailFields.vue.d.ts +1 -1
- package/dist/types/platform-components/RecordExplorerPanel.vue.d.ts +15 -9
- package/dist/types/platform-components/RecordExplorerTools.vue.d.ts +27 -0
- package/dist/types/platform-components/RecordFormFields.vue.d.ts +5 -1
- package/dist/types/platform-components/RecordModeDrawer.vue.d.ts +2 -2
- package/dist/types/platform-components/RecordMultiPicker.vue.d.ts +2 -0
- package/dist/types/platform-components/RecordPicker.vue.d.ts +2 -0
- package/dist/types/platform-components/RecordQueryListCell.vue.d.ts +1 -1
- package/dist/types/platform-components/RecordQueryListPanel.vue.d.ts +9 -1
- package/dist/types/platform-components/RecordQueryListSurface.vue.d.ts +1 -1
- package/dist/types/platform-components/RecordRelationTabs.vue.d.ts +1 -0
- package/dist/types/platform-components/ReferencePicker.vue.d.ts +2 -0
- package/dist/types/platform-components/StaticManagementLayout.vue.d.ts +2 -0
- package/dist/types/platform-components/TreeRecordExplorer.vue.d.ts +5 -2
- package/dist/types/platform-components/index.d.ts +9 -1
- package/dist/types/platform-components/optionFieldOptionCache.d.ts +1 -1
- package/dist/types/platform-components/queryNumericValue.d.ts +3 -0
- package/dist/types/platform-components/querySettlementController.d.ts +5 -0
- package/dist/types/platform-components/recordDetailFieldModel.d.ts +2 -0
- package/dist/types/platform-components/recordFormFieldModel.d.ts +22 -0
- package/dist/types/platform-components/recordQueryListColumnModel.d.ts +8 -0
- package/dist/types/platform-components/recordQueryListQueryController.d.ts +53 -0
- package/dist/types/platform-components/recordQueryListStandardQuery.d.ts +3 -0
- package/dist/types/platform-components/recordTreeQueryController.d.ts +18 -0
- package/dist/types/platform-components/recycleBinState.d.ts +17 -0
- package/dist/types/platform-components/referencePickerModel.d.ts +3 -0
- package/dist/types/platform-workbench/AssistantMarkdownContent.vue.d.ts +6 -0
- package/dist/types/platform-workbench/AssistantSelectionCard.vue.d.ts +15 -0
- package/dist/types/platform-workbench/ConstructionPlanCard.vue.d.ts +8 -0
- package/dist/types/platform-workbench/Workbench.vue.d.ts +12 -2
- package/dist/types/platform-workbench/WorkbenchAssistantPanel.vue.d.ts +18 -0
- package/dist/types/platform-workbench/assistantMarkdown.d.ts +1 -0
- package/dist/types/platform-workbench/configurationCollaboration.d.ts +23 -0
- package/dist/types/platform-workbench/constructionDelivery.d.ts +3 -0
- package/dist/types/platform-workbench/constructionFields.d.ts +5 -0
- package/dist/types/platform-workbench/constructionInitialization.d.ts +4 -0
- package/dist/types/platform-workbench/constructionPlanGuard.d.ts +21 -0
- package/dist/types/platform-workbench/constructionPlanSession.d.ts +95 -0
- package/dist/types/platform-workbench/constructionReferenceDiscovery.d.ts +3 -0
- package/dist/types/platform-workbench/index.d.ts +1 -0
- package/dist/types/platform-workbench/useAssistantConversation.d.ts +360 -0
- package/dist/types/platform-workbench/useAssistantConversationArchive.d.ts +47 -0
- package/dist/types/platform-workbench/workbenchAssistantCapabilities.d.ts +22 -0
- package/dist/types/views/BusinessLogRetentionControl.vue.d.ts +7 -0
- package/dist/types/views/MetadataSourceTree.vue.d.ts +7 -3
- package/dist/types/views/ModuleRuntimeActivationStatus.vue.d.ts +11 -0
- package/dist/types/views/PageCompositionDescriptorPreview.vue.d.ts +8 -8
- package/dist/types/views/PageCompositionEditor.vue.d.ts +10 -0
- package/dist/types/views/PageCompositionTree.vue.d.ts +19 -13
- package/dist/types/views/businessLogClient.d.ts +3 -0
- package/dist/types/views/businessLogRetentionClient.d.ts +25 -0
- package/dist/types/views/businessRuleAssistantSurface.d.ts +7 -0
- package/dist/types/views/businessRuleEditor.d.ts +22 -0
- package/dist/types/views/businessRuleGovernance.d.ts +7 -1
- package/dist/types/views/businessRuleSession.d.ts +63 -0
- package/dist/types/views/businessRuleWorkspace.d.ts +144 -0
- package/dist/types/views/configurationEditorNavigation.d.ts +2 -0
- package/dist/types/views/metadataChangeSetSubmission.d.ts +10 -0
- package/dist/types/views/metadataEditorSession.d.ts +652 -0
- package/dist/types/views/metadataGovernanceAssistantSurface.d.ts +4 -0
- package/dist/types/views/metadataGovernanceEditor.d.ts +220 -0
- package/dist/types/views/metadataModelChangeSetClient.d.ts +36 -0
- package/dist/types/views/metadataModelEditSession.d.ts +26 -1
- package/dist/types/views/metadataNaming.d.ts +11 -1
- package/dist/types/views/metadataOrchestrationState.d.ts +22 -0
- package/dist/types/views/metadataWorkspace.d.ts +1316 -0
- package/dist/types/views/moduleGovernanceWorkspaceView.d.ts +1 -1
- package/dist/types/views/moduleRuntimeActivation.d.ts +11 -0
- package/dist/types/views/pageCompositionAssistantSurface.d.ts +27 -0
- package/dist/types/views/pageCompositionCandidate.d.ts +47 -0
- package/dist/types/views/pageCompositionComponents.d.ts +42 -0
- package/dist/types/views/pageCompositionDraftState.d.ts +277 -8
- package/dist/types/views/pageCompositionDragPayload.d.ts +7 -1
- package/dist/types/views/pageCompositionMode.d.ts +1 -1
- package/dist/types/views/pageCompositionPlacement.d.ts +6 -1
- package/dist/types/views/pageCompositionPublication.d.ts +37 -0
- package/dist/types/views/pageCompositionSession.d.ts +1341 -0
- package/dist/types/views/pageCompositionWorkspace.d.ts +2555 -0
- package/dist/types/views/roleAuthorizationWorkspaceSession.d.ts +1 -1
- package/dist/types/views/roleDetailWorkspaceSession.d.ts +1 -1
- package/dist/types/views/runtimeLogSse.d.ts +3 -13
- package/dist/types/views/usePageCompositionComponents.d.ts +68 -0
- package/dist/types/vue-ui-antdv/components/UiInput.vue.d.ts +1 -0
- package/dist/types/vue-ui-antdv/components/UiSearchInput.vue.d.ts +2 -0
- package/dist/types/vue-ui-antdv/components/UiSelect.vue.d.ts +2 -0
- package/dist/types/vue-ui-antdv/components/UiTextArea.vue.d.ts +4 -0
- package/dist/types/vue-ui-antdv/components/UiTreeSelect.vue.d.ts +2 -0
- package/dist/types/vue-ui-antdv/types.d.ts +4 -0
- package/dist/types/web-contracts/assistant.d.ts +87 -0
- package/dist/types/web-contracts/constructionPlan.d.ts +212 -0
- package/dist/types/web-contracts/index.d.ts +33 -0
- package/dist/types/web-contracts/operation.d.ts +33 -0
- package/dist/types/web-contracts/referenceTarget.d.ts +13 -0
- package/dist/types/web-core/assistantCapabilityCatalog.d.ts +22 -0
- package/dist/types/web-core/assistantCatalogPage.d.ts +12 -0
- package/dist/types/web-core/assistantConfirmation.d.ts +23 -0
- package/dist/types/web-core/assistantConversationClient.d.ts +42 -0
- package/dist/types/web-core/assistantRuntime.d.ts +123 -0
- package/dist/types/web-core/assistantSurface.d.ts +162 -0
- package/dist/types/web-core/assistantTurnClient.d.ts +16 -0
- package/dist/types/web-core/constructionPlanClient.d.ts +55 -0
- package/dist/types/web-core/errors.d.ts +2 -0
- package/dist/types/web-core/http.d.ts +1 -0
- package/dist/types/web-core/index.d.ts +12 -0
- package/dist/types/web-core/module/dataExchangeClient.d.ts +53 -0
- package/dist/types/web-core/module/index.d.ts +1 -0
- package/dist/types/web-core/module/staticModuleClient.d.ts +12 -2
- package/dist/types/web-core/operationConfirmation.d.ts +28 -0
- package/dist/types/web-core/operationErrors.d.ts +9 -0
- package/dist/types/web-core/operationReceipt.d.ts +10 -0
- package/dist/types/web-core/sse.d.ts +9 -0
- package/dist/types/web-core/uuid.d.ts +2 -0
- package/dist/{workspaceViews-CCg6V0pr.js → workspaceViews-CHsgLFwY.js} +783 -1189
- package/package.json +1 -1
- package/dist/BusinessLogListDrawer-BtaXVJKz.js +0 -564
- package/dist/moduleGovernanceWorkspaceView-4V_UW-Bt.js +0 -40
- package/dist/platform-workbench-Cu14Xd9d.js +0 -10299
|
@@ -0,0 +1,639 @@
|
|
|
1
|
+
import { Ct as e, dt as t, mt as n, u as r } from "./platform-workbench-C-kE-Yqq.js";
|
|
2
|
+
import { Br as i, Dn as a, Ln as o, Tn as s, Ur as c, Xr as l, Zn as u, bn as d, hn as f, xn as p } from "./platform-components-Hs3DrTqE.js";
|
|
3
|
+
import { i as m } from "./sse-Q1wa3p_k.js";
|
|
4
|
+
import { Fragment as h, computed as g, createBlock as _, createCommentVNode as v, createElementBlock as y, createElementVNode as b, createTextVNode as x, createVNode as S, defineAsyncComponent as C, defineComponent as w, inject as T, nextTick as E, openBlock as D, ref as O, shallowRef as k, toDisplayString as A, unref as j, watch as M, withCtx as N } from "vue";
|
|
5
|
+
//#region src/platform-workbench/workspaceViewContract.ts
|
|
6
|
+
function P(e) {
|
|
7
|
+
return e;
|
|
8
|
+
}
|
|
9
|
+
//#endregion
|
|
10
|
+
//#region src/platform-admin-runtime/module-menu/moduleMenuClient.ts
|
|
11
|
+
function F(t) {
|
|
12
|
+
let n = o(t, { moduleAlias: "platform.menu_scheme" });
|
|
13
|
+
return {
|
|
14
|
+
async schemes() {
|
|
15
|
+
let e = [];
|
|
16
|
+
for (let t = 1;; t++) {
|
|
17
|
+
let r = await n.query({ page: {
|
|
18
|
+
pageNum: t,
|
|
19
|
+
pageSize: 100
|
|
20
|
+
} });
|
|
21
|
+
if (e.push(...r.records), e.length >= r.total || r.records.length === 0) return e;
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
async tree(e) {
|
|
25
|
+
return (await t.request({
|
|
26
|
+
method: "POST",
|
|
27
|
+
path: "/platform.menu/tree/query",
|
|
28
|
+
headers: { "X-MuYun-Page-Context": JSON.stringify({ scheme: e }) },
|
|
29
|
+
body: { externalQueryValues: { schemeId: e } }
|
|
30
|
+
})).records;
|
|
31
|
+
},
|
|
32
|
+
context(e) {
|
|
33
|
+
return t.request({ path: `/platform.module/${encodeURIComponent(e)}/context` });
|
|
34
|
+
},
|
|
35
|
+
insert(e, n, r) {
|
|
36
|
+
return o(m(t, { "X-MuYun-Page-Context": JSON.stringify({ scheme: e }) }), { moduleAlias: "platform.menu" }).insert(n, { requestId: r });
|
|
37
|
+
},
|
|
38
|
+
view(e, n) {
|
|
39
|
+
return o(m(t, { "X-MuYun-Page-Context": JSON.stringify({ scheme: e }) }), { moduleAlias: "platform.menu" }).view(n);
|
|
40
|
+
},
|
|
41
|
+
receipt(e, n) {
|
|
42
|
+
return o(m(t, { "X-MuYun-Page-Context": JSON.stringify({ scheme: e }) }), { moduleAlias: "platform.menu" }).saveReceipt(n);
|
|
43
|
+
},
|
|
44
|
+
visible: () => e(t).mine().then((e) => e.records)
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
function I(e) {
|
|
48
|
+
return e ? e.scopeType === "system" ? "系统配置用户" : e.organizationId ? `机构 ${e.organizationId} 的用户` : e.tenantId ? `租户 ${e.tenantId} 的用户` : "尚未声明适用范围" : "尚未确定";
|
|
49
|
+
}
|
|
50
|
+
function L(e, t = "") {
|
|
51
|
+
return e.flatMap(({ record: e, children: n }) => {
|
|
52
|
+
let r = t ? `${t} / ${e.title}` : e.title;
|
|
53
|
+
return [{
|
|
54
|
+
menu: e,
|
|
55
|
+
path: r
|
|
56
|
+
}, ...L(n, r)];
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
function R(e, t = !1) {
|
|
60
|
+
return e.map(({ record: e, children: n }) => {
|
|
61
|
+
let r = t || e.enabled === !1;
|
|
62
|
+
return {
|
|
63
|
+
value: e.id,
|
|
64
|
+
title: e.title,
|
|
65
|
+
disabled: r || !!e.moduleAlias,
|
|
66
|
+
children: R(n, r)
|
|
67
|
+
};
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
//#endregion
|
|
71
|
+
//#region src/platform-admin-runtime/module-menu/ModuleMenuEditor.vue?vue&type=script&setup=true&lang.ts
|
|
72
|
+
var z = { class: "module-menu-form" }, B = { key: 0 }, V = {
|
|
73
|
+
key: 1,
|
|
74
|
+
class: "hint"
|
|
75
|
+
}, ee = {
|
|
76
|
+
key: 2,
|
|
77
|
+
role: "status"
|
|
78
|
+
}, H = { class: "hint" }, U = {
|
|
79
|
+
key: 1,
|
|
80
|
+
class: "hint"
|
|
81
|
+
}, W = {
|
|
82
|
+
key: 2,
|
|
83
|
+
role: "status"
|
|
84
|
+
}, G = {
|
|
85
|
+
key: 3,
|
|
86
|
+
role: "status"
|
|
87
|
+
}, te = {
|
|
88
|
+
key: 5,
|
|
89
|
+
role: "alert"
|
|
90
|
+
}, K = /*#__PURE__*/ a(/* @__PURE__ */ w({
|
|
91
|
+
__name: "ModuleMenuEditor",
|
|
92
|
+
props: {
|
|
93
|
+
session: {},
|
|
94
|
+
showSave: { type: Boolean }
|
|
95
|
+
},
|
|
96
|
+
emits: ["saved", "opened"],
|
|
97
|
+
setup(e, { expose: t, emit: n }) {
|
|
98
|
+
let i = e, a = n, o = i.session, c = r();
|
|
99
|
+
async function l() {
|
|
100
|
+
try {
|
|
101
|
+
await o.startAnother();
|
|
102
|
+
} catch (e) {
|
|
103
|
+
o.error.value = e instanceof Error ? e.message : "暂时无法开始新入口";
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
let u = g(() => o.loading.value || o.saving.value || o.resultUnknown.value || !o.authorized.value), m = g(() => u.value || o.updating.value), C = g(() => o.options.value.map((e) => ({
|
|
107
|
+
value: e.id,
|
|
108
|
+
label: `${e.title ?? e.alias ?? e.id} · ${I(e)}`
|
|
109
|
+
}))), w = g(() => [{
|
|
110
|
+
value: "root",
|
|
111
|
+
title: "顶层",
|
|
112
|
+
children: R(o.tree.value)
|
|
113
|
+
}]);
|
|
114
|
+
async function T() {
|
|
115
|
+
try {
|
|
116
|
+
await (await o.prepare()).execute(), a("saved");
|
|
117
|
+
} catch (e) {
|
|
118
|
+
o.resultUnknown.value || (o.error.value = e instanceof Error ? e.message : "暂时无法添加入口");
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
async function E() {
|
|
122
|
+
try {
|
|
123
|
+
await o.lookupPending() && a("saved");
|
|
124
|
+
} catch {
|
|
125
|
+
o.error.value = "结果暂时无法核实,请重试查询,勿重复添加。";
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
async function O() {
|
|
129
|
+
await o.refreshVisibility(), o.visibleMenu.value && c?.openMenu && (c.openMenu(o.visibleMenu.value), a("opened"));
|
|
130
|
+
}
|
|
131
|
+
return t({ save: T }), (t, n) => (D(), y("div", z, [
|
|
132
|
+
j(o).saved.value ? (D(), y(h, { key: 1 }, [
|
|
133
|
+
n[15] ||= b("strong", null, "已添加到菜单", -1),
|
|
134
|
+
b("p", null, A(j(o).savedPath.value), 1),
|
|
135
|
+
b("p", H, "适用范围:" + A(j(o).savedAudience.value), 1),
|
|
136
|
+
j(o).visibleMenu.value && j(c)?.openMenu ? (D(), _(j(s), {
|
|
137
|
+
key: 0,
|
|
138
|
+
type: "primary",
|
|
139
|
+
onClick: O
|
|
140
|
+
}, {
|
|
141
|
+
default: N(() => [...n[12] ||= [x("打开", -1)]]),
|
|
142
|
+
_: 1
|
|
143
|
+
})) : j(o).visibilityChecked.value ? (D(), y("p", U, " 入口已保存,当前登录身份的导航暂不可见。请由适用范围内的使用者核实;若其也看不到,再检查上级菜单状态和业务访问权限。 ")) : v("v-if", !0),
|
|
144
|
+
S(j(s), {
|
|
145
|
+
disabled: j(o).saving.value,
|
|
146
|
+
onClick: l
|
|
147
|
+
}, {
|
|
148
|
+
default: N(() => [...n[13] ||= [x("另加一个入口", -1)]]),
|
|
149
|
+
_: 1
|
|
150
|
+
}, 8, ["disabled"]),
|
|
151
|
+
j(o).error.value ? (D(), _(j(s), {
|
|
152
|
+
key: 2,
|
|
153
|
+
disabled: j(o).saving.value,
|
|
154
|
+
onClick: j(o).refreshVisibility
|
|
155
|
+
}, {
|
|
156
|
+
default: N(() => [...n[14] ||= [x("刷新导航", -1)]]),
|
|
157
|
+
_: 1
|
|
158
|
+
}, 8, ["disabled", "onClick"])) : v("v-if", !0)
|
|
159
|
+
], 64)) : (D(), y(h, { key: 0 }, [
|
|
160
|
+
b("label", null, [n[4] ||= x("菜单名称", -1), S(j(d), {
|
|
161
|
+
value: j(o).title.value,
|
|
162
|
+
disabled: m.value,
|
|
163
|
+
"aria-label": "菜单名称",
|
|
164
|
+
"onUpdate:value": n[0] ||= (e) => j(o).update({ title: String(e ?? "") })
|
|
165
|
+
}, null, 8, ["value", "disabled"])]),
|
|
166
|
+
C.value.length > 1 ? (D(), y("label", B, [n[5] ||= x("菜单方案", -1), S(j(p), {
|
|
167
|
+
value: j(o).schemeId.value,
|
|
168
|
+
options: C.value,
|
|
169
|
+
"allow-clear": !1,
|
|
170
|
+
disabled: u.value,
|
|
171
|
+
"onUpdate:value": n[1] ||= (e) => j(o).update({ schemeId: String(e ?? "") })
|
|
172
|
+
}, null, 8, [
|
|
173
|
+
"value",
|
|
174
|
+
"options",
|
|
175
|
+
"disabled"
|
|
176
|
+
])])) : v("v-if", !0),
|
|
177
|
+
b("label", null, [n[6] ||= x("放置位置", -1), S(j(f), {
|
|
178
|
+
value: j(o).parentId.value,
|
|
179
|
+
"tree-data": w.value,
|
|
180
|
+
"allow-clear": !1,
|
|
181
|
+
disabled: m.value,
|
|
182
|
+
loading: j(o).loading.value || j(o).updating.value,
|
|
183
|
+
"onUpdate:value": n[2] ||= (e) => j(o).update({ parentId: String(e ?? "root") })
|
|
184
|
+
}, null, 8, [
|
|
185
|
+
"value",
|
|
186
|
+
"tree-data",
|
|
187
|
+
"disabled",
|
|
188
|
+
"loading"
|
|
189
|
+
])]),
|
|
190
|
+
b("details", null, [n[8] ||= b("summary", null, "更多设置", -1), b("label", null, [n[7] ||= x("打开方式", -1), S(j(p), {
|
|
191
|
+
value: j(o).openMode.value,
|
|
192
|
+
"allow-clear": !1,
|
|
193
|
+
disabled: m.value,
|
|
194
|
+
options: [{
|
|
195
|
+
value: "tab",
|
|
196
|
+
label: "页签内打开"
|
|
197
|
+
}, {
|
|
198
|
+
value: "window",
|
|
199
|
+
label: "新窗口打开"
|
|
200
|
+
}],
|
|
201
|
+
"onUpdate:value": n[3] ||= (e) => j(o).update({ openMode: e === "window" ? "window" : "tab" })
|
|
202
|
+
}, null, 8, ["value", "disabled"])])]),
|
|
203
|
+
j(o).duplicate.value ? (D(), y("p", V, " 此位置已有「" + A(j(o).duplicate.value.menu.title) + "」,仍可另加入口。 ", 1)) : v("v-if", !0),
|
|
204
|
+
n[11] ||= b("p", { class: "hint" }, "只添加访问入口,不开通应用或授予业务权限。", -1),
|
|
205
|
+
j(o).updating.value ? (D(), y("p", ee, "正在读取菜单方案,请等待候选就绪。")) : v("v-if", !0),
|
|
206
|
+
e.showSave && !j(o).resultUnknown.value ? (D(), _(j(s), {
|
|
207
|
+
key: 3,
|
|
208
|
+
type: "primary",
|
|
209
|
+
disabled: !j(o).canSave.value,
|
|
210
|
+
loading: j(o).saving.value,
|
|
211
|
+
onClick: T
|
|
212
|
+
}, {
|
|
213
|
+
default: N(() => [...n[9] ||= [x("添加入口", -1)]]),
|
|
214
|
+
_: 1
|
|
215
|
+
}, 8, ["disabled", "loading"])) : v("v-if", !0),
|
|
216
|
+
j(o).resultUnknown.value ? (D(), _(j(s), {
|
|
217
|
+
key: 4,
|
|
218
|
+
onClick: E
|
|
219
|
+
}, {
|
|
220
|
+
default: N(() => [...n[10] ||= [x("查询保存结果", -1)]]),
|
|
221
|
+
_: 1
|
|
222
|
+
})) : v("v-if", !0)
|
|
223
|
+
], 64)),
|
|
224
|
+
j(o).entryIssue.value ? (D(), y("p", W, A(j(o).entryIssue.value), 1)) : v("v-if", !0),
|
|
225
|
+
j(o).ready.value && !j(o).authorized.value ? (D(), y("p", G, "当前没有添加菜单入口权限。")) : v("v-if", !0),
|
|
226
|
+
j(o).error.value && j(o).ready.value && !j(o).saved.value && !j(o).resultUnknown.value ? (D(), _(j(s), {
|
|
227
|
+
key: 4,
|
|
228
|
+
disabled: j(o).saving.value,
|
|
229
|
+
onClick: j(o).load
|
|
230
|
+
}, {
|
|
231
|
+
default: N(() => [...n[16] ||= [x("重新读取候选", -1)]]),
|
|
232
|
+
_: 1
|
|
233
|
+
}, 8, ["disabled", "onClick"])) : v("v-if", !0),
|
|
234
|
+
j(o).error.value ? (D(), y("p", te, A(j(o).error.value), 1)) : v("v-if", !0),
|
|
235
|
+
j(o).error.value && !j(o).ready.value && !j(o).resultUnknown.value ? (D(), _(j(s), {
|
|
236
|
+
key: 6,
|
|
237
|
+
disabled: j(o).saving.value,
|
|
238
|
+
onClick: j(o).load
|
|
239
|
+
}, {
|
|
240
|
+
default: N(() => [...n[17] ||= [x("重试", -1)]]),
|
|
241
|
+
_: 1
|
|
242
|
+
}, 8, ["disabled", "onClick"])) : v("v-if", !0)
|
|
243
|
+
]));
|
|
244
|
+
}
|
|
245
|
+
}), [["__scopeId", "data-v-4363c074"]]);
|
|
246
|
+
//#endregion
|
|
247
|
+
//#region src/platform-admin-runtime/module-menu/moduleMenuReceiptStore.ts
|
|
248
|
+
function q(e, t, n, r = u, i) {
|
|
249
|
+
let a = `muyun.menu-pending.${JSON.stringify([e, t])}`, o = { persistence: "backend" }, s;
|
|
250
|
+
function l() {
|
|
251
|
+
if (!n()) throw new c("菜单编辑身份已变化");
|
|
252
|
+
return i ?? window.sessionStorage;
|
|
253
|
+
}
|
|
254
|
+
function d(e) {
|
|
255
|
+
if (!/^[a-zA-Z0-9-]{16,80}$/.test(e)) throw new c("原入口查询标识无效");
|
|
256
|
+
return `menu.pending.r${e.toLowerCase().replaceAll("-", "")}`;
|
|
257
|
+
}
|
|
258
|
+
return {
|
|
259
|
+
async restore() {
|
|
260
|
+
if (s = l().getItem(a) ?? void 0, !s) return;
|
|
261
|
+
let e = await r.restore(d(s), void 0, o);
|
|
262
|
+
if (!e) throw new c("原入口查询引用暂不可读取,请核实后重试");
|
|
263
|
+
return e;
|
|
264
|
+
},
|
|
265
|
+
async save(e) {
|
|
266
|
+
if (e.kind !== "record-save") throw new c("原入口查询标识无效");
|
|
267
|
+
let t = l();
|
|
268
|
+
s = e.requestId, await r.set(d(s), e, o), l(), t.setItem(a, s);
|
|
269
|
+
},
|
|
270
|
+
async clear() {
|
|
271
|
+
let e = l(), t = s;
|
|
272
|
+
t && (await r.remove(d(t), o), l(), e.getItem(a) === t && e.removeItem(a), s === t && (s = void 0));
|
|
273
|
+
}
|
|
274
|
+
};
|
|
275
|
+
}
|
|
276
|
+
//#endregion
|
|
277
|
+
//#region src/platform-admin-runtime/module-menu/moduleMenuSession.ts
|
|
278
|
+
function ne(e, r, a, o, s = e.visible) {
|
|
279
|
+
let u = O(0), d = O(!1), f = O(!1), p = O(!1), m = O(""), h = O(""), _ = O(""), v = O(""), y = O("root"), b = O("tab"), x = k([]), S = k([]), C = k(), w = O(""), T = O(""), E = k(), D = O(!1), A = O(!1), j = O(!1), M = O(!1), N = !1, P = 0, F = 0, R, z = !1, B = () => !N && a.valid(), V = g(() => x.value.filter((e) => e.enabled !== !1 && e.id)), ee = g(() => J(S.value)), H = g(() => B() && j.value && A.value && !d.value && !f.value && !p.value && !R && !C.value && !h.value && !!_.value.trim()), U = g(() => L(S.value).find(({ menu: e }) => e.moduleAlias === r && e.parentId === y.value));
|
|
280
|
+
function W() {
|
|
281
|
+
if (!B()) throw new c("菜单编辑范围已变化,请重新打开");
|
|
282
|
+
}
|
|
283
|
+
function G(e = !1) {
|
|
284
|
+
if (W(), !j.value || !A.value || d.value || p.value || R || C.value || !e && f.value) throw new c("请先等待菜单候选就绪,或查询未确定的保存结果");
|
|
285
|
+
}
|
|
286
|
+
async function te() {
|
|
287
|
+
if (W(), C.value || R && j.value) return;
|
|
288
|
+
F++, f.value = !1;
|
|
289
|
+
let t = ++P;
|
|
290
|
+
d.value = !0, j.value = !1, m.value = "";
|
|
291
|
+
try {
|
|
292
|
+
if (!z) {
|
|
293
|
+
let e = await o.restore();
|
|
294
|
+
if (!B() || t !== P) return;
|
|
295
|
+
if (e) {
|
|
296
|
+
let t = n(e);
|
|
297
|
+
if (t.kind !== "record-save" || t.moduleAlias !== "platform.menu" || !t.pageContext?.scheme) throw new c("原入口查询范围无效,请核实保存结果后继续");
|
|
298
|
+
R = {
|
|
299
|
+
requestId: t.requestId,
|
|
300
|
+
schemeId: t.pageContext.scheme
|
|
301
|
+
}, M.value = !0;
|
|
302
|
+
}
|
|
303
|
+
z = !0;
|
|
304
|
+
}
|
|
305
|
+
let [i, a, s, l] = await Promise.all([
|
|
306
|
+
e.schemes(),
|
|
307
|
+
e.context(r),
|
|
308
|
+
e.context("platform.menu"),
|
|
309
|
+
e.visible()
|
|
310
|
+
]);
|
|
311
|
+
if (!B() || t !== P) return;
|
|
312
|
+
A.value = s.actions.some((e) => e.actionCode === "create" && e.authorized), h.value = Y(a), x.value = i, _.value ||= a.title ?? r, b.value = a.entryType === "link" ? "window" : "tab";
|
|
313
|
+
let d = l[0]?.record.schemeId, f = V.value.find((e) => e.id === (R?.schemeId ?? v.value)) ?? V.value.find((e) => e.id === d) ?? V.value[0];
|
|
314
|
+
if (!f?.id) throw new c("暂无可用菜单方案,请先配置适用的菜单方案");
|
|
315
|
+
let p = await e.tree(f.id);
|
|
316
|
+
if (!B() || t !== P) return;
|
|
317
|
+
v.value = f.id, S.value = p, y.value = "root", j.value = !0, u.value++;
|
|
318
|
+
} catch (e) {
|
|
319
|
+
B() && t === P && (m.value = X(e));
|
|
320
|
+
} finally {
|
|
321
|
+
B() && t === P && (d.value = !1);
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
function K(t) {
|
|
325
|
+
let n = t.schemeId ?? v.value;
|
|
326
|
+
if (!V.value.some((e) => e.id === n)) throw new c("请选择当前可用的菜单方案");
|
|
327
|
+
let r = t.title ?? _.value;
|
|
328
|
+
if ([...r].length > 120) throw new c("菜单名称不能超过120个字符");
|
|
329
|
+
let i = t.parentId ?? (n === v.value ? y.value : "root"), a = t.openMode ?? b.value, o = (e) => {
|
|
330
|
+
if (i !== "root" && !J(e).some((e) => e.menu.id === i)) throw new c("请选择当前方案中的启用目录");
|
|
331
|
+
return {
|
|
332
|
+
schemeId: n,
|
|
333
|
+
nodes: e,
|
|
334
|
+
parentId: i,
|
|
335
|
+
title: r,
|
|
336
|
+
openMode: a
|
|
337
|
+
};
|
|
338
|
+
};
|
|
339
|
+
return n === v.value ? o(S.value) : e.tree(n).then(o);
|
|
340
|
+
}
|
|
341
|
+
function q(e) {
|
|
342
|
+
v.value = e.schemeId, S.value = e.nodes, y.value = e.parentId, _.value = e.title, b.value = e.openMode, u.value++;
|
|
343
|
+
}
|
|
344
|
+
async function ne(e) {
|
|
345
|
+
G();
|
|
346
|
+
let t = u.value, n = await K(e);
|
|
347
|
+
return () => {
|
|
348
|
+
if (G(), t !== u.value) throw new c("菜单候选已变化,请重新读取");
|
|
349
|
+
q(n);
|
|
350
|
+
};
|
|
351
|
+
}
|
|
352
|
+
async function ie(e) {
|
|
353
|
+
let t;
|
|
354
|
+
try {
|
|
355
|
+
G(!0), t = ++F, f.value = !0;
|
|
356
|
+
let n = ++u.value;
|
|
357
|
+
m.value = "";
|
|
358
|
+
let r = K(e), i = "then" in r ? await r : r;
|
|
359
|
+
if (!B() || t !== F) return;
|
|
360
|
+
if (G(!0), n !== u.value) throw new c("菜单候选已变化,请重新读取");
|
|
361
|
+
q(i), m.value = "";
|
|
362
|
+
} catch (e) {
|
|
363
|
+
B() && (t === void 0 || t === F) && (m.value = X(e));
|
|
364
|
+
} finally {
|
|
365
|
+
t === F && (f.value = !1);
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
async function Z() {
|
|
369
|
+
W();
|
|
370
|
+
let e = C.value?.id;
|
|
371
|
+
if (e) {
|
|
372
|
+
D.value = !1, E.value = void 0;
|
|
373
|
+
try {
|
|
374
|
+
let t = await s();
|
|
375
|
+
if (!B() || C.value?.id !== e) return;
|
|
376
|
+
E.value = L(t).find(({ menu: t }) => t.id === e)?.menu, D.value = !0, m.value = "";
|
|
377
|
+
} catch {
|
|
378
|
+
B() && (m.value = "菜单已添加,导航刷新失败。请查询或刷新导航,无需重复添加。");
|
|
379
|
+
}
|
|
380
|
+
}
|
|
381
|
+
}
|
|
382
|
+
async function Q(t, n) {
|
|
383
|
+
if (B()) {
|
|
384
|
+
let r = R, i = n ?? (r.record ? {
|
|
385
|
+
...r.record,
|
|
386
|
+
id: t
|
|
387
|
+
} : await e.view(r.schemeId, t));
|
|
388
|
+
W(), C.value = i, T.value = r.audience ?? I(V.value.find((e) => e.id === i.schemeId)), w.value = r.path ?? [
|
|
389
|
+
V.value.find((e) => e.id === i.schemeId)?.title,
|
|
390
|
+
L(S.value).find(({ menu: e }) => e.id === i.parentId)?.path,
|
|
391
|
+
i.title
|
|
392
|
+
].filter(Boolean).join(" / "), R = void 0, M.value = !1, u.value++, await o.clear().catch(() => {}), B() && await Z();
|
|
393
|
+
}
|
|
394
|
+
return {
|
|
395
|
+
title: "菜单入口已保存",
|
|
396
|
+
lines: B() ? [w.value, D.value ? E.value ? "当前用户可见,可打开业务页面。" : "入口已保存;当前登录身份暂不可见,请由适用范围内的使用者核实导航。" : "导航可见性尚未核实;不要重复添加。"] : ["保存已完成,请在原范围核实入口。"]
|
|
397
|
+
};
|
|
398
|
+
}
|
|
399
|
+
async function $(t, n) {
|
|
400
|
+
let [a, o, s, c] = await Promise.all([
|
|
401
|
+
e.context(r),
|
|
402
|
+
e.context("platform.menu"),
|
|
403
|
+
e.schemes(),
|
|
404
|
+
e.tree(t.schemeId)
|
|
405
|
+
]);
|
|
406
|
+
if (W(), !o.actions.some((e) => e.actionCode === "create" && e.authorized)) throw new i("当前没有添加菜单入口权限");
|
|
407
|
+
if (Y(a)) throw new i(Y(a));
|
|
408
|
+
let l = s.find((e) => e.id === t.schemeId && e.enabled !== !1);
|
|
409
|
+
if (!l) throw new i("菜单方案已不可用");
|
|
410
|
+
if (t.parentId !== "root" && !J(c).some((e) => e.menu.id === t.parentId)) throw new i("放置目录已不可用,请重新审阅");
|
|
411
|
+
let u = t.parentId === "root" ? [] : re(c, t.parentId), d = JSON.stringify([
|
|
412
|
+
l.id,
|
|
413
|
+
l.alias ?? null,
|
|
414
|
+
l.title ?? null,
|
|
415
|
+
l.scopeType ?? null,
|
|
416
|
+
l.tenantId ?? null,
|
|
417
|
+
l.organizationId ?? null,
|
|
418
|
+
u.map((e) => [e.id, e.title])
|
|
419
|
+
]);
|
|
420
|
+
if (n && d !== n) throw new i("菜单方案适用范围或目录已变化,请重新读取候选并审阅");
|
|
421
|
+
return {
|
|
422
|
+
scheme: l,
|
|
423
|
+
signature: d,
|
|
424
|
+
path: [
|
|
425
|
+
l.title ?? l.alias,
|
|
426
|
+
...u.map((e) => e.title),
|
|
427
|
+
t.title
|
|
428
|
+
].filter(Boolean).join(" / ")
|
|
429
|
+
};
|
|
430
|
+
}
|
|
431
|
+
async function ae() {
|
|
432
|
+
if (G(), !H.value) throw new c("请补齐菜单名称及可用业务页面");
|
|
433
|
+
let n = u.value, s = {
|
|
434
|
+
moduleAlias: r,
|
|
435
|
+
schemeId: v.value,
|
|
436
|
+
parentId: y.value,
|
|
437
|
+
title: _.value.trim(),
|
|
438
|
+
openMode: b.value,
|
|
439
|
+
enabled: !0
|
|
440
|
+
}, d = await $(s);
|
|
441
|
+
if (G(), u.value !== n) throw new c("菜单候选已变化,请重新审阅");
|
|
442
|
+
let h = d.path, g = t(), x = () => B() && a.active() && j.value && A.value && !f.value && !R && !C.value && u.value === n, S = {
|
|
443
|
+
kind: "record-save",
|
|
444
|
+
moduleAlias: "platform.menu",
|
|
445
|
+
requestId: g,
|
|
446
|
+
pageContext: { scheme: s.schemeId }
|
|
447
|
+
};
|
|
448
|
+
return {
|
|
449
|
+
receiptReference: S,
|
|
450
|
+
presentation: {
|
|
451
|
+
title: "添加业务入口",
|
|
452
|
+
lines: [
|
|
453
|
+
h,
|
|
454
|
+
`适用范围:${I(d.scheme)}`,
|
|
455
|
+
`打开方式:${s.openMode === "window" ? "新窗口" : "页签内"}`,
|
|
456
|
+
"只添加入口,不开通应用或授予业务权限。",
|
|
457
|
+
...U.value ? [`此位置已有「${U.value.menu.title}」,本次将另加一个入口。`] : []
|
|
458
|
+
],
|
|
459
|
+
details: {
|
|
460
|
+
title: "查看目标模块",
|
|
461
|
+
lines: [r]
|
|
462
|
+
}
|
|
463
|
+
},
|
|
464
|
+
confirmLabel: "确认添加入口",
|
|
465
|
+
expiresAt: Date.now() + 3e5,
|
|
466
|
+
isCurrent: x,
|
|
467
|
+
async execute() {
|
|
468
|
+
if (!x() || p.value) throw new i("菜单候选或编辑范围已变化,请重新审阅");
|
|
469
|
+
p.value = !0, m.value = "";
|
|
470
|
+
let t = !1;
|
|
471
|
+
try {
|
|
472
|
+
if (await $(s, d.signature), !x() || (R = {
|
|
473
|
+
requestId: g,
|
|
474
|
+
schemeId: s.schemeId,
|
|
475
|
+
record: s,
|
|
476
|
+
path: h,
|
|
477
|
+
audience: I(d.scheme)
|
|
478
|
+
}, await o.save(S), !B() || !a.active() || u.value !== n)) throw new i("菜单候选或编辑范围已变化,请重新审阅");
|
|
479
|
+
t = !0;
|
|
480
|
+
let r = await e.insert(s.schemeId, s, g);
|
|
481
|
+
return await Q(r.record.id, r.record);
|
|
482
|
+
} catch (e) {
|
|
483
|
+
if (B()) {
|
|
484
|
+
if (!t || e instanceof i || e instanceof l && [
|
|
485
|
+
400,
|
|
486
|
+
401,
|
|
487
|
+
403,
|
|
488
|
+
404,
|
|
489
|
+
409,
|
|
490
|
+
422
|
|
491
|
+
].includes(e.status ?? 0)) {
|
|
492
|
+
try {
|
|
493
|
+
R && await o.clear(), R = void 0;
|
|
494
|
+
} catch {
|
|
495
|
+
R && (R.rejected = !0), M.value = !0, m.value = "操作未提交,但原请求标识尚未清除,请先查询结果。";
|
|
496
|
+
}
|
|
497
|
+
throw new i(X(e));
|
|
498
|
+
}
|
|
499
|
+
R && (M.value = !0, u.value++), m.value = R ? "保存结果尚未确定,请查询原请求结果,勿重复添加。" : X(e);
|
|
500
|
+
}
|
|
501
|
+
throw e;
|
|
502
|
+
} finally {
|
|
503
|
+
B() && (p.value = !1);
|
|
504
|
+
}
|
|
505
|
+
},
|
|
506
|
+
lookup: oe
|
|
507
|
+
};
|
|
508
|
+
}
|
|
509
|
+
async function oe() {
|
|
510
|
+
if (W(), !R || p.value) return;
|
|
511
|
+
let t = R;
|
|
512
|
+
if (t.rejected) return await o.clear(), W(), R === t ? (R = void 0, M.value = !1, m.value = "", u.value++, {
|
|
513
|
+
title: "操作未提交",
|
|
514
|
+
lines: ["恢复标识已清除,可以重新审阅并添加入口。"]
|
|
515
|
+
}) : void 0;
|
|
516
|
+
let n = await e.receipt(t.schemeId, t.requestId);
|
|
517
|
+
if (W(), R === t && n.committed && n.recordId) return Q(n.recordId);
|
|
518
|
+
}
|
|
519
|
+
return {
|
|
520
|
+
moduleAlias: r,
|
|
521
|
+
revision: u,
|
|
522
|
+
loading: d,
|
|
523
|
+
updating: f,
|
|
524
|
+
saving: p,
|
|
525
|
+
error: m,
|
|
526
|
+
entryIssue: h,
|
|
527
|
+
title: _,
|
|
528
|
+
schemeId: v,
|
|
529
|
+
parentId: y,
|
|
530
|
+
openMode: b,
|
|
531
|
+
schemes: x,
|
|
532
|
+
tree: S,
|
|
533
|
+
options: V,
|
|
534
|
+
directories: ee,
|
|
535
|
+
saved: C,
|
|
536
|
+
savedPath: w,
|
|
537
|
+
savedAudience: T,
|
|
538
|
+
visibleMenu: E,
|
|
539
|
+
visibilityChecked: D,
|
|
540
|
+
authorized: A,
|
|
541
|
+
ready: j,
|
|
542
|
+
resultUnknown: M,
|
|
543
|
+
canSave: H,
|
|
544
|
+
duplicate: U,
|
|
545
|
+
load: te,
|
|
546
|
+
update: ie,
|
|
547
|
+
planRevision: ne,
|
|
548
|
+
prepare: ae,
|
|
549
|
+
lookupPending: oe,
|
|
550
|
+
refreshVisibility: Z,
|
|
551
|
+
async startAnother() {
|
|
552
|
+
if (W(), !C.value || p.value || R) throw new c("请先核实当前入口保存结果");
|
|
553
|
+
await o.clear(), W(), C.value = void 0, w.value = "", T.value = "", E.value = void 0, D.value = !1, j.value = !1, u.value++, await te();
|
|
554
|
+
},
|
|
555
|
+
dispose() {
|
|
556
|
+
N = !0, P++, F++, f.value = !1, u.value++;
|
|
557
|
+
},
|
|
558
|
+
invalidate() {
|
|
559
|
+
F++, f.value = !1, u.value++;
|
|
560
|
+
}
|
|
561
|
+
};
|
|
562
|
+
}
|
|
563
|
+
function re(e, t, n = []) {
|
|
564
|
+
for (let r of e) {
|
|
565
|
+
let e = [...n, r.record];
|
|
566
|
+
if (r.record.id === t) return e;
|
|
567
|
+
let i = re(r.children, t, e);
|
|
568
|
+
if (i.length) return i;
|
|
569
|
+
}
|
|
570
|
+
return [];
|
|
571
|
+
}
|
|
572
|
+
function J(e) {
|
|
573
|
+
return e.flatMap(({ record: e, children: t }) => e.enabled === !1 ? [] : [...e.moduleAlias ? [] : [{
|
|
574
|
+
menu: e,
|
|
575
|
+
path: e.title
|
|
576
|
+
}], ...J(t).map((t) => ({
|
|
577
|
+
...t,
|
|
578
|
+
path: `${e.title} / ${t.path}`
|
|
579
|
+
}))]);
|
|
580
|
+
}
|
|
581
|
+
function Y(e) {
|
|
582
|
+
return e.entryType === "route" ? e.entryRoute ? "" : "该模块尚未配置页面地址,请返回模块补充。" : e.entryType === "link" ? e.entryExternalUrl ? "" : "该模块尚未配置链接地址,请返回模块补充。" : e.uiDescriptor?.page ? "" : "该模块尚无可用业务页面,请先发布页面配置。";
|
|
583
|
+
}
|
|
584
|
+
function X(e) {
|
|
585
|
+
return e instanceof Error ? e.message : "操作暂不可用,请重试。";
|
|
586
|
+
}
|
|
587
|
+
//#endregion
|
|
588
|
+
//#region src/views/configurationEditorNavigation.ts
|
|
589
|
+
async function ie(e, t) {
|
|
590
|
+
if (t?.aborted || (e() || await new Promise((n, r) => {
|
|
591
|
+
let i = (e) => {
|
|
592
|
+
o(), clearTimeout(s), t?.removeEventListener("abort", a), e ? r(e) : n();
|
|
593
|
+
}, a = () => i(new DOMException("Navigation cancelled", "AbortError")), o = M(e, (e) => {
|
|
594
|
+
e && i();
|
|
595
|
+
}, { flush: "post" }), s = setTimeout(() => i(/* @__PURE__ */ Error("配置页面尚未就绪,请重新打开后继续。")), 15e3);
|
|
596
|
+
t?.addEventListener("abort", a, { once: !0 });
|
|
597
|
+
}), await E(), t?.aborted)) throw new DOMException("Navigation cancelled", "AbortError");
|
|
598
|
+
}
|
|
599
|
+
//#endregion
|
|
600
|
+
//#region src/platform-admin-runtime/module-menu/moduleMenuWorkspace.ts
|
|
601
|
+
var Z = Symbol("module-menu-workspace");
|
|
602
|
+
function Q() {
|
|
603
|
+
return T(Z, void 0);
|
|
604
|
+
}
|
|
605
|
+
//#endregion
|
|
606
|
+
//#region src/views/moduleGovernanceWorkspaceView.ts
|
|
607
|
+
var $ = [
|
|
608
|
+
"overview",
|
|
609
|
+
"metadata",
|
|
610
|
+
"actions",
|
|
611
|
+
"rules",
|
|
612
|
+
"ui",
|
|
613
|
+
"menu",
|
|
614
|
+
"preview"
|
|
615
|
+
], ae = P({
|
|
616
|
+
type: "platform.module.governance",
|
|
617
|
+
route: "/_platform/workspace/platform.module.governance",
|
|
618
|
+
moduleAlias: "platform.module",
|
|
619
|
+
component: C(() => import("./ModuleGovernanceView-LkWCtops.js")),
|
|
620
|
+
layout: "workspace",
|
|
621
|
+
routeTitle: "模块管理",
|
|
622
|
+
presentations: ["tab"],
|
|
623
|
+
titleOf: (e) => `低代码治理:${e.moduleTitle ?? e.moduleAlias}`,
|
|
624
|
+
tabIdentityParamsOf: (e) => ({ moduleAlias: e.moduleAlias }),
|
|
625
|
+
parentRouteQueryOf: () => ({}),
|
|
626
|
+
parse(e) {
|
|
627
|
+
let t = e.moduleAlias, n = e.moduleTitle, r = e.governanceTab === "diagnostics" ? "preview" : e.governanceTab;
|
|
628
|
+
if (typeof t == "string" && t) return {
|
|
629
|
+
moduleAlias: t,
|
|
630
|
+
...typeof n == "string" && n ? { moduleTitle: n } : {},
|
|
631
|
+
...oe(r) ? { governanceTab: r } : {}
|
|
632
|
+
};
|
|
633
|
+
}
|
|
634
|
+
});
|
|
635
|
+
function oe(e) {
|
|
636
|
+
return typeof e == "string" && $.includes(e);
|
|
637
|
+
}
|
|
638
|
+
//#endregion
|
|
639
|
+
export { ne as a, F as c, ie as i, L as l, ae as n, q as o, Q as r, K as s, $ as t, P as u };
|