@ximatai/muyun-web-app 0.26.21 → 0.26.22
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-6L75GZVc.js → BusinessActivityLogView-CXBpVbZW.js} +2 -2
- package/dist/{BusinessLogListDrawer-C4iFnkE7.js → BusinessLogListDrawer-DToyqP9V.js} +1 -1
- package/dist/{CodeConfigurationView-D7sqbNCg.js → CodeConfigurationView-DAdbnF2Y.js} +3 -3
- package/dist/{ConfigurationTranslationView-ta82REbn.js → ConfigurationTranslationView-D1aLZQlx.js} +1 -1
- package/dist/{LoginAuditLogView-B_RQ9JIX.js → LoginAuditLogView-DRxp6BbU.js} +2 -2
- package/dist/{ModuleActionManagementView-DtGF3NC_.js → ModuleActionManagementView-D4oXCnW2.js} +2 -2
- package/dist/{ModuleGovernanceView-Cl6tkZ6M.js → ModuleGovernanceView-C7V5KQcA.js} +6 -6
- package/dist/{RequestErrorLogView-BJDO3Scn.js → RequestErrorLogView-S6O4ha82.js} +2 -2
- package/dist/{RoleDetailWorkspaceView-C0Ab3PEp.js → RoleDetailWorkspaceView-lg4XwTlN.js} +3 -3
- package/dist/{RuntimeLogView-jP9ceuJD.js → RuntimeLogView-BuF-xgEc.js} +1 -1
- package/dist/{WorkflowAdministrationView-BmNJQYtq.js → WorkflowAdministrationView-DkK3Wybi.js} +2 -2
- package/dist/{WorkflowConfigurationView-Dh6BKQm5.js → WorkflowConfigurationView-8DFNdIyI.js} +3 -3
- package/dist/{WorkflowWorkbenchView-BvPNKbuV.js → WorkflowWorkbenchView-CAloU49z.js} +2 -2
- package/dist/{codeConfiguration-DhCBKbkc.js → codeConfiguration-BV9yki1E.js} +3 -3
- package/dist/index.css +1 -1
- package/dist/index.js +9 -9
- package/dist/{moduleMenuWorkspace-BbVmNKZn.js → moduleMenuWorkspace-BBOQrHeT.js} +2 -2
- package/dist/{platform-components-i2ONyZ8r.js → platform-components-C9cG_1E2.js} +1098 -1074
- package/dist/{platform-workbench-DhaREttd.js → platform-workbench-BSTroBaq.js} +1024 -999
- package/dist/types/dynamic-page-runtime/ModulePageBusinessSession.d.ts +4 -0
- package/dist/types/dynamic-page-runtime/ModulePageHostRuntime.vue.d.ts +8 -0
- package/dist/types/dynamic-page-runtime/ModulePageRecordContent.vue.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/ModuleRecordDetailActions.vue.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/RecordFormSurface.vue.d.ts +2 -0
- package/dist/types/dynamic-page-runtime/useModulePageSession.d.ts +2 -0
- package/dist/types/platform-components/RecordFormFields.vue.d.ts +10 -8
- package/dist/types/platform-components/useBusinessCodeForm.d.ts +1 -0
- package/dist/types/platform-workbench/useAssistantConversation.d.ts +3 -0
- package/dist/types/web-contracts/operation.d.ts +2 -0
- package/dist/{useWorkflowConfigurationContext-B_NxZFyz.js → useWorkflowConfigurationContext-ClwD0BWE.js} +2 -2
- package/dist/{workspaceViews-MTwNg_aQ.js → workspaceViews-Cvi7uakV.js} +9 -9
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as e } from "./rolldown-runtime-BAC7EHh5.js";
|
|
2
|
-
import { $ as t, $i as n, $t as r, An as i, Ar as a, At as o, B as s, Ba as c, Br as l, Bt as u, C as d, Ct as f, Da as p, Dn as m, Dt as h, E as g, Et as _, F as v, Fa as y, Fn as b, Fr as x, Ft as S, G as C, Ga as w, Gi as T, H as E, Hn as D, Hr as ee, Ht as te, I as ne, It as O, J as k, Ji as re, K as ie, Ka as ae, Ki as oe, L as se, La as A, Lt as ce, M as le, Ma as ue, Mn as j, Mt as de, N as fe, Nn as pe, Nt as me, O as he, P as ge, Pi as _e, Pn as ve, Pt as ye, Qi as be, R as xe, Rr as M, Rt as Se, St as Ce, T as N, Tt as P, U as we, Ui as Te, Un as Ee, Va as De, Vr as Oe, W as ke, Wr as Ae, X as je, Xa as Me, Xi as F, Xr as Ne, Y as Pe, Yt as Fe, Zr as Ie, _ as Le, _i as Re, _n as ze, _t as Be, aa as Ve, ai as He, at as Ue, b as We, bt as Ge, ca as Ke, ci as qe, da as Je, dr as Ye, ea as Xe, en as Ze, eo as Qe, er as $e, fa as I, fr as et, g as tt, gi as nt, gn as rt, hi as it, hn as at, hr as ot, ht as st, i as ct, ia as lt, in as ut, io as dt, jr as ft, jt as pt, ka as mt, kr as ht, kt as gt, mi as _t, n as vt, na as yt, nt as bt, or as xt, ot as St, pa as Ct, pn as wt, q as Tt, qa as Et, qi as Dt, qr as Ot, qt as kt, r as At, ra as jt, rn as Mt, ro as Nt, rr as Pt, rt as Ft, sa as It, st as Lt, ta as Rt, tn as zt, to as Bt, u as Vt, ua as Ht, ur as L, v as Ut, vi as Wt, vt as Gt, wa as Kt, wt as qt, xa as Jt, xi as Yt, yi as Xt, yn as Zt, yt as Qt, zn as $t, zr as en, zt as tn } from "./platform-components-
|
|
3
|
-
import { Fragment as R, Teleport as nn, Transition as rn, computed as z, createBlock as B, createCommentVNode as V, createElementBlock as H, createElementVNode as U, createSlots as an, createStaticVNode as on, createTextVNode as W, createVNode as G, defineComponent as sn, getCurrentInstance as cn, guardReactiveProps as ln, h as un, inject as dn, isRef as fn, markRaw as pn, mergeProps as mn, nextTick as hn, normalizeClass as gn, normalizeProps as _n, normalizeStyle as vn, onActivated as yn, onBeforeUnmount as bn, onDeactivated as xn, onMounted as Sn, onUnmounted as Cn, openBlock as K, provide as wn, proxyRefs as Tn, ref as q, renderList as J, renderSlot as En, resolveComponent as Dn, resolveDynamicComponent as
|
|
2
|
+
import { $ as t, $i as n, $t as r, An as i, Ar as a, At as o, B as s, Ba as c, Br as l, Bt as u, C as d, Ct as f, Da as p, Dn as m, Dt as h, E as g, Et as _, F as v, Fa as y, Fn as b, Fr as x, Ft as S, G as C, Ga as w, Gi as T, H as E, Hn as D, Hr as ee, Ht as te, I as ne, It as O, J as k, Ji as re, K as ie, Ka as ae, Ki as oe, L as se, La as A, Lt as ce, M as le, Ma as ue, Mn as j, Mt as de, N as fe, Nn as pe, Nt as me, O as he, P as ge, Pi as _e, Pn as ve, Pt as ye, Qi as be, R as xe, Rr as M, Rt as Se, St as Ce, T as N, Tt as P, U as we, Ui as Te, Un as Ee, Va as De, Vr as Oe, W as ke, Wr as Ae, X as je, Xa as Me, Xi as F, Xr as Ne, Y as Pe, Yt as Fe, Zr as Ie, _ as Le, _i as Re, _n as ze, _t as Be, aa as Ve, ai as He, at as Ue, b as We, bt as Ge, ca as Ke, ci as qe, da as Je, dr as Ye, ea as Xe, en as Ze, eo as Qe, er as $e, fa as I, fr as et, g as tt, gi as nt, gn as rt, hi as it, hn as at, hr as ot, ht as st, i as ct, ia as lt, in as ut, io as dt, jr as ft, jt as pt, ka as mt, kr as ht, kt as gt, mi as _t, n as vt, na as yt, nt as bt, or as xt, ot as St, pa as Ct, pn as wt, q as Tt, qa as Et, qi as Dt, qr as Ot, qt as kt, r as At, ra as jt, rn as Mt, ro as Nt, rr as Pt, rt as Ft, sa as It, st as Lt, ta as Rt, tn as zt, to as Bt, u as Vt, ua as Ht, ur as L, v as Ut, vi as Wt, vt as Gt, wa as Kt, wt as qt, xa as Jt, xi as Yt, yi as Xt, yn as Zt, yt as Qt, zn as $t, zr as en, zt as tn } from "./platform-components-C9cG_1E2.js";
|
|
3
|
+
import { Fragment as R, Teleport as nn, Transition as rn, computed as z, createBlock as B, createCommentVNode as V, createElementBlock as H, createElementVNode as U, createSlots as an, createStaticVNode as on, createTextVNode as W, createVNode as G, defineComponent as sn, getCurrentInstance as cn, guardReactiveProps as ln, h as un, inject as dn, isRef as fn, markRaw as pn, mergeProps as mn, nextTick as hn, normalizeClass as gn, normalizeProps as _n, normalizeStyle as vn, onActivated as yn, onBeforeUnmount as bn, onDeactivated as xn, onMounted as Sn, onUnmounted as Cn, openBlock as K, provide as wn, proxyRefs as Tn, ref as q, renderList as J, renderSlot as En, resolveComponent as Dn, resolveDynamicComponent as On, shallowReactive as Y, shallowRef as kn, toDisplayString as X, toHandlers as An, toRaw as jn, unref as Z, vModelSelect as Mn, vModelText as Nn, vShow as Pn, watch as Q, watchEffect as Fn, withCtx as $, withDirectives as In, withKeys as Ln, withModifiers as Rn } from "vue";
|
|
4
4
|
//#region src/web-contracts/constructionPlan.ts
|
|
5
5
|
var zn = {
|
|
6
6
|
textItems: 64,
|
|
@@ -183,13 +183,14 @@ function tr(e) {
|
|
|
183
183
|
"tenantId",
|
|
184
184
|
"menuId",
|
|
185
185
|
"pageContext",
|
|
186
|
-
"pageSelection"
|
|
186
|
+
"pageSelection",
|
|
187
|
+
"recordId"
|
|
187
188
|
] : [
|
|
188
189
|
"kind",
|
|
189
190
|
"moduleAlias",
|
|
190
191
|
"requestId",
|
|
191
192
|
"relationId"
|
|
192
|
-
], !n("moduleAlias", i) || String(t.moduleAlias).length > 128 || !n("requestId", /^[a-zA-Z0-9-]{16,80}$/) || t.kind === "child-metadata" && !n("relationId", r) || t.tenantId !== void 0 && !n("tenantId", r) || t.menuId !== void 0 && !n("menuId", /^[a-zA-Z0-9_.:-]{1,128}$/)) throw Error("无效操作查询引用");
|
|
193
|
+
], !n("moduleAlias", i) || String(t.moduleAlias).length > 128 || !n("requestId", /^[a-zA-Z0-9-]{16,80}$/) || t.kind === "child-metadata" && !n("relationId", r) || t.tenantId !== void 0 && !n("tenantId", r) || t.menuId !== void 0 && !n("menuId", /^[a-zA-Z0-9_.:-]{1,128}$/) || t.kind === "record-save" && t.recordId !== void 0 && !n("recordId", r)) throw Error("无效操作查询引用");
|
|
193
194
|
} else throw Error("不支持的操作查询引用");
|
|
194
195
|
if (t.kind === "record-save") {
|
|
195
196
|
let e = (e) => typeof e == "string" && e.trim().length > 0 && e.length <= 512 && Array.from(e).every((e) => e.charCodeAt(0) >= 32 && e.charCodeAt(0) !== 127);
|
|
@@ -217,6 +218,10 @@ async function rr(e, t) {
|
|
|
217
218
|
headers: {
|
|
218
219
|
...n.tenantId ? { "X-MuYun-Tenant-Id": n.tenantId } : {},
|
|
219
220
|
...n.menuId ? { "X-MuYun-Menu-Id": n.menuId } : {},
|
|
221
|
+
...n.recordId ? { "X-MuYun-Record-Context": JSON.stringify({
|
|
222
|
+
moduleAlias: n.moduleAlias,
|
|
223
|
+
recordId: n.recordId
|
|
224
|
+
}) } : {},
|
|
220
225
|
...n.pageContext ? { "X-MuYun-Page-Context": JSON.stringify(n.pageContext) } : {},
|
|
221
226
|
...n.pageSelection ? { "X-MuYun-Page-Selection": JSON.stringify(n.pageSelection) } : {}
|
|
222
227
|
}
|
|
@@ -1909,7 +1914,7 @@ var Zr = ["src", "alt"], Qr = {
|
|
|
1909
1914
|
"workbench-brand-control--with-title": e.showTitleArea,
|
|
1910
1915
|
"workbench-brand-control--compact-open": e.presentation === "compact" && e.compactOpen
|
|
1911
1916
|
}]])
|
|
1912
|
-
}, [(K(), B(
|
|
1917
|
+
}, [(K(), B(On(e.presentation === "compact" ? "button" : "div"), {
|
|
1913
1918
|
class: gn(["workbench-brand-identity", {
|
|
1914
1919
|
"workbench-brand-identity--open": e.compactOpen,
|
|
1915
1920
|
"workbench-brand-identity--with-title": e.showTitleArea
|
|
@@ -6218,7 +6223,7 @@ var bl = ["aria-label"], xl = { class: "assistant-panel__header" }, Sl = ["aria-
|
|
|
6218
6223
|
return K(), H("li", {
|
|
6219
6224
|
class: "deep-node",
|
|
6220
6225
|
style: vn({ "--depth": i.value })
|
|
6221
|
-
}, [(K(), B(
|
|
6226
|
+
}, [(K(), B(On(e.node.navigable ? "button" : "div"), {
|
|
6222
6227
|
class: gn(["deep-node-button", {
|
|
6223
6228
|
navigable: e.node.navigable,
|
|
6224
6229
|
branch: e.node.hasChildren,
|
|
@@ -7732,7 +7737,7 @@ var xd = ["id"], Sd = {
|
|
|
7732
7737
|
}, [...n[2] ||= [U("i", {
|
|
7733
7738
|
class: "root-menu-branch-indicator",
|
|
7734
7739
|
"aria-hidden": "true"
|
|
7735
|
-
}, null, -1)]], 8, Dd)], 42, Td)) : (K(), B(
|
|
7740
|
+
}, null, -1)]], 8, Dd)], 42, Td)) : (K(), B(On(t.navigable || ge.value ? "button" : "div"), {
|
|
7736
7741
|
key: 1,
|
|
7737
7742
|
class: gn(["root-menu-item", {
|
|
7738
7743
|
active: A.value?.record.id === t.record.id,
|
|
@@ -8640,7 +8645,7 @@ function pp(e) {
|
|
|
8640
8645
|
//#endregion
|
|
8641
8646
|
//#region src/dynamic-page-runtime/relationDraftController.ts
|
|
8642
8647
|
function mp() {
|
|
8643
|
-
let e =
|
|
8648
|
+
let e = Y(/* @__PURE__ */ new Map()), t = q(0);
|
|
8644
8649
|
return {
|
|
8645
8650
|
register(t) {
|
|
8646
8651
|
let n = Symbol();
|
|
@@ -8703,6 +8708,10 @@ var _p = () => dn(hp, () => void 0), vp = ["role"], yp = /*#__PURE__*/ et(/* @__
|
|
|
8703
8708
|
type: Boolean,
|
|
8704
8709
|
default: !1
|
|
8705
8710
|
},
|
|
8711
|
+
formPending: {
|
|
8712
|
+
type: Boolean,
|
|
8713
|
+
default: !1
|
|
8714
|
+
},
|
|
8706
8715
|
saveNeedsCheck: {
|
|
8707
8716
|
type: Boolean,
|
|
8708
8717
|
default: !1
|
|
@@ -8759,7 +8768,7 @@ var _p = () => dn(hp, () => void 0), vp = ["role"], yp = /*#__PURE__*/ et(/* @__
|
|
|
8759
8768
|
"detailAction"
|
|
8760
8769
|
],
|
|
8761
8770
|
setup(e, { emit: t }) {
|
|
8762
|
-
let n = Me(), r = e, i = t, a = z(() => r.mode === "create" || r.mode === "edit"), o = z(() => r.record?.id == null ? void 0 : String(r.record.id)), s = z(() => !a.value || r.recycleBinActive || r.detailLoading || r.detailLoadFailed ? !1 : r.context.can(r.mode === "create" ? "create" : "update") === !0), c = z(() => r.mode === "view" && !r.recycleBinActive && r.showStandardViewActions && !r.managedActions), l = z(() => {
|
|
8771
|
+
let n = Me(), r = e, i = t, a = z(() => r.mode === "create" || r.mode === "edit"), o = z(() => r.record?.id == null ? void 0 : String(r.record.id)), s = z(() => !a.value || r.formPending || r.recycleBinActive || r.detailLoading || r.detailLoadFailed ? !1 : r.context.can(r.mode === "create" ? "create" : "update") === !0), c = z(() => r.mode === "view" && !r.recycleBinActive && r.showStandardViewActions && !r.managedActions), l = z(() => {
|
|
8763
8772
|
if (r.saveNeedsCheck) return [{
|
|
8764
8773
|
key: "__platform-check-save",
|
|
8765
8774
|
title: r.checkingSave ? n.t("platform.screen.ModuleRecordDetailActions.checking", "核实中") : n.t("platform.action.check-save", "核实保存结果"),
|
|
@@ -8776,14 +8785,14 @@ var _p = () => dn(hp, () => void 0), vp = ["role"], yp = /*#__PURE__*/ et(/* @__
|
|
|
8776
8785
|
},
|
|
8777
8786
|
...r.managedActions ? [] : [{
|
|
8778
8787
|
key: "__platform-save",
|
|
8779
|
-
title: r.saving ? n.t("platform.action.saving", "保存中") : n.t("platform.action.save", "保存"),
|
|
8788
|
+
title: r.formPending ? n.t("platform.form.preparing", "正在准备表单…") : r.saving ? n.t("platform.action.saving", "保存中") : n.t("platform.action.save", "保存"),
|
|
8780
8789
|
actionLevel: "primary",
|
|
8781
|
-
loading: r.saving,
|
|
8790
|
+
loading: r.saving || r.formPending,
|
|
8782
8791
|
disabled: !s.value
|
|
8783
8792
|
}],
|
|
8784
8793
|
...r.formActions.filter((e) => e.actionCode === (r.mode === "create" ? "create" : "update")).map((e) => ({
|
|
8785
8794
|
...e,
|
|
8786
|
-
loading: e.loading || e.key === r.activeActionKey,
|
|
8795
|
+
loading: r.formPending || e.loading || e.key === r.activeActionKey,
|
|
8787
8796
|
disabled: r.saving || !s.value || e.disabled
|
|
8788
8797
|
}))
|
|
8789
8798
|
];
|
|
@@ -10446,7 +10455,7 @@ var Bp = {
|
|
|
10446
10455
|
"record",
|
|
10447
10456
|
"retained",
|
|
10448
10457
|
"entries"
|
|
10449
|
-
])) : V("v-if", !0), e.extension && e.extensionContext ? (K(), B(
|
|
10458
|
+
])) : V("v-if", !0), e.extension && e.extensionContext ? (K(), B(On(e.extension?.component), {
|
|
10450
10459
|
key: 1,
|
|
10451
10460
|
context: e.extensionContext
|
|
10452
10461
|
}, null, 8, ["context"])) : V("v-if", !0)]),
|
|
@@ -10485,7 +10494,7 @@ var nm = /* @__PURE__ */ sn({
|
|
|
10485
10494
|
let n = e.location;
|
|
10486
10495
|
return n.surface === t.surface ? "section" in n ? n.section === t.position : !t.field || n.fieldName !== t.field.fieldName ? !1 : n.placement === t.position : !1;
|
|
10487
10496
|
}));
|
|
10488
|
-
return (t, r) => (K(!0), H(R, null, J(n.value, (t) => (K(), B(
|
|
10497
|
+
return (t, r) => (K(!0), H(R, null, J(n.value, (t) => (K(), B(On(t.component), {
|
|
10489
10498
|
key: t.key,
|
|
10490
10499
|
context: e.contextFor(t, e.field)
|
|
10491
10500
|
}, null, 8, ["context"]))), 128));
|
|
@@ -10776,11 +10785,18 @@ var Tm = /* @__PURE__ */ sn({
|
|
|
10776
10785
|
function g(e) {
|
|
10777
10786
|
return d(e)?.imageUploadAdvisory?.(u(), n);
|
|
10778
10787
|
}
|
|
10779
|
-
let _ = q(!0);
|
|
10780
|
-
function
|
|
10781
|
-
_.value = e.valid;
|
|
10788
|
+
let _ = q(!0), v = q(!1);
|
|
10789
|
+
function y(e) {
|
|
10790
|
+
_.value = e.valid, v.value = e.pending === !0;
|
|
10782
10791
|
}
|
|
10783
|
-
return Q([
|
|
10792
|
+
return Q([
|
|
10793
|
+
_,
|
|
10794
|
+
v,
|
|
10795
|
+
c
|
|
10796
|
+
], () => i("validity-change", {
|
|
10797
|
+
valid: _.value && c.value,
|
|
10798
|
+
...v.value ? { pending: !0 } : {}
|
|
10799
|
+
}), { immediate: !0 }), (t, n) => (K(), B(Z(ne), {
|
|
10784
10800
|
as: "div",
|
|
10785
10801
|
surface: "record",
|
|
10786
10802
|
class: "module-form"
|
|
@@ -10808,7 +10824,7 @@ var Tm = /* @__PURE__ */ sn({
|
|
|
10808
10824
|
"image-upload-hint-of": h,
|
|
10809
10825
|
"image-upload-advisory-of": g,
|
|
10810
10826
|
"onUpdate:field": n[0] ||= (e, t) => i("update:field", e, t),
|
|
10811
|
-
onValidityChange:
|
|
10827
|
+
onValidityChange: y,
|
|
10812
10828
|
onReferenceDisplayChange: n[1] ||= (e, t) => i("reference-display-change", e, t)
|
|
10813
10829
|
}, {
|
|
10814
10830
|
"before-field": $(({ field: e }) => [G(nm, {
|
|
@@ -10956,11 +10972,11 @@ var Tm = /* @__PURE__ */ sn({
|
|
|
10956
10972
|
title: t.titleKey ? Z(r).t(t.titleKey, t.title) : t.title,
|
|
10957
10973
|
subtitle: t.subtitle
|
|
10958
10974
|
}, an({
|
|
10959
|
-
default: $(() => [(K(), B(
|
|
10975
|
+
default: $(() => [(K(), B(On(t.component), { context: e.detailSectionContext(e.record) }, null, 8, ["context"]))]),
|
|
10960
10976
|
_: 2
|
|
10961
10977
|
}, [t.subtitleComponent ? {
|
|
10962
10978
|
name: "subtitle",
|
|
10963
|
-
fn: $(() => [(K(), B(
|
|
10979
|
+
fn: $(() => [(K(), B(On(t.subtitleComponent), { context: e.detailSectionContext(e.record) }, null, 8, ["context"]))]),
|
|
10964
10980
|
key: "0"
|
|
10965
10981
|
} : void 0]), 1032, ["title", "subtitle"]))), 128))
|
|
10966
10982
|
], 64)) : V("v-if", !0),
|
|
@@ -11030,7 +11046,7 @@ var Tm = /* @__PURE__ */ sn({
|
|
|
11030
11046
|
}, null, 8, ["record"])) : V("v-if", !0)
|
|
11031
11047
|
], 64));
|
|
11032
11048
|
}
|
|
11033
|
-
}), [["__scopeId", "data-v-
|
|
11049
|
+
}), [["__scopeId", "data-v-795e4b51"]]), Am = /* @__PURE__ */ sn({
|
|
11034
11050
|
name: "ModuleReferenceRecordDetailBrowser",
|
|
11035
11051
|
__name: "ModuleReferenceRecordDetailBrowser",
|
|
11036
11052
|
props: {
|
|
@@ -11661,7 +11677,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
11661
11677
|
navigator: $(({ index: n }) => [e.tenantScopeExplorerVisible && e.tenantScopeContext && n === 0 ? (K(), B(o, {
|
|
11662
11678
|
key: 0,
|
|
11663
11679
|
controller: e.tenantController
|
|
11664
|
-
}, null, 8, ["controller"])) : V("v-if", !0), e.businessVisible ? (K(), H(R, { key: 1 }, [e.navigatorExtension && n === e.tenantScopeExplorerCount ? (K(), B(
|
|
11680
|
+
}, null, 8, ["controller"])) : V("v-if", !0), e.businessVisible ? (K(), H(R, { key: 1 }, [e.navigatorExtension && n === e.tenantScopeExplorerCount ? (K(), B(On(e.navigatorExtension.component), {
|
|
11665
11681
|
key: 0,
|
|
11666
11682
|
context: e.navigatorExtensionContext
|
|
11667
11683
|
}, null, 8, ["context"])) : V("v-if", !0), !(e.navigatorExtension && n === e.tenantScopeExplorerCount) && e.navigatorLevelAt(n - e.tenantScopeExplorerCount) ? (K(), B(f, {
|
|
@@ -11944,12 +11960,12 @@ function oh(e, t, n, r, i, a) {
|
|
|
11944
11960
|
} : void 0,
|
|
11945
11961
|
e.businessVisible && e.hasCardAssistantAt("outside", "top") ? {
|
|
11946
11962
|
name: "detail-outside-top",
|
|
11947
|
-
fn: $(() => [U("aside", Km, [(K(), B(
|
|
11963
|
+
fn: $(() => [U("aside", Km, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
11948
11964
|
key: "2"
|
|
11949
11965
|
} : void 0,
|
|
11950
11966
|
e.businessVisible && e.hasCardAssistantAt("inside", "top") ? {
|
|
11951
11967
|
name: "detail-content-top",
|
|
11952
|
-
fn: $(() => [U("aside", qm, [(K(), B(
|
|
11968
|
+
fn: $(() => [U("aside", qm, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
11953
11969
|
key: "3"
|
|
11954
11970
|
} : void 0,
|
|
11955
11971
|
e.businessVisible ? {
|
|
@@ -12005,12 +12021,12 @@ function oh(e, t, n, r, i, a) {
|
|
|
12005
12021
|
} : void 0,
|
|
12006
12022
|
e.businessVisible && e.hasCardAssistantAt("inside", "bottom") ? {
|
|
12007
12023
|
name: "detail-content-bottom",
|
|
12008
|
-
fn: $(() => [U("aside", Jm, [(K(), B(
|
|
12024
|
+
fn: $(() => [U("aside", Jm, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12009
12025
|
key: "6"
|
|
12010
12026
|
} : void 0,
|
|
12011
12027
|
e.businessVisible && e.hasCardAssistantAt("outside", "bottom") ? {
|
|
12012
12028
|
name: "detail-outside-bottom",
|
|
12013
|
-
fn: $(() => [U("aside", Ym, [(K(), B(
|
|
12029
|
+
fn: $(() => [U("aside", Ym, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12014
12030
|
key: "7"
|
|
12015
12031
|
} : void 0
|
|
12016
12032
|
]), 1032, [
|
|
@@ -12039,7 +12055,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
12039
12055
|
controller: e.tenantController
|
|
12040
12056
|
}, null, 8, ["controller"])) : V("v-if", !0),
|
|
12041
12057
|
e.navigatorExtension ? (K(), B(x, { key: e.navigatorExtension.key }, {
|
|
12042
|
-
default: $(() => [e.businessVisible ? (K(), B(
|
|
12058
|
+
default: $(() => [e.businessVisible ? (K(), B(On(e.navigatorExtension.component), {
|
|
12043
12059
|
key: 0,
|
|
12044
12060
|
context: e.navigatorExtensionContext
|
|
12045
12061
|
}, null, 8, ["context"])) : V("v-if", !0)]),
|
|
@@ -12304,12 +12320,12 @@ function oh(e, t, n, r, i, a) {
|
|
|
12304
12320
|
}, [
|
|
12305
12321
|
e.businessVisible && e.hasCardAssistantAt("outside", "top") ? {
|
|
12306
12322
|
name: "outside-top",
|
|
12307
|
-
fn: $(() => [U("aside", Xm, [(K(), B(
|
|
12323
|
+
fn: $(() => [U("aside", Xm, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12308
12324
|
key: "0"
|
|
12309
12325
|
} : void 0,
|
|
12310
12326
|
e.businessVisible && e.hasCardAssistantAt("inside", "top") ? {
|
|
12311
12327
|
name: "content-top",
|
|
12312
|
-
fn: $(() => [U("aside", Zm, [(K(), B(
|
|
12328
|
+
fn: $(() => [U("aside", Zm, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12313
12329
|
key: "1"
|
|
12314
12330
|
} : void 0,
|
|
12315
12331
|
e.businessVisible ? {
|
|
@@ -12331,6 +12347,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
12331
12347
|
e.businessVisible ? {
|
|
12332
12348
|
name: "actions",
|
|
12333
12349
|
fn: $(() => [G(w, {
|
|
12350
|
+
"form-pending": e.mainFormPending,
|
|
12334
12351
|
"save-needs-check": e.recordSaveNeedsCheck,
|
|
12335
12352
|
"checking-save": e.saving,
|
|
12336
12353
|
context: e.context,
|
|
@@ -12354,6 +12371,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
12354
12371
|
onOpenWorkspace: e.openDetailWorkspaceView,
|
|
12355
12372
|
onDetailAction: t[16] ||= (t) => e.editorMode === "view" ? e.handleDetailAction(t) : e.handlePlacedFormAction(t)
|
|
12356
12373
|
}, null, 8, [
|
|
12374
|
+
"form-pending",
|
|
12357
12375
|
"save-needs-check",
|
|
12358
12376
|
"checking-save",
|
|
12359
12377
|
"context",
|
|
@@ -12397,12 +12415,12 @@ function oh(e, t, n, r, i, a) {
|
|
|
12397
12415
|
} : void 0,
|
|
12398
12416
|
e.businessVisible && e.hasCardAssistantAt("inside", "bottom") ? {
|
|
12399
12417
|
name: "content-bottom",
|
|
12400
|
-
fn: $(() => [U("aside", Qm, [(K(), B(
|
|
12418
|
+
fn: $(() => [U("aside", Qm, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12401
12419
|
key: "5"
|
|
12402
12420
|
} : void 0,
|
|
12403
12421
|
e.businessVisible && e.hasCardAssistantAt("outside", "bottom") ? {
|
|
12404
12422
|
name: "outside-bottom",
|
|
12405
|
-
fn: $(() => [U("aside", $m, [(K(), B(
|
|
12423
|
+
fn: $(() => [U("aside", $m, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12406
12424
|
key: "6"
|
|
12407
12425
|
} : void 0
|
|
12408
12426
|
]), 1032, ["title", "subtitle"]))
|
|
@@ -12426,7 +12444,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
12426
12444
|
controller: e.tenantController
|
|
12427
12445
|
}, null, 8, ["controller"])) : V("v-if", !0),
|
|
12428
12446
|
e.navigatorExtension ? (K(), B(x, { key: e.navigatorExtension.key }, {
|
|
12429
|
-
default: $(() => [e.businessVisible ? (K(), B(
|
|
12447
|
+
default: $(() => [e.businessVisible ? (K(), B(On(e.navigatorExtension.component), {
|
|
12430
12448
|
key: 0,
|
|
12431
12449
|
context: e.navigatorExtensionContext
|
|
12432
12450
|
}, null, 8, ["context"])) : V("v-if", !0)]),
|
|
@@ -12720,11 +12738,11 @@ function oh(e, t, n, r, i, a) {
|
|
|
12720
12738
|
title: t.titleKey ? e.language.t(t.titleKey, t.title) : t.title,
|
|
12721
12739
|
subtitle: t.subtitle
|
|
12722
12740
|
}, an({
|
|
12723
|
-
default: $(() => [(K(), B(
|
|
12741
|
+
default: $(() => [(K(), B(On(t.component), { context: e.detailSectionContext(e.editingRecord) }, null, 8, ["context"]))]),
|
|
12724
12742
|
_: 2
|
|
12725
12743
|
}, [t.subtitleComponent ? {
|
|
12726
12744
|
name: "subtitle",
|
|
12727
|
-
fn: $(() => [(K(), B(
|
|
12745
|
+
fn: $(() => [(K(), B(On(t.subtitleComponent), { context: e.detailSectionContext(e.editingRecord) }, null, 8, ["context"]))]),
|
|
12728
12746
|
key: "0"
|
|
12729
12747
|
} : void 0]), 1032, ["title", "subtitle"]))), 128))
|
|
12730
12748
|
], 64)) : (K(), H("div", nh, [G(O, {
|
|
@@ -12787,12 +12805,12 @@ function oh(e, t, n, r, i, a) {
|
|
|
12787
12805
|
}, [
|
|
12788
12806
|
e.businessVisible && e.hasCardAssistantAt("outside", "top") ? {
|
|
12789
12807
|
name: "outside-top",
|
|
12790
|
-
fn: $(() => [U("aside", eh, [(K(), B(
|
|
12808
|
+
fn: $(() => [U("aside", eh, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12791
12809
|
key: "0"
|
|
12792
12810
|
} : void 0,
|
|
12793
12811
|
e.businessVisible && e.hasCardAssistantAt("inside", "top") ? {
|
|
12794
12812
|
name: "content-top",
|
|
12795
|
-
fn: $(() => [U("aside", th, [(K(), B(
|
|
12813
|
+
fn: $(() => [U("aside", th, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12796
12814
|
key: "1"
|
|
12797
12815
|
} : void 0,
|
|
12798
12816
|
e.businessVisible ? {
|
|
@@ -12814,6 +12832,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
12814
12832
|
"onBusy",
|
|
12815
12833
|
"onChanged"
|
|
12816
12834
|
]), G(w, {
|
|
12835
|
+
"form-pending": e.mainFormPending,
|
|
12817
12836
|
"save-needs-check": e.recordSaveNeedsCheck,
|
|
12818
12837
|
"checking-save": e.saving,
|
|
12819
12838
|
context: e.context,
|
|
@@ -12839,6 +12858,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
12839
12858
|
onCreateChild: e.createChildRecord,
|
|
12840
12859
|
onDetailAction: t[26] ||= (t) => e.editorMode === "view" ? e.handleDetailAction(t) : e.handlePlacedFormAction(t)
|
|
12841
12860
|
}, null, 8, [
|
|
12861
|
+
"form-pending",
|
|
12842
12862
|
"save-needs-check",
|
|
12843
12863
|
"checking-save",
|
|
12844
12864
|
"context",
|
|
@@ -12884,12 +12904,12 @@ function oh(e, t, n, r, i, a) {
|
|
|
12884
12904
|
} : void 0,
|
|
12885
12905
|
e.businessVisible && e.hasCardAssistantAt("inside", "bottom") ? {
|
|
12886
12906
|
name: "content-bottom",
|
|
12887
|
-
fn: $(() => [U("aside", rh, [(K(), B(
|
|
12907
|
+
fn: $(() => [U("aside", rh, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12888
12908
|
key: "4"
|
|
12889
12909
|
} : void 0,
|
|
12890
12910
|
e.businessVisible && e.hasCardAssistantAt("outside", "bottom") ? {
|
|
12891
12911
|
name: "outside-bottom",
|
|
12892
|
-
fn: $(() => [U("aside", ih, [(K(), B(
|
|
12912
|
+
fn: $(() => [U("aside", ih, [(K(), B(On(e.enhancementCardAssistant.component), { context: e.cardAssistantContext }, null, 8, ["context"]))])]),
|
|
12893
12913
|
key: "5"
|
|
12894
12914
|
} : void 0
|
|
12895
12915
|
]), 1032, ["title", "subtitle"])
|
|
@@ -13030,7 +13050,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
13030
13050
|
"loading",
|
|
13031
13051
|
"onChange"
|
|
13032
13052
|
])) : V("v-if", !0)]),
|
|
13033
|
-
view: $(() => [e.editingRecord ? (K(), H(R, { key: 0 }, [e.enhancementDetailDrawer ? (K(), B(
|
|
13053
|
+
view: $(() => [e.editingRecord ? (K(), H(R, { key: 0 }, [e.enhancementDetailDrawer ? (K(), B(On(e.enhancementDetailDrawer.component), {
|
|
13034
13054
|
key: 0,
|
|
13035
13055
|
context: e.recordViewContext(e.editingRecord)
|
|
13036
13056
|
}, null, 8, ["context"])) : (K(), B(y, {
|
|
@@ -13133,6 +13153,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
13133
13153
|
!e.enhancementDetailDrawer || e.enhancementDetailActions.length > 0 ? {
|
|
13134
13154
|
name: "operation",
|
|
13135
13155
|
fn: $(() => [G(w, {
|
|
13156
|
+
"form-pending": e.mainFormPending,
|
|
13136
13157
|
"save-needs-check": e.recordSaveNeedsCheck,
|
|
13137
13158
|
"checking-save": e.saving,
|
|
13138
13159
|
context: e.context,
|
|
@@ -13155,6 +13176,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
13155
13176
|
onDelete: t[30] ||= (t) => e.selectedRecord && e.deleteRecord(e.selectedRecord),
|
|
13156
13177
|
onDetailAction: t[31] ||= (t) => e.editorMode === "view" ? e.handleDetailAction(t) : e.handlePlacedFormAction(t)
|
|
13157
13178
|
}, null, 8, [
|
|
13179
|
+
"form-pending",
|
|
13158
13180
|
"save-needs-check",
|
|
13159
13181
|
"checking-save",
|
|
13160
13182
|
"context",
|
|
@@ -13226,7 +13248,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
13226
13248
|
onClose: e.closeEnhancementDrawer,
|
|
13227
13249
|
onAfterClose: e.disposeEnhancementDrawer
|
|
13228
13250
|
}, an({
|
|
13229
|
-
default: $(() => [(K(), B(
|
|
13251
|
+
default: $(() => [(K(), B(On(e.enhancementDrawer.definition.component), { context: e.enhancementDrawer.context }, null, 8, ["context"]))]),
|
|
13230
13252
|
_: 2
|
|
13231
13253
|
}, [
|
|
13232
13254
|
e.enhancementDrawer.titleActions.length ? {
|
|
@@ -13292,7 +13314,7 @@ function oh(e, t, n, r, i, a) {
|
|
|
13292
13314
|
])
|
|
13293
13315
|
], 64)) : V("v-if", !0)], 64);
|
|
13294
13316
|
}
|
|
13295
|
-
var sh = /*#__PURE__*/ et(Hm, [["render", oh], ["__scopeId", "data-v-
|
|
13317
|
+
var sh = /*#__PURE__*/ et(Hm, [["render", oh], ["__scopeId", "data-v-1866dc07"]]), ch = Symbol("assistant-business-scope");
|
|
13296
13318
|
//#endregion
|
|
13297
13319
|
//#region src/dynamic-page-runtime/useModuleRecordDataChanges.ts
|
|
13298
13320
|
function lh(e) {
|
|
@@ -14368,7 +14390,7 @@ function mg(e, n, r) {
|
|
|
14368
14390
|
Cn(() => {
|
|
14369
14391
|
c = !0;
|
|
14370
14392
|
});
|
|
14371
|
-
let l = Ch(), f = Ot({ moduleAlias: e.descriptor.target.moduleAlias }), p = `/${e.descriptor.target.moduleAlias}`, m = z(() => e.tenantScope?.id == null ? "" : String(e.tenantScope.id)), h = q([]), g = cm(e.descriptor.target.moduleAlias, void 0, e.descriptor.menuId), _ = kn(g?.navigator ?? {}), v = q(
|
|
14393
|
+
let l = Ch(), f = Ot({ moduleAlias: e.descriptor.target.moduleAlias }), p = `/${e.descriptor.target.moduleAlias}`, m = z(() => e.tenantScope?.id == null ? "" : String(e.tenantScope.id)), h = q([]), g = cm(e.descriptor.target.moduleAlias, void 0, e.descriptor.menuId), _ = kn(g?.navigator ?? {}), v = q(Wr(_.value.extension?.selection)), b = q(Gr(_.value.extension?.selection)), S = q({}), C, w = q(), T = q(0), E = q(!1), D = q(), ee = q(), te = z(() => {
|
|
14372
14394
|
let e = v.value;
|
|
14373
14395
|
return e ? JSON.stringify(e) : void 0;
|
|
14374
14396
|
});
|
|
@@ -14382,7 +14404,7 @@ function mg(e, n, r) {
|
|
|
14382
14404
|
"X-MuYun-Menu-Id": e.descriptor.menuId,
|
|
14383
14405
|
"X-MuYun-Page-Context": ee.value,
|
|
14384
14406
|
"X-MuYun-Page-Selection": te.value
|
|
14385
|
-
}), (e) => ne(e.path))
|
|
14407
|
+
}), (e) => !Object.keys(e.headers ?? {}).some((e) => e.toLowerCase() === "x-muyun-record-context") && ne(e.path))
|
|
14386
14408
|
}), k = Ce(O.http, a);
|
|
14387
14409
|
Cn(k.dispose);
|
|
14388
14410
|
let { tenantScopeExplorerCount: re, tenantScopeFixedByIdentity: ie } = e.tenantController, ae = z(() => O.runtime.snapshot()?.tenantRequired === !0), oe = z(() => !ae.value || !!m.value), se = z(() => {
|
|
@@ -14393,7 +14415,7 @@ function mg(e, n, r) {
|
|
|
14393
14415
|
...O,
|
|
14394
14416
|
crud: {
|
|
14395
14417
|
async querySchema(e) {
|
|
14396
|
-
let t = await (w.value ?? O.crud).querySchema(e), n =
|
|
14418
|
+
let t = await (w.value ?? O.crud).querySchema(e), n = Vt.value?.quickSearchFields;
|
|
14397
14419
|
return n == null ? t : {
|
|
14398
14420
|
...t,
|
|
14399
14421
|
quickSearch: {
|
|
@@ -14406,7 +14428,7 @@ function mg(e, n, r) {
|
|
|
14406
14428
|
},
|
|
14407
14429
|
query(e, t) {
|
|
14408
14430
|
if (w.value) return w.value.query(e, t);
|
|
14409
|
-
let n =
|
|
14431
|
+
let n = oa.value ?? [];
|
|
14410
14432
|
return O.crud.query({
|
|
14411
14433
|
...e,
|
|
14412
14434
|
conditions: [...e?.conditions ?? [], ...n]
|
|
@@ -14443,7 +14465,7 @@ function mg(e, n, r) {
|
|
|
14443
14465
|
}
|
|
14444
14466
|
};
|
|
14445
14467
|
function ce(e) {
|
|
14446
|
-
let t =
|
|
14468
|
+
let t = V.value?.resource;
|
|
14447
14469
|
if (!t) return e;
|
|
14448
14470
|
let n = `${t}_`;
|
|
14449
14471
|
return {
|
|
@@ -14455,7 +14477,7 @@ function mg(e, n, r) {
|
|
|
14455
14477
|
};
|
|
14456
14478
|
}
|
|
14457
14479
|
function le(e) {
|
|
14458
|
-
let t =
|
|
14480
|
+
let t = V.value?.resource;
|
|
14459
14481
|
return t && [
|
|
14460
14482
|
"create",
|
|
14461
14483
|
"view",
|
|
@@ -14469,10 +14491,10 @@ function mg(e, n, r) {
|
|
|
14469
14491
|
].includes(e) ? `${t}_${e}` : e;
|
|
14470
14492
|
}
|
|
14471
14493
|
let j = jh(), { presentActionSuccess: de, runEnhancementAction: fe } = cg(), pe = Kh(), { invalidatePendingRequests: me, commitLoadedRecord: ge, openRecord: _e, openRecycleBinRecord: ve, settlePendingRecord: be } = lg(A, pe, () => {
|
|
14472
|
-
|
|
14494
|
+
on.value += 1;
|
|
14473
14495
|
});
|
|
14474
14496
|
async function xe(e, t, n = {}) {
|
|
14475
|
-
if (t !== "edit" || await
|
|
14497
|
+
if (t !== "edit" || await as(String(e.id ?? ""), "update")) return _e(e, t, n, t === "view" && Wi.value?.loadRecord === !1);
|
|
14476
14498
|
}
|
|
14477
14499
|
let { record: M, draft: N, mode: P, open: we, saving: Te, isDirty: Ee, formSessionKey: De, togglingEnabled: Oe, loading: ke, loadFailed: je } = pe, F = q({}), Pe = z(() => Object.fromEntries(Object.entries(F.value).map(([e, t]) => [e, t.options]))), Fe = q(/* @__PURE__ */ new Set()), Ie = z(() => {
|
|
14478
14500
|
let e = P.value === "view" ? M.value : N.value;
|
|
@@ -14532,18 +14554,18 @@ function mg(e, n, r) {
|
|
|
14532
14554
|
editing: !1,
|
|
14533
14555
|
busy: !1,
|
|
14534
14556
|
dirty: !1
|
|
14535
|
-
}), pt = q(!0), mt = q(!
|
|
14557
|
+
}), pt = q(!0), mt = q(!1), ht = q(!0), yt = q(0), bt = kn();
|
|
14536
14558
|
Q([N, De], () => {
|
|
14537
|
-
|
|
14559
|
+
bt.value = void 0;
|
|
14538
14560
|
}, {
|
|
14539
14561
|
deep: !0,
|
|
14540
14562
|
flush: "sync"
|
|
14541
14563
|
});
|
|
14542
|
-
let
|
|
14543
|
-
function
|
|
14544
|
-
|
|
14564
|
+
let xt = q(!0), Ct = q(!1), wt = 0, Tt = q(0);
|
|
14565
|
+
function Et(e) {
|
|
14566
|
+
Tt.value += 1, pt.value = e.valid, mt.value = e.pending === !0;
|
|
14545
14567
|
}
|
|
14546
|
-
function
|
|
14568
|
+
function Dt(e, t, n, r = {}) {
|
|
14547
14569
|
if (P.value !== "view" && (Te.value || tt.value)) return;
|
|
14548
14570
|
let i = F.value[e]?.rows;
|
|
14549
14571
|
if (F.value = {
|
|
@@ -14559,27 +14581,27 @@ function mg(e, n, r) {
|
|
|
14559
14581
|
[e]: t
|
|
14560
14582
|
}, o = A.runtime.snapshot()?.uiDescriptor;
|
|
14561
14583
|
N.value.id != null && !Object.hasOwn(N.value, e) && (Fe.value = /* @__PURE__ */ new Set([...Fe.value, ...$h(e, o)]));
|
|
14562
|
-
let s =
|
|
14563
|
-
N.value =
|
|
14564
|
-
}
|
|
14565
|
-
function Dt(e) {
|
|
14566
|
-
wt.value += 1, mt.value = e;
|
|
14584
|
+
let s = zo(o);
|
|
14585
|
+
N.value = Uo(a, Qh(e, o, s), s);
|
|
14567
14586
|
}
|
|
14568
14587
|
function kt(e) {
|
|
14569
|
-
|
|
14588
|
+
Tt.value += 1, ht.value = e;
|
|
14589
|
+
}
|
|
14590
|
+
function At(e) {
|
|
14591
|
+
xt.value = e.valid;
|
|
14570
14592
|
}
|
|
14571
14593
|
Q([() => N.value?.id, De], () => {
|
|
14572
|
-
pt.value = !0, mt.value = !0, Fe.value = /* @__PURE__ */ new Set();
|
|
14594
|
+
pt.value = !0, mt.value = !1, ht.value = !0, Fe.value = /* @__PURE__ */ new Set();
|
|
14573
14595
|
}), Q(P, (e) => {
|
|
14574
|
-
e !== "edit" && (
|
|
14596
|
+
e !== "edit" && (ht.value = !0);
|
|
14575
14597
|
});
|
|
14576
|
-
let { pageBootstrap:
|
|
14577
|
-
Q(() => e.descriptor.params, (e) =>
|
|
14598
|
+
let { pageBootstrap: jt, pageBootstrapError: Pt, setPageBootstrapFailure: Ft, loadPageBootstrap: It } = ng(A, () => e.descriptor.menuId, a), { formFields: Rt, detailDisplayFields: zt, runtimeUiDescriptor: Bt, runtimePage: Vt, runtimePageResolved: Ht, treeModule: L, navigatorLevels: Ut, pageContextBindings: Wt, selectedNavigatorRecords: Gt, navigatorSingleResultKeys: Kt, navigatorDismissedSelectionKeys: Yt, setNavigatorEntrySelection: Xt, navigatorEntrySelectionPendingFor: Qt, resolveNavigatorEntrySelection: $t, isCurrentNavigatorEntrySelection: en, loadRuntimeDescriptor: R, loadRuntimeForm: nn } = sg(A, O.http), rn = q({}), B = q({});
|
|
14599
|
+
Q(() => e.descriptor.params, (e) => Za(Xt(e)), {
|
|
14578
14600
|
immediate: !0,
|
|
14579
14601
|
deep: !0
|
|
14580
14602
|
});
|
|
14581
|
-
let
|
|
14582
|
-
Q(
|
|
14603
|
+
let V = z(() => Vt.value?.treeResource);
|
|
14604
|
+
Q(Gt, (e) => {
|
|
14583
14605
|
let t = Object.entries(e).flatMap(([e, t]) => t?.id == null ? [] : [[e, String(t.id)]]);
|
|
14584
14606
|
ee.value = t.length === 0 ? void 0 : JSON.stringify(Object.fromEntries(t));
|
|
14585
14607
|
}, {
|
|
@@ -14587,30 +14609,30 @@ function mg(e, n, r) {
|
|
|
14587
14609
|
immediate: !0,
|
|
14588
14610
|
flush: "sync"
|
|
14589
14611
|
});
|
|
14590
|
-
let
|
|
14591
|
-
let e =
|
|
14592
|
-
return e ?
|
|
14593
|
-
}),
|
|
14594
|
-
let e =
|
|
14612
|
+
let H = z(() => {
|
|
14613
|
+
let e = V.value;
|
|
14614
|
+
return e ? Gt.value[e.scopeNavigatorKey] : void 0;
|
|
14615
|
+
}), U = z(() => {
|
|
14616
|
+
let e = V.value;
|
|
14595
14617
|
if (!e) return !0;
|
|
14596
|
-
let t =
|
|
14618
|
+
let t = H.value;
|
|
14597
14619
|
return t?.id == null ? !1 : !e.scopeRecordField || String(t[e.scopeRecordField] ?? "") === e.scopeRecordEquals;
|
|
14598
|
-
}),
|
|
14620
|
+
}), an = z(() => V.value ? U.value : ua.value);
|
|
14599
14621
|
Q([
|
|
14600
|
-
B,
|
|
14601
14622
|
V,
|
|
14602
|
-
H
|
|
14623
|
+
H,
|
|
14624
|
+
U
|
|
14603
14625
|
], ([e, t, n], [r, i, a]) => {
|
|
14604
14626
|
let o = t?.id == null ? void 0 : String(t.id);
|
|
14605
14627
|
w.value = e && o && n ? He(A.http, `/${A.moduleAlias}/tree-resources/${encodeURIComponent(e.resource)}/${encodeURIComponent(o)}`) : void 0, !(r === void 0 || e?.resource === r?.resource && o === (i?.id == null ? void 0 : String(i.id)) && n === a) && (me(), T.value += 1, D.value = void 0, pe.close(), M.value = void 0, N.value = void 0);
|
|
14606
14628
|
}, { immediate: !0 });
|
|
14607
|
-
let
|
|
14629
|
+
let on = q(0), { drawer: W, drawerOpen: G, sectionContext: sn, recordViewContext: cn, openDrawer: ln, closeDrawer: un, disposeDrawer: dn } = fg({
|
|
14608
14630
|
module: A,
|
|
14609
|
-
scope: () =>
|
|
14610
|
-
refreshList:
|
|
14611
|
-
reload:
|
|
14612
|
-
closeDetail:
|
|
14613
|
-
}),
|
|
14631
|
+
scope: () => nc().scope,
|
|
14632
|
+
refreshList: ac,
|
|
14633
|
+
reload: rc,
|
|
14634
|
+
closeDetail: sc
|
|
14635
|
+
}), fn = q(""), pn = q(""), mn = q(0), gn = q(!1), { listMode: _n, reloadKey: vn, cardAssistantRecords: yn, handleLoaded: bn, handleFlatManagementLoaded: xn, setCardAssistantRecords: K, resetFlatManagementSelection: wn, handleListModeChange: Tn, handleRecycleBinRestore: J, selectListDetailRecord: En, selectStandaloneListRecord: Dn, openListRecord: On } = ug({
|
|
14614
14636
|
selectedRecord: M,
|
|
14615
14637
|
saving: Te,
|
|
14616
14638
|
resetDetail: () => {
|
|
@@ -14620,38 +14642,38 @@ function mg(e, n, r) {
|
|
|
14620
14642
|
resetTreeSelection: () => {
|
|
14621
14643
|
D.value = void 0;
|
|
14622
14644
|
},
|
|
14623
|
-
openRecord: (e) => void
|
|
14645
|
+
openRecord: (e) => void Ks(e),
|
|
14624
14646
|
openRecycleBinRecord: (e) => {
|
|
14625
14647
|
Be(), ve(e);
|
|
14626
14648
|
},
|
|
14627
14649
|
markUserInteraction: Be
|
|
14628
|
-
}), Y = Kh(),
|
|
14629
|
-
function
|
|
14650
|
+
}), Y = Kh(), X = q(), An = q(!1), Z = q(!0), Mn = q(0), Nn = 0, Pn = q(""), Fn = q(0), $ = q(Lh(_t.get(`module-page.detail-surface.${A.moduleAlias}`, void 0))), In = q(Hh(_t.get(`module-page.list-page-size.${A.moduleAlias}`, 20))), Ln = q(!1), Rn = q(), zn, Bn = 0, Vn = Promise.resolve(), Hn = 0, Un = Promise.resolve(), Wn = jp(), Gn = /* @__PURE__ */ new Map(), Kn = /* @__PURE__ */ new Map();
|
|
14651
|
+
function qn(e, n) {
|
|
14630
14652
|
if (e.candidateDelivery !== "TARGET_NAVIGATOR" || !n) return {};
|
|
14631
|
-
let r = `${e.targetModuleAlias}:${e.cardinality}`, i =
|
|
14653
|
+
let r = `${e.targetModuleAlias}:${e.cardinality}`, i = Gn.get(r);
|
|
14632
14654
|
return i || (i = t({
|
|
14633
14655
|
http: O.http,
|
|
14634
14656
|
reference: {
|
|
14635
14657
|
targetModuleAlias: e.targetModuleAlias,
|
|
14636
14658
|
cardinality: e.cardinality
|
|
14637
14659
|
}
|
|
14638
|
-
}),
|
|
14660
|
+
}), Gn.set(r, i)), {
|
|
14639
14661
|
provider: i,
|
|
14640
14662
|
reloadKey: `target-reference:${r}`
|
|
14641
14663
|
};
|
|
14642
14664
|
}
|
|
14643
|
-
function
|
|
14665
|
+
function Jn(e) {
|
|
14644
14666
|
let t = e.fieldControl?.properties?.presentation;
|
|
14645
14667
|
if (t === "DIALOG") return "dialog";
|
|
14646
14668
|
if (t === "DROPDOWN") return "dropdown";
|
|
14647
14669
|
}
|
|
14648
|
-
function
|
|
14649
|
-
let { reference: t, pickerFieldName: n } = e, r =
|
|
14670
|
+
function Yn(e) {
|
|
14671
|
+
let { reference: t, pickerFieldName: n } = e, r = Xn(t), i = Wn({
|
|
14650
14672
|
...e,
|
|
14651
14673
|
legacyTreeLoaders: !!r
|
|
14652
14674
|
});
|
|
14653
14675
|
if (!r) return i;
|
|
14654
|
-
let a = i.provider, o =
|
|
14676
|
+
let a = i.provider, o = Kn.get(a), s = o?.live ?? { options: e };
|
|
14655
14677
|
s.options = e;
|
|
14656
14678
|
let c = () => {
|
|
14657
14679
|
let e = s.options.formValues()[r.sourceField];
|
|
@@ -14725,14 +14747,14 @@ function mg(e, n, r) {
|
|
|
14725
14747
|
})).results.flatMap((e) => e.item ? [l(e.item)] : []) : []
|
|
14726
14748
|
},
|
|
14727
14749
|
live: s
|
|
14728
|
-
},
|
|
14750
|
+
}, Kn.set(a, o)), i.scopedTree = {
|
|
14729
14751
|
title: r.title,
|
|
14730
14752
|
disabled: !c(),
|
|
14731
14753
|
unavailableMessage: c() ? void 0 : r.unavailableMessage,
|
|
14732
14754
|
provider: o.provider
|
|
14733
14755
|
}, i;
|
|
14734
14756
|
}
|
|
14735
|
-
function
|
|
14757
|
+
function Xn(e) {
|
|
14736
14758
|
let t = {
|
|
14737
14759
|
"iam.department": {
|
|
14738
14760
|
sourceField: "organizationId",
|
|
@@ -14749,20 +14771,20 @@ function mg(e, n, r) {
|
|
|
14749
14771
|
let n = e.candidateDependencies ?? [];
|
|
14750
14772
|
return n.length === 0 || n.some((e) => e.sourceField === t.sourceField) ? t : void 0;
|
|
14751
14773
|
}
|
|
14752
|
-
let
|
|
14753
|
-
let e =
|
|
14774
|
+
let Zn = z(() => {
|
|
14775
|
+
let e = X.value;
|
|
14754
14776
|
return e ? tn(Ne(e.context.runtime)?.uiDescriptor, void 0, e.descriptor.management?.editorSurface) : tn(void 0);
|
|
14755
|
-
}),
|
|
14756
|
-
let e =
|
|
14777
|
+
}), Qn = z(() => {
|
|
14778
|
+
let e = X.value;
|
|
14757
14779
|
return e ? cm(e.context.moduleAlias) : void 0;
|
|
14758
|
-
}),
|
|
14759
|
-
let e =
|
|
14780
|
+
}), $n = z(() => Qn.value?.form?.contributions ?? []), er = z(() => Qn.value?.form?.fieldPolicies ?? []), tr = z(() => {
|
|
14781
|
+
let e = X.value;
|
|
14760
14782
|
if (!e) return {};
|
|
14761
14783
|
let t = {};
|
|
14762
|
-
for (let n of
|
|
14784
|
+
for (let n of Zn.value.values()) {
|
|
14763
14785
|
let r = n.reference;
|
|
14764
14786
|
if (!r) continue;
|
|
14765
|
-
let i = n.fieldRef.fieldName, o = r.candidateDelivery === "SOURCE_FIELD" ?
|
|
14787
|
+
let i = n.fieldRef.fieldName, o = r.candidateDelivery === "SOURCE_FIELD" ? Yn({
|
|
14766
14788
|
reference: r,
|
|
14767
14789
|
providerScopeKey: `navigator:${e.descriptor.key}`,
|
|
14768
14790
|
sourceModuleAlias: e.context.moduleAlias,
|
|
@@ -14771,7 +14793,7 @@ function mg(e, n, r) {
|
|
|
14771
14793
|
formValues: () => ({ ...Y.draft.value ?? {} }),
|
|
14772
14794
|
reloadRecord: () => Y.draft.value,
|
|
14773
14795
|
source: () => Y.draft.value?.id == null ? void 0 : { recordId: String(Y.draft.value.id) }
|
|
14774
|
-
}) : {}, s =
|
|
14796
|
+
}) : {}, s = qn(r, Jn(n));
|
|
14775
14797
|
t[i] = {
|
|
14776
14798
|
context: Ae({
|
|
14777
14799
|
http: O.http,
|
|
@@ -14784,87 +14806,87 @@ function mg(e, n, r) {
|
|
|
14784
14806
|
...s
|
|
14785
14807
|
};
|
|
14786
14808
|
}
|
|
14787
|
-
return e.tree &&
|
|
14809
|
+
return e.tree && Zn.value.has("parentId") && (t.parentId = {
|
|
14788
14810
|
context: e.context,
|
|
14789
14811
|
mode: "tree",
|
|
14790
14812
|
placeholder: a.t("platform.screen.useModulePageSession.leave-blank-for-the-root", "根目录留空"),
|
|
14791
14813
|
allowClear: !0,
|
|
14792
14814
|
loadTree: async () => {
|
|
14793
14815
|
let t = e.context.abilities.tryTree();
|
|
14794
|
-
return t ? (await t.tree({ externalQueryValues:
|
|
14816
|
+
return t ? (await t.tree({ externalQueryValues: oo(e.descriptor.key) })).records : [];
|
|
14795
14817
|
},
|
|
14796
|
-
constraints:
|
|
14818
|
+
constraints: Qr(e, Y.draft.value?.id == null ? void 0 : String(Y.draft.value.id))
|
|
14797
14819
|
}), t;
|
|
14798
|
-
}),
|
|
14799
|
-
let e =
|
|
14820
|
+
}), nr = z(() => {
|
|
14821
|
+
let e = X.value;
|
|
14800
14822
|
return e ? Y.mode.value === "create" ? a.t("platform.screen.ModulePageHostRuntime.create-value", "新建{value1}", { value1: e.descriptor.title }) : a.t("platform.screen.ManagedDetailRelationSurface.edit-value", "编辑{value1}", { value1: e.descriptor.title }) : a.t("platform.screen.useModulePageSession.management-scope", "管理范围");
|
|
14801
|
-
}),
|
|
14823
|
+
}), rr = z(() => e.descriptor.title ?? A.runtime.snapshot()?.title ?? A.moduleAlias), ar = z(() => P.value === "create" ? Nr.value ? ni.value?.createTitle ?? a.t("platform.screen.ModulePageHostRuntime.create-value", "新建{value1}", { value1: rr.value }) : a.t("platform.screen.ModulePageHostRuntime.create-value", "新建{value1}", { value1: rr.value }) : vc(N.value ?? M.value) ?? a.t("platform.screen.useModulePageSession.record-details", "记录详情")), { detailPageActions: or, localEditOpen: sr, localEditSaving: cr, localEditBlock: lr, localEditDraft: ur, localEditDirty: dr, localEditFields: fr, handleConfiguredAction: pr, dismissLocalEdit: mr, submitLocalEdit: hr } = dg({
|
|
14802
14824
|
context: A,
|
|
14803
|
-
pageBootstrap:
|
|
14825
|
+
pageBootstrap: jt,
|
|
14804
14826
|
selectedRecord: M,
|
|
14805
14827
|
editorMode: P,
|
|
14806
14828
|
detail: pe,
|
|
14807
|
-
refreshList:
|
|
14808
|
-
localEditValid:
|
|
14809
|
-
presentSuccess:
|
|
14829
|
+
refreshList: ac,
|
|
14830
|
+
localEditValid: xt,
|
|
14831
|
+
presentSuccess: Bs,
|
|
14810
14832
|
presentError: (e, t) => ze(e, {
|
|
14811
14833
|
source: t,
|
|
14812
14834
|
phase: "action",
|
|
14813
14835
|
language: a
|
|
14814
14836
|
}),
|
|
14815
|
-
reportRefreshFailure: (e, t) =>
|
|
14837
|
+
reportRefreshFailure: (e, t) => zs(e, t),
|
|
14816
14838
|
recordChanged: (t) => {
|
|
14817
14839
|
e.recordOnly && n("record-only-change", {
|
|
14818
14840
|
type: "saved",
|
|
14819
14841
|
record: t
|
|
14820
14842
|
});
|
|
14821
14843
|
}
|
|
14822
|
-
}),
|
|
14844
|
+
}), gr = z(() => st.value || Ct.value || cr.value || Y.loading.value || Y.saving.value || An.value || ft.value.busy || ct.value.busy), _r = z(() => !!(we.value && P.value !== "view") || Y.open.value || sr.value || ft.value.editing || ct.value.editing);
|
|
14823
14845
|
lh({
|
|
14824
14846
|
moduleAlias: A.moduleAlias,
|
|
14825
14847
|
presentationModules: () => [
|
|
14826
|
-
...uh(
|
|
14827
|
-
...[...
|
|
14828
|
-
...
|
|
14829
|
-
...
|
|
14848
|
+
...uh(Bt.value),
|
|
14849
|
+
...[...Rt.value.values()].flatMap((e) => e.reference ? [e.reference.targetModuleAlias] : []),
|
|
14850
|
+
...br.value.map((e) => e.targetModuleAlias),
|
|
14851
|
+
...Ut.value.map((e) => e.context.moduleAlias)
|
|
14830
14852
|
],
|
|
14831
14853
|
recordId: () => we.value && M.value?.id != null ? String(M.value.id) : void 0,
|
|
14832
|
-
blocked: () =>
|
|
14854
|
+
blocked: () => gr.value || _r.value || ke.value || Te.value || Oe.value || !e.recordOnly && (!oe.value || !Ht.value),
|
|
14833
14855
|
invalidate: (e) => A.invalidateRecordActions?.(e),
|
|
14834
|
-
refreshList:
|
|
14835
|
-
refreshRecord: async (e, t) =>
|
|
14856
|
+
refreshList: ac,
|
|
14857
|
+
refreshRecord: async (e, t) => Sa.value ? t() ? (await ve({ id: e }), !0) : !1 : (await x(A, e).catch((e) => ze(e, {
|
|
14836
14858
|
source: "module-data-change",
|
|
14837
14859
|
phase: "authorization",
|
|
14838
14860
|
language: a
|
|
14839
|
-
})), t() ? (await _e({ id: e }, "view", {}, !1, (e) =>
|
|
14861
|
+
})), t() ? (await _e({ id: e }, "view", {}, !1, (e) => zs(e, "module-data-change")), Ir.value && M.value?.id === e && (D.value = M.value), !0) : !1),
|
|
14840
14862
|
onError: (e) => ze(e, {
|
|
14841
14863
|
source: "module-data-change",
|
|
14842
14864
|
phase: "load",
|
|
14843
14865
|
language: a
|
|
14844
14866
|
})
|
|
14845
14867
|
});
|
|
14846
|
-
let
|
|
14847
|
-
function
|
|
14868
|
+
let vr = z(() => Ee.value || Y.isDirty.value || dr.value || ft.value.dirty || ct.value.dirty);
|
|
14869
|
+
function yr(e) {
|
|
14848
14870
|
ft.value = {
|
|
14849
14871
|
...e,
|
|
14850
14872
|
dirty: e.dirty === !0
|
|
14851
14873
|
};
|
|
14852
14874
|
}
|
|
14853
14875
|
Q(() => ({
|
|
14854
|
-
editing:
|
|
14855
|
-
busy:
|
|
14856
|
-
dirty:
|
|
14876
|
+
editing: _r.value,
|
|
14877
|
+
busy: gr.value,
|
|
14878
|
+
dirty: vr.value
|
|
14857
14879
|
}), (e) => n("interaction-state-change", e), {
|
|
14858
14880
|
immediate: !0,
|
|
14859
14881
|
flush: "sync"
|
|
14860
|
-
}), Q(
|
|
14861
|
-
|
|
14882
|
+
}), Q(sr, () => {
|
|
14883
|
+
xt.value = !0;
|
|
14862
14884
|
}), cp(async (e) => {
|
|
14863
14885
|
let t = new Set(e.changes.filter((e) => e.type === "configuration-translations-changed").map((e) => e.moduleAlias));
|
|
14864
14886
|
if (!t.size) return;
|
|
14865
14887
|
let n = /* @__PURE__ */ new Set([
|
|
14866
14888
|
A,
|
|
14867
|
-
...
|
|
14889
|
+
...Ut.value.map((e) => e.context),
|
|
14868
14890
|
k.activeContext.value
|
|
14869
14891
|
]);
|
|
14870
14892
|
await Promise.all([...n].filter((e) => e && t.has(e.moduleAlias)).map(async (e) => {
|
|
@@ -14879,52 +14901,52 @@ function mg(e, n, r) {
|
|
|
14879
14901
|
}
|
|
14880
14902
|
}));
|
|
14881
14903
|
});
|
|
14882
|
-
let
|
|
14883
|
-
let t =
|
|
14904
|
+
let br = z(() => [...Bt.value?.detailRelations ?? [], ...(jt.value?.resolvedConfig.associationBlocks ?? []).flatMap((e) => e.relation ? [e.relation] : [])].filter((e, t, n) => (!!e.embeddedField || Nt(e)) && n.findIndex((t) => t.sourceModuleAlias === e.sourceModuleAlias && t.code === e.code) === t)), xr = z(() => (Bt.value?.page?.list?.relationExpansions ?? []).map((e) => {
|
|
14905
|
+
let t = br.value.find((t) => t.code === e.relationCode && t.embeddedField);
|
|
14884
14906
|
return t ? {
|
|
14885
14907
|
expansion: e,
|
|
14886
14908
|
relation: t
|
|
14887
14909
|
} : void 0;
|
|
14888
|
-
}).filter((e) => e != null)),
|
|
14889
|
-
function
|
|
14910
|
+
}).filter((e) => e != null)), Sr = q([]), Cr = z(() => xr.value.length > 0);
|
|
14911
|
+
function wr(e, t) {
|
|
14890
14912
|
let n = e.id == null ? void 0 : String(e.id);
|
|
14891
|
-
n && (
|
|
14913
|
+
n && (Sr.value = t ? [.../* @__PURE__ */ new Set([...Sr.value, n])] : Sr.value.filter((e) => e !== n));
|
|
14892
14914
|
}
|
|
14893
|
-
function
|
|
14915
|
+
function Tr(e, t) {
|
|
14894
14916
|
return {
|
|
14895
14917
|
module: A,
|
|
14896
14918
|
record: fm(e),
|
|
14897
14919
|
expanded: t,
|
|
14898
|
-
refreshList:
|
|
14920
|
+
refreshList: ac
|
|
14899
14921
|
};
|
|
14900
14922
|
}
|
|
14901
|
-
let
|
|
14923
|
+
let Er = z(() => e.descriptor.target.pageMode ?? "LIST"), Dr = z(() => jt.value?.entry.pageMode ?? Er.value), Or = z(() => Dr.value === "LIST"), kr = z(() => Or.value ? e.descriptor.target.defaultUiConfigId : void 0), Ar = z(() => jt.value?.entry.defaultUiConfigId ?? kr.value), jr = z(() => jt.value?.entry.defaultQueryTemplateId ?? e.descriptor.target.defaultQueryTemplateId), Mr = z(() => Vt.value?.list?.fields), Nr = z(() => Vt.value?.template === "FLAT_MANAGEMENT"), Pr = z(() => Vt.value?.detail?.showSystemInfo !== !1), Fr = z(() => Vt.value?.template === "TREE_MANAGEMENT"), Ir = z(() => Fr.value || L.value), Lr = z(() => Mt(Br.value + re.value)), Rr = z(() => _.value.hidden ? [] : Ut.value.filter((e) => !Gh(e.descriptor, Kt.value.includes(e.descriptor.key), l?.value?.tenantId))), zr = z(() => _.value.extension), Br = z(() => Rr.value.length + +!!zr.value), Vr = vt(Rn, Lr), Hr = z(() => ({
|
|
14902
14924
|
moduleAlias: A.moduleAlias,
|
|
14903
14925
|
selectionKey: v.value?.key,
|
|
14904
|
-
selectSelectionKey:
|
|
14905
|
-
refreshList:
|
|
14906
|
-
reload:
|
|
14926
|
+
selectSelectionKey: Kr,
|
|
14927
|
+
refreshList: ac,
|
|
14928
|
+
reload: rc
|
|
14907
14929
|
}));
|
|
14908
|
-
function
|
|
14930
|
+
function Ur(e) {
|
|
14909
14931
|
if (!e) {
|
|
14910
14932
|
v.value = void 0, b.value = void 0;
|
|
14911
14933
|
return;
|
|
14912
14934
|
}
|
|
14913
14935
|
let t = v.value;
|
|
14914
|
-
t?.kind === e.kind && t.key || (v.value =
|
|
14936
|
+
t?.kind === e.kind && t.key || (v.value = Wr(e), b.value = Gr(e));
|
|
14915
14937
|
}
|
|
14916
|
-
function
|
|
14938
|
+
function Wr(e) {
|
|
14917
14939
|
let t = e?.initialKey?.(l?.value);
|
|
14918
14940
|
return e && t ? {
|
|
14919
14941
|
kind: e.kind,
|
|
14920
14942
|
key: t
|
|
14921
14943
|
} : void 0;
|
|
14922
14944
|
}
|
|
14923
|
-
function
|
|
14945
|
+
function Gr(e) {
|
|
14924
14946
|
return e?.initialPresentation?.(l?.value);
|
|
14925
14947
|
}
|
|
14926
|
-
function
|
|
14927
|
-
let n =
|
|
14948
|
+
function Kr(e, t) {
|
|
14949
|
+
let n = zr.value?.selection, r = e.trim();
|
|
14928
14950
|
if (!n || !r) throw Error(a.t("platform.screen.useModulePageSession.the-navigation-extension-has-no-trusted-selection-or-selection-key", "导航扩展未声明可信选择或选择键为空"));
|
|
14929
14951
|
let i = v.value;
|
|
14930
14952
|
if (i?.kind === n.kind && i.key === r) {
|
|
@@ -14934,10 +14956,10 @@ function mg(e, n, r) {
|
|
|
14934
14956
|
v.value = {
|
|
14935
14957
|
kind: n.kind,
|
|
14936
14958
|
key: r
|
|
14937
|
-
}, b.value = t,
|
|
14959
|
+
}, b.value = t, qr(), ac();
|
|
14938
14960
|
}
|
|
14939
|
-
async function
|
|
14940
|
-
let e = v.value, t =
|
|
14961
|
+
async function qr() {
|
|
14962
|
+
let e = v.value, t = Wt.value.some((e) => e.source === "RESOLVED_SELECTION" && e.target === "FORM_DEFAULT");
|
|
14941
14963
|
if (!e || !t) {
|
|
14942
14964
|
S.value = {};
|
|
14943
14965
|
return;
|
|
@@ -14950,23 +14972,23 @@ function mg(e, n, r) {
|
|
|
14950
14972
|
});
|
|
14951
14973
|
return C = r, r;
|
|
14952
14974
|
}
|
|
14953
|
-
function
|
|
14975
|
+
function Jr(e) {
|
|
14954
14976
|
if (e) return e.text == null ? new u().evaluatePageText(e.program, {
|
|
14955
14977
|
"selection.label": ue(b.value?.label ?? "", b.value?.labelText, a),
|
|
14956
14978
|
"selection.secondaryLabel": b.value?.secondaryLabel ?? ""
|
|
14957
14979
|
}) : e.text;
|
|
14958
14980
|
}
|
|
14959
|
-
function Jr(e) {
|
|
14960
|
-
return Rr.value ? e - 1 : e;
|
|
14961
|
-
}
|
|
14962
14981
|
function Yr(e) {
|
|
14963
|
-
return
|
|
14982
|
+
return zr.value ? e - 1 : e;
|
|
14964
14983
|
}
|
|
14965
14984
|
function Xr(e) {
|
|
14985
|
+
return Rr.value[Yr(e)];
|
|
14986
|
+
}
|
|
14987
|
+
function Zr(e) {
|
|
14966
14988
|
return cm(e.context.moduleAlias)?.navigator?.treeParentPolicy;
|
|
14967
14989
|
}
|
|
14968
|
-
function
|
|
14969
|
-
let n = Lt(t), r =
|
|
14990
|
+
function Qr(e, t) {
|
|
14991
|
+
let n = Lt(t), r = Zr(e);
|
|
14970
14992
|
return r && n.push({
|
|
14971
14993
|
code: "tree-parent-policy",
|
|
14972
14994
|
message: r.rejectionMessage,
|
|
@@ -14974,24 +14996,24 @@ function mg(e, n, r) {
|
|
|
14974
14996
|
test: (e) => r.canUseAsParent(e)
|
|
14975
14997
|
}), n;
|
|
14976
14998
|
}
|
|
14977
|
-
function
|
|
14999
|
+
function $r(e) {
|
|
14978
15000
|
return _.value.lockedEntry?.navigatorKey === e;
|
|
14979
15001
|
}
|
|
14980
|
-
let
|
|
15002
|
+
let ei = z(() => oe.value ? (_.value.lockedEntry?.unavailableDescriptionKey ? a.t(_.value.lockedEntry.unavailableDescriptionKey, _.value.lockedEntry.unavailableDescription) : _.value.lockedEntry?.unavailableDescription) ?? a.t("platform.screen.recordCreationReadiness.select-a-business-navigation-scope-first", "请先选择业务导航范围") : a.t("platform.screen.recordCreationReadiness.select-a-tenant-first", "请先选择租户"));
|
|
14981
15003
|
Q([
|
|
14982
|
-
|
|
15004
|
+
Ut,
|
|
14983
15005
|
() => e.descriptor.params,
|
|
14984
15006
|
() => _.value.lockedEntry
|
|
14985
15007
|
], () => {
|
|
14986
|
-
|
|
14987
|
-
|
|
15008
|
+
Ut.value.forEach((e) => {
|
|
15009
|
+
$r(e.descriptor.key) && Qt(e) && qa(e);
|
|
14988
15010
|
});
|
|
14989
15011
|
}, {
|
|
14990
15012
|
immediate: !0,
|
|
14991
15013
|
deep: !0
|
|
14992
15014
|
});
|
|
14993
|
-
let
|
|
14994
|
-
let e =
|
|
15015
|
+
let ti = z(() => Vr.value || $.value === "drawer"), ni = z(() => {
|
|
15016
|
+
let e = Vt.value?.explorer, t = Vt.value?.detail;
|
|
14995
15017
|
return e == null || t == null ? void 0 : {
|
|
14996
15018
|
explorerTitle: e.title,
|
|
14997
15019
|
explorerSearchPlaceholder: e.searchPlaceholder,
|
|
@@ -15002,19 +15024,19 @@ function mg(e, n, r) {
|
|
|
15002
15024
|
fallbackTitle: e.fallbackTitle,
|
|
15003
15025
|
secondaryField: e.secondaryField
|
|
15004
15026
|
};
|
|
15005
|
-
}),
|
|
15006
|
-
let e =
|
|
15007
|
-
return !e || !
|
|
15008
|
-
}),
|
|
15009
|
-
let e =
|
|
15010
|
-
return e ?
|
|
15027
|
+
}), ri = z(() => Vt.value?.treeResource?.title ?? (Nr.value ? ni.value?.recordLabel ?? o("platform.record.label", "记录") : Vt.value?.explorer?.recordLabel ?? o("platform.record.label", "记录"))), ii = z(() => Jr(Vt.value?.list?.title) ?? Vt.value?.treeResource?.title ?? Vt.value?.explorer?.title ?? (e.descriptor.title ? ue(e.descriptor.title, e.descriptor.titleText, a) : void 0) ?? ri.value), ai = z(() => Jr(Vt.value?.list?.subtitle)), oi = z(() => Vt.value?.treeResource?.title ?? ii.value), si = z(() => Vt.value?.list?.searchPlaceholder ?? Vt.value?.explorer?.searchPlaceholder ?? o("platform.record.search", "搜索{label}", { label: ri.value })), ci = z(() => Vt.value?.treeResource?.emptyDescription ?? Vt.value?.explorer?.emptyDescription ?? o("platform.record.empty", "暂无{label}", { label: ri.value })), li = z(() => Vt.value?.treeResource?.emptyDescription ?? Vt.value?.detail?.emptyDescription ?? o("platform.record.choose", "请选择{label},或新建{label}", { label: ri.value })), ui = z(() => {
|
|
15028
|
+
let e = V.value;
|
|
15029
|
+
return !e || !H.value?.id ? a.t("platform.screen.PageNavigatorExplorer.select-a-navigation-scope-first", "请先选择导航范围") : e.scopeRecordField ? a.t("platform.screen.useModulePageSession.this-resource-cannot-be-managed-in-the-current-navigation-scope", "当前导航范围不支持维护此资源") : a.t("platform.screen.PageNavigatorExplorer.select-a-navigation-scope-first", "请先选择导航范围");
|
|
15030
|
+
}), di = z(() => {
|
|
15031
|
+
let e = V.value;
|
|
15032
|
+
return e ? fi([e.scopeNavigatorKey]) : void 0;
|
|
15011
15033
|
});
|
|
15012
|
-
function
|
|
15013
|
-
let t = new Set(e), n =
|
|
15034
|
+
function fi(e) {
|
|
15035
|
+
let t = new Set(e), n = Ut.value.flatMap((e) => {
|
|
15014
15036
|
if (!t.has(e.descriptor.key)) return [];
|
|
15015
|
-
let n =
|
|
15037
|
+
let n = Gt.value[e.descriptor.key], r = vc(n);
|
|
15016
15038
|
if (!n || !r) return [];
|
|
15017
|
-
let i = e.descriptor.secondaryField, o =
|
|
15039
|
+
let i = e.descriptor.secondaryField, o = Na(n, i), s = o && String(o) !== r ? `${r}(${o})` : r;
|
|
15018
15040
|
return [a.t("platform.screen.useModulePageSession.value-value", "{value1}:{value2}", {
|
|
15019
15041
|
value1: e.descriptor.title,
|
|
15020
15042
|
value2: s
|
|
@@ -15022,60 +15044,60 @@ function mg(e, n, r) {
|
|
|
15022
15044
|
});
|
|
15023
15045
|
return n.length === 0 ? void 0 : n.join(" · ");
|
|
15024
15046
|
}
|
|
15025
|
-
function
|
|
15026
|
-
let t =
|
|
15047
|
+
function pi(e) {
|
|
15048
|
+
let t = fi(Wt.value.filter((t) => t.target === "NAVIGATOR_QUERY" && t.targetNavigatorLevelKey === e).map((e) => e.sourceKey));
|
|
15027
15049
|
return [se.value, t].filter((e) => !!e).join(" · ") || void 0;
|
|
15028
15050
|
}
|
|
15029
|
-
let
|
|
15030
|
-
let e =
|
|
15051
|
+
let mi = z(() => {
|
|
15052
|
+
let e = fi(Wt.value.filter((e) => e.source === "NAVIGATOR" && (e.target === "FORM_DEFAULT" || e.target === "LIST_QUERY")).map((e) => e.sourceKey));
|
|
15031
15053
|
return [se.value, e].filter(Boolean).join(" · ") || void 0;
|
|
15032
|
-
}),
|
|
15033
|
-
Q(
|
|
15034
|
-
|
|
15054
|
+
}), hi = z(() => V.value ? di.value : fi(Wt.value.filter((e) => e.target === "LIST_QUERY" && e.source === "NAVIGATOR").map((e) => e.sourceKey))), gi = z(() => Rt.value.get("parentId")?.treeRootTitle ?? a.t("platform.screen.useModulePageSession.root-value", "根{value1}", { value1: ri.value })), _i = z(() => cm(A.moduleAlias, Mr.value?.viewCode, e.descriptor.menuId)), vi = z(() => _i.value?.form?.contributions ?? []), yi = z(() => _i.value?.form?.fieldPolicies ?? []), bi;
|
|
15055
|
+
Q(_i, (e) => {
|
|
15056
|
+
bi?.(), h.value = e?.standardActions?.disabled ?? [], _.value = e?.navigator ?? {}, Ur(_.value.extension?.selection);
|
|
15035
15057
|
let t = e?.activate?.({ module: A });
|
|
15036
|
-
|
|
15037
|
-
}, { immediate: !0 }), Q(() => l?.value, () =>
|
|
15058
|
+
bi = typeof t == "function" ? t : void 0;
|
|
15059
|
+
}, { immediate: !0 }), Q(() => l?.value, () => Ur(_.value.extension?.selection), { immediate: !0 }), Q([v, Wt], () => void qr(), {
|
|
15038
15060
|
immediate: !0,
|
|
15039
15061
|
deep: !0
|
|
15040
15062
|
});
|
|
15041
|
-
let
|
|
15042
|
-
let r =
|
|
15063
|
+
let xi = z(() => _i.value?.list?.actions ?? []), Si = z(() => xi.value.map(({ state: e, authorization: t, ...n }) => {
|
|
15064
|
+
let r = nc(), i = r.scope?.record?.id;
|
|
15043
15065
|
return {
|
|
15044
15066
|
...n,
|
|
15045
15067
|
...e?.(r),
|
|
15046
|
-
...t === "scope-record" &&
|
|
15047
|
-
authorizationContext:
|
|
15068
|
+
...t === "scope-record" && ia.value ? {
|
|
15069
|
+
authorizationContext: ia.value,
|
|
15048
15070
|
authorizationRecordId: i == null ? void 0 : String(i)
|
|
15049
15071
|
} : {}
|
|
15050
15072
|
};
|
|
15051
|
-
})),
|
|
15073
|
+
})), Ci = z(() => _i.value?.list?.columns ?? []), wi = z(() => [...Ci.value.map((e) => ({
|
|
15052
15074
|
key: e.key,
|
|
15053
15075
|
component: e.cell
|
|
15054
|
-
})), ...(
|
|
15076
|
+
})), ...(_i.value?.list?.cellComponents ?? []).map((e) => ({
|
|
15055
15077
|
key: e.key,
|
|
15056
15078
|
component: e.cell
|
|
15057
|
-
}))]),
|
|
15058
|
-
function
|
|
15059
|
-
return
|
|
15079
|
+
}))]), Ti = z(() => _i.value?.list?.rowActions ?? []);
|
|
15080
|
+
function Ei(e) {
|
|
15081
|
+
return Ti.value.map(({ state: t, ...n }) => ({
|
|
15060
15082
|
...n,
|
|
15061
|
-
...t?.(e,
|
|
15083
|
+
...t?.(e, nc())
|
|
15062
15084
|
}));
|
|
15063
15085
|
}
|
|
15064
|
-
let
|
|
15086
|
+
let Di = z(() => _i.value?.list?.batchActions ?? []), Oi = z(() => Vt.value?.managedActions === !0), ki = z(() => [...tt.value || rt.value ? [{
|
|
15065
15087
|
key: "__platform-check-save",
|
|
15066
15088
|
title: o("platform.action.check-save", "核实保存结果"),
|
|
15067
15089
|
loading: Te.value,
|
|
15068
15090
|
disabled: Te.value
|
|
15069
|
-
}] : [], ...
|
|
15091
|
+
}] : [], ...Li("PAGE")]), Ai = z(() => ki.value.find((e) => Hs(e.key) === "REFRESH")), ji = z(() => ki.value.find((e) => Hs(e.key) === "OPEN_CREATE")), Mi = z(() => ki.value.filter((e) => e !== Ai.value && e !== ji.value)), Ni = z(() => Li("DETAIL")), Pi = z(() => Li("FORM")), Fi = z(() => {
|
|
15070
15092
|
let e = M.value?.enabled === !1 ? "ENABLE" : "DISABLE";
|
|
15071
|
-
return
|
|
15072
|
-
}),
|
|
15073
|
-
function
|
|
15074
|
-
let t = bh(
|
|
15093
|
+
return Ni.value.find((t) => Hs(t.key) === e);
|
|
15094
|
+
}), Ii = z(() => Oi.value && !Wi.value ? Ni.value.filter((e) => !["ENABLE", "DISABLE"].includes(Hs(e.key) ?? "")) : Ni.value);
|
|
15095
|
+
function Li(e) {
|
|
15096
|
+
let t = bh(Vt.value?.actions ?? [], e, (e) => A.runtimeAction(e), or.value, P.value, Oi.value, M.value ?? void 0, a);
|
|
15075
15097
|
if (e === "DETAIL") {
|
|
15076
15098
|
let e = M.value?.id == null ? void 0 : String(M.value.id), n = M.value == null ? void 0 : We(M.value);
|
|
15077
15099
|
return t.map((t) => {
|
|
15078
|
-
let r =
|
|
15100
|
+
let r = Us(t.key);
|
|
15079
15101
|
return !t.key || r?.statusMode !== "INPUT_VALIDATION" ? t : {
|
|
15080
15102
|
...t,
|
|
15081
15103
|
loading: t.key === $e.value,
|
|
@@ -15086,51 +15108,51 @@ function mg(e, n, r) {
|
|
|
15086
15108
|
if (e !== "FORM") return t;
|
|
15087
15109
|
let n = N.value, r = n == null ? void 0 : We(n);
|
|
15088
15110
|
return t.map((e) => {
|
|
15089
|
-
let t =
|
|
15111
|
+
let t = Us(e.key);
|
|
15090
15112
|
return !e.key || t?.statusMode !== "INPUT_VALIDATION" ? e : {
|
|
15091
15113
|
...e,
|
|
15092
15114
|
iconName: I.isDraftValidated(e.key, r) ? "check" : "reload"
|
|
15093
15115
|
};
|
|
15094
15116
|
});
|
|
15095
15117
|
}
|
|
15096
|
-
let
|
|
15118
|
+
let Ri = z(() => _i.value?.list?.rowExpansion), zi = z(() => Vt.value?.list?.persistentQueryControls ?? []), Bi = z(() => Vt.value?.list?.querySummaries ?? []), Vi = z(() => Cr.value || Ri.value !== void 0), Hi = z(() => {
|
|
15097
15119
|
let e = M.value;
|
|
15098
|
-
return (
|
|
15099
|
-
let r = e ? t?.(e,
|
|
15120
|
+
return (_i.value?.detail?.actions ?? []).map(({ state: t, ...n }) => {
|
|
15121
|
+
let r = e ? t?.(e, nc()) : { visible: !1 };
|
|
15100
15122
|
return {
|
|
15101
15123
|
...n,
|
|
15102
15124
|
...r,
|
|
15103
15125
|
disabled: st.value || n.disabled === !0 || r?.disabled === !0
|
|
15104
15126
|
};
|
|
15105
15127
|
});
|
|
15106
|
-
}),
|
|
15107
|
-
if (!
|
|
15128
|
+
}), Ui = z(() => _i.value?.detail?.sections ?? []), Wi = z(() => _i.value?.recordView?.drawer), Gi = z(() => Wi.value ? Wi.value.width ?? "standard" : br.value.some((e) => e.visible?.constant !== !1) ? "extraWide" : "standard"), Ki = z(() => _i.value?.card?.assistant), qi = z(() => {
|
|
15129
|
+
if (!Ki.value) return;
|
|
15108
15130
|
let e = N.value ?? M.value;
|
|
15109
15131
|
return {
|
|
15110
15132
|
module: A,
|
|
15111
15133
|
mode: P.value,
|
|
15112
15134
|
...e ? { record: fm(jn(e)) } : {},
|
|
15113
|
-
loadedRecords:
|
|
15135
|
+
loadedRecords: yn.value.map((e) => fm(jn(e))),
|
|
15114
15136
|
formSessionKey: De.value,
|
|
15115
15137
|
saving: Te.value,
|
|
15116
15138
|
loading: ke.value,
|
|
15117
15139
|
loadFailed: je.value
|
|
15118
15140
|
};
|
|
15119
15141
|
});
|
|
15120
|
-
function
|
|
15121
|
-
let n =
|
|
15122
|
-
return !!(
|
|
15123
|
-
}
|
|
15124
|
-
let
|
|
15125
|
-
let e =
|
|
15126
|
-
if (e) return
|
|
15127
|
-
}),
|
|
15142
|
+
function Ji(e, t) {
|
|
15143
|
+
let n = Ki.value?.placement;
|
|
15144
|
+
return !!(qi.value && n?.boundary === e && n.position === t);
|
|
15145
|
+
}
|
|
15146
|
+
let Yi = z(() => {
|
|
15147
|
+
let e = Vt.value?.detail.workspaceView?.type;
|
|
15148
|
+
if (e) return _i.value?.workspaceViews?.find((t) => t.type === e);
|
|
15149
|
+
}), Xi = z(() => !(!j || !Yi.value || M.value?.id == null || P.value !== "view" || ke.value || je.value || Sa.value)), Zi = z(() => Vt.value?.template === "LIST_DETAIL_CARD" && !Wi.value), Qi = z(() => Nr.value || Zi.value || Fr.value || L.value), $i = z(() => Wi.value ? ["view"] : [
|
|
15128
15150
|
"view",
|
|
15129
15151
|
"edit",
|
|
15130
15152
|
"delete"
|
|
15131
|
-
]),
|
|
15132
|
-
NAVIGATOR: Object.fromEntries(
|
|
15133
|
-
let t =
|
|
15153
|
+
]), ea = z(() => !e.recordOnly && !!e.descriptor.menuId), ta = z(() => (!ea.value || jt.value !== void 0) && (!Or.value || Ht.value)), na = z(() => a.t("platform.screen.useModulePageSession.the-value-entry-is-not-supported-by-the-module-page", "{value1}入口暂未接入模块页面运行器", { value1: Dr.value })), ra = z(() => Qi.value || Rr.value.length > 0 ? "workspace" : e.descriptor.layout), ia = z(() => _.value.hidden ? void 0 : Ut.value[0]?.context), aa = z(() => ({
|
|
15154
|
+
NAVIGATOR: Object.fromEntries(Ut.value.flatMap((e) => {
|
|
15155
|
+
let t = Gt.value[e.descriptor.key]?.id;
|
|
15134
15156
|
return t == null ? [] : [[e.descriptor.key, t]];
|
|
15135
15157
|
})),
|
|
15136
15158
|
SESSION: {
|
|
@@ -15139,13 +15161,13 @@ function mg(e, n, r) {
|
|
|
15139
15161
|
organizationId: l?.value?.organizationId
|
|
15140
15162
|
},
|
|
15141
15163
|
RESOLVED_SELECTION: S.value
|
|
15142
|
-
})),
|
|
15164
|
+
})), oa = z(() => _.value.emptyListScope?.({
|
|
15143
15165
|
currentUser: l?.value,
|
|
15144
|
-
selectedNavigatorRecords:
|
|
15145
|
-
})),
|
|
15146
|
-
if (!(_.value.bypassListScope ||
|
|
15147
|
-
}),
|
|
15148
|
-
let e = Yh(
|
|
15166
|
+
selectedNavigatorRecords: Gt.value
|
|
15167
|
+
})), sa = z(() => {
|
|
15168
|
+
if (!(_.value.bypassListScope || oa.value !== void 0)) return Yh(Wt.value, "LIST_QUERY", { NAVIGATOR: aa.value.NAVIGATOR });
|
|
15169
|
+
}), ca = z(() => _.value.bypassListScope || oa.value !== void 0 ? [] : qh(Wt.value, "LIST_QUERY")), la = z(() => _.value.bypassListScope || oa.value !== void 0 ? [] : Jh(Wt.value)), ua = z(() => oe.value && la.value.every((e) => sa.value?.[e] != null)), da = z(() => {
|
|
15170
|
+
let e = Yh(Wt.value, "FORM_DEFAULT", aa.value) ?? {}, t = Vt.value?.treeResource, n = H.value?.id, r = ae.value && m.value ? { tenantId: m.value } : {};
|
|
15149
15171
|
return t && n != null ? {
|
|
15150
15172
|
...r,
|
|
15151
15173
|
...e,
|
|
@@ -15154,17 +15176,17 @@ function mg(e, n, r) {
|
|
|
15154
15176
|
...r,
|
|
15155
15177
|
...e
|
|
15156
15178
|
};
|
|
15157
|
-
}),
|
|
15158
|
-
let e = {}, t =
|
|
15159
|
-
for (let n of
|
|
15179
|
+
}), fa = z(() => {
|
|
15180
|
+
let e = {}, t = aa.value;
|
|
15181
|
+
for (let n of Wt.value) {
|
|
15160
15182
|
if (n.target !== "PICKER_QUERY" || !n.targetPickerFieldKey) continue;
|
|
15161
15183
|
let r = t[n.source]?.[n.sourceKey];
|
|
15162
15184
|
r == null || typeof r != "string" && typeof r != "number" && typeof r != "boolean" || ((e[n.targetPickerFieldKey] ??= {})[n.targetKey] = r);
|
|
15163
15185
|
}
|
|
15164
15186
|
return e;
|
|
15165
|
-
}),
|
|
15187
|
+
}), pa = z(() => new Set(Wt.value.filter((e) => e.target === "PICKER_QUERY" && e.targetPickerFieldKey).map((e) => e.targetPickerFieldKey))), ma = z(() => A.abilities.hasEnable() === !0 && typeof M.value?.enabled == "boolean" && (!Oi.value || !!Fi.value));
|
|
15166
15188
|
Q(() => [
|
|
15167
|
-
|
|
15189
|
+
ma.value,
|
|
15168
15190
|
M.value?.id,
|
|
15169
15191
|
M.value?.version
|
|
15170
15192
|
], ([e, t]) => {
|
|
@@ -15174,27 +15196,27 @@ function mg(e, n, r) {
|
|
|
15174
15196
|
language: a
|
|
15175
15197
|
}));
|
|
15176
15198
|
});
|
|
15177
|
-
let
|
|
15199
|
+
let ha = z(() => {
|
|
15178
15200
|
let e = M.value;
|
|
15179
|
-
return !
|
|
15180
|
-
}),
|
|
15201
|
+
return !ma.value || Sa.value || !e?.id || P.value !== "view" || ke.value || je.value || st.value || Oi.value && (!Fi.value || Fi.value.disabled) ? !1 : A.recordActionsSnapshot(String(e.id))?.actions.find((t) => t.actionCode === (e.enabled ? "disable" : "enable"))?.available === !0;
|
|
15202
|
+
}), ga = z(() => {
|
|
15181
15203
|
let e = M.value;
|
|
15182
|
-
if (!e?.id ||
|
|
15183
|
-
if (
|
|
15204
|
+
if (!e?.id || ha.value) return;
|
|
15205
|
+
if (Fi.value?.disabled) return Fi.value.disabledReason;
|
|
15184
15206
|
let t = e.enabled === !1 ? "enable" : "disable";
|
|
15185
15207
|
return A.action(t, String(e.id))?.reason ?? a.t("platform.screen.useModulePageSession.this-action-is-unavailable-for-the-current-record", "当前记录不允许执行此操作");
|
|
15186
|
-
}),
|
|
15208
|
+
}), _a = he({
|
|
15187
15209
|
context: A,
|
|
15188
|
-
listReloadKey:
|
|
15189
|
-
searchKeyword:
|
|
15210
|
+
listReloadKey: mn,
|
|
15211
|
+
searchKeyword: pn,
|
|
15190
15212
|
canChange: () => !st.value,
|
|
15191
|
-
resetSelection:
|
|
15192
|
-
}),
|
|
15213
|
+
resetSelection: wn
|
|
15214
|
+
}), va = z(() => tt.value || rt.value ? [{
|
|
15193
15215
|
key: "__platform-check-save",
|
|
15194
15216
|
title: o("platform.action.check-save", "核实保存结果"),
|
|
15195
15217
|
loading: Te.value,
|
|
15196
15218
|
disabled: Te.value
|
|
15197
|
-
}] :
|
|
15219
|
+
}] : _a.active.value ? [] : Oi.value ? P.value === "view" ? [] : [{
|
|
15198
15220
|
key: "cancel",
|
|
15199
15221
|
title: o("platform.action.cancel", "取消"),
|
|
15200
15222
|
disabled: st.value
|
|
@@ -15217,43 +15239,43 @@ function mg(e, n, r) {
|
|
|
15217
15239
|
}, {
|
|
15218
15240
|
key: "save",
|
|
15219
15241
|
actionCode: P.value === "create" ? "create" : "update",
|
|
15220
|
-
title: Te.value && $e.value === "save" ? o("platform.action.saving", "保存中") : o("platform.action.save", "保存"),
|
|
15221
|
-
loading: Te.value && $e.value === "save",
|
|
15222
|
-
disabled: st.value,
|
|
15242
|
+
title: mt.value ? o("platform.form.preparing", "正在准备表单…") : Te.value && $e.value === "save" ? o("platform.action.saving", "保存中") : o("platform.action.save", "保存"),
|
|
15243
|
+
loading: mt.value || Te.value && $e.value === "save",
|
|
15244
|
+
disabled: mt.value || st.value,
|
|
15223
15245
|
primary: !0
|
|
15224
15246
|
}]);
|
|
15225
|
-
function
|
|
15226
|
-
return P.value === "view" && !
|
|
15227
|
-
}
|
|
15228
|
-
let
|
|
15229
|
-
...
|
|
15230
|
-
...
|
|
15231
|
-
...
|
|
15232
|
-
...
|
|
15233
|
-
...!
|
|
15247
|
+
function ya() {
|
|
15248
|
+
return P.value === "view" && !_a.active.value && _n.value !== "recycleBin" && M.value != null;
|
|
15249
|
+
}
|
|
15250
|
+
let ba = z(() => ya() ? Hi.value : []), xa = z(() => [
|
|
15251
|
+
...va.value,
|
|
15252
|
+
...ba.value,
|
|
15253
|
+
...or.value,
|
|
15254
|
+
...ya() ? Ii.value : [],
|
|
15255
|
+
...!_a.active.value && P.value !== "view" ? Pi.value.map((e) => ({
|
|
15234
15256
|
...e,
|
|
15235
15257
|
disabled: st.value || ke.value || je.value || e.disabled,
|
|
15236
15258
|
loading: e.loading || e.key === $e.value
|
|
15237
15259
|
})) : []
|
|
15238
|
-
]),
|
|
15260
|
+
]), Sa = z(() => _a.active.value || _n.value === "recycleBin"), Ca = z(() => {
|
|
15239
15261
|
let e = M.value?.id, t = N.value?.id;
|
|
15240
|
-
return we.value && !
|
|
15241
|
-
}),
|
|
15242
|
-
if (!
|
|
15243
|
-
let e =
|
|
15262
|
+
return we.value && !Sa.value && !ke.value && !je.value && (P.value === "create" || t != null && e != null && String(e) === String(t));
|
|
15263
|
+
}), wa = z(() => {
|
|
15264
|
+
if (!Ir.value || !Rt.value.has("parentId")) return {};
|
|
15265
|
+
let e = pa.value.has("parentId");
|
|
15244
15266
|
return { parentId: {
|
|
15245
|
-
context:
|
|
15246
|
-
queryValues: () =>
|
|
15267
|
+
context: V.value ? A : e ? d(A, {
|
|
15268
|
+
queryValues: () => fa.value.parentId,
|
|
15247
15269
|
treePath: `/${A.moduleAlias}/tree`
|
|
15248
15270
|
}) : A,
|
|
15249
15271
|
mode: "tree",
|
|
15250
|
-
placeholder: a.t("platform.screen.useModulePageSession.leave-value-blank", "{value1}留空", { value1:
|
|
15272
|
+
placeholder: a.t("platform.screen.useModulePageSession.leave-value-blank", "{value1}留空", { value1: gi.value }),
|
|
15251
15273
|
allowClear: !0,
|
|
15252
15274
|
constraints: Lt(N.value?.id == null ? void 0 : String(N.value.id))
|
|
15253
15275
|
} };
|
|
15254
|
-
}),
|
|
15255
|
-
let e = { ...
|
|
15256
|
-
for (let t of
|
|
15276
|
+
}), Ta = z(() => {
|
|
15277
|
+
let e = { ...wa.value };
|
|
15278
|
+
for (let t of Rt.value.values()) {
|
|
15257
15279
|
let n = t.reference;
|
|
15258
15280
|
if (!n) continue;
|
|
15259
15281
|
let r = t.fieldRef.fieldName;
|
|
@@ -15262,8 +15284,8 @@ function mg(e, n, r) {
|
|
|
15262
15284
|
http: O.http,
|
|
15263
15285
|
moduleAlias: n.targetModuleAlias,
|
|
15264
15286
|
runtimeAccess: "REFERENCE"
|
|
15265
|
-
}), a =
|
|
15266
|
-
o && Object.assign(s,
|
|
15287
|
+
}), a = pa.value.has(r), o = n.candidateDelivery === "SOURCE_FIELD", s = {};
|
|
15288
|
+
o && Object.assign(s, Yn({
|
|
15267
15289
|
reference: n,
|
|
15268
15290
|
providerScopeKey: "main",
|
|
15269
15291
|
sourceModuleAlias: A.moduleAlias,
|
|
@@ -15273,10 +15295,10 @@ function mg(e, n, r) {
|
|
|
15273
15295
|
reloadRecord: () => N.value,
|
|
15274
15296
|
source: () => N.value?.id == null ? void 0 : { recordId: String(N.value.id) }
|
|
15275
15297
|
}));
|
|
15276
|
-
let c =
|
|
15298
|
+
let c = qn(n, Jn(t));
|
|
15277
15299
|
e[r] = {
|
|
15278
15300
|
context: a ? d(i, {
|
|
15279
|
-
queryValues: () =>
|
|
15301
|
+
queryValues: () => fa.value[r],
|
|
15280
15302
|
treePath: `/${n.targetModuleAlias}/tree`
|
|
15281
15303
|
}) : i,
|
|
15282
15304
|
mode: St(n.pickerMode),
|
|
@@ -15290,227 +15312,227 @@ function mg(e, n, r) {
|
|
|
15290
15312
|
Sn(async () => {
|
|
15291
15313
|
if (e.recordOnly) {
|
|
15292
15314
|
try {
|
|
15293
|
-
await
|
|
15315
|
+
await R(), await xe({ id: e.recordOnly.recordId }, "view");
|
|
15294
15316
|
} catch (e) {
|
|
15295
|
-
|
|
15317
|
+
Ft(e instanceof Error ? e : () => a.t("platform.screen.useModulePageSession.unable-to-load-the-page-runtime", "页面运行时加载失败"));
|
|
15296
15318
|
}
|
|
15297
15319
|
c || r();
|
|
15298
15320
|
return;
|
|
15299
15321
|
}
|
|
15300
|
-
|
|
15322
|
+
Ea(), Aa(), await It();
|
|
15301
15323
|
let t;
|
|
15302
15324
|
try {
|
|
15303
|
-
await
|
|
15304
|
-
|
|
15325
|
+
await nn(Or, () => !!_i.value?.recordView, () => {
|
|
15326
|
+
Ft(() => a.t("platform.screen.useModulePageSession.the-record-view-of-page-enhancement-value-supports-list-modules", "模块页面增强 {value1} 的业务查看呈现仅支持普通列表模块,不支持树模块", { value1: _i.value?.id ?? "unknown" }));
|
|
15305
15327
|
}), t = O.runtime.snapshot()?.tenantRequired === !0;
|
|
15306
15328
|
} catch (e) {
|
|
15307
|
-
|
|
15329
|
+
Ft(e instanceof Error ? e : () => a.t("platform.screen.useModulePageSession.unable-to-load-the-page-runtime", "页面运行时加载失败"));
|
|
15308
15330
|
}
|
|
15309
|
-
c || (t !== void 0 && e.tenantController.setRequired(t), r(), await hn(), !c &&
|
|
15331
|
+
c || (t !== void 0 && e.tenantController.setRequired(t), r(), await hn(), !c && Or.value && !Pt.value && (zn = Nh.register(A.moduleAlias, ac)));
|
|
15310
15332
|
}), Cn(() => {
|
|
15311
|
-
|
|
15333
|
+
wt += 1;
|
|
15312
15334
|
});
|
|
15313
|
-
async function
|
|
15314
|
-
let e = ++
|
|
15335
|
+
async function Ea() {
|
|
15336
|
+
let e = ++Bn;
|
|
15315
15337
|
try {
|
|
15316
15338
|
let t = await Rh(_t, A.moduleAlias);
|
|
15317
|
-
e ===
|
|
15339
|
+
e === Bn && ($.value = t);
|
|
15318
15340
|
} catch {}
|
|
15319
15341
|
}
|
|
15320
|
-
function Ea() {
|
|
15321
|
-
Oa("drawer");
|
|
15322
|
-
}
|
|
15323
15342
|
function Da() {
|
|
15324
|
-
|
|
15343
|
+
ka("drawer");
|
|
15344
|
+
}
|
|
15345
|
+
function Oa() {
|
|
15346
|
+
ka("pinned");
|
|
15325
15347
|
}
|
|
15326
|
-
function
|
|
15327
|
-
|
|
15348
|
+
function ka(e) {
|
|
15349
|
+
$.value = e, Vn = Vn.catch(() => void 0).then(() => zh(_t, A.moduleAlias, e)), Vn.catch(() => void 0);
|
|
15328
15350
|
}
|
|
15329
|
-
async function
|
|
15330
|
-
let e = ++
|
|
15351
|
+
async function Aa() {
|
|
15352
|
+
let e = ++Hn;
|
|
15331
15353
|
try {
|
|
15332
|
-
let t = await Uh(_t, A.moduleAlias,
|
|
15333
|
-
e ===
|
|
15354
|
+
let t = await Uh(_t, A.moduleAlias, In.value);
|
|
15355
|
+
e === Hn && (In.value = t);
|
|
15334
15356
|
} catch {}
|
|
15335
15357
|
}
|
|
15336
|
-
function
|
|
15337
|
-
|
|
15338
|
-
let t = Hh(e,
|
|
15339
|
-
|
|
15358
|
+
function ja(e) {
|
|
15359
|
+
Hn += 1;
|
|
15360
|
+
let t = Hh(e, In.value);
|
|
15361
|
+
In.value = t, Un = Un.catch(() => void 0).then(() => Wh(_t, A.moduleAlias, t)), Un.catch(() => void 0);
|
|
15340
15362
|
}
|
|
15341
15363
|
Cn(() => {
|
|
15342
|
-
|
|
15364
|
+
bi?.(), zn?.(), zn = void 0;
|
|
15343
15365
|
});
|
|
15344
|
-
function
|
|
15345
|
-
|
|
15366
|
+
function Ma(e) {
|
|
15367
|
+
xn(e, _a.active.value);
|
|
15346
15368
|
}
|
|
15347
|
-
function
|
|
15369
|
+
function Na(e, t) {
|
|
15348
15370
|
if (!t) return;
|
|
15349
15371
|
let n = e[t];
|
|
15350
15372
|
return n == null || String(n).trim() === "" ? void 0 : y(e, t, a);
|
|
15351
15373
|
}
|
|
15352
|
-
function
|
|
15353
|
-
let n =
|
|
15354
|
-
return n == null ? `${
|
|
15355
|
-
}
|
|
15356
|
-
function Pa(e) {
|
|
15357
|
-
return Ma(e, Bt.value?.explorer?.titleField ?? "title") ?? a.t("platform.record.unnamed", "未命名记录");
|
|
15374
|
+
function Pa(e, t) {
|
|
15375
|
+
let n = Vt.value?.quickSearchFields;
|
|
15376
|
+
return n == null ? `${Fa(e)} ${Ia(e) ?? ""}`.toLowerCase().includes(t.toLowerCase()) : n.some((n) => (Na(e, n) ?? "").toLowerCase().includes(t.toLowerCase()));
|
|
15358
15377
|
}
|
|
15359
15378
|
function Fa(e) {
|
|
15360
|
-
return
|
|
15379
|
+
return Na(e, Vt.value?.explorer?.titleField ?? "title") ?? a.t("platform.record.unnamed", "未命名记录");
|
|
15380
|
+
}
|
|
15381
|
+
function Ia(e) {
|
|
15382
|
+
return Na(e, Vt.value?.explorer?.secondaryField);
|
|
15361
15383
|
}
|
|
15362
|
-
function
|
|
15363
|
-
let n =
|
|
15384
|
+
function La(e, t = {}) {
|
|
15385
|
+
let n = ni.value?.secondaryField, r = Na(e, n);
|
|
15364
15386
|
return {
|
|
15365
|
-
title: t[
|
|
15387
|
+
title: t[Vt.value?.explorer?.titleField ?? "title"] ?? Na(e, Vt.value?.explorer?.titleField) ?? y(e, "title", a) ?? e.alias ?? e.code ?? e.id ?? ni.value?.fallbackTitle ?? a.t("platform.record.unnamed", "未命名记录"),
|
|
15366
15388
|
secondary: t[n ?? ""] ?? (r == null || String(r).trim() === "" ? void 0 : String(r)),
|
|
15367
15389
|
muted: e.enabled === !1
|
|
15368
15390
|
};
|
|
15369
15391
|
}
|
|
15370
|
-
function
|
|
15371
|
-
if (Be(),
|
|
15392
|
+
function Ra(e) {
|
|
15393
|
+
if (Be(), _a.active.value) {
|
|
15372
15394
|
ve(e);
|
|
15373
15395
|
return;
|
|
15374
15396
|
}
|
|
15375
|
-
|
|
15397
|
+
Ks(e);
|
|
15376
15398
|
}
|
|
15377
|
-
function
|
|
15399
|
+
function za(e) {
|
|
15378
15400
|
if (e.key === "__platform-check-save") {
|
|
15379
|
-
|
|
15401
|
+
Es();
|
|
15380
15402
|
return;
|
|
15381
15403
|
}
|
|
15382
|
-
if (Be(),
|
|
15383
|
-
|
|
15404
|
+
if (Be(), Pi.value.some((t) => t.key === e.key)) {
|
|
15405
|
+
Qs(e);
|
|
15384
15406
|
return;
|
|
15385
15407
|
}
|
|
15386
|
-
if (
|
|
15387
|
-
|
|
15408
|
+
if (Ni.value.some((t) => t.key === e.key)) {
|
|
15409
|
+
Xs(e);
|
|
15388
15410
|
return;
|
|
15389
15411
|
}
|
|
15390
|
-
let t = M.value, n =
|
|
15412
|
+
let t = M.value, n = ba.value.find((t) => t.key === e.key);
|
|
15391
15413
|
if (t && n) {
|
|
15392
|
-
|
|
15414
|
+
Ba(n, t);
|
|
15393
15415
|
return;
|
|
15394
15416
|
}
|
|
15395
|
-
if (
|
|
15396
|
-
|
|
15417
|
+
if (or.value.some((t) => t.key === e.key)) {
|
|
15418
|
+
pr(e);
|
|
15397
15419
|
return;
|
|
15398
15420
|
}
|
|
15399
15421
|
if (e.key === "cancel") {
|
|
15400
|
-
|
|
15422
|
+
hc();
|
|
15401
15423
|
return;
|
|
15402
15424
|
}
|
|
15403
15425
|
if (e.key === "save") {
|
|
15404
|
-
|
|
15426
|
+
Ds();
|
|
15405
15427
|
return;
|
|
15406
15428
|
}
|
|
15407
15429
|
if (e.key === "edit" && M.value) {
|
|
15408
|
-
|
|
15430
|
+
os(M.value, "restore-view");
|
|
15409
15431
|
return;
|
|
15410
15432
|
}
|
|
15411
|
-
e.key === "delete" && M.value &&
|
|
15433
|
+
e.key === "delete" && M.value && Fs(M.value);
|
|
15412
15434
|
}
|
|
15413
|
-
async function
|
|
15435
|
+
async function Ba(t, n) {
|
|
15414
15436
|
if (!st.value) {
|
|
15415
15437
|
et.value = !0;
|
|
15416
15438
|
try {
|
|
15417
15439
|
await fe(t, {
|
|
15418
|
-
...
|
|
15440
|
+
...tc(n),
|
|
15419
15441
|
record: n
|
|
15420
|
-
}) && e.recordOnly && await
|
|
15442
|
+
}) && e.recordOnly && await Va(n);
|
|
15421
15443
|
} finally {
|
|
15422
15444
|
et.value = !1;
|
|
15423
15445
|
}
|
|
15424
15446
|
}
|
|
15425
15447
|
}
|
|
15426
|
-
async function
|
|
15448
|
+
async function Va(t) {
|
|
15427
15449
|
let n = t.id == null ? void 0 : String(t.id);
|
|
15428
15450
|
if (!e.recordOnly || !n) return;
|
|
15429
|
-
let r = await
|
|
15430
|
-
r.failure &&
|
|
15431
|
-
}
|
|
15432
|
-
async function Va(e) {
|
|
15433
|
-
(M.value?.id === e.id || await sc()) && M.value?.id !== e.id && (Re.value += 1, J(e, ei.value));
|
|
15451
|
+
let r = await Rs(n);
|
|
15452
|
+
r.failure && zs(r.failure, "module-record-only");
|
|
15434
15453
|
}
|
|
15435
15454
|
async function Ha(e) {
|
|
15436
|
-
(M.value?.id === e.id || await
|
|
15455
|
+
(M.value?.id === e.id || await cc()) && M.value?.id !== e.id && (Re.value += 1, En(e, ti.value));
|
|
15456
|
+
}
|
|
15457
|
+
async function Ua(e) {
|
|
15458
|
+
(M.value?.id === e.id || await cc()) && (Re.value += 1, On(e));
|
|
15437
15459
|
}
|
|
15438
|
-
function
|
|
15439
|
-
if (!
|
|
15440
|
-
let r =
|
|
15460
|
+
function Wa(e, t, n = "user") {
|
|
15461
|
+
if (!Ut.value.some((t) => t.descriptor.key === e) || n !== "entry" && $r(e)) return;
|
|
15462
|
+
let r = Gt.value[e], i = r?.id != null && String(r.id) === String(t.id);
|
|
15441
15463
|
if (i && n !== "user") return;
|
|
15442
15464
|
n === "user" && (Re.value += 1);
|
|
15443
|
-
let a = { ...
|
|
15465
|
+
let a = { ...Gt.value };
|
|
15444
15466
|
a[e] = i ? void 0 : t;
|
|
15445
|
-
let o =
|
|
15467
|
+
let o = ro(e);
|
|
15446
15468
|
for (let e of o) a[e] = void 0;
|
|
15447
|
-
|
|
15469
|
+
Gt.value = a, Yt.value = i ? [.../* @__PURE__ */ new Set([...Yt.value, e])] : Yt.value.filter((t) => t !== e && !o.has(t)), Do();
|
|
15448
15470
|
}
|
|
15449
|
-
function
|
|
15450
|
-
if (
|
|
15451
|
-
Re.value += 1,
|
|
15471
|
+
function Ga(e) {
|
|
15472
|
+
if ($r(e) || !Gt.value[e]) return;
|
|
15473
|
+
Re.value += 1, Yt.value = [.../* @__PURE__ */ new Set([...Yt.value, e])];
|
|
15452
15474
|
let t = {
|
|
15453
|
-
...
|
|
15475
|
+
...Gt.value,
|
|
15454
15476
|
[e]: void 0
|
|
15455
15477
|
};
|
|
15456
|
-
for (let n of
|
|
15457
|
-
|
|
15478
|
+
for (let n of ro(e)) t[n] = void 0;
|
|
15479
|
+
Gt.value = t, Do();
|
|
15458
15480
|
}
|
|
15459
|
-
function
|
|
15460
|
-
|
|
15481
|
+
function Ka(e, t, n = !1) {
|
|
15482
|
+
no(e, t);
|
|
15461
15483
|
let r = e.descriptor.key, i = n && t.length === 1 && t[0]?.id != null;
|
|
15462
|
-
if (i !==
|
|
15463
|
-
|
|
15484
|
+
if (i !== Kt.value.includes(r) && (Kt.value = i ? [...Kt.value, r] : Kt.value.filter((e) => e !== r)), Qt(e)) {
|
|
15485
|
+
Ja(e, t, n);
|
|
15464
15486
|
return;
|
|
15465
15487
|
}
|
|
15466
|
-
|
|
15488
|
+
Ya(e, t, n);
|
|
15467
15489
|
}
|
|
15468
|
-
function
|
|
15469
|
-
|
|
15490
|
+
function qa(e) {
|
|
15491
|
+
Ja(e, []);
|
|
15470
15492
|
}
|
|
15471
|
-
function
|
|
15472
|
-
let r = e.descriptor.key, i =
|
|
15473
|
-
|
|
15474
|
-
if (a &&
|
|
15475
|
-
if (a.record &&
|
|
15476
|
-
|
|
15493
|
+
function Ja(e, t, n = !1) {
|
|
15494
|
+
let r = e.descriptor.key, i = Xa(r);
|
|
15495
|
+
$t(e, t, oo(r)).then((a) => {
|
|
15496
|
+
if (a && en(e, a) && i === Xa(r)) {
|
|
15497
|
+
if (a.record && Gt.value[r]?.id == null) {
|
|
15498
|
+
Wa(r, a.record, "entry");
|
|
15477
15499
|
return;
|
|
15478
15500
|
}
|
|
15479
|
-
|
|
15501
|
+
Ya(e, t, n);
|
|
15480
15502
|
}
|
|
15481
15503
|
});
|
|
15482
15504
|
}
|
|
15483
|
-
function
|
|
15484
|
-
if (
|
|
15505
|
+
function Ya(e, t, n) {
|
|
15506
|
+
if ($r(e.descriptor.key)) return;
|
|
15485
15507
|
let r = e.descriptor.key, i = n && t.length === 1 && t[0]?.id != null && e.descriptor.singleResultPolicy !== void 0 && e.descriptor.singleResultPolicy !== "NONE", a = t[0]?.id != null && e.descriptor.initialSelectionPolicy === "FIRST_RECORD";
|
|
15486
|
-
(i || a) &&
|
|
15508
|
+
(i || a) && Gt.value[r]?.id == null && !Yt.value.includes(r) && Wa(r, t[0], "entry");
|
|
15487
15509
|
}
|
|
15488
|
-
function
|
|
15489
|
-
let t =
|
|
15510
|
+
function Xa(e) {
|
|
15511
|
+
let t = oo(e);
|
|
15490
15512
|
return JSON.stringify(Object.entries(t ?? {}).sort(([e], [t]) => e.localeCompare(t)));
|
|
15491
15513
|
}
|
|
15492
|
-
function
|
|
15514
|
+
function Za(e) {
|
|
15493
15515
|
if (!e) return;
|
|
15494
|
-
let t = new Set([e.previous?.moduleAlias, e.current?.moduleAlias].filter((e) => e != null)), n =
|
|
15516
|
+
let t = new Set([e.previous?.moduleAlias, e.current?.moduleAlias].filter((e) => e != null)), n = Ut.value.filter((e) => t.has(e.descriptor.sourceModuleAlias)).map((e) => e.descriptor.key);
|
|
15495
15517
|
if (n.length === 0) return;
|
|
15496
15518
|
let r = new Set(n);
|
|
15497
|
-
n.forEach((e) =>
|
|
15498
|
-
let i = { ...
|
|
15519
|
+
n.forEach((e) => ro(e).forEach((e) => r.add(e)));
|
|
15520
|
+
let i = { ...Gt.value }, a = [...r].some((e) => i[e] !== void 0);
|
|
15499
15521
|
r.forEach((e) => {
|
|
15500
15522
|
i[e] = void 0;
|
|
15501
|
-
}),
|
|
15502
|
-
...
|
|
15503
|
-
...Object.fromEntries(n.map((e) => [e, (
|
|
15523
|
+
}), Gt.value = i, Yt.value = Yt.value.filter((e) => !r.has(e)), a && Do(), rn.value = {
|
|
15524
|
+
...rn.value,
|
|
15525
|
+
...Object.fromEntries(n.map((e) => [e, (rn.value[e] ?? 0) + 1]))
|
|
15504
15526
|
};
|
|
15505
15527
|
}
|
|
15506
|
-
function Za(e) {
|
|
15507
|
-
return Pn.value + (nn.value[e] ?? 0);
|
|
15508
|
-
}
|
|
15509
15528
|
function Qa(e) {
|
|
15510
|
-
return rn.value[e
|
|
15529
|
+
return Fn.value + (rn.value[e] ?? 0);
|
|
15511
15530
|
}
|
|
15512
15531
|
function $a(e) {
|
|
15513
|
-
|
|
15532
|
+
return B.value[e.descriptor.key] === !0;
|
|
15533
|
+
}
|
|
15534
|
+
function eo(e) {
|
|
15535
|
+
let t = $a(e), n = Pn.value.trim() ? a.t("platform.screen.ModulePageHostRuntime.clear-the-search-to-reorder-records", "清空搜索后可调整排序") : lo(e);
|
|
15514
15536
|
return {
|
|
15515
15537
|
...e.sort,
|
|
15516
15538
|
active: t && e.sort.enabled && n === void 0,
|
|
@@ -15518,59 +15540,59 @@ function mg(e, n, r) {
|
|
|
15518
15540
|
disabledReason: n
|
|
15519
15541
|
};
|
|
15520
15542
|
}
|
|
15521
|
-
function
|
|
15543
|
+
function to(e) {
|
|
15522
15544
|
let t = e.descriptor.key;
|
|
15523
|
-
|
|
15524
|
-
...
|
|
15525
|
-
[t]:
|
|
15545
|
+
B.value = {
|
|
15546
|
+
...B.value,
|
|
15547
|
+
[t]: !$a(e)
|
|
15526
15548
|
};
|
|
15527
15549
|
}
|
|
15528
|
-
function
|
|
15529
|
-
if (!
|
|
15550
|
+
function no(e, t) {
|
|
15551
|
+
if (!uo(e)) return;
|
|
15530
15552
|
let n = t.flatMap((e) => e.id == null ? [] : [String(e.id)]);
|
|
15531
15553
|
n.length !== 0 && e.context.recordActionsBatch?.(n).catch(() => {});
|
|
15532
15554
|
}
|
|
15533
|
-
function
|
|
15555
|
+
function ro(e) {
|
|
15534
15556
|
let t = /* @__PURE__ */ new Set(), n = [e];
|
|
15535
15557
|
for (; n.length > 0;) {
|
|
15536
|
-
let e = n.pop(), r =
|
|
15537
|
-
for (let e of
|
|
15558
|
+
let e = n.pop(), r = Ut.value.find((t) => t.descriptor.key === e);
|
|
15559
|
+
for (let e of Wt.value) e.source === "NAVIGATOR" && e.sourceKey === r?.descriptor.key && e.target === "NAVIGATOR_QUERY" && e.targetNavigatorLevelKey != null && !t.has(e.targetNavigatorLevelKey) && (t.add(e.targetNavigatorLevelKey), n.push(e.targetNavigatorLevelKey));
|
|
15538
15560
|
}
|
|
15539
15561
|
return t;
|
|
15540
15562
|
}
|
|
15541
|
-
let
|
|
15563
|
+
let io = /* @__PURE__ */ new Map(), ao = z(() => {
|
|
15542
15564
|
let e = /* @__PURE__ */ new Set(), t = /* @__PURE__ */ new Map();
|
|
15543
|
-
for (let n of
|
|
15565
|
+
for (let n of Ut.value) {
|
|
15544
15566
|
let r = n.descriptor.key;
|
|
15545
15567
|
e.add(r);
|
|
15546
|
-
let i = Yh(
|
|
15547
|
-
|
|
15568
|
+
let i = Yh(Wt.value, "NAVIGATOR_QUERY", aa.value, r), a = Xh(io.get(r), i);
|
|
15569
|
+
io.set(r, a), t.set(r, a);
|
|
15548
15570
|
}
|
|
15549
|
-
for (let t of
|
|
15571
|
+
for (let t of io.keys()) e.has(t) || io.delete(t);
|
|
15550
15572
|
return t;
|
|
15551
15573
|
});
|
|
15552
|
-
function ao(e) {
|
|
15553
|
-
return io.value.get(e);
|
|
15554
|
-
}
|
|
15555
15574
|
function oo(e) {
|
|
15556
|
-
return
|
|
15575
|
+
return ao.value.get(e);
|
|
15557
15576
|
}
|
|
15558
15577
|
function so(e) {
|
|
15559
|
-
|
|
15560
|
-
let t = oo(e.descriptor.key), n = ao(e.descriptor.key);
|
|
15561
|
-
return t.every((e) => n?.[e] != null);
|
|
15578
|
+
return qh(Wt.value, "NAVIGATOR_QUERY", e);
|
|
15562
15579
|
}
|
|
15563
15580
|
function co(e) {
|
|
15564
|
-
|
|
15581
|
+
if (!oe.value) return !1;
|
|
15582
|
+
let t = so(e.descriptor.key), n = oo(e.descriptor.key);
|
|
15583
|
+
return t.every((e) => n?.[e] != null);
|
|
15565
15584
|
}
|
|
15566
15585
|
function lo(e) {
|
|
15586
|
+
return oe.value ? co(e) ? void 0 : a.t("platform.screen.useModulePageSession.select-the-upstream-scope-first", "请先完成上游范围选择") : a.t("platform.screen.useModulePageSession.select-a-business-tenant-first", "请先选择业务租户");
|
|
15587
|
+
}
|
|
15588
|
+
function uo(e) {
|
|
15567
15589
|
return e.descriptor.management != null;
|
|
15568
15590
|
}
|
|
15569
|
-
function
|
|
15570
|
-
if (!
|
|
15591
|
+
function fo(e, t) {
|
|
15592
|
+
if (!uo(e)) return [];
|
|
15571
15593
|
let n = [];
|
|
15572
15594
|
if (e.tree && e.context.can("create") === !0) {
|
|
15573
|
-
let t =
|
|
15595
|
+
let t = mo(e);
|
|
15574
15596
|
n.push({
|
|
15575
15597
|
key: "create-child",
|
|
15576
15598
|
title: a.t("platform.screen.ModuleRecordDetailActions.create-child", "新建子项"),
|
|
@@ -15579,9 +15601,9 @@ function mg(e, n, r) {
|
|
|
15579
15601
|
disabledReason: t.message
|
|
15580
15602
|
});
|
|
15581
15603
|
}
|
|
15582
|
-
return e.context.can("update") === !0 && n.push(
|
|
15604
|
+
return e.context.can("update") === !0 && n.push(po(e, t, "edit", "update", a.t("platform.screen.ManagedDetailRelationSurface.edit-value", "编辑{value1}", { value1: e.descriptor.title }), "edit")), e.context.can("delete") === !0 && n.push(po(e, t, "delete", "delete", a.t("platform.screen.ManagedDetailRelationSurface.delete-value", "删除{value1}", { value1: e.descriptor.title }), "delete")), n;
|
|
15583
15605
|
}
|
|
15584
|
-
function
|
|
15606
|
+
function po(e, t, n, r, i, o) {
|
|
15585
15607
|
let s = t.id == null ? void 0 : String(t.id);
|
|
15586
15608
|
if (!s) return {
|
|
15587
15609
|
key: n,
|
|
@@ -15593,7 +15615,7 @@ function mg(e, n, r) {
|
|
|
15593
15615
|
disabledReason: a.t("platform.screen.useModulePageSession.the-record-id-is-missing", "记录标识缺失")
|
|
15594
15616
|
};
|
|
15595
15617
|
let c = e.context.recordActionsSnapshot(s)?.actions.find((e) => e.actionCode === r);
|
|
15596
|
-
return n === "edit" && !
|
|
15618
|
+
return n === "edit" && !ss() ? {
|
|
15597
15619
|
key: n,
|
|
15598
15620
|
actionCode: r,
|
|
15599
15621
|
title: i,
|
|
@@ -15618,70 +15640,70 @@ function mg(e, n, r) {
|
|
|
15618
15640
|
disabledReason: a.t("platform.screen.ModuleActionButton.checking-action-availability", "正在校验操作可用性")
|
|
15619
15641
|
};
|
|
15620
15642
|
}
|
|
15621
|
-
function
|
|
15643
|
+
function mo(e) {
|
|
15622
15644
|
let t = ph({
|
|
15623
15645
|
tenantReady: oe.value,
|
|
15624
|
-
pageReady:
|
|
15625
|
-
permitted:
|
|
15626
|
-
editing:
|
|
15627
|
-
busy:
|
|
15628
|
-
scopeReady:
|
|
15646
|
+
pageReady: ta.value && e.context.runtime.snapshot() != null,
|
|
15647
|
+
permitted: uo(e) && e.context.can("create") === !0,
|
|
15648
|
+
editing: _r.value,
|
|
15649
|
+
busy: gr.value,
|
|
15650
|
+
scopeReady: co(e)
|
|
15629
15651
|
}, a);
|
|
15630
15652
|
return t.reason === "SCOPE_REQUIRED" ? {
|
|
15631
15653
|
...t,
|
|
15632
|
-
message:
|
|
15654
|
+
message: lo(e)
|
|
15633
15655
|
} : t;
|
|
15634
15656
|
}
|
|
15635
|
-
function
|
|
15636
|
-
if (!
|
|
15637
|
-
n === "user" && Be(),
|
|
15638
|
-
let r = Yh(
|
|
15657
|
+
function ho(e, t, n = "user") {
|
|
15658
|
+
if (!mo(e).ready) return;
|
|
15659
|
+
n === "user" && Be(), Nn += 1, An.value = !1, Z.value = !0, X.value = e;
|
|
15660
|
+
let r = Yh(Wt.value.filter((e) => e.source === "SESSION" && e.target === "FORM_DEFAULT"), "FORM_DEFAULT", aa.value), i = {
|
|
15639
15661
|
...ae.value && m.value ? { tenantId: m.value } : {},
|
|
15640
15662
|
...r ?? {},
|
|
15641
|
-
...
|
|
15663
|
+
...oo(e.descriptor.key) ?? {},
|
|
15642
15664
|
...t ? { parentId: t } : {}
|
|
15643
15665
|
};
|
|
15644
15666
|
Y.beginCreate(i);
|
|
15645
15667
|
let a = Y.draft.value;
|
|
15646
15668
|
if (a) {
|
|
15647
|
-
let t =
|
|
15669
|
+
let t = zo(e.context.runtime.snapshot()?.uiDescriptor, e.descriptor.management?.editorSurface) ?? [];
|
|
15648
15670
|
Y.draft.value = new Np(t).applyOnCreate(a);
|
|
15649
15671
|
}
|
|
15650
15672
|
}
|
|
15651
|
-
let
|
|
15652
|
-
let e =
|
|
15653
|
-
return !!(e &&
|
|
15673
|
+
let go = z(() => {
|
|
15674
|
+
let e = X.value, t = Y.draft.value;
|
|
15675
|
+
return !!(e && uo(e) && t?.id != null && Y.mode.value === "edit" && e.context.abilities.hasEnable() === !0);
|
|
15654
15676
|
});
|
|
15655
|
-
function
|
|
15656
|
-
let t =
|
|
15657
|
-
return !t || !
|
|
15677
|
+
function _o(e) {
|
|
15678
|
+
let t = X.value, n = Y.draft.value?.id;
|
|
15679
|
+
return !t || !uo(t) || n == null ? !1 : t.context.recordActionsSnapshot(String(n))?.actions.find((t) => t.actionCode === e)?.available === !0;
|
|
15658
15680
|
}
|
|
15659
|
-
let
|
|
15681
|
+
let vo = z(() => {
|
|
15660
15682
|
let e = Y.draft.value;
|
|
15661
|
-
return !
|
|
15662
|
-
}),
|
|
15683
|
+
return !go.value || !e?.id || typeof e.version != "number" || Y.loading.value || Y.loadFailed.value || Y.saving.value || An.value ? !0 : !_o(e.enabled === !1 ? "enable" : "disable");
|
|
15684
|
+
}), yo = z(() => {
|
|
15663
15685
|
let e = Y.draft.value;
|
|
15664
|
-
if (!e?.id || !
|
|
15686
|
+
if (!e?.id || !vo.value) return;
|
|
15665
15687
|
let t = e.enabled === !1 ? "enable" : "disable";
|
|
15666
|
-
return
|
|
15688
|
+
return X.value?.context.action(t, String(e.id))?.reason;
|
|
15667
15689
|
});
|
|
15668
|
-
async function
|
|
15669
|
-
let t =
|
|
15670
|
-
if (!t || !
|
|
15690
|
+
async function bo(e) {
|
|
15691
|
+
let t = X.value, n = Y.draft.value, r = n?.id == null ? void 0 : String(n.id), i = typeof n?.version == "number" ? n.version : void 0;
|
|
15692
|
+
if (!t || !uo(t) || !n || !r || i === void 0 || vo.value) return;
|
|
15671
15693
|
Be();
|
|
15672
|
-
let o =
|
|
15673
|
-
|
|
15694
|
+
let o = Nn, s = { ...n };
|
|
15695
|
+
An.value = !0;
|
|
15674
15696
|
try {
|
|
15675
15697
|
let n = e ? await t.context.crud.enable(r, { version: i }) : await t.context.crud.disable(r, { version: i });
|
|
15676
15698
|
t.context.invalidateRecordActions?.([r]);
|
|
15677
15699
|
let c = await t.context.crud.view(r);
|
|
15678
|
-
if (await t.context.recordActions(r).catch(() => void 0), o !==
|
|
15700
|
+
if (await t.context.recordActions(r).catch(() => void 0), o !== Nn || X.value !== t) return;
|
|
15679
15701
|
Y.record.value = c, Y.draft.value = {
|
|
15680
15702
|
...c,
|
|
15681
15703
|
...s,
|
|
15682
15704
|
enabled: c.enabled,
|
|
15683
15705
|
version: c.version
|
|
15684
|
-
}, Y.formSessionKey.value += 1,
|
|
15706
|
+
}, Y.formSessionKey.value += 1, Fn.value += 1, await Bs(n, e ? a.t("platform.screen.DynamicModuleWorkspaceDetailView.enabled", "已启用") : a.t("platform.workflow.disabled", "已停用"));
|
|
15685
15707
|
} catch (e) {
|
|
15686
15708
|
ze(e, {
|
|
15687
15709
|
source: "navigator-management",
|
|
@@ -15689,64 +15711,64 @@ function mg(e, n, r) {
|
|
|
15689
15711
|
language: a
|
|
15690
15712
|
});
|
|
15691
15713
|
} finally {
|
|
15692
|
-
o ===
|
|
15714
|
+
o === Nn && (An.value = !1);
|
|
15693
15715
|
}
|
|
15694
15716
|
}
|
|
15695
|
-
function
|
|
15696
|
-
|
|
15717
|
+
function xo(e, t) {
|
|
15718
|
+
So([{
|
|
15697
15719
|
fieldName: e,
|
|
15698
15720
|
value: t
|
|
15699
15721
|
}]);
|
|
15700
15722
|
}
|
|
15701
|
-
function
|
|
15723
|
+
function So(e, t = "user", n) {
|
|
15702
15724
|
let r = Y.draft.value;
|
|
15703
|
-
if (!r ||
|
|
15725
|
+
if (!r || gr.value) {
|
|
15704
15726
|
if (t === "assistant") throw Error(a.t("platform.screen.useModulePageSession.the-navigation-form-is-not-ready-wait-or-reopen-the", "导航表单尚未就绪,请等待或重新打开编辑器"));
|
|
15705
15727
|
return;
|
|
15706
15728
|
}
|
|
15707
15729
|
if (e.length === 0) return;
|
|
15708
|
-
let i =
|
|
15709
|
-
for (let { fieldName: t, value: n } of e) o = gt(o, t, n,
|
|
15710
|
-
let s = new Np(
|
|
15730
|
+
let i = X.value, o = r;
|
|
15731
|
+
for (let { fieldName: t, value: n } of e) o = gt(o, t, n, Zn.value);
|
|
15732
|
+
let s = new Np(zo(i?.context.runtime.snapshot()?.uiDescriptor, i?.descriptor.management?.editorSurface)).applyAfterChange(o, zp(r, o, e.map(({ fieldName: e }) => e)));
|
|
15711
15733
|
Cp(s, n), t === "user" && Be(), Y.draft.value = s;
|
|
15712
15734
|
}
|
|
15713
|
-
async function
|
|
15735
|
+
async function Co(e, t) {
|
|
15714
15736
|
let n = t.id == null ? void 0 : String(t.id);
|
|
15715
|
-
if (!
|
|
15737
|
+
if (!uo(e) || !n || e.context.can("update") !== !0 || !co(e) || !ss()) return;
|
|
15716
15738
|
Be();
|
|
15717
|
-
let r = ++
|
|
15718
|
-
|
|
15739
|
+
let r = ++Nn;
|
|
15740
|
+
An.value = !1, Z.value = !0, X.value = e, Y.beginLoad(t, "edit");
|
|
15719
15741
|
try {
|
|
15720
15742
|
let t = await e.context.crud.view(n);
|
|
15721
|
-
await e.context.recordActions(n).catch(() => void 0), r ===
|
|
15743
|
+
await e.context.recordActions(n).catch(() => void 0), r === Nn && X.value === e && Y.resolveLoad(t);
|
|
15722
15744
|
} catch {
|
|
15723
|
-
r ===
|
|
15745
|
+
r === Nn && X.value === e && Y.failLoad();
|
|
15724
15746
|
} finally {
|
|
15725
|
-
r ===
|
|
15747
|
+
r === Nn && X.value === e && Y.finishLoad();
|
|
15726
15748
|
}
|
|
15727
15749
|
}
|
|
15728
|
-
async function
|
|
15729
|
-
|
|
15750
|
+
async function wo(e, t, n) {
|
|
15751
|
+
uo(e) && (t.key === "create-child" ? ho(e, n.id == null ? void 0 : String(n.id)) : t.key === "edit" ? await Co(e, n) : t.key === "delete" && await Eo(e, n));
|
|
15730
15752
|
}
|
|
15731
|
-
async function
|
|
15732
|
-
let e =
|
|
15733
|
-
if (!e || !
|
|
15734
|
-
if (!
|
|
15735
|
-
|
|
15753
|
+
async function To() {
|
|
15754
|
+
let e = X.value, t = Y.draft.value;
|
|
15755
|
+
if (!e || !uo(e) || !t || Y.saving.value) return;
|
|
15756
|
+
if (!Z.value) {
|
|
15757
|
+
Mn.value += 1;
|
|
15736
15758
|
return;
|
|
15737
15759
|
}
|
|
15738
|
-
if (!
|
|
15760
|
+
if (!Ho(t, Vo(e.context.runtime.snapshot()?.uiDescriptor, e.descriptor.management?.editorSurface), !0, Vo(Ne(e.context.runtime)?.uiDescriptor, e.descriptor.management?.editorSurface))) return;
|
|
15739
15761
|
let n = Y.mode.value === "create";
|
|
15740
15762
|
if (e.context.can(n ? "create" : "update") === !0) {
|
|
15741
15763
|
Be(), Y.saving.value = !0;
|
|
15742
15764
|
try {
|
|
15743
|
-
let r = Tp(t,
|
|
15765
|
+
let r = Tp(t, Zn.value.values(), e.context.runtime.snapshot()?.capabilities), i = r.id == null ? void 0 : String(r.id), o = !n && i ? await e.context.crud.update(i, r) : await e.context.crud.insert(r), s = o.record.id == null ? void 0 : String(o.record.id), c = o.record, l;
|
|
15744
15766
|
if (s) try {
|
|
15745
15767
|
c = await e.context.crud.view(s);
|
|
15746
15768
|
} catch (e) {
|
|
15747
15769
|
l = e;
|
|
15748
15770
|
}
|
|
15749
|
-
s && (e.context.invalidateRecordActions?.([s]), e.context.recordActions(s).catch(() => void 0)), Y.applySaved(c),
|
|
15771
|
+
s && (e.context.invalidateRecordActions?.([s]), e.context.recordActions(s).catch(() => void 0)), Y.applySaved(c), Fn.value += 1, await Bs(o, a.t("platform.screen.DynamicModuleWorkspaceDetailView.saved-successfully", "保存成功")), Oo("background"), l && ze(l, {
|
|
15750
15772
|
source: "navigator-management",
|
|
15751
15773
|
phase: "load",
|
|
15752
15774
|
language: a
|
|
@@ -15762,9 +15784,9 @@ function mg(e, n, r) {
|
|
|
15762
15784
|
}
|
|
15763
15785
|
}
|
|
15764
15786
|
}
|
|
15765
|
-
async function
|
|
15787
|
+
async function Eo(e, t) {
|
|
15766
15788
|
let n = t.id == null ? void 0 : String(t.id), r = typeof t.version == "number" ? t.version : void 0;
|
|
15767
|
-
if (
|
|
15789
|
+
if (uo(e) && n && r !== void 0 && e.context.can("delete") === !0) try {
|
|
15768
15790
|
if (!await i({
|
|
15769
15791
|
presentation: () => ({
|
|
15770
15792
|
title: a.t("platform.screen.ManagedDetailRelationSurface.delete-value", "删除{value1}", { value1: e.descriptor.title }),
|
|
@@ -15776,7 +15798,7 @@ function mg(e, n, r) {
|
|
|
15776
15798
|
}, a)) return;
|
|
15777
15799
|
Be();
|
|
15778
15800
|
let t = await e.context.crud.delete(n, { version: r });
|
|
15779
|
-
e.context.invalidateRecordActions?.([n]),
|
|
15801
|
+
e.context.invalidateRecordActions?.([n]), Gt.value[e.descriptor.key]?.id === n && Wa(e.descriptor.key, { id: n }), Fn.value += 1, await Bs(t, a.t("platform.screen.DynamicModuleWorkspaceDetailView.deleted-successfully", "删除成功"));
|
|
15780
15802
|
} catch (e) {
|
|
15781
15803
|
ze(e, {
|
|
15782
15804
|
source: "navigator-management",
|
|
@@ -15785,65 +15807,65 @@ function mg(e, n, r) {
|
|
|
15785
15807
|
});
|
|
15786
15808
|
}
|
|
15787
15809
|
}
|
|
15788
|
-
function
|
|
15789
|
-
|
|
15810
|
+
function Do() {
|
|
15811
|
+
Oo("background"), me(), ke.value = !1, je.value = !1, we.value = !1, P.value = "view", M.value = void 0, N.value = void 0, D.value = void 0;
|
|
15790
15812
|
}
|
|
15791
|
-
function
|
|
15792
|
-
e === "user" && Be(),
|
|
15813
|
+
function Oo(e = "user") {
|
|
15814
|
+
e === "user" && Be(), Nn += 1, An.value = !1, Z.value = !0, Y.close(), X.value = void 0;
|
|
15793
15815
|
}
|
|
15794
|
-
function
|
|
15816
|
+
function ko(e, t = "user") {
|
|
15795
15817
|
let n = e;
|
|
15796
15818
|
(D.value?.id == null || String(D.value.id) !== String(n.id)) && (t === "user" && (Re.value += 1), D.value = n, xe(D.value, "view"));
|
|
15797
15819
|
}
|
|
15798
|
-
function
|
|
15820
|
+
function Ao() {
|
|
15799
15821
|
Te.value || (D.value || M.value) && (Re.value += 1, me(), D.value = void 0, pe.close(), M.value = void 0, N.value = void 0);
|
|
15800
15822
|
}
|
|
15801
|
-
function
|
|
15823
|
+
function jo() {
|
|
15802
15824
|
D.value && P.value === "view" && !Te.value && xe(D.value, "view");
|
|
15803
15825
|
}
|
|
15804
|
-
function
|
|
15805
|
-
if (
|
|
15826
|
+
function Mo(e) {
|
|
15827
|
+
if (K(e), D.value || P.value !== "view") return;
|
|
15806
15828
|
let t = e.at(0);
|
|
15807
|
-
t &&
|
|
15829
|
+
t && ko(t, "background");
|
|
15808
15830
|
}
|
|
15809
|
-
let
|
|
15831
|
+
let No = fh({
|
|
15810
15832
|
language: a,
|
|
15811
15833
|
get editingRecord() {
|
|
15812
15834
|
return N.value;
|
|
15813
15835
|
},
|
|
15814
15836
|
get referencePickerConfigs() {
|
|
15815
|
-
return
|
|
15837
|
+
return Ta.value;
|
|
15816
15838
|
}
|
|
15817
|
-
}, () => De.value),
|
|
15818
|
-
function Po(e, t) {
|
|
15819
|
-
P.value !== "view" && Mo.observe(e, t);
|
|
15820
|
-
}
|
|
15839
|
+
}, () => De.value), Po = (e) => No.current(e);
|
|
15821
15840
|
function Fo(e, t) {
|
|
15822
|
-
|
|
15841
|
+
P.value !== "view" && No.observe(e, t);
|
|
15842
|
+
}
|
|
15843
|
+
function Io(e, t) {
|
|
15844
|
+
Lo([{
|
|
15823
15845
|
fieldName: e,
|
|
15824
15846
|
value: t
|
|
15825
15847
|
}], "user");
|
|
15826
15848
|
}
|
|
15827
|
-
function
|
|
15849
|
+
function Lo(e, t = "user", n) {
|
|
15828
15850
|
if (Te.value || tt.value || rt.value || !N.value || e.length === 0) return;
|
|
15829
|
-
let r = /* @__PURE__ */ new Set(), i =
|
|
15830
|
-
for (let { fieldName: t, value: n } of e) a[t] !== n && ye(t,
|
|
15831
|
-
let o =
|
|
15832
|
-
Cp(o, n), t === "user" && (Re.value += 1),
|
|
15833
|
-
}
|
|
15834
|
-
function Lo(e, t, n = "user", r = [], i) {
|
|
15835
|
-
Te.value || tt.value || rt.value || (Io(wp(e, t, r), n, i), Po(e, [t]));
|
|
15851
|
+
let r = /* @__PURE__ */ new Set(), i = zo(A.runtime.snapshot()?.uiDescriptor), a = N.value;
|
|
15852
|
+
for (let { fieldName: t, value: n } of e) a[t] !== n && ye(t, Rt.value).forEach((e) => r.add(e)), a = gt(a, t, n, Rt.value);
|
|
15853
|
+
let o = Uo(a, zp(N.value, a, e.map(({ fieldName: e }) => e)), i);
|
|
15854
|
+
Cp(o, n), t === "user" && (Re.value += 1), No.clear([...r]), N.value = o;
|
|
15836
15855
|
}
|
|
15837
|
-
function Ro(e, t) {
|
|
15838
|
-
|
|
15856
|
+
function Ro(e, t, n = "user", r = [], i) {
|
|
15857
|
+
Te.value || tt.value || rt.value || (Lo(wp(e, t, r), n, i), Fo(e, [t]));
|
|
15839
15858
|
}
|
|
15840
15859
|
function zo(e, t) {
|
|
15841
|
-
return
|
|
15860
|
+
return Bo(e, t)?.formComputeRules ?? [];
|
|
15842
15861
|
}
|
|
15843
15862
|
function Bo(e, t) {
|
|
15844
|
-
return
|
|
15863
|
+
return t ? e?.editorSurfaces?.find((e) => e.key === t)?.editor : e?.page?.detail.editor ?? e?.defaultEditor;
|
|
15864
|
+
}
|
|
15865
|
+
function Vo(e, t) {
|
|
15866
|
+
return Bo(e, t)?.formValidationRules ?? [];
|
|
15845
15867
|
}
|
|
15846
|
-
function
|
|
15868
|
+
function Ho(e, t, n = !0, r = t) {
|
|
15847
15869
|
let i = new eg(t).validate(e, r);
|
|
15848
15870
|
return !i || (n && Zt(i.message, {
|
|
15849
15871
|
source: "module-formula-validation",
|
|
@@ -15851,85 +15873,85 @@ function mg(e, n, r) {
|
|
|
15851
15873
|
language: a
|
|
15852
15874
|
}), !1);
|
|
15853
15875
|
}
|
|
15854
|
-
function
|
|
15876
|
+
function Uo(e, t, n) {
|
|
15855
15877
|
let r = {
|
|
15856
15878
|
...e,
|
|
15857
15879
|
...Object.fromEntries(Object.entries(F.value).filter(([t, n]) => JSON.stringify(e[t]) === n.snapshot).map(([e, t]) => [e, t.rows]))
|
|
15858
15880
|
};
|
|
15859
15881
|
return new Np(n).applyAfterChange(e, t, Zh(r, A.runtime.snapshot()?.uiDescriptor, Fe.value));
|
|
15860
15882
|
}
|
|
15861
|
-
async function
|
|
15862
|
-
if (!
|
|
15863
|
-
let t =
|
|
15864
|
-
if (await (C ??
|
|
15865
|
-
let n =
|
|
15866
|
-
...
|
|
15883
|
+
async function Wo(e) {
|
|
15884
|
+
if (!qo().ready) return !1;
|
|
15885
|
+
let t = Jo();
|
|
15886
|
+
if (await (C ?? qr()), !qo().ready || t !== Jo() || e && String(M.value?.id) !== e) return !1;
|
|
15887
|
+
let n = Go({
|
|
15888
|
+
...da.value,
|
|
15867
15889
|
...e ? { parentId: e } : {}
|
|
15868
15890
|
});
|
|
15869
15891
|
return n && (Re.value += 1), n;
|
|
15870
15892
|
}
|
|
15871
|
-
function
|
|
15872
|
-
return me(), pe.beginCreate(e, { cancelDestination:
|
|
15873
|
-
}
|
|
15874
|
-
function Go() {
|
|
15875
|
-
return Uo();
|
|
15893
|
+
function Go(e) {
|
|
15894
|
+
return me(), pe.beginCreate(e, { cancelDestination: Ir.value ? "restore-view" : "close" }), N.value &&= new Np(zo(A.runtime.snapshot()?.uiDescriptor)).applyOnCreate(N.value, Zh(N.value, A.runtime.snapshot()?.uiDescriptor, Fe.value)), P.value === "create" && !!N.value;
|
|
15876
15895
|
}
|
|
15877
15896
|
function Ko() {
|
|
15897
|
+
return Wo();
|
|
15898
|
+
}
|
|
15899
|
+
function qo() {
|
|
15878
15900
|
return ph({
|
|
15879
15901
|
tenantReady: oe.value,
|
|
15880
|
-
pageReady:
|
|
15902
|
+
pageReady: ta.value,
|
|
15881
15903
|
permitted: A.can("create") === !0,
|
|
15882
|
-
editing:
|
|
15883
|
-
busy:
|
|
15884
|
-
scopeReady:
|
|
15904
|
+
editing: _r.value,
|
|
15905
|
+
busy: gr.value,
|
|
15906
|
+
scopeReady: V.value ? an.value : ua.value
|
|
15885
15907
|
}, a);
|
|
15886
15908
|
}
|
|
15887
|
-
function
|
|
15909
|
+
function Jo() {
|
|
15888
15910
|
return JSON.stringify({
|
|
15889
15911
|
contextRevision: Le.value,
|
|
15890
15912
|
tenantId: m.value,
|
|
15891
15913
|
selection: v.value,
|
|
15892
|
-
navigators:
|
|
15893
|
-
treeScopeId:
|
|
15914
|
+
navigators: Ut.value.map((e) => [e.descriptor.key, Gt.value[e.descriptor.key]?.id ?? null]),
|
|
15915
|
+
treeScopeId: H.value?.id ?? null
|
|
15894
15916
|
});
|
|
15895
15917
|
}
|
|
15896
|
-
async function
|
|
15897
|
-
let t =
|
|
15918
|
+
async function Yo(e = {}) {
|
|
15919
|
+
let t = qo();
|
|
15898
15920
|
if (!t.ready) throw Error(t.message);
|
|
15899
|
-
let n =
|
|
15921
|
+
let n = Jo(), r = e.asChildOfSelectedRecord ? M.value?.id == null ? void 0 : String(M.value.id) : void 0, i = () => !e.asChildOfSelectedRecord || Ir.value && !Oi.value && r !== void 0 && String(M.value?.id) === r;
|
|
15900
15922
|
if (!i()) throw Error("Child record creation requires the selected tree record");
|
|
15901
|
-
await (C ??
|
|
15923
|
+
await (C ?? qr());
|
|
15902
15924
|
let a = {
|
|
15903
|
-
...
|
|
15925
|
+
...da.value,
|
|
15904
15926
|
...r ? { parentId: r } : {}
|
|
15905
15927
|
};
|
|
15906
15928
|
return () => {
|
|
15907
|
-
if (!
|
|
15908
|
-
return
|
|
15929
|
+
if (!qo().ready || n !== Jo() || !i() || !Go(a)) throw Error("Record creation is unavailable");
|
|
15930
|
+
return hs();
|
|
15909
15931
|
};
|
|
15910
15932
|
}
|
|
15911
|
-
function
|
|
15912
|
-
return
|
|
15933
|
+
function Xo() {
|
|
15934
|
+
return Rr.value.filter((e) => mo(e).ready).map((e) => ({
|
|
15913
15935
|
key: e.descriptor.key,
|
|
15914
15936
|
title: e.descriptor.title,
|
|
15915
15937
|
moduleAlias: e.context.moduleAlias
|
|
15916
15938
|
}));
|
|
15917
15939
|
}
|
|
15918
|
-
async function
|
|
15919
|
-
let t =
|
|
15920
|
-
if (!t || !
|
|
15921
|
-
let n =
|
|
15940
|
+
async function Zo(e) {
|
|
15941
|
+
let t = Rr.value.find((t) => t.descriptor.key === e);
|
|
15942
|
+
if (!t || !mo(t).ready) throw Error(a.t("platform.screen.useModulePageSession.creation-is-unavailable-in-this-navigator-or-an-unsaved-draft", "当前导航区不支持新建,或已有未保存草稿"));
|
|
15943
|
+
let n = es(e);
|
|
15922
15944
|
return () => {
|
|
15923
|
-
if (!
|
|
15924
|
-
return
|
|
15945
|
+
if (!Rr.value.includes(t) || n !== es(e) || !mo(t).ready) throw Error(a.t("platform.screen.useModulePageSession.the-navigation-scope-or-editing-state-has-changed-prepare-creation", "导航范围或编辑状态已变化,请重新准备新建"));
|
|
15946
|
+
return ho(t, void 0, "assistant"), {
|
|
15925
15947
|
scopeKey: e,
|
|
15926
15948
|
moduleAlias: t.context.moduleAlias,
|
|
15927
15949
|
saved: !1
|
|
15928
15950
|
};
|
|
15929
15951
|
};
|
|
15930
15952
|
}
|
|
15931
|
-
let
|
|
15932
|
-
let e =
|
|
15953
|
+
let Qo = z(() => {
|
|
15954
|
+
let e = X.value;
|
|
15933
15955
|
if (!e || !Y.open.value) return;
|
|
15934
15956
|
let t = {
|
|
15935
15957
|
language: a,
|
|
@@ -15943,16 +15965,16 @@ function mg(e, n, r) {
|
|
|
15943
15965
|
return Y.record.value;
|
|
15944
15966
|
},
|
|
15945
15967
|
get formFields() {
|
|
15946
|
-
let e = Sm(Y.mode.value, Y.draft.value ?? {},
|
|
15947
|
-
return new Map([...
|
|
15968
|
+
let e = Sm(Y.mode.value, Y.draft.value ?? {}, Zn.value, Y.formSessionKey.value);
|
|
15969
|
+
return new Map([...Zn.value].filter(([t]) => t !== "enabled" && er.value.find((e) => e.fieldName === t)?.visible?.(e) !== !1));
|
|
15948
15970
|
},
|
|
15949
15971
|
get referencePickerConfigs() {
|
|
15950
|
-
return
|
|
15972
|
+
return tr.value;
|
|
15951
15973
|
},
|
|
15952
15974
|
contextRevision: () => String(Le.value),
|
|
15953
|
-
updateDraftFields:
|
|
15975
|
+
updateDraftFields: So,
|
|
15954
15976
|
updateDraftReference(e, t, n, r, i) {
|
|
15955
|
-
|
|
15977
|
+
So(wp(e, t, r), n, i);
|
|
15956
15978
|
}
|
|
15957
15979
|
};
|
|
15958
15980
|
return {
|
|
@@ -15960,14 +15982,14 @@ function mg(e, n, r) {
|
|
|
15960
15982
|
moduleAlias: e.context.moduleAlias,
|
|
15961
15983
|
loading: Y.loading.value,
|
|
15962
15984
|
loadFailed: Y.loadFailed.value,
|
|
15963
|
-
busy:
|
|
15985
|
+
busy: gr.value || Y.loadFailed.value || Y.mode.value === "view" || !Y.draft.value,
|
|
15964
15986
|
title: e.descriptor.title,
|
|
15965
15987
|
dirty: Y.isDirty.value,
|
|
15966
15988
|
form: t
|
|
15967
15989
|
};
|
|
15968
15990
|
});
|
|
15969
15991
|
Q([
|
|
15970
|
-
() =>
|
|
15992
|
+
() => X.value?.descriptor.key,
|
|
15971
15993
|
Y.open,
|
|
15972
15994
|
Y.mode,
|
|
15973
15995
|
Y.loading,
|
|
@@ -15980,57 +16002,57 @@ function mg(e, n, r) {
|
|
|
15980
16002
|
deep: !0,
|
|
15981
16003
|
flush: "sync"
|
|
15982
16004
|
});
|
|
15983
|
-
function
|
|
15984
|
-
return
|
|
16005
|
+
function $o() {
|
|
16006
|
+
return _r.value || gr.value || vr.value ? [] : Rr.value.filter((e) => !$r(e.descriptor.key) && co(e));
|
|
15985
16007
|
}
|
|
15986
|
-
function
|
|
16008
|
+
function es(e) {
|
|
15987
16009
|
return JSON.stringify({
|
|
15988
16010
|
tenantId: m.value,
|
|
15989
|
-
selections:
|
|
15990
|
-
queryValues:
|
|
16011
|
+
selections: Ut.value.map((e) => [e.descriptor.key, Gt.value[e.descriptor.key]?.id ?? null]),
|
|
16012
|
+
queryValues: oo(e) ?? null
|
|
15991
16013
|
});
|
|
15992
16014
|
}
|
|
15993
|
-
function
|
|
15994
|
-
return
|
|
16015
|
+
function ts(e, t, n) {
|
|
16016
|
+
return !$o().find((t) => t.descriptor.key === e) || t.id == null || es(e) !== n || String(Gt.value[e]?.id ?? "") === String(t.id) ? !1 : (Wa(e, t, "assistant"), String(Gt.value[e]?.id ?? "") === String(t.id));
|
|
15995
16017
|
}
|
|
15996
|
-
async function
|
|
15997
|
-
|
|
16018
|
+
async function ns(e) {
|
|
16019
|
+
rs(e), await hn();
|
|
15998
16020
|
for (let t = 0; t < 10; t += 1) {
|
|
15999
|
-
|
|
16021
|
+
rs(e);
|
|
16000
16022
|
let t = Le.value, n = s.revision(), r = Ve.value, i = Ue.value;
|
|
16001
16023
|
for (let t of [...Ge.values()]) await t.settle(e), await hn();
|
|
16002
|
-
if (await r?.settle(e), await hn(), await i?.settle(e), await hn(), await be(e), await hn(), await s.settle(), await hn(),
|
|
16024
|
+
if (await r?.settle(e), await hn(), await i?.settle(e), await hn(), await be(e), await hn(), await s.settle(), await hn(), rs(e), r !== Ve.value || i !== Ue.value || t !== Le.value || n !== s.revision()) continue;
|
|
16003
16025
|
let a = r?.snapshot().status;
|
|
16004
|
-
if (!ke.value && (!
|
|
16026
|
+
if (!ke.value && (!ua.value || a !== "waiting" && a !== "loading")) return;
|
|
16005
16027
|
}
|
|
16006
16028
|
throw Error("Assistant page state did not settle on a stable page session");
|
|
16007
16029
|
}
|
|
16008
|
-
function
|
|
16030
|
+
function rs(e) {
|
|
16009
16031
|
if (e.aborted) throw new DOMException("Assistant invocation was cancelled", "AbortError");
|
|
16010
16032
|
}
|
|
16011
|
-
function
|
|
16033
|
+
function is() {
|
|
16012
16034
|
let e = M.value?.id == null ? void 0 : String(M.value.id);
|
|
16013
|
-
e &&
|
|
16035
|
+
e && Wo(e);
|
|
16014
16036
|
}
|
|
16015
|
-
async function
|
|
16037
|
+
async function as(t, n) {
|
|
16016
16038
|
if (!t || A.can(n) !== !0) return !1;
|
|
16017
|
-
let r =
|
|
16018
|
-
e.recordOnly && (
|
|
16039
|
+
let r = wt, i = Le.value, o = Re.value;
|
|
16040
|
+
e.recordOnly && (Ct.value = !0);
|
|
16019
16041
|
try {
|
|
16020
16042
|
let a = await A.recordActions(t);
|
|
16021
|
-
return i === Le.value && o === Re.value && A.can(n) === !0 && (!e.recordOnly || r ===
|
|
16043
|
+
return i === Le.value && o === Re.value && A.can(n) === !0 && (!e.recordOnly || r === wt && we.value) && a.actions.some((e) => e.actionCode === n && e.available);
|
|
16022
16044
|
} catch (e) {
|
|
16023
|
-
return i === Le.value && r ===
|
|
16045
|
+
return i === Le.value && r === wt && ze(e, {
|
|
16024
16046
|
source: "module-record-action",
|
|
16025
16047
|
phase: "authorization",
|
|
16026
16048
|
language: a
|
|
16027
16049
|
}), !1;
|
|
16028
16050
|
} finally {
|
|
16029
|
-
e.recordOnly && r ===
|
|
16051
|
+
e.recordOnly && r === wt && (Ct.value = !1);
|
|
16030
16052
|
}
|
|
16031
16053
|
}
|
|
16032
|
-
async function
|
|
16033
|
-
if (
|
|
16054
|
+
async function os(e, t = "close") {
|
|
16055
|
+
if (cs() && A.can("update") === !0 && await as(String(e.id ?? ""), "update") && cs()) {
|
|
16034
16056
|
if (M.value?.id === e.id && pe.beginEdit({ cancelDestination: t })) {
|
|
16035
16057
|
Re.value += 1;
|
|
16036
16058
|
return;
|
|
@@ -16038,38 +16060,38 @@ function mg(e, n, r) {
|
|
|
16038
16060
|
await _e(e, "edit", { cancelDestination: t }), P.value === "edit" && (Re.value += 1);
|
|
16039
16061
|
}
|
|
16040
16062
|
}
|
|
16041
|
-
function os() {
|
|
16042
|
-
return !gr.value && !hr.value && !_r.value;
|
|
16043
|
-
}
|
|
16044
16063
|
function ss() {
|
|
16045
|
-
return
|
|
16064
|
+
return !_r.value && !gr.value && !vr.value;
|
|
16046
16065
|
}
|
|
16047
16066
|
function cs() {
|
|
16048
|
-
return
|
|
16067
|
+
return ta.value && P.value === "view" && ss();
|
|
16049
16068
|
}
|
|
16050
|
-
function ls(
|
|
16051
|
-
|
|
16052
|
-
return ds(e, "view");
|
|
16069
|
+
function ls() {
|
|
16070
|
+
return cs() && !ke.value && !je.value;
|
|
16053
16071
|
}
|
|
16054
16072
|
function us(e) {
|
|
16055
|
-
|
|
16073
|
+
if (_i.value?.recordView) throw Error("Standard record viewing is unavailable");
|
|
16074
|
+
return fs(e, "view");
|
|
16075
|
+
}
|
|
16076
|
+
function ds(e) {
|
|
16077
|
+
return fs(e, "edit");
|
|
16056
16078
|
}
|
|
16057
|
-
async function
|
|
16079
|
+
async function fs(e, t) {
|
|
16058
16080
|
let n = t === "view" ? "view" : "update";
|
|
16059
|
-
if (!
|
|
16081
|
+
if (!ls()) throw Error("A form draft is already active");
|
|
16060
16082
|
let r = Le.value, i = e.trim(), o = Ve.value?.snapshot();
|
|
16061
16083
|
if (o?.mode === "recycleBin") throw Error("Record editing is unavailable in recycle bin mode");
|
|
16062
16084
|
let s = new Set(Eh(M.value?.id, o));
|
|
16063
16085
|
if (!i || !s.has(i)) throw Error(`Record is not available on the current page: ${e}`);
|
|
16064
16086
|
let c = M.value;
|
|
16065
|
-
if (A.can(n) !== !0 || !await
|
|
16087
|
+
if (A.can(n) !== !0 || !await ps(i, n)) throw Error("Record action is unavailable");
|
|
16066
16088
|
let l = c?.id != null && String(c.id) === i ? c : await A.crud.view(i);
|
|
16067
16089
|
return () => {
|
|
16068
|
-
if (r !== Le.value || !
|
|
16069
|
-
return ge(l, t, { cancelDestination: Oh(we.value, c?.id, i) }),
|
|
16090
|
+
if (r !== Le.value || !ls() || A.can(n) !== !0 || t === "view" && _i.value?.recordView || !Eh(M.value?.id, Ve.value?.snapshot()).includes(i)) throw Error(a.t("platform.screen.useModulePageSession.the-editing-state-or-scope-has-changed-prepare-the-action", "编辑状态或范围已变化,请重新准备操作"));
|
|
16091
|
+
return ge(l, t, { cancelDestination: Oh(we.value, c?.id, i) }), hs();
|
|
16070
16092
|
};
|
|
16071
16093
|
}
|
|
16072
|
-
async function
|
|
16094
|
+
async function ps(e, t) {
|
|
16073
16095
|
try {
|
|
16074
16096
|
return Dh(await A.recordActions(e), t);
|
|
16075
16097
|
} catch (e) {
|
|
@@ -16080,10 +16102,10 @@ function mg(e, n, r) {
|
|
|
16080
16102
|
}), !1;
|
|
16081
16103
|
}
|
|
16082
16104
|
}
|
|
16083
|
-
function ps() {
|
|
16084
|
-
return ea.value && we.value && P.value === "view" && M.value?.id != null && !ke.value && !je.value && !xa.value && !gi.value?.recordView;
|
|
16085
|
-
}
|
|
16086
16105
|
function ms() {
|
|
16106
|
+
return ta.value && we.value && P.value === "view" && M.value?.id != null && !ke.value && !je.value && !Sa.value && !_i.value?.recordView;
|
|
16107
|
+
}
|
|
16108
|
+
function hs() {
|
|
16087
16109
|
return {
|
|
16088
16110
|
editorMode: P.value,
|
|
16089
16111
|
recordId: N.value?.id == null ? void 0 : String(N.value.id),
|
|
@@ -16091,56 +16113,58 @@ function mg(e, n, r) {
|
|
|
16091
16113
|
dirty: Ee.value
|
|
16092
16114
|
};
|
|
16093
16115
|
}
|
|
16094
|
-
async function
|
|
16116
|
+
async function gs(t = !0) {
|
|
16095
16117
|
let n = N.value;
|
|
16096
16118
|
if (n) {
|
|
16097
|
-
if (Fe.value.size > 0 || P.value === "edit" &&
|
|
16098
|
-
if (!pt.value || !
|
|
16099
|
-
t && (
|
|
16119
|
+
if (Fe.value.size > 0 || P.value === "edit" && br.value.some((e) => e.embeddedField && e.editing?.saveMode === "AGGREGATE_DRAFT" && !Array.isArray(n[e.embeddedField]))) throw new Je(a.t("platform.screen.useModulePageSession.some-details-have-not-loaded-reopen-the-record-before-editing", "明细未完整加载,无法安全保存;请重新打开记录后再修改"));
|
|
16120
|
+
if (mt.value || !pt.value || !ht.value) {
|
|
16121
|
+
t && (yt.value += 1);
|
|
16100
16122
|
return;
|
|
16101
16123
|
}
|
|
16102
|
-
if (
|
|
16124
|
+
if (Ho(n, Vo(A.runtime.snapshot()?.uiDescriptor), t, Vo(Ne(A.runtime)?.uiDescriptor)) && !(P.value === "create" ? A.can("create") !== !0 : A.can("update") !== !0)) {
|
|
16103
16125
|
if (e.recordOnly && P.value === "edit") {
|
|
16104
16126
|
let e = n.id == null ? void 0 : String(n.id);
|
|
16105
|
-
if (!e || !await
|
|
16127
|
+
if (!e || !await as(e, "update")) return;
|
|
16106
16128
|
}
|
|
16107
16129
|
if (wh({
|
|
16108
16130
|
hasRecord: !0,
|
|
16109
16131
|
saving: st.value,
|
|
16110
16132
|
loading: ke.value,
|
|
16111
16133
|
loadFailed: je.value
|
|
16112
|
-
})) return Tp(n,
|
|
16134
|
+
})) return Tp(n, Rt.value.values(), A.runtime.snapshot()?.capabilities);
|
|
16113
16135
|
}
|
|
16114
16136
|
}
|
|
16115
16137
|
}
|
|
16116
|
-
let
|
|
16138
|
+
let _s = z(() => !!O.crud.saveReceipt && !w.value), vs = z(() => JSON.stringify([
|
|
16117
16139
|
l?.value?.userId,
|
|
16118
16140
|
l?.value?.tenantId,
|
|
16119
16141
|
m.value,
|
|
16120
16142
|
A.moduleAlias,
|
|
16121
16143
|
e.descriptor.menuId,
|
|
16144
|
+
e.recordOnly?.recordId,
|
|
16122
16145
|
ee.value,
|
|
16123
16146
|
v.value,
|
|
16124
|
-
|
|
16147
|
+
V.value?.resource
|
|
16125
16148
|
]));
|
|
16126
|
-
function
|
|
16149
|
+
function ys(t) {
|
|
16127
16150
|
return {
|
|
16128
16151
|
kind: "record-save",
|
|
16129
16152
|
moduleAlias: A.moduleAlias,
|
|
16130
16153
|
requestId: t,
|
|
16154
|
+
...e.recordOnly ? { recordId: e.recordOnly.recordId } : {},
|
|
16131
16155
|
...m.value ? { tenantId: m.value } : {},
|
|
16132
16156
|
...e.descriptor.menuId ? { menuId: e.descriptor.menuId } : {},
|
|
16133
16157
|
...ee.value ? { pageContext: JSON.parse(ee.value) } : {},
|
|
16134
16158
|
...v.value ? { pageSelection: { ...v.value } } : {}
|
|
16135
16159
|
};
|
|
16136
16160
|
}
|
|
16137
|
-
function
|
|
16138
|
-
return l?.value?.userId ? dh(
|
|
16161
|
+
function bs() {
|
|
16162
|
+
return l?.value?.userId ? dh(vs.value, window.sessionStorage, a) : void 0;
|
|
16139
16163
|
}
|
|
16140
|
-
Q(
|
|
16164
|
+
Q(vs, () => {
|
|
16141
16165
|
tt.value = void 0, at = void 0, ot = !1, nt.value = void 0;
|
|
16142
16166
|
try {
|
|
16143
|
-
tt.value =
|
|
16167
|
+
tt.value = bs()?.restore();
|
|
16144
16168
|
} catch {
|
|
16145
16169
|
nt.value = "restore";
|
|
16146
16170
|
}
|
|
@@ -16148,62 +16172,62 @@ function mg(e, n, r) {
|
|
|
16148
16172
|
immediate: !0,
|
|
16149
16173
|
flush: "sync"
|
|
16150
16174
|
});
|
|
16151
|
-
let
|
|
16152
|
-
function
|
|
16175
|
+
let xs = z(() => !!tt.value || !!rt.value);
|
|
16176
|
+
function Ss(e) {
|
|
16153
16177
|
try {
|
|
16154
|
-
|
|
16178
|
+
bs()?.clear(e), tt.value?.requestId === e && (tt.value = void 0, at = void 0, ot = !1), nt.value = void 0;
|
|
16155
16179
|
} catch {
|
|
16156
16180
|
nt.value = "clear";
|
|
16157
16181
|
}
|
|
16158
16182
|
}
|
|
16159
|
-
async function
|
|
16183
|
+
async function Cs(t, r) {
|
|
16160
16184
|
if (!r()) return !1;
|
|
16161
16185
|
try {
|
|
16162
16186
|
let i = await A.crud.view(t);
|
|
16163
|
-
return r() ? (ge(i, "view"),
|
|
16187
|
+
return r() ? (ge(i, "view"), Ir.value && (D.value = i), e.recordOnly && n("record-only-change", {
|
|
16164
16188
|
type: "saved",
|
|
16165
16189
|
record: i
|
|
16166
|
-
}),
|
|
16190
|
+
}), ht.value = !0, !0) : !1;
|
|
16167
16191
|
} catch (e) {
|
|
16168
|
-
return r() ? (pe.beginLoad({ id: t }, "view"), pe.failLoad(), pe.finishLoad(),
|
|
16192
|
+
return r() ? (pe.beginLoad({ id: t }, "view"), pe.failLoad(), pe.finishLoad(), Ir.value && (D.value = { id: t }), zs(e, "module-action"), !1) : !1;
|
|
16169
16193
|
}
|
|
16170
16194
|
}
|
|
16171
|
-
function
|
|
16195
|
+
function ws(e, t) {
|
|
16172
16196
|
return {
|
|
16173
16197
|
title: a.t("platform.screen.DynamicModuleWorkspaceDetailView.saved-successfully", "保存成功"),
|
|
16174
|
-
lines: [a.t("platform.screen.useModulePageSession.value-saved", "{value1}已保存", { value1:
|
|
16198
|
+
lines: [a.t("platform.screen.useModulePageSession.value-saved", "{value1}已保存", { value1: ii.value }), ...t ? [] : [a.t("platform.screen.useModulePageSession.submission-is-confirmed-but-the-current-details-have-not-been", "提交已确认,当前详情尚未核实;请重新读取详情,不要重复保存。")]],
|
|
16175
16199
|
details: {
|
|
16176
16200
|
title: a.t("platform.screen.useModulePageSession.save-details", "保存详情"),
|
|
16177
16201
|
lines: [a.t("platform.screen.useModulePageSession.record-id-value", "记录标识:{value1}", { value1: e })]
|
|
16178
16202
|
}
|
|
16179
16203
|
};
|
|
16180
16204
|
}
|
|
16181
|
-
async function
|
|
16205
|
+
async function Ts(e, t) {
|
|
16182
16206
|
if (Te.value) throw new Je(a.t("platform.screen.useModulePageSession.a-save-result-check-is-already-in-progress", "已有保存核实正在执行"));
|
|
16183
16207
|
Te.value = !0;
|
|
16184
16208
|
try {
|
|
16185
|
-
if (c || t !==
|
|
16186
|
-
if (ot && tt.value?.requestId === e) return
|
|
16209
|
+
if (c || t !== vs.value) throw new Je(a.t("platform.screen.useModulePageSession.the-save-scope-has-changed-return-to-the-original-scope", "保存范围已变化,请返回原范围核实"));
|
|
16210
|
+
if (ot && tt.value?.requestId === e) return Ss(e), {
|
|
16187
16211
|
title: a.t("platform.screen.useModulePageSession.action-not-submitted", "操作未提交"),
|
|
16188
16212
|
lines: [a.t("platform.screen.useModulePageSession.the-previous-save-was-rejected-review-the-draft-before-saving", "原保存已被明确拒绝,可以重新审阅后保存。")]
|
|
16189
16213
|
};
|
|
16190
16214
|
let n = await A.crud.saveReceipt(e);
|
|
16191
|
-
if (c || t !==
|
|
16215
|
+
if (c || t !== vs.value) throw new Je(a.t("platform.screen.useModulePageSession.the-save-scope-has-changed-return-to-the-original-scope", "保存范围已变化,请返回原范围核实"));
|
|
16192
16216
|
if (!n.committed || !n.recordId) return;
|
|
16193
16217
|
let r = tt.value?.requestId === e ? at : void 0;
|
|
16194
|
-
|
|
16195
|
-
let i = r ? await
|
|
16196
|
-
return
|
|
16218
|
+
Ss(e);
|
|
16219
|
+
let i = r ? await Cs(n.recordId, r) : !1;
|
|
16220
|
+
return ac(), ws(n.recordId, i);
|
|
16197
16221
|
} finally {
|
|
16198
16222
|
Te.value = !1;
|
|
16199
16223
|
}
|
|
16200
16224
|
}
|
|
16201
|
-
async function
|
|
16225
|
+
async function Es() {
|
|
16202
16226
|
if (!Te.value) try {
|
|
16203
|
-
rt.value && !tt.value && (tt.value =
|
|
16227
|
+
rt.value && !tt.value && (tt.value = bs()?.restore(), nt.value = void 0);
|
|
16204
16228
|
let e = tt.value;
|
|
16205
16229
|
if (!e) return;
|
|
16206
|
-
let t = await
|
|
16230
|
+
let t = await Ts(e.requestId, vs.value);
|
|
16207
16231
|
Zt(t ? t.lines.join(a.t("platform.list.clause-separator", ";")) : a.t("platform.screen.useModulePageSession.the-previous-save-result-is-still-unknown-check-again-later", "原保存结果仍未确定,请稍后再核实,不要重复提交"), t ? { tone: "success" } : {});
|
|
16208
16232
|
} catch (e) {
|
|
16209
16233
|
ze(e, {
|
|
@@ -16213,55 +16237,55 @@ function mg(e, n, r) {
|
|
|
16213
16237
|
});
|
|
16214
16238
|
}
|
|
16215
16239
|
}
|
|
16216
|
-
async function
|
|
16217
|
-
if (
|
|
16240
|
+
async function Ds(e = "save") {
|
|
16241
|
+
if (bt.value = void 0, xs.value) return Es();
|
|
16218
16242
|
try {
|
|
16219
|
-
let t = await
|
|
16220
|
-
t && await
|
|
16243
|
+
let t = await gs();
|
|
16244
|
+
t && await Os(t, P.value, e);
|
|
16221
16245
|
} catch (e) {
|
|
16222
|
-
|
|
16246
|
+
bt.value || ze(e, {
|
|
16223
16247
|
source: "module-action",
|
|
16224
16248
|
phase: "action",
|
|
16225
16249
|
language: a
|
|
16226
16250
|
});
|
|
16227
16251
|
}
|
|
16228
16252
|
}
|
|
16229
|
-
async function
|
|
16253
|
+
async function Os(e, t, n, r = _s.value ? ir() : void 0) {
|
|
16230
16254
|
if (st.value) throw new Ke(a.t("platform.screen.useModulePageSession.a-previous-save-is-unverified-check-its-result-first", "已有保存尚未核实,请先查询结果"));
|
|
16231
|
-
|
|
16232
|
-
let i =
|
|
16255
|
+
bt.value = void 0;
|
|
16256
|
+
let i = vs.value, o = JSON.stringify(e), s = De.value;
|
|
16233
16257
|
Re.value += 1;
|
|
16234
|
-
let l = Re.value, u = () => !c && i ===
|
|
16258
|
+
let l = Re.value, u = () => !c && i === vs.value && s === De.value && l === Re.value && t === P.value && !!N.value && o === JSON.stringify(Tp(N.value, Rt.value.values(), A.runtime.snapshot()?.capabilities));
|
|
16235
16259
|
Te.value = !0, $e.value = n;
|
|
16236
16260
|
try {
|
|
16237
16261
|
if (r) {
|
|
16238
|
-
let e =
|
|
16262
|
+
let e = ys(r);
|
|
16239
16263
|
try {
|
|
16240
|
-
|
|
16264
|
+
bs()?.save(e);
|
|
16241
16265
|
} catch {
|
|
16242
16266
|
throw new Ke(a.t("platform.screen.useModulePageSession.the-save-query-reference-could-not-be-retained-nothing-was", "无法保留保存查询引用,本次未提交,请稍后重试"));
|
|
16243
16267
|
}
|
|
16244
16268
|
tt.value = e, at = u, ot = !1;
|
|
16245
16269
|
}
|
|
16246
16270
|
let n = e.id == null ? void 0 : String(e.id), o = await (t === "edit" && n ? A.crud.update(n, e, r ? { requestId: r } : void 0) : A.crud.insert(e, r ? { requestId: r } : void 0)).catch((e) => {
|
|
16247
|
-
throw u() && e instanceof Jt && em(e) && (
|
|
16271
|
+
throw u() && e instanceof Jt && em(e) && (bt.value = e), r && e instanceof Jt && [
|
|
16248
16272
|
400,
|
|
16249
16273
|
401,
|
|
16250
16274
|
403,
|
|
16251
16275
|
404,
|
|
16252
16276
|
409,
|
|
16253
16277
|
422
|
|
16254
|
-
].includes(e.status ?? 0) ? (i ===
|
|
16278
|
+
].includes(e.status ?? 0) ? (i === vs.value && (ot = !0, Ss(r)), new Ke(e.message, { cause: e })) : e;
|
|
16255
16279
|
});
|
|
16256
|
-
if (i !==
|
|
16280
|
+
if (i !== vs.value || c) return {
|
|
16257
16281
|
result: o,
|
|
16258
16282
|
viewRefreshed: !1
|
|
16259
16283
|
};
|
|
16260
16284
|
let s = o.record.id == null ? void 0 : String(o.record.id);
|
|
16261
16285
|
if (!s) throw Error(a.t("platform.screen.useModulePageSession.the-save-response-has-no-record-id-check-the-previous", "保存响应缺少记录身份,请先核实原保存结果"));
|
|
16262
|
-
r &&
|
|
16263
|
-
let l = await
|
|
16264
|
-
return s && (A.invalidateRecordActions?.([s]), I.invalidateRecord(s), A.recordActions(s).catch(() => void 0)),
|
|
16286
|
+
r && Ss(r);
|
|
16287
|
+
let l = await Cs(s, u);
|
|
16288
|
+
return s && (A.invalidateRecordActions?.([s]), I.invalidateRecord(s), A.recordActions(s).catch(() => void 0)), ac(), await Bs(o, a.t("platform.screen.DynamicModuleWorkspaceDetailView.saved-successfully", "保存成功")).catch(() => void 0), {
|
|
16265
16289
|
result: o,
|
|
16266
16290
|
viewRefreshed: l
|
|
16267
16291
|
};
|
|
@@ -16269,11 +16293,11 @@ function mg(e, n, r) {
|
|
|
16269
16293
|
$e.value = void 0, Te.value = !1;
|
|
16270
16294
|
}
|
|
16271
16295
|
}
|
|
16272
|
-
let
|
|
16273
|
-
function ks() {
|
|
16274
|
-
return ea.value && we.value && (P.value === "create" || P.value === "edit") && !!N.value && !hr.value && !ke.value && !je.value && !Y.open.value && !or.value && !ft.value.editing;
|
|
16275
|
-
}
|
|
16296
|
+
let ks = z(() => !!O.crud.saveReceipt && !w.value && !["platform", "iam"].includes(A.moduleAlias.split(".")[0] ?? ""));
|
|
16276
16297
|
function As() {
|
|
16298
|
+
return ta.value && we.value && (P.value === "create" || P.value === "edit") && !!N.value && !gr.value && !ke.value && !je.value && !Y.open.value && !sr.value && !ft.value.editing;
|
|
16299
|
+
}
|
|
16300
|
+
function js() {
|
|
16277
16301
|
return JSON.stringify([
|
|
16278
16302
|
l?.value,
|
|
16279
16303
|
m.value,
|
|
@@ -16285,28 +16309,28 @@ function mg(e, n, r) {
|
|
|
16285
16309
|
M.value,
|
|
16286
16310
|
F.value,
|
|
16287
16311
|
[...Fe.value],
|
|
16288
|
-
|
|
16312
|
+
Bt.value,
|
|
16289
16313
|
pt.value,
|
|
16290
|
-
|
|
16291
|
-
|
|
16314
|
+
ht.value,
|
|
16315
|
+
Tt.value
|
|
16292
16316
|
]);
|
|
16293
16317
|
}
|
|
16294
|
-
async function
|
|
16295
|
-
if (!
|
|
16296
|
-
let e =
|
|
16297
|
-
fields:
|
|
16298
|
-
pickerConfigs:
|
|
16318
|
+
async function Ms() {
|
|
16319
|
+
if (!As()) throw new Je(a.t("platform.screen.useModulePageSession.there-is-no-record-draft-to-review", "当前没有可审阅的记录草稿"));
|
|
16320
|
+
let e = js(), t = () => As() && e === js(), n = P.value, r = { ...N.value }, i = [...Rt.value.keys()].map((e) => Se(e, {
|
|
16321
|
+
fields: Rt.value,
|
|
16322
|
+
pickerConfigs: Ta.value,
|
|
16299
16323
|
record: r,
|
|
16300
16324
|
mode: n
|
|
16301
16325
|
})).filter((e) => e.visible && e.assistantPolicy !== "HIDDEN" && e.fieldControl?.alias !== "password"), o = await Promise.all(i.map(async (e) => ({
|
|
16302
16326
|
field: e,
|
|
16303
16327
|
value: await Op(e, r, e.hasOption && e.calculationTiming === "IMMEDIATE" && !e.optionItems ? await qt(A, e.fieldName).catch(() => []) : e.optionItems, a).catch(() => e.reference ? a.t("platform.screen.ManagedDetailRelationInlineSurface.selected-name-unavailable", "已选择(名称暂不可用)") : a.t("platform.screen.useModulePageSession.display-value-unavailable", "显示值暂不可用")),
|
|
16304
16328
|
...n === "edit" ? { before: Ep(Se(e.fieldName, {
|
|
16305
|
-
fields:
|
|
16329
|
+
fields: Rt.value,
|
|
16306
16330
|
record: M.value,
|
|
16307
16331
|
mode: "view"
|
|
16308
16332
|
}), M.value ?? {}, void 0, !1, a) } : {}
|
|
16309
|
-
}))), s = Ap(
|
|
16333
|
+
}))), s = Ap(Bt.value, br.value, Ie.value, {
|
|
16310
16334
|
language: a,
|
|
16311
16335
|
baseline: M.value,
|
|
16312
16336
|
purpose: "confirmation",
|
|
@@ -16321,7 +16345,7 @@ function mg(e, n, r) {
|
|
|
16321
16345
|
relations: s,
|
|
16322
16346
|
complete: s.every((e) => e.loaded),
|
|
16323
16347
|
isCurrent: t,
|
|
16324
|
-
inputValid: pt.value &&
|
|
16348
|
+
inputValid: !mt.value && pt.value && ht.value,
|
|
16325
16349
|
fieldLines: o.map(({ field: e, value: t, before: n }) => a.t("platform.screen.useModulePageSession.value-valuevalue", "{value1}:{value2}{value3}", {
|
|
16326
16350
|
value1: e.label,
|
|
16327
16351
|
value2: t,
|
|
@@ -16354,36 +16378,36 @@ function mg(e, n, r) {
|
|
|
16354
16378
|
])
|
|
16355
16379
|
};
|
|
16356
16380
|
}
|
|
16357
|
-
async function
|
|
16358
|
-
let e = await
|
|
16381
|
+
async function Ns() {
|
|
16382
|
+
let e = await Ms();
|
|
16359
16383
|
return {
|
|
16360
16384
|
review: e,
|
|
16361
16385
|
isCurrent: e.isCurrent,
|
|
16362
16386
|
async execute() {
|
|
16363
16387
|
if (!e.isCurrent()) throw new Ke(a.t("platform.screen.useModulePageSession.the-draft-or-scope-has-changed-review-the-changes-to", "草稿或范围已变化,请重新审阅放弃内容"));
|
|
16364
16388
|
let t = Re.value + 1;
|
|
16365
|
-
await
|
|
16366
|
-
let n =
|
|
16389
|
+
await fc(), await hn();
|
|
16390
|
+
let n = js(), r = ms(), i = !we.value || r;
|
|
16367
16391
|
return {
|
|
16368
16392
|
discarded: !0,
|
|
16369
16393
|
saved: !1,
|
|
16370
16394
|
detailReady: r,
|
|
16371
|
-
isCurrent: () => i && t === Re.value && n ===
|
|
16395
|
+
isCurrent: () => i && t === Re.value && n === js() && P.value === "view" && !gr.value && !ke.value && !je.value
|
|
16372
16396
|
};
|
|
16373
16397
|
}
|
|
16374
16398
|
};
|
|
16375
16399
|
}
|
|
16376
|
-
async function
|
|
16377
|
-
if (!
|
|
16378
|
-
let e = Le.value, t = JSON.stringify([l?.value, m.value]), n = P.value, r = await
|
|
16400
|
+
async function Ps() {
|
|
16401
|
+
if (!ks.value) throw Error(a.t("platform.screen.useModulePageSession.this-form-does-not-support-saving-from-the-conversation", "当前表单不支持对话内保存"));
|
|
16402
|
+
let e = Le.value, t = JSON.stringify([l?.value, m.value]), n = P.value, r = await gs(!1);
|
|
16379
16403
|
if (!r || e !== Le.value) throw Error(a.t("platform.screen.useModulePageSession.complete-form-validation-before-preparing-the-save-again", "请完成表单校验后重新准备保存"));
|
|
16380
|
-
let i = await
|
|
16404
|
+
let i = await Ms(), o = i.relations.filter((e) => e.loaded), s = i.relationLines, c = JSON.stringify(r), u = JSON.stringify(A.runtime.snapshot()?.uiDescriptor), d = ir(), f = vs.value, p, h = () => t === JSON.stringify([l?.value, m.value]) && e === Le.value && u === JSON.stringify(A.runtime.snapshot()?.uiDescriptor) && n === P.value && i.isCurrent() && !st.value && !!N.value && JSON.stringify(Tp(N.value, Rt.value.values(), A.runtime.snapshot()?.capabilities)) === c, g = i.fieldLines;
|
|
16381
16405
|
if (!h()) throw new Ke(a.t("platform.screen.useModulePageSession.the-draft-has-changed-confirm-it-again", "草稿已变化,请重新确认"));
|
|
16382
16406
|
return {
|
|
16383
|
-
receiptReference:
|
|
16407
|
+
receiptReference: ys(d),
|
|
16384
16408
|
modelSummary: a.t("platform.screen.useModulePageSession.save-the-current-form-and-its-embedded-details-after-user", "保存当前表单及随单明细,等待用户确认,尚未提交。字段值仅依据当前表单能力返回的授权事实。"),
|
|
16385
16409
|
presentation: {
|
|
16386
|
-
title: a.t("platform.screen.useModulePageSession.confirm-saving-value", "确认保存{value1}", { value1:
|
|
16410
|
+
title: a.t("platform.screen.useModulePageSession.confirm-saving-value", "确认保存{value1}", { value1: ii.value }),
|
|
16387
16411
|
...s.length ? { details: {
|
|
16388
16412
|
title: a.t("platform.screen.useModulePageSession.view-all-details-and-removed-rows", "查看全部明细与移除内容"),
|
|
16389
16413
|
lines: s
|
|
@@ -16406,27 +16430,27 @@ function mg(e, n, r) {
|
|
|
16406
16430
|
},
|
|
16407
16431
|
async execute() {
|
|
16408
16432
|
if (!h()) throw new Ke(a.t("platform.screen.useModulePageSession.the-draft-has-changed-confirm-it-again", "草稿已变化,请重新确认"));
|
|
16409
|
-
if (!await
|
|
16410
|
-
let e = Re.value + 1, { result: t, viewRefreshed: r } = await
|
|
16433
|
+
if (!await gs() || !h()) throw new Ke(a.t("platform.screen.useModulePageSession.the-save-conditions-have-changed-confirm-them-again", "保存条件已变化,请重新确认"));
|
|
16434
|
+
let e = Re.value + 1, { result: t, viewRefreshed: r } = await Os(JSON.parse(c), n, "save", d);
|
|
16411
16435
|
return r && Re.value === e && (p = {
|
|
16412
16436
|
interaction: e,
|
|
16413
16437
|
recordId: String(t.record.id)
|
|
16414
|
-
}),
|
|
16438
|
+
}), ws(String(t.record.id), r);
|
|
16415
16439
|
},
|
|
16416
16440
|
async lookup() {
|
|
16417
|
-
return
|
|
16441
|
+
return Ts(d, f);
|
|
16418
16442
|
}
|
|
16419
16443
|
};
|
|
16420
16444
|
}
|
|
16421
|
-
async function
|
|
16445
|
+
async function Fs(t, r = "delete") {
|
|
16422
16446
|
let o = t.id == null ? void 0 : String(t.id), s = typeof t.version == "number" ? t.version : void 0;
|
|
16423
|
-
if (!(!o || s === void 0 || st.value || ct.value.editing || ct.value.busy) && (!e.recordOnly || await
|
|
16447
|
+
if (!(!o || s === void 0 || st.value || ct.value.editing || ct.value.busy) && (!e.recordOnly || await as(o, "delete"))) {
|
|
16424
16448
|
Ze.value = !0;
|
|
16425
16449
|
try {
|
|
16426
16450
|
if (!await i({
|
|
16427
16451
|
presentation: () => ({
|
|
16428
|
-
title: a.t("platform.screen.ManagedDetailRelationSurface.delete-value", "删除{value1}", { value1:
|
|
16429
|
-
content: a.t("platform.screen.DynamicModuleWorkspaceDetailView.delete-value", "确认删除「{value1}」?", { value1:
|
|
16452
|
+
title: a.t("platform.screen.ManagedDetailRelationSurface.delete-value", "删除{value1}", { value1: ri.value }),
|
|
16453
|
+
content: a.t("platform.screen.DynamicModuleWorkspaceDetailView.delete-value", "确认删除「{value1}」?", { value1: vc(t) ?? o }),
|
|
16430
16454
|
okText: a.t("platform.action.delete", "删除")
|
|
16431
16455
|
}),
|
|
16432
16456
|
title: a.t("platform.action.delete", "删除"),
|
|
@@ -16434,7 +16458,7 @@ function mg(e, n, r) {
|
|
|
16434
16458
|
}, a)) return;
|
|
16435
16459
|
Re.value += 1, $e.value = r;
|
|
16436
16460
|
let c = await A.crud.delete(o, { version: s });
|
|
16437
|
-
A.invalidateRecordActions?.([o]), M.value?.id === o && (pe.clearDeleted(), D.value = void 0), e.recordOnly && n("record-only-change", { type: "deleted" }),
|
|
16461
|
+
A.invalidateRecordActions?.([o]), M.value?.id === o && (pe.clearDeleted(), D.value = void 0), e.recordOnly && n("record-only-change", { type: "deleted" }), ac(), await Bs(c, a.t("platform.screen.DynamicModuleWorkspaceDetailView.deleted-successfully", "删除成功"));
|
|
16438
16462
|
} catch (e) {
|
|
16439
16463
|
ze(e, {
|
|
16440
16464
|
source: "module-action",
|
|
@@ -16446,15 +16470,15 @@ function mg(e, n, r) {
|
|
|
16446
16470
|
}
|
|
16447
16471
|
}
|
|
16448
16472
|
}
|
|
16449
|
-
async function
|
|
16473
|
+
async function Is() {
|
|
16450
16474
|
let t = M.value, n = t?.id == null ? void 0 : String(t.id), r = typeof t?.version == "number" ? t.version : void 0;
|
|
16451
|
-
if (t && n && r !== void 0 &&
|
|
16475
|
+
if (t && n && r !== void 0 && ha.value && (!e.recordOnly || await as(n, t.enabled === !1 ? "enable" : "disable"))) {
|
|
16452
16476
|
Re.value += 1, Oe.value = !0;
|
|
16453
16477
|
try {
|
|
16454
16478
|
let e = t.enabled === !1, i = e ? await A.crud.enable(n, { version: r }) : await A.crud.disable(n, { version: r });
|
|
16455
16479
|
A.invalidateRecordActions?.([n]);
|
|
16456
|
-
let o = await
|
|
16457
|
-
|
|
16480
|
+
let o = await Rs(n);
|
|
16481
|
+
ac(), await Bs(i, e ? a.t("platform.screen.DynamicModuleWorkspaceDetailView.enabled", "已启用") : a.t("platform.workflow.disabled", "已停用")), o.failure && zs(o.failure, "module-action");
|
|
16458
16482
|
} catch (e) {
|
|
16459
16483
|
ze(e, {
|
|
16460
16484
|
source: "module-action",
|
|
@@ -16466,10 +16490,10 @@ function mg(e, n, r) {
|
|
|
16466
16490
|
}
|
|
16467
16491
|
}
|
|
16468
16492
|
}
|
|
16469
|
-
function
|
|
16493
|
+
function Ls(e) {
|
|
16470
16494
|
return e instanceof Jt && (e.status === 403 || e.status === 404);
|
|
16471
16495
|
}
|
|
16472
|
-
async function
|
|
16496
|
+
async function Rs(t) {
|
|
16473
16497
|
try {
|
|
16474
16498
|
let r = await A.crud.view(t);
|
|
16475
16499
|
return pe.resolveLoad(r), e.recordOnly && n("record-only-change", {
|
|
@@ -16480,8 +16504,8 @@ function mg(e, n, r) {
|
|
|
16480
16504
|
return { failure: e };
|
|
16481
16505
|
}
|
|
16482
16506
|
}
|
|
16483
|
-
function
|
|
16484
|
-
if (e.recordOnly &&
|
|
16507
|
+
function zs(t, r) {
|
|
16508
|
+
if (e.recordOnly && Ls(t)) {
|
|
16485
16509
|
pe.clearDeleted(), n("record-only-change", { type: "unavailable" });
|
|
16486
16510
|
return;
|
|
16487
16511
|
}
|
|
@@ -16491,71 +16515,71 @@ function mg(e, n, r) {
|
|
|
16491
16515
|
language: a
|
|
16492
16516
|
});
|
|
16493
16517
|
}
|
|
16494
|
-
function
|
|
16518
|
+
function Bs(e, t, n = "module-action") {
|
|
16495
16519
|
return de(e, t, n);
|
|
16496
16520
|
}
|
|
16497
|
-
function
|
|
16521
|
+
function Vs(e) {
|
|
16498
16522
|
if (e.key === "__platform-check-save") {
|
|
16499
|
-
|
|
16523
|
+
Ws(e);
|
|
16500
16524
|
return;
|
|
16501
16525
|
}
|
|
16502
16526
|
if (Be(), e.key === "create") {
|
|
16503
|
-
|
|
16527
|
+
Wo();
|
|
16504
16528
|
return;
|
|
16505
16529
|
}
|
|
16506
|
-
let t =
|
|
16530
|
+
let t = xi.value.find((t) => t.key === e.key);
|
|
16507
16531
|
if (t) {
|
|
16508
|
-
fe(t,
|
|
16532
|
+
fe(t, tc());
|
|
16509
16533
|
return;
|
|
16510
16534
|
}
|
|
16511
|
-
|
|
16512
|
-
}
|
|
16513
|
-
function Vs(e) {
|
|
16514
|
-
return Hs(e)?.operation;
|
|
16535
|
+
ki.value.some((t) => t.key === e.key) && Ws(e);
|
|
16515
16536
|
}
|
|
16516
16537
|
function Hs(e) {
|
|
16517
|
-
return
|
|
16538
|
+
return Us(e)?.operation;
|
|
16518
16539
|
}
|
|
16519
16540
|
function Us(e) {
|
|
16520
|
-
|
|
16541
|
+
return Vt.value?.actions?.find((t) => `page-placement:${t.anchor}:${t.actionCode}` === e);
|
|
16542
|
+
}
|
|
16543
|
+
function Ws(e) {
|
|
16544
|
+
if (!Te.value && ki.value.some((t) => t.key === e.key && !t.disabled)) {
|
|
16521
16545
|
if (e.key === "__platform-check-save") {
|
|
16522
|
-
|
|
16546
|
+
Es();
|
|
16523
16547
|
return;
|
|
16524
16548
|
}
|
|
16525
|
-
if (Be(),
|
|
16526
|
-
let t =
|
|
16527
|
-
t === "OPEN_CREATE" ?
|
|
16549
|
+
if (Be(), Oi.value) {
|
|
16550
|
+
let t = Hs(e.key);
|
|
16551
|
+
t === "OPEN_CREATE" ? Wo() : t === "REFRESH" ? ac() : t === "INVOKE" && Zs(e.key);
|
|
16528
16552
|
return;
|
|
16529
16553
|
}
|
|
16530
16554
|
if (e.actionCode === "create") {
|
|
16531
|
-
|
|
16555
|
+
Wo();
|
|
16532
16556
|
return;
|
|
16533
16557
|
}
|
|
16534
|
-
e.actionCode === "query" &&
|
|
16558
|
+
e.actionCode === "query" && ac();
|
|
16535
16559
|
}
|
|
16536
16560
|
}
|
|
16537
|
-
function
|
|
16561
|
+
function Gs(e, t) {
|
|
16538
16562
|
if (Be(), e.key === "view") {
|
|
16539
|
-
|
|
16563
|
+
Ks(t);
|
|
16540
16564
|
return;
|
|
16541
16565
|
}
|
|
16542
16566
|
if (e.key === "edit") {
|
|
16543
|
-
|
|
16567
|
+
os(t);
|
|
16544
16568
|
return;
|
|
16545
16569
|
}
|
|
16546
16570
|
if (e.key === "delete") {
|
|
16547
|
-
|
|
16571
|
+
Fs(t);
|
|
16548
16572
|
return;
|
|
16549
16573
|
}
|
|
16550
|
-
let n =
|
|
16574
|
+
let n = Ti.value.find((t) => t.key === e.key);
|
|
16551
16575
|
n && fe(n, {
|
|
16552
|
-
...
|
|
16576
|
+
...tc(t),
|
|
16553
16577
|
record: t
|
|
16554
16578
|
});
|
|
16555
16579
|
}
|
|
16556
|
-
async function
|
|
16580
|
+
async function Ks(e) {
|
|
16557
16581
|
Be();
|
|
16558
|
-
let t =
|
|
16582
|
+
let t = _i.value?.recordView?.authorizationActionCode, n = e.id == null ? void 0 : String(e.id);
|
|
16559
16583
|
if (t && n) try {
|
|
16560
16584
|
if (!(await A.recordActions(n)).actions.some((e) => e.actionCode === t && e.available)) return;
|
|
16561
16585
|
} catch (e) {
|
|
@@ -16568,72 +16592,72 @@ function mg(e, n, r) {
|
|
|
16568
16592
|
}
|
|
16569
16593
|
await xe(e, "view");
|
|
16570
16594
|
}
|
|
16571
|
-
let
|
|
16572
|
-
async function
|
|
16595
|
+
let qs = q(!1);
|
|
16596
|
+
async function Js() {
|
|
16573
16597
|
Be();
|
|
16574
16598
|
let e = M.value;
|
|
16575
16599
|
if (e?.id) {
|
|
16576
16600
|
let t = String(e.id);
|
|
16577
16601
|
A.invalidateRecordActions?.([t]), A.recordActions(t).catch(() => void 0);
|
|
16578
16602
|
}
|
|
16579
|
-
|
|
16580
|
-
e instanceof Jt && (e.status === 403 || e.status === 404 || e.code === "ACCESS_DENIED" || e.code === "RESOURCE_NOT_FOUND") ?
|
|
16603
|
+
ac(), e?.id && await _e(e, "view", {}, !1, (e) => {
|
|
16604
|
+
e instanceof Jt && (e.status === 403 || e.status === 404 || e.code === "ACCESS_DENIED" || e.code === "RESOURCE_NOT_FOUND") ? Do() : ze(e, {
|
|
16581
16605
|
source: "record-permissions",
|
|
16582
16606
|
phase: "load",
|
|
16583
16607
|
language: a
|
|
16584
16608
|
});
|
|
16585
16609
|
});
|
|
16586
16610
|
}
|
|
16587
|
-
function
|
|
16611
|
+
function Ys(e) {
|
|
16588
16612
|
if (ct.value.editing || ct.value.busy) return;
|
|
16589
|
-
if (Be(),
|
|
16590
|
-
|
|
16613
|
+
if (Be(), or.value.some((t) => t.key === e.key)) {
|
|
16614
|
+
pr(e);
|
|
16591
16615
|
return;
|
|
16592
16616
|
}
|
|
16593
|
-
let t = M.value, n =
|
|
16617
|
+
let t = M.value, n = Hi.value.find((t) => t.key === e.key);
|
|
16594
16618
|
if (t && n) {
|
|
16595
|
-
|
|
16619
|
+
Ba(n, t);
|
|
16596
16620
|
return;
|
|
16597
16621
|
}
|
|
16598
|
-
|
|
16622
|
+
Ni.value.some((t) => t.key === e.key) && Xs(e);
|
|
16599
16623
|
}
|
|
16600
|
-
async function
|
|
16601
|
-
let t = M.value, n = t?.id == null ? void 0 : String(t.id), r =
|
|
16624
|
+
async function Xs(e) {
|
|
16625
|
+
let t = M.value, n = t?.id == null ? void 0 : String(t.id), r = Oi.value && Hs(e.key) !== "INVOKE" ? {
|
|
16602
16626
|
OPEN_EDIT: "update",
|
|
16603
16627
|
DELETE: "delete",
|
|
16604
16628
|
ENABLE: "enable",
|
|
16605
16629
|
DISABLE: "disable",
|
|
16606
16630
|
MANAGE_PERMISSIONS: "managePermissions"
|
|
16607
|
-
}[
|
|
16608
|
-
if (t && n && r && P.value === "view" &&
|
|
16631
|
+
}[Hs(e.key) ?? ""] : e.actionCode;
|
|
16632
|
+
if (t && n && r && P.value === "view" && Ni.value.some((t) => t.key === e.key && !t.disabled)) {
|
|
16609
16633
|
if (r === "managePermissions") {
|
|
16610
|
-
|
|
16634
|
+
qs.value = !0;
|
|
16611
16635
|
return;
|
|
16612
16636
|
}
|
|
16613
16637
|
if (r === "update") {
|
|
16614
|
-
|
|
16638
|
+
os(t, "restore-view");
|
|
16615
16639
|
return;
|
|
16616
16640
|
}
|
|
16617
16641
|
if (r === "delete") {
|
|
16618
|
-
|
|
16642
|
+
Fs(t, e.key);
|
|
16619
16643
|
return;
|
|
16620
16644
|
}
|
|
16621
16645
|
if (r === "enable" || r === "disable") {
|
|
16622
|
-
r === "enable" == (t.enabled === !1) && await
|
|
16646
|
+
r === "enable" == (t.enabled === !1) && await Is();
|
|
16623
16647
|
return;
|
|
16624
16648
|
}
|
|
16625
|
-
if (
|
|
16649
|
+
if (Hs(e.key) === "INVOKE") await Zs(e.key, n);
|
|
16626
16650
|
else {
|
|
16627
|
-
let e =
|
|
16628
|
-
e &&
|
|
16651
|
+
let e = or.value.find((e) => e.actionCode === r);
|
|
16652
|
+
e && pr(e);
|
|
16629
16653
|
}
|
|
16630
16654
|
}
|
|
16631
16655
|
}
|
|
16632
|
-
async function
|
|
16656
|
+
async function Zs(e, t) {
|
|
16633
16657
|
if (!st.value) {
|
|
16634
16658
|
Re.value += 1, Te.value = !0, $e.value = e;
|
|
16635
16659
|
try {
|
|
16636
|
-
let n =
|
|
16660
|
+
let n = Us(e), r = n?.anchor === "FORM", i = r && !t && N.value ? jn(N.value) : void 0, o = i == null ? void 0 : We(i), s = t && M.value && String(M.value.id) === t ? We(M.value) : void 0, c = e && n?.statusMode === "INPUT_VALIDATION" ? t && s ? I.begin(e, {
|
|
16637
16661
|
kind: "record",
|
|
16638
16662
|
recordId: t,
|
|
16639
16663
|
fingerprint: s
|
|
@@ -16645,7 +16669,7 @@ function mg(e, n, r) {
|
|
|
16645
16669
|
record: i
|
|
16646
16670
|
}, a), u;
|
|
16647
16671
|
if (t) {
|
|
16648
|
-
let e = await
|
|
16672
|
+
let e = await Rs(t);
|
|
16649
16673
|
u = e.failure, c?.target.kind === "record" && e.record && I.succeed(c, We(e.record));
|
|
16650
16674
|
} else if (r && N.value) {
|
|
16651
16675
|
if (gh(l)) {
|
|
@@ -16657,7 +16681,7 @@ function mg(e, n, r) {
|
|
|
16657
16681
|
}
|
|
16658
16682
|
c?.target.kind === "draft" && I.succeed(c);
|
|
16659
16683
|
}
|
|
16660
|
-
r ||
|
|
16684
|
+
r || ac(), await Bs(l, a.t("platform.screen.useModulePageSession.action-completed", "操作成功")), u && zs(u, "module-page-action");
|
|
16661
16685
|
} catch (e) {
|
|
16662
16686
|
ze(e, {
|
|
16663
16687
|
source: "module-page-action",
|
|
@@ -16669,41 +16693,41 @@ function mg(e, n, r) {
|
|
|
16669
16693
|
}
|
|
16670
16694
|
}
|
|
16671
16695
|
}
|
|
16672
|
-
function
|
|
16673
|
-
if (st.value || !
|
|
16696
|
+
function Qs(e) {
|
|
16697
|
+
if (st.value || !Pi.value.some((t) => t.key === e.key && !t.disabled)) return;
|
|
16674
16698
|
Be();
|
|
16675
|
-
let t =
|
|
16676
|
-
if (!
|
|
16699
|
+
let t = Hs(e.key), n = t === "INVOKE" && e.actionCode !== "create" && e.actionCode !== "update";
|
|
16700
|
+
if (!Oi.value || n || t === (P.value === "create" ? "SUBMIT_CREATE" : "SUBMIT_UPDATE")) {
|
|
16677
16701
|
if (e.actionCode === "create" || e.actionCode === "update") {
|
|
16678
|
-
|
|
16702
|
+
Ds(e.key);
|
|
16679
16703
|
return;
|
|
16680
16704
|
}
|
|
16681
16705
|
if (n && e.actionCode) {
|
|
16682
|
-
|
|
16706
|
+
Zs(e.key);
|
|
16683
16707
|
return;
|
|
16684
16708
|
}
|
|
16685
|
-
|
|
16709
|
+
Xs(e);
|
|
16686
16710
|
}
|
|
16687
16711
|
}
|
|
16688
|
-
function
|
|
16689
|
-
let r =
|
|
16712
|
+
function $s(e, t, n) {
|
|
16713
|
+
let r = Di.value.find((t) => t.key === e.key);
|
|
16690
16714
|
r && (Be(), fe(r, {
|
|
16691
|
-
...
|
|
16715
|
+
...tc(),
|
|
16692
16716
|
records: t,
|
|
16693
16717
|
clearSelection: n
|
|
16694
16718
|
}));
|
|
16695
16719
|
}
|
|
16696
|
-
function
|
|
16697
|
-
let e =
|
|
16698
|
-
e && n &&
|
|
16720
|
+
function ec() {
|
|
16721
|
+
let e = Yi.value, t = M.value, n = t?.id == null ? void 0 : String(t.id);
|
|
16722
|
+
e && n && Xi.value && j && (Be(), j.openWorkspaceTab(e, { recordId: n }, vc(t) ?? void 0));
|
|
16699
16723
|
}
|
|
16700
|
-
function
|
|
16724
|
+
function tc(e) {
|
|
16701
16725
|
return {
|
|
16702
16726
|
module: A,
|
|
16703
|
-
scope:
|
|
16704
|
-
refreshList:
|
|
16705
|
-
reload:
|
|
16706
|
-
openDrawer: (t) =>
|
|
16727
|
+
scope: nc().scope,
|
|
16728
|
+
refreshList: ac,
|
|
16729
|
+
reload: rc,
|
|
16730
|
+
openDrawer: (t) => ln(t, e),
|
|
16707
16731
|
openWorkspaceTab: (e, t) => {
|
|
16708
16732
|
if (!j) throw Error(a.t("platform.screen.DynamicModuleWorkspaceDetailView.a-module-page-work-view-requires-workbench-navigation", "模块页面工作视图需要 Workbench 导航承载"));
|
|
16709
16733
|
j.openWorkspaceTab(e, t);
|
|
@@ -16714,38 +16738,38 @@ function mg(e, n, r) {
|
|
|
16714
16738
|
}
|
|
16715
16739
|
};
|
|
16716
16740
|
}
|
|
16717
|
-
function
|
|
16741
|
+
function nc() {
|
|
16718
16742
|
if (_.value.hidden) return { module: A };
|
|
16719
|
-
let e =
|
|
16743
|
+
let e = Ut.value[0];
|
|
16720
16744
|
return e ? {
|
|
16721
16745
|
module: A,
|
|
16722
16746
|
scope: {
|
|
16723
16747
|
moduleAlias: e.descriptor.sourceModuleAlias,
|
|
16724
|
-
record:
|
|
16748
|
+
record: Gt.value[e.descriptor.key]
|
|
16725
16749
|
}
|
|
16726
16750
|
} : { module: A };
|
|
16727
16751
|
}
|
|
16728
|
-
function
|
|
16729
|
-
|
|
16752
|
+
function rc() {
|
|
16753
|
+
ac(), Ir.value || (T.value += 1);
|
|
16730
16754
|
}
|
|
16731
|
-
function
|
|
16755
|
+
function ic(e) {
|
|
16732
16756
|
Te.value = e;
|
|
16733
16757
|
}
|
|
16734
|
-
function
|
|
16758
|
+
function ac() {
|
|
16735
16759
|
if (!(ct.value.editing || ct.value.busy)) {
|
|
16736
|
-
if (
|
|
16760
|
+
if (Ir.value) {
|
|
16737
16761
|
T.value += 1;
|
|
16738
16762
|
return;
|
|
16739
16763
|
}
|
|
16740
|
-
if (
|
|
16741
|
-
|
|
16764
|
+
if (Nr.value) {
|
|
16765
|
+
_a.refresh();
|
|
16742
16766
|
return;
|
|
16743
16767
|
}
|
|
16744
|
-
|
|
16768
|
+
vn.value += 1;
|
|
16745
16769
|
}
|
|
16746
16770
|
}
|
|
16747
|
-
function
|
|
16748
|
-
|
|
16771
|
+
function oc(e) {
|
|
16772
|
+
ac();
|
|
16749
16773
|
let t = M.value;
|
|
16750
16774
|
if (!t?.id) return;
|
|
16751
16775
|
if (P.value === "view") {
|
|
@@ -16754,13 +16778,13 @@ function mg(e, n, r) {
|
|
|
16754
16778
|
}
|
|
16755
16779
|
let n = N.value;
|
|
16756
16780
|
if (P.value !== "edit" || !n) return;
|
|
16757
|
-
let r = pg(n,
|
|
16781
|
+
let r = pg(n, Rt.value, e);
|
|
16758
16782
|
r !== n && (N.value = r);
|
|
16759
16783
|
}
|
|
16760
|
-
function
|
|
16784
|
+
function sc() {
|
|
16761
16785
|
st.value || (Re.value += 1, me(), pe.close());
|
|
16762
16786
|
}
|
|
16763
|
-
async function
|
|
16787
|
+
async function cc() {
|
|
16764
16788
|
return lt && !await lt() || st.value ? !1 : !Ee.value || i({
|
|
16765
16789
|
presentation: () => ({
|
|
16766
16790
|
title: a.t("platform.screen.useModulePageSession.discard-unsaved-changes", "放弃未保存更改"),
|
|
@@ -16771,153 +16795,153 @@ function mg(e, n, r) {
|
|
|
16771
16795
|
danger: !0
|
|
16772
16796
|
}, a);
|
|
16773
16797
|
}
|
|
16774
|
-
function cc() {
|
|
16775
|
-
return sc();
|
|
16776
|
-
}
|
|
16777
16798
|
function lc() {
|
|
16778
|
-
|
|
16799
|
+
return cc();
|
|
16779
16800
|
}
|
|
16780
16801
|
function uc() {
|
|
16781
|
-
|
|
16802
|
+
gr.value || Ln.value || (Re.value += 1, Ln.value = !0, pe.close());
|
|
16803
|
+
}
|
|
16804
|
+
function dc() {
|
|
16805
|
+
e.recordOnly && Ln.value && (Ln.value = !1, n("record-only-close"));
|
|
16782
16806
|
}
|
|
16783
|
-
async function
|
|
16807
|
+
async function fc() {
|
|
16784
16808
|
if (st.value || (Re.value += 1, me(), pe.cancelEdit(), !we.value)) return;
|
|
16785
16809
|
let e = M.value;
|
|
16786
16810
|
e?.id != null && await _e(e, "view");
|
|
16787
16811
|
}
|
|
16788
|
-
function fc() {
|
|
16789
|
-
return ea.value && P.value === "edit" && !_r.value && pt.value && mt.value && !hr.value && !Y.open.value && !or.value && !ft.value.editing && !ke.value && !je.value;
|
|
16790
|
-
}
|
|
16791
16812
|
function pc() {
|
|
16792
|
-
|
|
16793
|
-
return dc();
|
|
16813
|
+
return ta.value && P.value === "edit" && !vr.value && !mt.value && pt.value && ht.value && !gr.value && !Y.open.value && !sr.value && !ft.value.editing && !ke.value && !je.value;
|
|
16794
16814
|
}
|
|
16795
|
-
|
|
16815
|
+
function mc() {
|
|
16816
|
+
if (!pc()) throw new Je(a.t("platform.screen.useModulePageSession.the-editing-state-has-changed-review-the-current-draft-first", "编辑状态已变化,请先审阅当前草稿"));
|
|
16817
|
+
return fc();
|
|
16818
|
+
}
|
|
16819
|
+
async function hc() {
|
|
16796
16820
|
if (st.value) return;
|
|
16797
16821
|
Re.value += 1, me(), pe.cancelEdit();
|
|
16798
16822
|
let e = M.value;
|
|
16799
16823
|
e?.id != null && (await _e(e, "view"), D.value = M.value);
|
|
16800
16824
|
}
|
|
16801
|
-
function
|
|
16825
|
+
function gc() {
|
|
16802
16826
|
let e = M.value;
|
|
16803
16827
|
if (e && P.value !== "create") {
|
|
16804
|
-
if (
|
|
16828
|
+
if (_a.active.value || _n.value === "recycleBin") {
|
|
16805
16829
|
Be(), ve(e);
|
|
16806
16830
|
return;
|
|
16807
16831
|
}
|
|
16808
16832
|
xe(e, P.value);
|
|
16809
16833
|
}
|
|
16810
16834
|
}
|
|
16811
|
-
function
|
|
16835
|
+
function _c() {
|
|
16812
16836
|
Le.value += 1;
|
|
16813
16837
|
let e = M.value?.id;
|
|
16814
16838
|
e != null && x(A, String(e)).catch((e) => ze(e, {
|
|
16815
16839
|
source: "module-workflow-change",
|
|
16816
16840
|
phase: "authorization",
|
|
16817
16841
|
language: a
|
|
16818
|
-
})),
|
|
16842
|
+
})), ac(), gc();
|
|
16819
16843
|
}
|
|
16820
|
-
function
|
|
16844
|
+
function vc(e) {
|
|
16821
16845
|
let t = e && (y(e, "title", a) ?? y(e, "name", a) ?? e.code ?? e.id);
|
|
16822
16846
|
return t == null ? void 0 : String(t);
|
|
16823
16847
|
}
|
|
16824
16848
|
return {
|
|
16825
16849
|
language: a,
|
|
16826
16850
|
props: e,
|
|
16827
|
-
runtimePageResolved:
|
|
16828
|
-
runtimePage:
|
|
16829
|
-
pageBootstrapError:
|
|
16830
|
-
pageReady:
|
|
16831
|
-
isListPage:
|
|
16832
|
-
constrainedManagementPage:
|
|
16833
|
-
flatManagementPage:
|
|
16834
|
-
managedPageActions:
|
|
16835
|
-
flatManagementRecycleBin:
|
|
16836
|
-
flatManagementContent:
|
|
16837
|
-
title:
|
|
16838
|
-
flatManagementSearchKeyword:
|
|
16851
|
+
runtimePageResolved: Ht,
|
|
16852
|
+
runtimePage: Vt,
|
|
16853
|
+
pageBootstrapError: Pt,
|
|
16854
|
+
pageReady: ta,
|
|
16855
|
+
isListPage: Or,
|
|
16856
|
+
constrainedManagementPage: Qi,
|
|
16857
|
+
flatManagementPage: Nr,
|
|
16858
|
+
managedPageActions: Oi,
|
|
16859
|
+
flatManagementRecycleBin: _a,
|
|
16860
|
+
flatManagementContent: ni,
|
|
16861
|
+
title: rr,
|
|
16862
|
+
flatManagementSearchKeyword: pn,
|
|
16839
16863
|
editorMode: P,
|
|
16840
|
-
detailTitle:
|
|
16841
|
-
navigatorExplorerCount:
|
|
16842
|
-
navigatorExtension:
|
|
16843
|
-
navigatorExtensionContext:
|
|
16844
|
-
navigatorLevelAt:
|
|
16845
|
-
selectedNavigatorRecords:
|
|
16846
|
-
navigatorReloadKey:
|
|
16847
|
-
scopeSearchKeyword:
|
|
16848
|
-
navigatorExplorerQueryValues:
|
|
16864
|
+
detailTitle: ar,
|
|
16865
|
+
navigatorExplorerCount: Br,
|
|
16866
|
+
navigatorExtension: zr,
|
|
16867
|
+
navigatorExtensionContext: Hr,
|
|
16868
|
+
navigatorLevelAt: Xr,
|
|
16869
|
+
selectedNavigatorRecords: Gt,
|
|
16870
|
+
navigatorReloadKey: Qa,
|
|
16871
|
+
scopeSearchKeyword: Pn,
|
|
16872
|
+
navigatorExplorerQueryValues: oo,
|
|
16849
16873
|
context: A,
|
|
16850
|
-
navigatorManagementScopeReady:
|
|
16851
|
-
navigatorRecordCreationState:
|
|
16852
|
-
navigatorManagementScopeDisabledReason:
|
|
16853
|
-
navigatorPanelScopeContext:
|
|
16854
|
-
navigatorTreeParentPolicy:
|
|
16855
|
-
navigatorInlineActions:
|
|
16856
|
-
navigatorSortState:
|
|
16857
|
-
scopeReloadKey:
|
|
16858
|
-
createNavigatorRecord:
|
|
16859
|
-
handleNavigatorLoaded:
|
|
16860
|
-
selectNavigatorRecord:
|
|
16861
|
-
clearNavigatorRecord:
|
|
16862
|
-
handleNavigatorInlineAction:
|
|
16863
|
-
toggleNavigatorSorting:
|
|
16864
|
-
navigatorManagementLevel:
|
|
16874
|
+
navigatorManagementScopeReady: co,
|
|
16875
|
+
navigatorRecordCreationState: mo,
|
|
16876
|
+
navigatorManagementScopeDisabledReason: lo,
|
|
16877
|
+
navigatorPanelScopeContext: pi,
|
|
16878
|
+
navigatorTreeParentPolicy: Zr,
|
|
16879
|
+
navigatorInlineActions: fo,
|
|
16880
|
+
navigatorSortState: eo,
|
|
16881
|
+
scopeReloadKey: Fn,
|
|
16882
|
+
createNavigatorRecord: ho,
|
|
16883
|
+
handleNavigatorLoaded: Ka,
|
|
16884
|
+
selectNavigatorRecord: Wa,
|
|
16885
|
+
clearNavigatorRecord: Ga,
|
|
16886
|
+
handleNavigatorInlineAction: wo,
|
|
16887
|
+
toggleNavigatorSorting: to,
|
|
16888
|
+
navigatorManagementLevel: X,
|
|
16865
16889
|
navigatorManagementDetail: Y,
|
|
16866
|
-
navigatorManagementTitle:
|
|
16867
|
-
navigatorManagementFormFields:
|
|
16868
|
-
navigatorManagementFormValidationRequestKey:
|
|
16869
|
-
navigatorManagementPickerConfigs:
|
|
16870
|
-
navigatorManagementFormContributions:
|
|
16871
|
-
navigatorManagementFormFieldPolicies:
|
|
16872
|
-
navigatorManagementEnabledVisible:
|
|
16873
|
-
navigatorManagementEnabledDisabled:
|
|
16874
|
-
navigatorManagementEnabledDisabledReason:
|
|
16875
|
-
navigatorManagementTogglingEnabled:
|
|
16876
|
-
closeNavigatorManagementEditor:
|
|
16877
|
-
saveNavigatorRecord:
|
|
16878
|
-
toggleNavigatorManagementEnabled:
|
|
16879
|
-
updateNavigatorManagementDraft:
|
|
16880
|
-
navigatorManagementFormValid:
|
|
16881
|
-
navigatorListScopeReady:
|
|
16890
|
+
navigatorManagementTitle: nr,
|
|
16891
|
+
navigatorManagementFormFields: Zn,
|
|
16892
|
+
navigatorManagementFormValidationRequestKey: Mn,
|
|
16893
|
+
navigatorManagementPickerConfigs: tr,
|
|
16894
|
+
navigatorManagementFormContributions: $n,
|
|
16895
|
+
navigatorManagementFormFieldPolicies: er,
|
|
16896
|
+
navigatorManagementEnabledVisible: go,
|
|
16897
|
+
navigatorManagementEnabledDisabled: vo,
|
|
16898
|
+
navigatorManagementEnabledDisabledReason: yo,
|
|
16899
|
+
navigatorManagementTogglingEnabled: An,
|
|
16900
|
+
closeNavigatorManagementEditor: Oo,
|
|
16901
|
+
saveNavigatorRecord: To,
|
|
16902
|
+
toggleNavigatorManagementEnabled: bo,
|
|
16903
|
+
updateNavigatorManagementDraft: xo,
|
|
16904
|
+
navigatorManagementFormValid: Z,
|
|
16905
|
+
navigatorListScopeReady: ua,
|
|
16882
16906
|
selectedRecord: M,
|
|
16883
16907
|
recordDisplayRecord: Ie,
|
|
16884
|
-
recordDetailReady:
|
|
16908
|
+
recordDetailReady: ms,
|
|
16885
16909
|
recordRelationOptions: Pe,
|
|
16886
|
-
flatManagementSorting:
|
|
16887
|
-
navigatorListQueryValues:
|
|
16888
|
-
flatManagementItemOf:
|
|
16889
|
-
matchesPageQuickSearch:
|
|
16890
|
-
handleFlatManagementLoaded:
|
|
16891
|
-
refreshList:
|
|
16892
|
-
openFlatManagementRecord:
|
|
16893
|
-
resetFlatManagementSelection:
|
|
16894
|
-
navigatorScopeUnavailableDescription:
|
|
16895
|
-
detailWorkspaceAvailable:
|
|
16896
|
-
openDetailWorkspaceView:
|
|
16897
|
-
flatManagementDetailActions:
|
|
16898
|
-
handleFlatManagementAction:
|
|
16910
|
+
flatManagementSorting: gn,
|
|
16911
|
+
navigatorListQueryValues: sa,
|
|
16912
|
+
flatManagementItemOf: La,
|
|
16913
|
+
matchesPageQuickSearch: Pa,
|
|
16914
|
+
handleFlatManagementLoaded: Ma,
|
|
16915
|
+
refreshList: ac,
|
|
16916
|
+
openFlatManagementRecord: Ra,
|
|
16917
|
+
resetFlatManagementSelection: wn,
|
|
16918
|
+
navigatorScopeUnavailableDescription: ei,
|
|
16919
|
+
detailWorkspaceAvailable: Xi,
|
|
16920
|
+
openDetailWorkspaceView: ec,
|
|
16921
|
+
flatManagementDetailActions: xa,
|
|
16922
|
+
handleFlatManagementAction: za,
|
|
16899
16923
|
editingRecord: N,
|
|
16900
16924
|
saving: Te,
|
|
16901
16925
|
detailActionBusy: st,
|
|
16902
16926
|
activeDetailActionKey: $e,
|
|
16903
16927
|
detailDirty: Ee,
|
|
16904
|
-
sessionDirty:
|
|
16905
|
-
updateDraftField:
|
|
16906
|
-
updateDraftFields:
|
|
16907
|
-
updateDraftReference:
|
|
16908
|
-
referenceDisplay:
|
|
16909
|
-
updateReferenceDisplay:
|
|
16910
|
-
showStatusSwitch:
|
|
16911
|
-
canToggleEnabled:
|
|
16912
|
-
toggleEnabledDisabledReason:
|
|
16928
|
+
sessionDirty: vr,
|
|
16929
|
+
updateDraftField: Io,
|
|
16930
|
+
updateDraftFields: Lo,
|
|
16931
|
+
updateDraftReference: Ro,
|
|
16932
|
+
referenceDisplay: Po,
|
|
16933
|
+
updateReferenceDisplay: Fo,
|
|
16934
|
+
showStatusSwitch: ma,
|
|
16935
|
+
canToggleEnabled: ha,
|
|
16936
|
+
toggleEnabledDisabledReason: ga,
|
|
16913
16937
|
togglingEnabled: Oe,
|
|
16914
|
-
toggleEnabled:
|
|
16915
|
-
detailEmptyDescription:
|
|
16938
|
+
toggleEnabled: Is,
|
|
16939
|
+
detailEmptyDescription: li,
|
|
16916
16940
|
detailLoading: ke,
|
|
16917
16941
|
detailLoadFailed: je,
|
|
16918
16942
|
rawContext: O,
|
|
16919
|
-
detailDisplayFields:
|
|
16920
|
-
formFields:
|
|
16943
|
+
detailDisplayFields: zt,
|
|
16944
|
+
formFields: Rt,
|
|
16921
16945
|
formSessionKey: De,
|
|
16922
16946
|
relationDrafts: s,
|
|
16923
16947
|
assistantContextRevision: Le,
|
|
@@ -16925,161 +16949,162 @@ function mg(e, n, r) {
|
|
|
16925
16949
|
listQueryController: Ve,
|
|
16926
16950
|
treeQueryController: Ue,
|
|
16927
16951
|
bindListQueryController: Ye,
|
|
16928
|
-
setDataExchangeBusy:
|
|
16952
|
+
setDataExchangeBusy: ic,
|
|
16929
16953
|
bindNavigatorQueryController: qe,
|
|
16930
16954
|
bindTreeQueryController: Xe,
|
|
16931
|
-
formValidationRequestKey:
|
|
16932
|
-
|
|
16933
|
-
|
|
16934
|
-
|
|
16935
|
-
|
|
16936
|
-
|
|
16937
|
-
|
|
16938
|
-
|
|
16939
|
-
|
|
16940
|
-
|
|
16941
|
-
|
|
16942
|
-
|
|
16943
|
-
|
|
16944
|
-
|
|
16945
|
-
|
|
16946
|
-
|
|
16947
|
-
|
|
16948
|
-
|
|
16949
|
-
|
|
16950
|
-
|
|
16951
|
-
|
|
16952
|
-
|
|
16953
|
-
|
|
16954
|
-
|
|
16955
|
-
|
|
16956
|
-
|
|
16957
|
-
|
|
16958
|
-
|
|
16959
|
-
|
|
16960
|
-
|
|
16961
|
-
|
|
16962
|
-
|
|
16963
|
-
|
|
16964
|
-
|
|
16965
|
-
|
|
16966
|
-
|
|
16967
|
-
|
|
16968
|
-
|
|
16969
|
-
|
|
16970
|
-
|
|
16971
|
-
|
|
16972
|
-
|
|
16973
|
-
|
|
16974
|
-
|
|
16975
|
-
|
|
16976
|
-
|
|
16977
|
-
|
|
16978
|
-
|
|
16979
|
-
|
|
16980
|
-
|
|
16981
|
-
|
|
16982
|
-
|
|
16983
|
-
|
|
16984
|
-
|
|
16985
|
-
|
|
16986
|
-
|
|
16987
|
-
|
|
16988
|
-
|
|
16989
|
-
|
|
16990
|
-
|
|
16991
|
-
|
|
16992
|
-
|
|
16993
|
-
|
|
16994
|
-
|
|
16995
|
-
|
|
16996
|
-
|
|
16997
|
-
|
|
16998
|
-
|
|
16999
|
-
|
|
17000
|
-
|
|
17001
|
-
|
|
17002
|
-
|
|
17003
|
-
|
|
17004
|
-
|
|
17005
|
-
|
|
17006
|
-
|
|
17007
|
-
|
|
17008
|
-
|
|
17009
|
-
|
|
17010
|
-
|
|
17011
|
-
|
|
16955
|
+
formValidationRequestKey: yt,
|
|
16956
|
+
mainFormPending: mt,
|
|
16957
|
+
recordSaveError: bt,
|
|
16958
|
+
referencePickerConfigs: Ta,
|
|
16959
|
+
runtimeUiDescriptor: Bt,
|
|
16960
|
+
executableDetailRelations: br,
|
|
16961
|
+
detailRelationsAvailable: Ca,
|
|
16962
|
+
detailRelationReloadKey: on,
|
|
16963
|
+
showDetailSystemInfo: Pr,
|
|
16964
|
+
enhancementDetailSections: Ui,
|
|
16965
|
+
detailSectionContext: sn,
|
|
16966
|
+
formContributions: vi,
|
|
16967
|
+
formFieldPolicies: yi,
|
|
16968
|
+
updateMainFormValidity: Et,
|
|
16969
|
+
updateEmbeddedChildren: Dt,
|
|
16970
|
+
updateRelationDraftValidity: kt,
|
|
16971
|
+
placedPageActions: ki,
|
|
16972
|
+
handlePlacedPageAction: Ws,
|
|
16973
|
+
createRootRecord: Ko,
|
|
16974
|
+
recordCreationState: qo,
|
|
16975
|
+
prepareAssistantCreate: Yo,
|
|
16976
|
+
prepareAssistantEdit: ds,
|
|
16977
|
+
prepareAssistantView: us,
|
|
16978
|
+
assistantNavigatorScopes: $o,
|
|
16979
|
+
assistantNavigatorCreationTargets: Xo,
|
|
16980
|
+
prepareAssistantNavigatorCreate: Zo,
|
|
16981
|
+
assistantNavigatorEditor: Qo,
|
|
16982
|
+
assistantNavigatorScopeRevision: es,
|
|
16983
|
+
applyAssistantNavigatorSelection: ts,
|
|
16984
|
+
settleAssistantPageState: ns,
|
|
16985
|
+
hasCardAssistantAt: Ji,
|
|
16986
|
+
enhancementCardAssistant: Ki,
|
|
16987
|
+
cardAssistantContext: qi,
|
|
16988
|
+
listDetailCardPage: Zi,
|
|
16989
|
+
detailSurfaceUsesDrawer: ti,
|
|
16990
|
+
visibleNavigatorLevels: Rr,
|
|
16991
|
+
listRowExpansionEnabled: Vi,
|
|
16992
|
+
modulePageTitle: ii,
|
|
16993
|
+
modulePageSubtitle: ai,
|
|
16994
|
+
expandedListRowKeys: Sr,
|
|
16995
|
+
reloadKey: vn,
|
|
16996
|
+
listMode: _n,
|
|
16997
|
+
standardCrudRowActionKeys: $i,
|
|
16998
|
+
enhancementActions: Si,
|
|
16999
|
+
enhancementColumns: Ci,
|
|
17000
|
+
enhancementCellComponents: wi,
|
|
17001
|
+
enhancementRowActionsFor: Ei,
|
|
17002
|
+
pageEnhancement: _i,
|
|
17003
|
+
enhancementBatchActions: Di,
|
|
17004
|
+
listUiConfigId: Ar,
|
|
17005
|
+
listQueryTemplateId: jr,
|
|
17006
|
+
listPageSize: In,
|
|
17007
|
+
persistentListQueryControls: zi,
|
|
17008
|
+
listQuerySummaries: Bi,
|
|
17009
|
+
navigatorListCriteriaKeys: ca,
|
|
17010
|
+
listSearchPlaceholder: si,
|
|
17011
|
+
listEmptyDescription: ci,
|
|
17012
|
+
handleLoaded: bn,
|
|
17013
|
+
handleListModeChange: Tn,
|
|
17014
|
+
setListPageSize: ja,
|
|
17015
|
+
handleRecycleBinRestore: J,
|
|
17016
|
+
selectListDetailRecord: Ha,
|
|
17017
|
+
openListRecord: Ua,
|
|
17018
|
+
handleListAction: Vs,
|
|
17019
|
+
handleRowAction: Gs,
|
|
17020
|
+
updateListRowExpansion: wr,
|
|
17021
|
+
handleBatchAction: $s,
|
|
17022
|
+
listRelationExpansions: xr,
|
|
17023
|
+
enhancementRowExpansion: Ri,
|
|
17024
|
+
listRowExpansionContext: Tr,
|
|
17025
|
+
useDrawerDetailSurface: Da,
|
|
17026
|
+
recycleBinDetailActive: Sa,
|
|
17027
|
+
enhancementDetailActions: Hi,
|
|
17028
|
+
detailPageActions: or,
|
|
17029
|
+
placedDetailButtons: Ii,
|
|
17030
|
+
placedFormActions: Pi,
|
|
17031
|
+
cancelDetailEditing: fc,
|
|
17032
|
+
canLeaveUnchangedEditor: pc,
|
|
17033
|
+
leaveUnchangedEditor: mc,
|
|
17034
|
+
saveRecord: Ds,
|
|
17035
|
+
checkRecordSave: Es,
|
|
17036
|
+
recordSaveNeedsCheck: xs,
|
|
17012
17037
|
recordSaveRecoveryError: rt,
|
|
17013
|
-
prepareAssistantSave:
|
|
17014
|
-
canReviewRecordDraft:
|
|
17015
|
-
reviewRecordDraft:
|
|
17016
|
-
prepareRecordDraftDiscard:
|
|
17017
|
-
assistantSaveAvailable:
|
|
17018
|
-
editRecord:
|
|
17019
|
-
deleteRecord:
|
|
17020
|
-
handleDetailAction:
|
|
17021
|
-
handlePlacedFormAction:
|
|
17022
|
-
treeManagementPage:
|
|
17023
|
-
treeModule:
|
|
17024
|
-
treePanelTitle:
|
|
17025
|
-
explorerRefreshAction:
|
|
17026
|
-
mainTreeScopeContext:
|
|
17027
|
-
recordFormScopeContext:
|
|
17028
|
-
treeSearchKeyword:
|
|
17038
|
+
prepareAssistantSave: Ps,
|
|
17039
|
+
canReviewRecordDraft: As,
|
|
17040
|
+
reviewRecordDraft: Ms,
|
|
17041
|
+
prepareRecordDraftDiscard: Ns,
|
|
17042
|
+
assistantSaveAvailable: ks,
|
|
17043
|
+
editRecord: os,
|
|
17044
|
+
deleteRecord: Fs,
|
|
17045
|
+
handleDetailAction: Ys,
|
|
17046
|
+
handlePlacedFormAction: Qs,
|
|
17047
|
+
treeManagementPage: Fr,
|
|
17048
|
+
treeModule: L,
|
|
17049
|
+
treePanelTitle: oi,
|
|
17050
|
+
explorerRefreshAction: Ai,
|
|
17051
|
+
mainTreeScopeContext: hi,
|
|
17052
|
+
recordFormScopeContext: mi,
|
|
17053
|
+
treeSearchKeyword: fn,
|
|
17029
17054
|
treeReloadKey: T,
|
|
17030
|
-
explorerExtraActions:
|
|
17031
|
-
mainTreeScopeReady:
|
|
17055
|
+
explorerExtraActions: Mi,
|
|
17056
|
+
mainTreeScopeReady: an,
|
|
17032
17057
|
mainTreeSorting: E,
|
|
17033
|
-
explorerCreateAction:
|
|
17034
|
-
treeRootTitle:
|
|
17058
|
+
explorerCreateAction: ji,
|
|
17059
|
+
treeRootTitle: gi,
|
|
17035
17060
|
selectedTreeRecord: D,
|
|
17036
|
-
mainTreeTitle:
|
|
17037
|
-
mainTreeSecondary:
|
|
17038
|
-
selectTreeRecord:
|
|
17039
|
-
clearTreeRecordSelection:
|
|
17040
|
-
handleTreeLoaded:
|
|
17041
|
-
handleTreeSorted:
|
|
17042
|
-
mainTreeScopeDescription:
|
|
17043
|
-
closeTreeCardEditor:
|
|
17044
|
-
createChildRecord:
|
|
17045
|
-
selectStandaloneListRecord:
|
|
17046
|
-
unsupportedPageModeText:
|
|
17047
|
-
workspaceElement:
|
|
17048
|
-
persistentTreeDetail:
|
|
17061
|
+
mainTreeTitle: Fa,
|
|
17062
|
+
mainTreeSecondary: Ia,
|
|
17063
|
+
selectTreeRecord: ko,
|
|
17064
|
+
clearTreeRecordSelection: Ao,
|
|
17065
|
+
handleTreeLoaded: Mo,
|
|
17066
|
+
handleTreeSorted: jo,
|
|
17067
|
+
mainTreeScopeDescription: ui,
|
|
17068
|
+
closeTreeCardEditor: hc,
|
|
17069
|
+
createChildRecord: is,
|
|
17070
|
+
selectStandaloneListRecord: Dn,
|
|
17071
|
+
unsupportedPageModeText: na,
|
|
17072
|
+
workspaceElement: Rn,
|
|
17073
|
+
persistentTreeDetail: Ir,
|
|
17049
17074
|
detailOpen: we,
|
|
17050
|
-
enhancementDetailDrawer:
|
|
17051
|
-
detailDrawerWidth:
|
|
17052
|
-
closeRecordOnlyDetail:
|
|
17053
|
-
closeDetail:
|
|
17054
|
-
confirmDetailDrawerClose:
|
|
17055
|
-
finishRecordOnlyDetailClose:
|
|
17056
|
-
retryLoadDetail:
|
|
17057
|
-
handleWorkflowChanged:
|
|
17058
|
-
recordViewContext:
|
|
17059
|
-
narrowDetailSurface:
|
|
17060
|
-
usePinnedDetailSurface:
|
|
17075
|
+
enhancementDetailDrawer: Wi,
|
|
17076
|
+
detailDrawerWidth: Gi,
|
|
17077
|
+
closeRecordOnlyDetail: uc,
|
|
17078
|
+
closeDetail: sc,
|
|
17079
|
+
confirmDetailDrawerClose: lc,
|
|
17080
|
+
finishRecordOnlyDetailClose: dc,
|
|
17081
|
+
retryLoadDetail: gc,
|
|
17082
|
+
handleWorkflowChanged: _c,
|
|
17083
|
+
recordViewContext: cn,
|
|
17084
|
+
narrowDetailSurface: Vr,
|
|
17085
|
+
usePinnedDetailSurface: Oa,
|
|
17061
17086
|
referenceRecordDetailBrowser: k,
|
|
17062
|
-
handleReferenceRecordChange:
|
|
17087
|
+
handleReferenceRecordChange: oc,
|
|
17063
17088
|
workflowInteraction: ct,
|
|
17064
17089
|
updateWorkflowInteraction: ut,
|
|
17065
17090
|
setWorkflowLeaveGuard: dt,
|
|
17066
17091
|
referenceRecordDetailInteraction: ft,
|
|
17067
|
-
updateReferenceRecordDetailInteraction:
|
|
17068
|
-
permissionsOpen:
|
|
17069
|
-
permissionsChanged:
|
|
17070
|
-
enhancementDrawer:
|
|
17071
|
-
enhancementDrawerOpen:
|
|
17072
|
-
closeEnhancementDrawer:
|
|
17073
|
-
disposeEnhancementDrawer:
|
|
17074
|
-
localEditOpen:
|
|
17075
|
-
localEditBlock:
|
|
17076
|
-
localEditSaving:
|
|
17077
|
-
submitLocalEdit:
|
|
17078
|
-
dismissLocalEdit:
|
|
17079
|
-
localEditDraft:
|
|
17080
|
-
localEditFields:
|
|
17081
|
-
updateLocalEditFormValidity:
|
|
17082
|
-
pageLayout:
|
|
17092
|
+
updateReferenceRecordDetailInteraction: yr,
|
|
17093
|
+
permissionsOpen: qs,
|
|
17094
|
+
permissionsChanged: Js,
|
|
17095
|
+
enhancementDrawer: W,
|
|
17096
|
+
enhancementDrawerOpen: G,
|
|
17097
|
+
closeEnhancementDrawer: un,
|
|
17098
|
+
disposeEnhancementDrawer: dn,
|
|
17099
|
+
localEditOpen: sr,
|
|
17100
|
+
localEditBlock: lr,
|
|
17101
|
+
localEditSaving: cr,
|
|
17102
|
+
submitLocalEdit: hr,
|
|
17103
|
+
dismissLocalEdit: mr,
|
|
17104
|
+
localEditDraft: ur,
|
|
17105
|
+
localEditFields: fr,
|
|
17106
|
+
updateLocalEditFormValidity: At,
|
|
17107
|
+
pageLayout: ra
|
|
17083
17108
|
};
|
|
17084
17109
|
}
|
|
17085
17110
|
//#endregion
|
|
@@ -19695,11 +19720,11 @@ var W_ = {
|
|
|
19695
19720
|
title: e.titleKey ? Z(n).t(e.titleKey, e.title) : e.title,
|
|
19696
19721
|
subtitle: e.subtitle
|
|
19697
19722
|
}, an({
|
|
19698
|
-
default: $(() => [(K(), B(
|
|
19723
|
+
default: $(() => [(K(), B(On(e.component), { context: Z(ee)(Z(u)) }, null, 8, ["context"]))]),
|
|
19699
19724
|
_: 2
|
|
19700
19725
|
}, [e.subtitleComponent ? {
|
|
19701
19726
|
name: "subtitle",
|
|
19702
|
-
fn: $(() => [(K(), B(
|
|
19727
|
+
fn: $(() => [(K(), B(On(e.subtitleComponent), { context: Z(ee)(Z(u)) }, null, 8, ["context"]))]),
|
|
19703
19728
|
key: "0"
|
|
19704
19729
|
} : void 0]), 1032, ["title", "subtitle"]))), 128))], 64)) : V("v-if", !0),
|
|
19705
19730
|
ce.value ? (K(), B(Z(v), {
|
|
@@ -19724,7 +19749,7 @@ var W_ = {
|
|
|
19724
19749
|
onClose: Z(O),
|
|
19725
19750
|
onAfterClose: Z(k)
|
|
19726
19751
|
}, an({
|
|
19727
|
-
default: $(() => [(K(), B(
|
|
19752
|
+
default: $(() => [(K(), B(On(Z(E).definition.component), { context: Z(E).context }, null, 8, ["context"]))]),
|
|
19728
19753
|
_: 2
|
|
19729
19754
|
}, [
|
|
19730
19755
|
Z(E).titleActions.length ? {
|
|
@@ -19875,7 +19900,7 @@ var uv = /* @__PURE__ */ sn({
|
|
|
19875
19900
|
close() {
|
|
19876
19901
|
o?.closePage(i);
|
|
19877
19902
|
}
|
|
19878
|
-
}), a({ registerUnsavedState: c }), Cn(() => s.forEach((e) => e())), (t, a) => r.value ? (K(), B(
|
|
19903
|
+
}), a({ registerUnsavedState: c }), Cn(() => s.forEach((e) => e())), (t, a) => r.value ? (K(), B(On(r.value.view.component), mn({ key: 0 }, r.value.input, {
|
|
19879
19904
|
title: Z(ue)(e.descriptor.title ?? r.value.view.titleOf(r.value.input), e.descriptor.titleText, Z(n)),
|
|
19880
19905
|
onCloseWorkspace: a[0] ||= (e) => Z(o)?.closePage(Z(i))
|
|
19881
19906
|
}), null, 16, ["title"])) : (K(), B(Z($t), {
|