@ximatai/muyun-web-app 0.26.18 → 0.26.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/dist/{BusinessActivityLogView-CNW817Sf.js → BusinessActivityLogView-BpcmlT8u.js} +2 -2
  2. package/dist/BusinessLogListDrawer-C3EteOgv.js +864 -0
  3. package/dist/CodeConfigurationView-CxqzINb9.js +1667 -0
  4. package/dist/{ConfigurationTranslationView-CbBt5s1q.js → ConfigurationTranslationView-QUeVtdcE.js} +37 -37
  5. package/dist/{LoginAuditLogView-CZF1Jfq_.js → LoginAuditLogView-Cd699_OD.js} +2 -2
  6. package/dist/ModuleActionManagementView-Ct1PqAXF.js +755 -0
  7. package/dist/{ModuleGovernanceView-CcwGyO3x.js → ModuleGovernanceView-CjKt6ryi.js} +2254 -2254
  8. package/dist/{RequestErrorLogView-DpudZrC2.js → RequestErrorLogView-B9sIOhWs.js} +2 -2
  9. package/dist/RoleDetailWorkspaceView-BnBL_Ihe.js +1435 -0
  10. package/dist/{RuntimeLogView-444BL_xs.js → RuntimeLogView-CjV223Pk.js} +70 -70
  11. package/dist/WorkflowAdministrationView-C2jgy4N4.js +650 -0
  12. package/dist/WorkflowConfigurationView-CNXwdgUP.js +980 -0
  13. package/dist/WorkflowWorkbenchView-DdJOTmtG.js +759 -0
  14. package/dist/{codeConfiguration-ChJ6ktRR.js → codeConfiguration-pvXI4qaR.js} +45 -45
  15. package/dist/index.css +1 -1
  16. package/dist/index.js +999 -627
  17. package/dist/{moduleMenuWorkspace-B8DKwC3L.js → moduleMenuWorkspace-D8ih_X-m.js} +204 -204
  18. package/dist/platform-components-DlKD3nyL.js +30676 -0
  19. package/dist/{platform-workbench-BhZPARiH.js → platform-workbench-D5w7Odpt.js} +5246 -5224
  20. package/dist/types/app/executeBusinessNotificationRecordAction.d.ts +7 -0
  21. package/dist/types/consumer/index.d.ts +8 -0
  22. package/dist/types/dynamic-page-runtime/ModulePageHostRuntime.vue.d.ts +3 -3
  23. package/dist/types/dynamic-page-runtime/composables/useModulePageDetailExtensionRuntime.d.ts +1 -0
  24. package/dist/types/dynamic-page-runtime/modulePageEnhancementState.d.ts +5 -0
  25. package/dist/types/dynamic-page-runtime/modulePageEnhancements.d.ts +4 -0
  26. package/dist/types/platform-admin-runtime/workflow/ModuleWorkflowDrawer.vue.d.ts +7 -0
  27. package/dist/types/platform-components/BusinessNotificationPanel.vue.d.ts +5 -3
  28. package/dist/types/platform-components/EmployeePicker.vue.d.ts +1 -1
  29. package/dist/types/platform-components/FormulaExpressionEditor.vue.d.ts +5 -0
  30. package/dist/types/platform-components/QueryCriteriaComposer.vue.d.ts +3 -1
  31. package/dist/types/platform-components/ReadonlyRecordWorkspace.vue.d.ts +56 -0
  32. package/dist/types/platform-components/RecordAdaptiveDetailPanel.vue.d.ts +30 -0
  33. package/dist/types/platform-components/RecordQueryControls.vue.d.ts +21 -0
  34. package/dist/types/platform-components/RecordQueryFieldControls.vue.d.ts +32 -0
  35. package/dist/types/platform-components/RecordQueryListPanel.vue.d.ts +1 -1
  36. package/dist/types/platform-components/RecordQueryListSurface.vue.d.ts +6 -2
  37. package/dist/types/platform-components/ReferencePicker.vue.d.ts +1 -1
  38. package/dist/types/platform-components/UserPicker.vue.d.ts +1 -1
  39. package/dist/types/platform-components/WorkflowBusinessTaskEditor.vue.d.ts +2 -0
  40. package/dist/types/platform-components/WorkflowDesignProperties.vue.d.ts +2 -6
  41. package/dist/types/platform-components/WorkflowDiagram.vue.d.ts +32 -1
  42. package/dist/types/platform-components/formulaExpressionTokens.d.ts +2 -0
  43. package/dist/types/platform-components/formulaExpressionTools.d.ts +6 -0
  44. package/dist/types/platform-components/index.d.ts +3 -0
  45. package/dist/types/platform-components/queryCriteria.d.ts +7 -0
  46. package/dist/types/platform-components/referencePickerModel.d.ts +5 -1
  47. package/dist/types/platform-components/useWorkflowDesignHistory.d.ts +14 -0
  48. package/dist/types/platform-components/useWorkspaceDetailSurface.d.ts +3 -0
  49. package/dist/types/platform-components/workflowDesignClipboard.d.ts +7 -0
  50. package/dist/types/platform-components/workflowPresentation.d.ts +4 -0
  51. package/dist/types/views/WorkflowConfigurationView.vue.d.ts +1 -0
  52. package/dist/types/views/WorkflowDefinitionSettings.vue.d.ts +35 -0
  53. package/dist/types/views/WorkflowSelectionFields.vue.d.ts +2 -4
  54. package/dist/types/views/useWorkflowConfigurationContext.d.ts +49 -0
  55. package/dist/types/views/workflowConfigurationWorkspaceView.d.ts +2 -0
  56. package/dist/types/vue-ui-antdv/components/UiIcon.vue.d.ts +1 -1
  57. package/dist/types/vue-ui-antdv/components/UiRadioGroup.vue.d.ts +4 -0
  58. package/dist/types/vue-ui-antdv/components/UiSidePanel.vue.d.ts +5 -0
  59. package/dist/types/vue-ui-antdv/index.d.ts +1 -0
  60. package/dist/types/vue-ui-antdv/overlayLayers.d.ts +5 -0
  61. package/dist/types/vue-ui-antdv/types.d.ts +2 -0
  62. package/dist/types/web-contracts/index.d.ts +7 -0
  63. package/dist/types/web-contracts/workflow.d.ts +16 -8
  64. package/dist/types/web-core/businessNotifications.d.ts +3 -1
  65. package/dist/types/web-core/index.d.ts +3 -0
  66. package/dist/types/web-core/recordReadEntry.d.ts +23 -0
  67. package/dist/types/web-core/recordReadView.d.ts +28 -0
  68. package/dist/types/web-core/useRecordReadSession.d.ts +27 -0
  69. package/dist/types/web-core/workflow.d.ts +13 -1
  70. package/dist/useWorkflowConfigurationContext-B6Wdt26l.js +66 -0
  71. package/dist/{workspaceViews-DeBqozVb.js → workspaceViews-B9wsCYdy.js} +1510 -930
  72. package/package.json +1 -1
  73. package/dist/BusinessLogListDrawer-YiJxOlnD.js +0 -864
  74. package/dist/CodeConfigurationView-DU8tjPMt.js +0 -1667
  75. package/dist/ModuleActionManagementView-CaiXH1l_.js +0 -755
  76. package/dist/RoleDetailWorkspaceView-DNMGsAJC.js +0 -1435
  77. package/dist/WorkflowAdministrationView-C-VIjvwB.js +0 -650
  78. package/dist/WorkflowConfigurationView-DLFY2x7V.js +0 -1110
  79. package/dist/WorkflowWorkbenchView-Gr02dbBc.js +0 -759
  80. package/dist/platform-components-5AE0j2_3.js +0 -29879
@@ -0,0 +1,35 @@
1
+ import type { useWorkflowConfigurationContext } from './useWorkflowConfigurationContext';
2
+ type __VLS_Props = {
3
+ configuration: ReturnType<typeof useWorkflowConfigurationContext>;
4
+ creating: boolean;
5
+ busy: boolean;
6
+ actionCodeLocked?: boolean;
7
+ };
8
+ type __VLS_ModelProps = {
9
+ 'title': string;
10
+ 'approvalEnabled': boolean;
11
+ 'actionCode': string;
12
+ 'organizationId': string;
13
+ 'matchExpression': string;
14
+ 'fallback': boolean;
15
+ };
16
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
17
+ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
18
+ submit: () => any;
19
+ "update:organizationId": (value: string) => any;
20
+ "update:matchExpression": (value: string) => any;
21
+ "update:fallback": (value: boolean) => any;
22
+ "update:title": (value: string) => any;
23
+ "update:approvalEnabled": (value: boolean) => any;
24
+ "update:actionCode": (value: string) => any;
25
+ }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
26
+ onSubmit?: (() => any) | undefined;
27
+ "onUpdate:organizationId"?: ((value: string) => any) | undefined;
28
+ "onUpdate:matchExpression"?: ((value: string) => any) | undefined;
29
+ "onUpdate:fallback"?: ((value: boolean) => any) | undefined;
30
+ "onUpdate:title"?: ((value: string) => any) | undefined;
31
+ "onUpdate:approvalEnabled"?: ((value: boolean) => any) | undefined;
32
+ "onUpdate:actionCode"?: ((value: string) => any) | undefined;
33
+ }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
34
+ declare const _default: typeof __VLS_export;
35
+ export default _default;
@@ -1,27 +1,25 @@
1
1
  import { type ModuleContext } from '../web-core/index';
2
+ import type { FormulaExpressionTools } from '../platform-components/formulaExpressionTools';
2
3
  import type { FormulaExpressionField } from '../platform-components/formulaExpressionTokens';
3
4
  type __VLS_Props = {
4
5
  organizationContext?: ModuleContext<Record<string, unknown>>;
5
6
  fields: readonly FormulaExpressionField[];
6
7
  disabled: boolean;
7
- invalidPriority: boolean;
8
+ conditionTools?: FormulaExpressionTools;
8
9
  };
9
10
  type __VLS_ModelProps = {
10
11
  'organizationId': string;
11
12
  'matchExpression': string;
12
- 'matchPriority': string;
13
13
  'fallback': boolean;
14
14
  };
15
15
  type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
16
16
  declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
17
17
  "update:organizationId": (value: string) => any;
18
18
  "update:matchExpression": (value: string) => any;
19
- "update:matchPriority": (value: string) => any;
20
19
  "update:fallback": (value: boolean) => any;
21
20
  }, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
22
21
  "onUpdate:organizationId"?: ((value: string) => any) | undefined;
23
22
  "onUpdate:matchExpression"?: ((value: string) => any) | undefined;
24
- "onUpdate:matchPriority"?: ((value: string) => any) | undefined;
25
23
  "onUpdate:fallback"?: ((value: boolean) => any) | undefined;
26
24
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
27
25
  declare const _default: typeof __VLS_export;
@@ -0,0 +1,49 @@
1
+ /** Shared module facts and formula assistance for definition management and design. */
2
+ export declare function useWorkflowConfigurationContext(moduleAlias: string): {
3
+ context: import("../web-core/index").ModuleContext<unknown>;
4
+ client: {
5
+ formulaFunctions: () => Promise<{
6
+ name: string;
7
+ title: string;
8
+ description: string;
9
+ example: string;
10
+ parameters: {
11
+ name: string;
12
+ description: string;
13
+ }[];
14
+ }[]>;
15
+ validateCondition: (expression: string) => Promise<void>;
16
+ sort: (id: string, targetId: string, position: -1 | 1) => Promise<unknown>;
17
+ catalog: (id: string) => Promise<import("../web-contracts").WorkflowConfigurationCatalog>;
18
+ query: () => Promise<import("../web-contracts").WorkflowDefinition[]>;
19
+ versions: (id: string) => Promise<import("../web-contracts").WorkflowVersion[]>;
20
+ create: (payload: import("../web-contracts").WorkflowDefinitionCreate) => Promise<import("../web-contracts").WorkflowDefinition>;
21
+ view: (id: string) => Promise<import("../web-contracts").WorkflowDefinition>;
22
+ upgrade: (id: string) => Promise<import("../web-contracts").WorkflowVersion>;
23
+ saveSelection: (id: string, payload: import("../web-contracts").WorkflowDefinitionSelection) => Promise<import("../web-contracts").WorkflowDefinition>;
24
+ design: (id: string, versionId: string) => Promise<import("../web-contracts").WorkflowDesign>;
25
+ saveDesign: (id: string, versionId: string, expectedVersion: number, design: import("../web-contracts").WorkflowDesign) => Promise<import("../web-contracts").WorkflowVersion>;
26
+ validate: (id: string, versionId: string) => Promise<unknown>;
27
+ publish: (id: string, versionId: string, definitionVersion: number, expectedVersion: number) => Promise<import("../web-contracts").WorkflowVersion>;
28
+ changeStatus: (id: string, action: "enable" | "disable" | "archive", expectedVersion: number) => Promise<import("../web-contracts").WorkflowDefinition>;
29
+ };
30
+ language: import("../web-core/index").LanguageContext;
31
+ businessRuntime: import("vue").ComputedRef<import("../web-core/index").ModuleRuntimeContext | undefined>;
32
+ fields: import("vue").ComputedRef<{
33
+ name: string;
34
+ label: string;
35
+ valueType: import("../web-contracts").ViewFieldValueType | undefined;
36
+ referenceModule: string | undefined;
37
+ }[]>;
38
+ organizationContext: import("vue").ComputedRef<import("../web-core/index").ModuleContext<Record<string, unknown>> | undefined>;
39
+ conditionTools: {
40
+ loadFunctions: () => Promise<{
41
+ name: string;
42
+ title: string;
43
+ description: string;
44
+ example: string;
45
+ signature: string;
46
+ }[]>;
47
+ validate: (expression: string) => Promise<void>;
48
+ };
49
+ };
@@ -1,5 +1,7 @@
1
1
  export interface WorkflowConfigurationInput {
2
2
  moduleAlias: string;
3
3
  moduleTitle?: string;
4
+ definitionId: string;
5
+ definitionTitle?: string;
4
6
  }
5
7
  export declare const workflowConfigurationWorkspaceView: import("../platform-workbench/workspaceViewContract.ts").WorkspaceViewDefinition<WorkflowConfigurationInput>;
@@ -1,4 +1,4 @@
1
- export type UiIconName = 'app' | 'language' | 'assistant' | 'check' | 'close' | 'delete' | 'download' | 'down' | 'up' | 'edit' | 'export' | 'eye' | 'eye-off' | 'filter' | 'help' | 'left' | 'lock' | 'menu-collapse' | 'menu-expand' | 'minus' | 'notification' | 'open-in-new' | 'plus' | 'pin-off' | 'pin' | 'power' | 'reload' | 'right' | 'save' | 'search' | 'skin' | 'settings' | 'swap' | 'swap-vertical' | 'user';
1
+ export type UiIconName = 'app' | 'fit-screen' | 'locate-start' | 'locate-end' | 'zoom-in' | 'zoom-out' | 'locate' | 'layout' | 'fullscreen' | 'fullscreen-exit' | 'language' | 'assistant' | 'check' | 'close' | 'delete' | 'download' | 'down' | 'up' | 'edit' | 'export' | 'eye' | 'eye-off' | 'filter' | 'help' | 'left' | 'lock' | 'menu-collapse' | 'menu-expand' | 'minus' | 'notification' | 'open-in-new' | 'plus' | 'pin-off' | 'pin' | 'power' | 'reload' | 'right' | 'save' | 'search' | 'skin' | 'settings' | 'swap' | 'swap-vertical' | 'user';
2
2
  type __VLS_Props = {
3
3
  name: UiIconName;
4
4
  };
@@ -2,12 +2,16 @@ export interface UiRadioOption {
2
2
  value: string;
3
3
  label: string;
4
4
  disabled?: boolean;
5
+ description?: string;
6
+ /** Optional categorical accent for card borders; accepts a CSS color or theme variable. */
7
+ color?: string;
5
8
  }
6
9
  type __VLS_Props = {
7
10
  value?: string;
8
11
  options: readonly UiRadioOption[];
9
12
  disabled?: boolean;
10
13
  size?: 'small' | 'default' | 'large';
14
+ appearance?: 'buttons' | 'cards';
11
15
  };
12
16
  declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
13
17
  "update:value": (value: string) => any;
@@ -3,6 +3,9 @@ import { type UiDrawerCloseGuard, type UiDrawerDismissal } from '../drawerDismis
3
3
  import { type UiSidePanelScope } from './sidePanelHost';
4
4
  type __VLS_Props = {
5
5
  open: boolean;
6
+ /** Keep a transfer target mounted when an adaptive detail surface is docked. */
7
+ forceRender?: boolean;
8
+ autofocus?: boolean;
6
9
  /** Inline surfaces stay in their owning workspace. */
7
10
  renderMode?: 'inline' | 'portal';
8
11
  width?: UiDrawerWidth;
@@ -25,6 +28,8 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {}, {}, {},
25
28
  }>, {
26
29
  scope: UiSidePanelScope;
27
30
  width: UiDrawerWidth;
31
+ autofocus: boolean;
32
+ forceRender: boolean;
28
33
  renderMode: "inline" | "portal";
29
34
  dismissal: UiDrawerDismissal;
30
35
  closeOnOutside: boolean;
@@ -36,6 +36,7 @@ export { default as DictionarySelect } from './components/DictionarySelect.vue';
36
36
  export { default as ReferenceSelect } from './components/ReferenceSelect.vue';
37
37
  export { default as UiTable } from './components/UiTable.vue';
38
38
  export { confirmAction } from './confirm';
39
+ export { uiOverlayLayers } from './overlayLayers';
39
40
  export { allowsUiDrawerOutsideDismissal, mayCloseUiDrawer, resolveUiDrawerDismissal, } from './drawerDismissal';
40
41
  export type { UiDrawerCloseGuard, UiDrawerCloseReason, UiDrawerDismissal, UiDrawerDismissalOptions, } from './drawerDismissal';
41
42
  export { showErrorMessage, showFeedback, showInfoMessage, showSuccessMessage, showWarningMessage, } from './feedback';
@@ -0,0 +1,5 @@
1
+ /** Notifications remain above page overlays; their own confirmations must remain actionable. */
2
+ export declare const uiOverlayLayers: {
3
+ readonly notification: 1200;
4
+ readonly notificationConfirmation: 1210;
5
+ };
@@ -123,6 +123,8 @@ export interface UiTreeDropEvent {
123
123
  }
124
124
  export type UiTreeChangeReason = 'interaction' | 'filter' | 'reset';
125
125
  export interface UiConfirmOptions {
126
+ /** Use the notification layer when the confirmation originates from a persistent notification. */
127
+ layer?: 'standard' | 'notification';
126
128
  title: string;
127
129
  content?: string;
128
130
  details?: {
@@ -126,6 +126,10 @@ export interface WebBusinessNotification {
126
126
  content: string;
127
127
  dismissible: boolean;
128
128
  actions: WebBusinessNotificationAction[];
129
+ /** Persistent cards remain above ordinary overlays and outside the collapsible queue. */
130
+ displayPolicy?: 'standard' | 'persistent';
131
+ /** Optional absolute action deadline, in ISO-8601 format. */
132
+ expiresAt?: string;
129
133
  /** Optional standard card accent. Omit it to use the neutral platform presentation. */
130
134
  tone?: WebBusinessNotificationTone;
131
135
  /** The business fact's occurrence time, displayed in the workbench time zone when supplied. */
@@ -546,6 +550,9 @@ export interface PageDescriptorBase<TPageType extends PageType, TOpenMode extend
546
550
  restoreState?: TabRestoreState;
547
551
  }
548
552
  export interface RoutePageTarget {
553
+ /** Preserved module-menu presentation defaults for a custom business page. */
554
+ defaultUiConfigId?: string;
555
+ defaultQueryTemplateId?: string;
549
556
  route?: string;
550
557
  routeName?: string;
551
558
  pageKey?: string;
@@ -3,14 +3,16 @@ import type { TextPresentation } from './index';
3
3
  export interface WorkflowDefinition {
4
4
  id: string;
5
5
  version: number;
6
- alias: string;
6
+ alias?: string | null;
7
+ actionCode?: string | null;
7
8
  title?: string;
8
9
  definitionStatus: string;
9
10
  currentVersionNo?: number;
10
11
  approvalEnabled: boolean;
11
12
  organizationId?: string;
12
13
  matchExpression?: string;
13
- matchPriority?: number;
14
+ sortOrder?: number;
15
+ tenantId?: string;
14
16
  defaultDefinition?: boolean;
15
17
  }
16
18
  export interface WorkflowVersion {
@@ -151,8 +153,9 @@ export interface WorkflowStatus {
151
153
  errorMessage?: string;
152
154
  errorMessageText?: TextPresentation;
153
155
  definition?: {
156
+ definitionId?: string;
154
157
  definitionTitle?: string;
155
- definitionAlias?: string;
158
+ definitionAlias?: string | null;
156
159
  };
157
160
  }
158
161
  export interface WorkflowRenderBundle {
@@ -290,18 +293,23 @@ export interface WorkflowConfigurationCatalog {
290
293
  }[];
291
294
  }
292
295
  export interface WorkflowDefinitionSelection {
296
+ actionCode?: string;
293
297
  version: number;
294
298
  title: string;
295
299
  organizationId: string | null;
296
300
  matchExpression: string | null;
297
- matchPriority: number;
298
301
  defaultDefinition: boolean;
299
302
  }
300
- export interface WorkflowDefinitionCreate extends Omit<WorkflowDefinitionSelection, 'version'> {
301
- alias: string;
302
- approvalEnabled: boolean;
303
+ export type WorkflowDefinitionCreate = Omit<WorkflowDefinitionSelection, 'version' | 'actionCode'> & {
304
+ alias?: string | null;
303
305
  enabled: boolean;
304
- }
306
+ } & ({
307
+ approvalEnabled: true;
308
+ actionCode?: string;
309
+ } | {
310
+ approvalEnabled: false;
311
+ actionCode: string;
312
+ });
305
313
  export interface WorkflowAdminInstance {
306
314
  instanceId: string;
307
315
  moduleAlias: string;
@@ -1,4 +1,6 @@
1
- import type { WebBusinessNotificationRecordAction } from '../web-contracts/index';
1
+ import type { WebBusinessNotification, WebBusinessNotificationRecordAction } from '../web-contracts/index';
2
2
  import type { HttpClient } from './http';
3
3
  /** Calls the standard record action declared by a notification. */
4
4
  export declare function invokeBusinessNotificationRecordAction(http: HttpClient, action: WebBusinessNotificationRecordAction): Promise<unknown>;
5
+ /** Invalid supplied deadlines fail closed; an omitted deadline preserves legacy actions. */
6
+ export declare function businessNotificationExpired(notification: Pick<WebBusinessNotification, 'expiresAt'>, now?: number): boolean;
@@ -33,3 +33,6 @@ export * from './useBusinessContentGenerationBatch';
33
33
  export * from './useBusinessContentReading';
34
34
  export * from './businessContentLanguage';
35
35
  export * from './recordReadRefreshGuard';
36
+ export * from './recordReadView';
37
+ export * from './useRecordReadSession';
38
+ export * from './recordReadEntry';
@@ -0,0 +1,23 @@
1
+ import type { PageDescriptor } from '../web-contracts/index';
2
+ export interface RecordReadEntry {
3
+ moduleAlias: string;
4
+ viewCode: string;
5
+ menuId?: string;
6
+ /** Presentation/default-query hints only; the server resolves these again from a visible menu. */
7
+ params: Readonly<Record<string, unknown>>;
8
+ defaultUiConfigId?: string;
9
+ defaultQueryTemplateId?: string;
10
+ }
11
+ /**
12
+ * Resolves a business-owned named read view from the existing workbench descriptor.
13
+ * This is presentation selection, never authorization. Pass menuId to the ordinary authenticated
14
+ * transport as X-MuYun-Menu-Id; MenuEntryRequestContext validates the visible menu server-side.
15
+ * Direct links must explicitly declare their default view or be rejected by omitting it.
16
+ */
17
+ export declare function resolveRecordReadEntry(options: {
18
+ moduleAlias: string;
19
+ viewCodes: readonly string[];
20
+ page?: PageDescriptor;
21
+ directViewCode?: string;
22
+ defaultViewCode?: string;
23
+ }): RecordReadEntry;
@@ -0,0 +1,28 @@
1
+ import type { QuerySchema, ResolvedModuleUiDescriptor, WebPageResponse, WebQueryRequest } from '../web-contracts/index';
2
+ export interface RecordReadRequestOptions {
3
+ signal: AbortSignal;
4
+ contentLanguage?: string;
5
+ }
6
+ /**
7
+ * A business-owned, authorized read projection. It declares no write capability and needs no
8
+ * entity table or ModuleContext. Query merging, stable ordering and pagination belong to the server.
9
+ */
10
+ export interface RecordReadView<TRecord extends Record<string, unknown> = Record<string, unknown>> {
11
+ sourceId: string;
12
+ viewCode: string;
13
+ /** Change on authentication, tenant or authorization/range changes; this key grants no access. */
14
+ scopeKey: string;
15
+ descriptor: ResolvedModuleUiDescriptor;
16
+ /** Authorized query capabilities; absent for legacy adapters that only support quick search. */
17
+ querySchema?: QuerySchema;
18
+ /** Stable within this source, including the origin when multiple sources share record IDs. */
19
+ recordKey(record: TRecord): string;
20
+ query(request: WebQueryRequest, options: RecordReadRequestOptions): Promise<WebPageResponse<TRecord>>;
21
+ /** Reauthorize detail reads on the server. Omit when this projection has no detail surface. */
22
+ detail?: {
23
+ load(record: TRecord, options: RecordReadRequestOptions): Promise<Record<string, unknown>>;
24
+ title(record: TRecord): string;
25
+ };
26
+ }
27
+ /** User-adjustable query input, never an authorization or mandatory business-scope declaration. */
28
+ export type RecordReadQuery = Omit<WebQueryRequest, 'page' | 'quickSearch' | 'unpaged'>;
@@ -0,0 +1,27 @@
1
+ import { type MaybeRefOrGetter } from 'vue';
2
+ import type { WebPageResponse } from '../web-contracts/index';
3
+ import type { RecordReadQuery, RecordReadView } from './recordReadView';
4
+ /** One mounted view session; no cross-view or cross-principal cache of authorized results. */
5
+ export declare function useRecordReadSession<TRecord extends Record<string, unknown>>(options: {
6
+ view: MaybeRefOrGetter<RecordReadView<TRecord>>;
7
+ query?: MaybeRefOrGetter<RecordReadQuery | undefined>;
8
+ pageSize?: number;
9
+ contentLanguage?: MaybeRefOrGetter<string | undefined>;
10
+ }): {
11
+ result: import("vue").ShallowRef<WebPageResponse<TRecord> | undefined, WebPageResponse<TRecord> | undefined>;
12
+ loading: import("vue").Ref<boolean, boolean>;
13
+ error: import("vue").ShallowRef<unknown, unknown>;
14
+ pageNum: import("vue").Ref<number, number>;
15
+ pageSize: import("vue").Ref<number, number>;
16
+ quickSearch: import("vue").Ref<string, string>;
17
+ selected: import("vue").ShallowRef<TRecord | undefined, TRecord | undefined>;
18
+ detail: import("vue").ShallowRef<Record<string, unknown> | undefined, Record<string, unknown> | undefined>;
19
+ detailLoading: import("vue").Ref<boolean, boolean>;
20
+ detailError: import("vue").ShallowRef<unknown, unknown>;
21
+ refresh: () => Promise<void>;
22
+ search: (keyword: string) => Promise<void>;
23
+ goPage: (value: number) => Promise<void>;
24
+ resizePage: (value: number) => Promise<void>;
25
+ select: (record: TRecord) => Promise<void>;
26
+ closeDetail: () => void;
27
+ };
@@ -47,6 +47,18 @@ export declare function createWorkflowClient(http: HttpClient): {
47
47
  };
48
48
  /** Definition commands are scoped to the owning business module. */
49
49
  export declare function createWorkflowDefinitionClient(http: HttpClient, moduleAlias: string): {
50
+ formulaFunctions: () => Promise<{
51
+ name: string;
52
+ title: string;
53
+ description: string;
54
+ example: string;
55
+ parameters: {
56
+ name: string;
57
+ description: string;
58
+ }[];
59
+ }[]>;
60
+ validateCondition: (expression: string) => Promise<void>;
61
+ sort: (id: string, targetId: string, position: -1 | 1) => Promise<unknown>;
50
62
  catalog: (id: string) => Promise<WorkflowConfigurationCatalog>;
51
63
  query: () => Promise<WorkflowDefinition[]>;
52
64
  versions: (id: string) => Promise<WorkflowVersion[]>;
@@ -58,7 +70,7 @@ export declare function createWorkflowDefinitionClient(http: HttpClient, moduleA
58
70
  saveDesign: (id: string, versionId: string, expectedVersion: number, design: WorkflowDesign) => Promise<WorkflowVersion>;
59
71
  validate: (id: string, versionId: string) => Promise<unknown>;
60
72
  publish: (id: string, versionId: string, definitionVersion: number, expectedVersion: number) => Promise<WorkflowVersion>;
61
- changeStatus: (id: string, action: "disable" | "archive", expectedVersion: number) => Promise<WorkflowDefinition>;
73
+ changeStatus: (id: string, action: "enable" | "disable" | "archive", expectedVersion: number) => Promise<WorkflowDefinition>;
62
74
  };
63
75
  /** Management projections and commands keep their separate authorization boundary. */
64
76
  export declare function createWorkflowAdminClient(http: HttpClient): {
@@ -0,0 +1,66 @@
1
+ import { E as e, y as t } from "./platform-workbench-D5w7Odpt.js";
2
+ import { Pr as n, Wr as r, Xa as i, Xr as a, _n as o, qr as s, zt as c } from "./platform-components-DlKD3nyL.js";
3
+ import { computed as l, onMounted as u } from "vue";
4
+ //#region src/views/useWorkflowConfigurationContext.ts
5
+ function d(d) {
6
+ let f = i(), p = s({ moduleAlias: "platform.workflow.definition" }), m = n(p.http, d), h = {
7
+ loadFunctions: async () => (await m.formulaFunctions()).map((e) => ({
8
+ name: e.name,
9
+ title: e.title,
10
+ description: e.description,
11
+ example: e.example,
12
+ signature: `${e.name}(${e.parameters.map((e) => e.name).join(", ")})`
13
+ })),
14
+ validate: (e) => m.validateCondition(e)
15
+ }, g = r({
16
+ http: p.http,
17
+ language: f,
18
+ moduleAlias: d,
19
+ runtimeAccess: "VIEW"
20
+ }), _ = t(), v = l(() => _?.value?.tenantId ? r({
21
+ http: p.http,
22
+ language: f,
23
+ moduleAlias: "iam.organization",
24
+ runtimeAccess: "REFERENCE"
25
+ }) : void 0);
26
+ e({
27
+ moduleAlias: d,
28
+ predicate: (e) => e.type === "configuration-translations-changed",
29
+ handler: async () => {
30
+ try {
31
+ await g.runtime.refreshTexts?.();
32
+ } catch (e) {
33
+ o(e, {
34
+ source: "workflow-design",
35
+ phase: "load"
36
+ });
37
+ }
38
+ }
39
+ });
40
+ let y = l(() => a(g.runtime)), b = l(() => [...c(y.value?.uiDescriptor)].map(([e, t]) => ({
41
+ name: e,
42
+ label: t.label ?? e,
43
+ valueType: t.valueType,
44
+ referenceModule: t.reference?.targetModuleAlias
45
+ })));
46
+ return u(async () => {
47
+ try {
48
+ await g.runtime.ready;
49
+ } catch (e) {
50
+ o(e, {
51
+ source: "workflow-design",
52
+ phase: "load"
53
+ });
54
+ }
55
+ }), {
56
+ context: p,
57
+ client: m,
58
+ language: f,
59
+ businessRuntime: y,
60
+ fields: b,
61
+ organizationContext: v,
62
+ conditionTools: h
63
+ };
64
+ }
65
+ //#endregion
66
+ export { d as t };