@acorex/connectivity 21.0.0-next.56 → 21.0.0-next.59

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 (19) hide show
  1. package/fesm2022/{acorex-connectivity-mock-acorex-connectivity-mock-DjTpf9Cv.mjs → acorex-connectivity-mock-acorex-connectivity-mock-SjZSega-.mjs} +985 -642
  2. package/fesm2022/acorex-connectivity-mock-acorex-connectivity-mock-SjZSega-.mjs.map +1 -0
  3. package/fesm2022/{acorex-connectivity-mock-assign-to-manager.activity-DZKQcO6f.mjs → acorex-connectivity-mock-assign-to-manager.activity-BF9U-Hd6.mjs} +2 -2
  4. package/fesm2022/{acorex-connectivity-mock-assign-to-manager.activity-DZKQcO6f.mjs.map → acorex-connectivity-mock-assign-to-manager.activity-BF9U-Hd6.mjs.map} +1 -1
  5. package/fesm2022/{acorex-connectivity-mock-chat-generate-image.command-CtQaCk3Y.mjs → acorex-connectivity-mock-chat-generate-image.command-DhNpfDnJ.mjs} +2 -2
  6. package/fesm2022/{acorex-connectivity-mock-chat-generate-image.command-CtQaCk3Y.mjs.map → acorex-connectivity-mock-chat-generate-image.command-DhNpfDnJ.mjs.map} +1 -1
  7. package/fesm2022/{acorex-connectivity-mock-chat-synthesize-speech.command-DqsIX8B8.mjs → acorex-connectivity-mock-chat-synthesize-speech.command-Bz-zOFK0.mjs} +2 -2
  8. package/fesm2022/{acorex-connectivity-mock-chat-synthesize-speech.command-DqsIX8B8.mjs.map → acorex-connectivity-mock-chat-synthesize-speech.command-Bz-zOFK0.mjs.map} +1 -1
  9. package/fesm2022/{acorex-connectivity-mock-chat-transcribe-speech.command-B59uD75x.mjs → acorex-connectivity-mock-chat-transcribe-speech.command-frk47mU7.mjs} +2 -2
  10. package/fesm2022/{acorex-connectivity-mock-chat-transcribe-speech.command-B59uD75x.mjs.map → acorex-connectivity-mock-chat-transcribe-speech.command-frk47mU7.mjs.map} +1 -1
  11. package/fesm2022/{acorex-connectivity-mock-entity-create.activity-Ca19tIj4.mjs → acorex-connectivity-mock-entity-create.activity-CdoUzUvF.mjs} +10 -3
  12. package/fesm2022/acorex-connectivity-mock-entity-create.activity-CdoUzUvF.mjs.map +1 -0
  13. package/fesm2022/{acorex-connectivity-mock-user-roles-for-list-column.query-vEJew9Py.mjs → acorex-connectivity-mock-user-roles-for-list-column.query-CAhDQnWv.mjs} +2 -2
  14. package/fesm2022/{acorex-connectivity-mock-user-roles-for-list-column.query-vEJew9Py.mjs.map → acorex-connectivity-mock-user-roles-for-list-column.query-CAhDQnWv.mjs.map} +1 -1
  15. package/fesm2022/acorex-connectivity-mock.mjs +1 -1
  16. package/package.json +2 -2
  17. package/types/acorex-connectivity-mock.d.ts +51 -24
  18. package/fesm2022/acorex-connectivity-mock-acorex-connectivity-mock-DjTpf9Cv.mjs.map +0 -1
  19. package/fesm2022/acorex-connectivity-mock-entity-create.activity-Ca19tIj4.mjs.map +0 -1
@@ -3,7 +3,7 @@ import * as i2$2 from '@acorex/platform/auth';
3
3
  import { AXPSessionService, AXP_PERMISSION_DEFINITION_PROVIDER, AXPPermissionDefinitionService, AXP_APPLICATION_LOADER, AXP_FEATURE_LOADER, AXP_PERMISSION_LOADER, AXP_TENANT_LOADER, AXP_PERMISSION_CHECKER, AXP_FEATURE_CHECKER, AXPLoginChallengeComponentBase, AXPLoginChallengeProvider, AXPAuthStrategy, AXPAuthModule, AXP_LOGIN_CHALLENGE_PROVIDER } from '@acorex/platform/auth';
4
4
  import * as i1 from '@acorex/platform/core';
5
5
  import { AXPDataGenerator, AXP_DISTRIBUTED_EVENT_LISTENER_PROVIDER, AXPIconLogoConfig, AXPModuleManifestRegistry, AXPActivityLogProvider, AXP_ACTIVITY_LOG_PROVIDER, AXP_DATASOURCE_DEFINITION_PROVIDER, AXPDataSourceDefinitionProviderService, AXPPlatformScope, AXPExpressionEvaluatorService, provideLazyProvider } from '@acorex/platform/core';
6
- import { runEntityQuery, filterSortEntityRows, computeEntityAggregates, AXP_ENTITY_STORAGE_BACKEND, AXPEntityStorageService, isAXPMiddlewareAbortError, AXPEntityResolver, collectEntityQuickSearchFieldPaths, AXP_ENTITY_DEFINITION_CRUD_SERVICE, AXPEntityService, AXP_ENTITY_DEFINITION_LOADER, axpCreateEntityAiToolInputDefaults, AXPMiddlewareAbortError, AXP_DATA_SEEDER_TOKEN, AXP_ENTITY_STORAGE_MIDDLEWARE, AXPEntityDefinitionRegistryService, eventDispatchMiddleware, AXPDataSeederService } from '@acorex/platform/layout/entity';
6
+ import { runEntityQuery, filterSortEntityRows, computeEntityAggregates, AXP_ENTITY_STORAGE_BACKEND, AXPEntityStorageService, isAXPMiddlewareAbortError, AXPEntityResolver, collectEntityQuickSearchFieldPaths, AXP_ENTITY_DEFINITION_CRUD_SERVICE, AXPEntityService, AXP_ENTITY_DEFINITION_LOADER, axpCreateEntityAiToolInputDefaults, AXPMiddlewareAbortError, AXP_DATA_SEEDER_TOKEN, AXP_ENTITY_STORAGE_MIDDLEWARE, AXPEntityDefinitionRegistryService, eventDispatchMiddleware, buildAXPRecordWorkflowInfo, AXPDataSeederService } from '@acorex/platform/layout/entity';
7
7
  import * as i0 from '@angular/core';
8
8
  import { InjectionToken, inject, Injectable, NgModule, isDevMode, Injector, Inject, signal, Component } from '@angular/core';
9
9
  import { AXP_MENU_PROVIDER, AXPFileStorageService, AXPSettingsService, AXPSystemStatusType, AXPAppVersionService, AXPFileStorageStatus, AXVChangeType as AXVChangeType$1, AXP_SEARCH_PROVIDER, AXPLockService, AXPVersioningService, AXPSystemStatuses, AXPStatusDefinitionProviderService } from '@acorex/platform/common';
@@ -27,12 +27,12 @@ import { AXMDataManagementFeatureKeys, AXMPermissionsKeys as AXMPermissionsKeys$
27
27
  import { AXPHumanCapitalManagementFeatureKeys, AXMPermissionsKeys as AXMPermissionsKeys$6, RootConfig as RootConfig$j, AXM_POSITION_ASSIGNMENT_OVERLAPPING_STATUS_IDS } from '@acorex/modules/human-capital-management';
28
28
  import { RootConfig as RootConfig$5 } from '@acorex/modules/locale-management';
29
29
  import { AXMPermissionsKeys as AXMPermissionsKeys$1, AXMSubscriptionManagementSubscriptionEntityService, AXMSubscriptionManagementSubscriptionPlanItemEntityService, RootConfig as RootConfig$x } from '@acorex/modules/subscription-management';
30
- import { AXPSecurityManagementPermissionKeys, AXMUserAccessState, resolveAXMUserEffectiveState, RootConfig as RootConfig$6, AXMUsersEntityService, AXMPolicyService } from '@acorex/modules/security-management';
31
- import { AXMTenantManagementPermissionsKeys, AXMTenantService, AXMTenantManagementTenantUserEntityService, RootConfig as RootConfig$A } from '@acorex/modules/tenant-management';
30
+ import { AXPSecurityManagementPermissionKeys, AXMUserAccessState, resolveAXMUserEffectiveState, RootConfig as RootConfig$6, AXMPolicyService } from '@acorex/modules/security-management';
31
+ import { AXMTenantManagementPermissionsKeys, AXMTenantService, AXMTenantManagementTenantUserEntityService, RootConfig as RootConfig$y } from '@acorex/modules/tenant-management';
32
32
  import { AXMPermissionsKeys as AXMPermissionsKeys$5, RootConfig as RootConfig$e, AXMDocumentTypeServiceImpl, AXPDocumentManagementService } from '@acorex/modules/document-management';
33
33
  import { AXMSettingsManagementPermissionKeys } from '@acorex/modules/settings-management';
34
- import { AXMPermissionsKeys as AXMPermissionsKeys$3, RootConfig as RootConfig$z, AXPWorkflowTaskProvider, matchesTaskBoardAssigneeFilter } from '@acorex/modules/task-management';
35
- import { AXMPermissionsKeys as AXMPermissionsKeys$4, AXMChatConversationApi, AXMChatMessageApi, axmAssistFollowUpItemsFromUnknown, axmAssistUserFacingPayloadLine, axmBuildAssistTranscriptLinePayload, AXM_ASSIST_TRANSCRIPT_LINE_PAYLOAD_TYPE, AXMChatRealtimeApi, AXMChatUserApi, axmIsAssistPeerParticipant, AXMChatManagementService, AXMChatRealtimeService, AXMCommentManagementService, AXMCommentRealtimeService, RootConfig as RootConfig$a } from '@acorex/modules/conversation';
34
+ import { AXMPermissionsKeys as AXMPermissionsKeys$3, RootConfig as RootConfig$A, AXPWorkflowTaskProvider, matchesTaskBoardAssigneeFilter } from '@acorex/modules/task-management';
35
+ import { AXMPermissionsKeys as AXMPermissionsKeys$4, AXMChatConversationApi, AXMChatMessageApi, axmAssistFollowUpItemsFromUnknown, axmAssistUserFacingPayloadLine, axmBuildAssistTranscriptLinePayload, AXM_ASSIST_TRANSCRIPT_LINE_PAYLOAD_TYPE, AXMChatRealtimeApi, AXMChatUserApi, axmIsAssistPeerParticipant, RootConfig as RootConfig$a } from '@acorex/modules/conversation';
36
36
  import { RootConfig as RootConfig$7 } from '@acorex/modules/business-core';
37
37
  import { RootConfig as RootConfig$8 } from '@acorex/modules/calendar-management';
38
38
  import { AXFileService } from '@acorex/core/file';
@@ -40,7 +40,7 @@ import { RootConfig as RootConfig$9, resolveTextTemplateLocalizedString, replace
40
40
  import { conversationSharedStorage, axConversationIndexedDbStorage, AXConversationAiResponderService } from '@acorex/components/conversation2';
41
41
  import { AXMNotificationEntityService, RootConfig as RootConfig$q, AXMNotificationEntityServiceImpl, AXMNotificationRealtimeService, NOTIFICATION_MANAGEMENT_EMAIL_SEND_COMMAND_KEY } from '@acorex/modules/notification-management';
42
42
  import { AXToastService } from '@acorex/components/toast';
43
- import { Observable, filter, pairwise, map, merge, take, throttleTime } from 'rxjs';
43
+ import { Observable, filter, pairwise, map, merge } from 'rxjs';
44
44
  import { RootConfig as RootConfig$b } from '@acorex/modules/customer-management';
45
45
  import { RootConfig as RootConfig$c } from '@acorex/modules/dashboard-management';
46
46
  import { AXDataSource } from '@acorex/cdk/common';
@@ -78,7 +78,7 @@ import { RootConfig as RootConfig$v } from '@acorex/modules/project-management';
78
78
  import { RootConfig as RootConfig$w } from '@acorex/modules/reservation-management';
79
79
  import { AXMSessionStatusTypes, AXMDeviceSessionsServiceImpl, AXMDeviceSessionsService, AXM_AUTH_CONFIG_TOKEN } from '@acorex/modules/auth';
80
80
  import * as i1$3 from '@acorex/components/dialog';
81
- import { RootConfig as RootConfig$y } from '@acorex/modules/supplier-management';
81
+ import { RootConfig as RootConfig$z } from '@acorex/modules/supplier-management';
82
82
  import { AXPLayoutBuilderService } from '@acorex/platform/layout/builder';
83
83
  import { Router } from '@angular/router';
84
84
  import { AXPWorkflowManager, AXPWorkflowDefinitionService, AXPActivityDefinitionService, AXP_WORKFLOW_PROVIDER, WorkflowExpressionScopeService, AXPWorkflowEngineError, AXP_WORKFLOW_ERROR_CODES, AXP_WORKFLOW_ENGINE } from '@acorex/platform/workflow';
@@ -4869,6 +4869,7 @@ function createDefaultContactEmergencyMenuDefinition() {
4869
4869
  icon: 'fa-light fa-siren',
4870
4870
  priority: 20,
4871
4871
  entityListRef: { module: 'ContactCore', entity: 'EmergencyService' },
4872
+ policyFeatures: ['ContactCore'],
4872
4873
  policyPermissions: ['ContactCore:Permission:EmergencyService.Management'],
4873
4874
  categoryIds: ['ContactCore'],
4874
4875
  categories: [{ id: 'ContactCore', title: 'Contact Core' }],
@@ -4914,6 +4915,17 @@ async function ensureDefaultMenuDefinitionsSeeded(crud) {
4914
4915
  const existing = await crud.getMenu(id);
4915
4916
  if (!existing) {
4916
4917
  await crud.createMenu(id, factory());
4918
+ continue;
4919
+ }
4920
+ if (id === DEFAULT_CONTACT_EMERGENCY_MENU_ID) {
4921
+ const expected = factory();
4922
+ const hasFeaturePolicy = existing.policyFeatures?.includes('ContactCore');
4923
+ if (!hasFeaturePolicy) {
4924
+ await crud.updateMenu(id, {
4925
+ ...existing,
4926
+ policyFeatures: expected.policyFeatures,
4927
+ });
4928
+ }
4917
4929
  }
4918
4930
  }
4919
4931
  }
@@ -5321,7 +5333,7 @@ class AXCEntityDefinitionsModule {
5321
5333
  constructor(appInitService) {
5322
5334
  // appInitService.registerTask({
5323
5335
  // name: 'StoredModuleManifests',
5324
- // statusText: 'Register module manifests from entity definition store...',
5336
+ // statusText: '@general:app-startup.registering-stored-module-manifests',
5325
5337
  // priority: 3,
5326
5338
  // run: () => storedModuleManifestRegistrar.registerFromEntityDefinitionStore(),
5327
5339
  // });
@@ -14545,7 +14557,7 @@ const AI_ASSIST_MOCK = [
14545
14557
  {
14546
14558
  id: AXMAiDemisAssistId,
14547
14559
  name: 'demis-payment-guide',
14548
- title: M$19('Demis', 'دیمیس'),
14560
+ title: M$19('Magfa Assistant', 'دستیار هوشمند مرکز گسترش فناوری اطلاعات'),
14549
14561
  metadata: {
14550
14562
  agent_uuid: AXMAiDemisAssistAgentUuid,
14551
14563
  },
@@ -21445,7 +21457,7 @@ class AXCAiManagementMockModule {
21445
21457
  provideCommandSetups([
21446
21458
  {
21447
21459
  key: 'AiManagement:ChatGenerateImage',
21448
- command: () => import('./acorex-connectivity-mock-chat-generate-image.command-CtQaCk3Y.mjs').then((c) => c.AiManagementChatGenerateImageCommand),
21460
+ command: () => import('./acorex-connectivity-mock-chat-generate-image.command-DhNpfDnJ.mjs').then((c) => c.AiManagementChatGenerateImageCommand),
21449
21461
  },
21450
21462
  {
21451
21463
  key: 'AiManagement:ExtractDocumentText',
@@ -21457,11 +21469,11 @@ class AXCAiManagementMockModule {
21457
21469
  },
21458
21470
  {
21459
21471
  key: 'AiManagement:ChatTranscribeSpeech',
21460
- command: () => import('./acorex-connectivity-mock-chat-transcribe-speech.command-B59uD75x.mjs').then((c) => c.AiManagementChatTranscribeSpeechCommand),
21472
+ command: () => import('./acorex-connectivity-mock-chat-transcribe-speech.command-frk47mU7.mjs').then((c) => c.AiManagementChatTranscribeSpeechCommand),
21461
21473
  },
21462
21474
  {
21463
21475
  key: 'AiManagement:ChatSynthesizeSpeech',
21464
- command: () => import('./acorex-connectivity-mock-chat-synthesize-speech.command-DqsIX8B8.mjs').then((c) => c.AiManagementChatSynthesizeSpeechCommand),
21476
+ command: () => import('./acorex-connectivity-mock-chat-synthesize-speech.command-Bz-zOFK0.mjs').then((c) => c.AiManagementChatSynthesizeSpeechCommand),
21465
21477
  },
21466
21478
  ]),
21467
21479
  ] }); }
@@ -21514,7 +21526,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
21514
21526
  provideCommandSetups([
21515
21527
  {
21516
21528
  key: 'AiManagement:ChatGenerateImage',
21517
- command: () => import('./acorex-connectivity-mock-chat-generate-image.command-CtQaCk3Y.mjs').then((c) => c.AiManagementChatGenerateImageCommand),
21529
+ command: () => import('./acorex-connectivity-mock-chat-generate-image.command-DhNpfDnJ.mjs').then((c) => c.AiManagementChatGenerateImageCommand),
21518
21530
  },
21519
21531
  {
21520
21532
  key: 'AiManagement:ExtractDocumentText',
@@ -21526,11 +21538,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
21526
21538
  },
21527
21539
  {
21528
21540
  key: 'AiManagement:ChatTranscribeSpeech',
21529
- command: () => import('./acorex-connectivity-mock-chat-transcribe-speech.command-B59uD75x.mjs').then((c) => c.AiManagementChatTranscribeSpeechCommand),
21541
+ command: () => import('./acorex-connectivity-mock-chat-transcribe-speech.command-frk47mU7.mjs').then((c) => c.AiManagementChatTranscribeSpeechCommand),
21530
21542
  },
21531
21543
  {
21532
21544
  key: 'AiManagement:ChatSynthesizeSpeech',
21533
- command: () => import('./acorex-connectivity-mock-chat-synthesize-speech.command-DqsIX8B8.mjs').then((c) => c.AiManagementChatSynthesizeSpeechCommand),
21545
+ command: () => import('./acorex-connectivity-mock-chat-synthesize-speech.command-Bz-zOFK0.mjs').then((c) => c.AiManagementChatSynthesizeSpeechCommand),
21534
21546
  },
21535
21547
  ]),
21536
21548
  ],
@@ -21785,6 +21797,7 @@ const APPLICATION_TREE = [
21785
21797
  'TenantManagement',
21786
21798
  'SubscriptionManagement',
21787
21799
  'AiManagement',
21800
+ 'PlatformDevTools',
21788
21801
  'Common',
21789
21802
  AXPCommonFeatureKeys.GlobalSearch,
21790
21803
  ],
@@ -22120,7 +22133,25 @@ class AXCEditionDataSeeder {
22120
22133
  this.storageService = inject(AXPEntityStorageService);
22121
22134
  }
22122
22135
  async seed() {
22123
- await this.storageService.initial(`${RootConfig$2.module.name}.${RootConfig$2.entities.edition.name}`, EDITIONS);
22136
+ const entityName = `${RootConfig$2.module.name}.${RootConfig$2.entities.edition.name}`;
22137
+ await this.storageService.initial(entityName, EDITIONS);
22138
+ await this.syncPlatformConsoleEditionModules(entityName);
22139
+ }
22140
+ /** Keeps Platform Console edition modules aligned when featureKeys change in mock data. */
22141
+ async syncPlatformConsoleEditionModules(editionsEntityName) {
22142
+ const storedEditions = await this.storageService.getAll(editionsEntityName);
22143
+ const stored = storedEditions.find((edition) => edition.id === PLATFORM_CONSOLE.id);
22144
+ if (!stored?.id || !PLATFORM_CONSOLE.modulesAndFeatures) {
22145
+ return;
22146
+ }
22147
+ const storedModules = [...(stored.modulesAndFeatures?.modules ?? [])].sort().join(',');
22148
+ const expectedModules = [...(PLATFORM_CONSOLE.modulesAndFeatures.modules ?? [])].sort().join(',');
22149
+ if (storedModules === expectedModules) {
22150
+ return;
22151
+ }
22152
+ await this.storageService.updateOne(editionsEntityName, stored.id, {
22153
+ modulesAndFeatures: PLATFORM_CONSOLE.modulesAndFeatures,
22154
+ });
22124
22155
  }
22125
22156
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCEditionDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
22126
22157
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCEditionDataSeeder }); }
@@ -30179,7 +30210,7 @@ if (locationMock.length >= 15) {
30179
30210
  }
30180
30211
  }
30181
30212
 
30182
- const uuid$o = AXPDataGenerator.uuid;
30213
+ const uuid$n = AXPDataGenerator.uuid;
30183
30214
  /**
30184
30215
  * Identifier rule `asset-system-type-code`: `ASYS-{seq:2}`. Seed uses a high sequence band (90+)
30185
30216
  * so `identifier.peek("asset-system-type-code")` on a fresh store (starts at ASYS-01) does not
@@ -30232,7 +30263,7 @@ const assetSystemTypeMock = [
30232
30263
  metaDataList: { groups: [] },
30233
30264
  },
30234
30265
  {
30235
- id: uuid$o(),
30266
+ id: uuid$n(),
30236
30267
  code: 'ASYS-94',
30237
30268
  title: ml$1('Power Distribution Subsystem Type', 'نوع زیرسیستم توزیع برق'),
30238
30269
  description: ml$1('Subsystem classification for electrical distribution and backup power.', 'طبقه‌بندی زیرسیستم برای توزیع برق و برق پشتیبان.'),
@@ -30246,7 +30277,7 @@ const assetSystemTypeMock = [
30246
30277
  },
30247
30278
  ];
30248
30279
 
30249
- const uuid$n = AXPDataGenerator.uuid;
30280
+ const uuid$m = AXPDataGenerator.uuid;
30250
30281
  const getLocationByCode$1 = (code) => locationMock.find((location) => location.code === code);
30251
30282
  const getAssetSystemTypeById = (id) => assetSystemTypeMock.find((item) => item.id === id);
30252
30283
  const toLocalized$1 = (enUS, faIR) => ({
@@ -30313,7 +30344,7 @@ const assetSystemMock = assetSystemEntries.map((entry) => {
30313
30344
  throw new Error(`Missing location for code: ${entry.locationCode}`);
30314
30345
  }
30315
30346
  return {
30316
- id: uuid$n(),
30347
+ id: uuid$m(),
30317
30348
  code: entry.code,
30318
30349
  title: toLocalized$1(entry.title, entry.titleFa),
30319
30350
  assetSystemTypeId: entry.assetSystemTypeId,
@@ -32634,10 +32665,10 @@ const POSITIONS_MOCK = (() => {
32634
32665
  })();
32635
32666
 
32636
32667
  const M$_ = createMultiLanguageString;
32637
- const uuid$m = AXPDataGenerator.uuid;
32668
+ const uuid$l = AXPDataGenerator.uuid;
32638
32669
  const BUSINESS_UNIT_TYPES_MOCK = [
32639
32670
  {
32640
- id: uuid$m(),
32671
+ id: uuid$l(),
32641
32672
  title: M$_('Division', 'بخش'),
32642
32673
  name: 'division',
32643
32674
  isLocationBased: true,
@@ -32646,7 +32677,7 @@ const BUSINESS_UNIT_TYPES_MOCK = [
32646
32677
  icon: 'fa-sitemap',
32647
32678
  },
32648
32679
  {
32649
- id: uuid$m(),
32680
+ id: uuid$l(),
32650
32681
  title: M$_('Department', 'دپارتمان'),
32651
32682
  name: 'department',
32652
32683
  isLocationBased: false,
@@ -32655,7 +32686,7 @@ const BUSINESS_UNIT_TYPES_MOCK = [
32655
32686
  icon: 'fa-building-user',
32656
32687
  },
32657
32688
  {
32658
- id: uuid$m(),
32689
+ id: uuid$l(),
32659
32690
  title: M$_('Branch', 'شعبه'),
32660
32691
  name: 'branch',
32661
32692
  isLocationBased: true,
@@ -32670,7 +32701,7 @@ const BUSINESS_UNIT_TYPES_MOCK = [
32670
32701
  * Aligns with SAP/Oracle-style “corporate / headquarters” org unit — not nullable on assignments.
32671
32702
  */
32672
32703
  const AXM_CORPORATE_BUSINESS_UNIT_ID = 'a1b2c3d4-e5f6-4789-a012-34567890abcd';
32673
- const uuid$l = AXPDataGenerator.uuid;
32704
+ const uuid$k = AXPDataGenerator.uuid;
32674
32705
  function pickHeadPositionId(bu) {
32675
32706
  const ids = bu.positionIds ?? [];
32676
32707
  if (!ids.length)
@@ -32733,7 +32764,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32733
32764
  items.push(corporateHeadquarters);
32734
32765
  // Divisions under corporate root
32735
32766
  const divisionOps = {
32736
- id: uuid$l(),
32767
+ id: uuid$k(),
32737
32768
  code: 'BU-DIV-OPS',
32738
32769
  title: createMultiLanguageString('Operations Division', 'بخش عملیات'),
32739
32770
  description: createMultiLanguageString('Core operations across plants', 'عملیات اصلی در کارخانه‌ها'),
@@ -32753,7 +32784,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32753
32784
  ]),
32754
32785
  };
32755
32786
  const divisionSales = {
32756
- id: uuid$l(),
32787
+ id: uuid$k(),
32757
32788
  code: 'BU-DIV-SALES',
32758
32789
  title: createMultiLanguageString('Sales Division', 'بخش فروش'),
32759
32790
  description: createMultiLanguageString('Global sales organization', 'سازمان فروش جهانی'),
@@ -32766,7 +32797,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32766
32797
  ...positionsByTitles(['Sales Associate', 'Account Executive', 'Sales Manager', 'VP of Sales']),
32767
32798
  };
32768
32799
  const divisionEngineering = {
32769
- id: uuid$l(),
32800
+ id: uuid$k(),
32770
32801
  code: 'BU-DIV-ENG',
32771
32802
  title: createMultiLanguageString('Engineering Division', 'بخش مهندسی'),
32772
32803
  description: createMultiLanguageString('Product and platform engineering', 'مهندسی محصول و پلتفرم'),
@@ -32781,7 +32812,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32781
32812
  items.push(divisionOps, divisionSales, divisionEngineering);
32782
32813
  // Departments under Operations
32783
32814
  const depHSE = {
32784
- id: uuid$l(),
32815
+ id: uuid$k(),
32785
32816
  code: 'BU-DEPT-HSE',
32786
32817
  title: createMultiLanguageString('Health, Safety & Environment', 'بهداشت، ایمنی و محیط زیست'),
32787
32818
  description: createMultiLanguageString('WHS/OHS', 'بهداشت و ایمنی شغلی'),
@@ -32792,7 +32823,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32792
32823
  ...positionsByTitles(['HSE Officer', 'Safety Officer', 'Environmental Specialist', 'HSE Manager']),
32793
32824
  };
32794
32825
  const depQuality = {
32795
- id: uuid$l(),
32826
+ id: uuid$k(),
32796
32827
  code: 'BU-DEPT-QA',
32797
32828
  title: createMultiLanguageString('Quality Assurance', 'تضمین کیفیت'),
32798
32829
  description: createMultiLanguageString('QA and compliance', 'کنترل کیفیت و انطباق'),
@@ -32810,7 +32841,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32810
32841
  ]),
32811
32842
  };
32812
32843
  const depMaintenance = {
32813
- id: uuid$l(),
32844
+ id: uuid$k(),
32814
32845
  code: 'BU-DEPT-MNT',
32815
32846
  title: createMultiLanguageString('Maintenance', 'نگهداری و تعمیرات'),
32816
32847
  description: createMultiLanguageString('Asset reliability and maintenance', 'قابلیت اطمینان دارایی و نگهداری'),
@@ -32823,7 +32854,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32823
32854
  items.push(depHSE, depQuality, depMaintenance);
32824
32855
  // Departments under Engineering
32825
32856
  const depPlatform = {
32826
- id: uuid$l(),
32857
+ id: uuid$k(),
32827
32858
  code: 'BU-DEPT-PLAT',
32828
32859
  title: createMultiLanguageString('Platform Engineering', 'مهندسی پلتفرم'),
32829
32860
  description: createMultiLanguageString('Core platform teams', 'تیم‌های اصلی پلتفرم'),
@@ -32834,7 +32865,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32834
32865
  ...positionsByTitles(['DevOps Engineer', 'Senior DevOps Engineer', 'Engineering Team Lead', 'Director of DevOps']),
32835
32866
  };
32836
32867
  const depProduct = {
32837
- id: uuid$l(),
32868
+ id: uuid$k(),
32838
32869
  code: 'BU-DEPT-PROD',
32839
32870
  title: createMultiLanguageString('Product Engineering', 'مهندسی محصول'),
32840
32871
  description: createMultiLanguageString('Product squads', 'اسکوادهای محصول'),
@@ -32847,7 +32878,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32847
32878
  items.push(depPlatform, depProduct);
32848
32879
  // Branches (location-based) under cities
32849
32880
  const branchLA = {
32850
- id: uuid$l(),
32881
+ id: uuid$k(),
32851
32882
  code: 'BU-BR-LA',
32852
32883
  title: createMultiLanguageString('Los Angeles Branch', 'شعبه لس‌آنجلس'),
32853
32884
  description: createMultiLanguageString('US West Region', 'منطقه غرب آمریکا'),
@@ -32859,7 +32890,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32859
32890
  geographicRegion: LA,
32860
32891
  };
32861
32892
  const branchSF = {
32862
- id: uuid$l(),
32893
+ id: uuid$k(),
32863
32894
  code: 'BU-BR-SF',
32864
32895
  title: createMultiLanguageString('San Francisco Branch', 'شعبه سان‌فرانسیسکو'),
32865
32896
  description: createMultiLanguageString('Bay Area', 'منطقه خلیج'),
@@ -32871,7 +32902,7 @@ const BUSINESS_UNITS_MOCK = (() => {
32871
32902
  geographicRegion: SF,
32872
32903
  };
32873
32904
  const branchSydney = {
32874
- id: uuid$l(),
32905
+ id: uuid$k(),
32875
32906
  code: 'BU-BR-SYD',
32876
32907
  title: createMultiLanguageString('Sydney Branch', 'شعبه سیدنی'),
32877
32908
  description: createMultiLanguageString('ANZ Region', 'منطقه استرالیا و نیوزیلند'),
@@ -33084,25 +33115,45 @@ const personTitleMocks = [
33084
33115
 
33085
33116
  //#region ---- Tenant ID Constants ----
33086
33117
  /**
33087
- * Tenant ID constants for use across mock data.
33088
- * These are generated once and exported to ensure consistency.
33118
+ * Stable tenant primary keys for mock data (not generated per process) so IndexedDB seeds,
33119
+ * tenant-user links, and subscriptions stay aligned across reloads and user switches.
33089
33120
  */
33090
- const PLATFORM_TENANT_ID = AXPDataGenerator.uuid();
33091
- const TIMEPLICITY_TENANT_ID = AXPDataGenerator.uuid();
33092
- const LASER_PLUMBING_TENANT_ID = AXPDataGenerator.uuid();
33121
+ const PLATFORM_TENANT_ID = 'f0000002-0000-4000-a000-000000000001';
33122
+ const TIMEPLICITY_TENANT_ID = 'f0000002-0000-4000-a000-000000000002';
33123
+ const LASER_PLUMBING_TENANT_ID = 'f0000002-0000-4000-a000-000000000003';
33093
33124
  /** MAGFA — Iran commerce tenant for conversation / AI / reports demo. */
33094
- const MAGFA_TENANT_ID = AXPDataGenerator.uuid();
33125
+ const MAGFA_TENANT_ID = 'f0000002-0000-4000-a000-000000000004';
33095
33126
  /** @deprecated Use {@link MAGFA_TENANT_ID}. */
33096
33127
  const COLLABORATION_TENANT_ID = MAGFA_TENANT_ID;
33097
33128
  //#endregion
33098
33129
 
33130
+ //#region ---- Role ID Constants ----
33131
+ /**
33132
+ * Stable role primary keys for mock data (not generated per process) so IndexedDB seeds,
33133
+ * tenant-user links, and user roleIds stay aligned across reloads.
33134
+ */
33135
+ const MOCK_ROLE_IDS = {
33136
+ root: 'f0000004-0000-4000-a000-000000000001',
33137
+ platformApplicationAdministrator: 'f0000004-0000-4000-a000-000000000002',
33138
+ admin: 'f0000004-0000-4000-a000-000000000003',
33139
+ manager: 'f0000004-0000-4000-a000-000000000004',
33140
+ user: 'f0000004-0000-4000-a000-000000000005',
33141
+ support: 'f0000004-0000-4000-a000-000000000006',
33142
+ hr: 'f0000004-0000-4000-a000-000000000007',
33143
+ finance: 'f0000004-0000-4000-a000-000000000008',
33144
+ dev: 'f0000004-0000-4000-a000-000000000009',
33145
+ accountHolder: 'f0000004-0000-4000-a000-00000000000a',
33146
+ tenantAdministrator: 'f0000004-0000-4000-a000-00000000000b',
33147
+ conversationOnly: 'f0000004-0000-4000-a000-00000000000c',
33148
+ };
33149
+ //#endregion
33150
+
33099
33151
  //#region ---- Imports ----
33100
33152
  //#endregion
33101
33153
  //#region ---- Mock Data ----
33102
- const uuid$k = AXPDataGenerator.uuid;
33103
33154
  const mockRoleDefinitions = [
33104
33155
  {
33105
- id: uuid$k(),
33156
+ id: MOCK_ROLE_IDS.root,
33106
33157
  name: 'root',
33107
33158
  title: 'Super Administrator',
33108
33159
  description: 'Full system access with all administrative privileges',
@@ -33157,7 +33208,7 @@ const mockRoleDefinitions = [
33157
33208
  },
33158
33209
  },
33159
33210
  {
33160
- id: uuid$k(),
33211
+ id: MOCK_ROLE_IDS.platformApplicationAdministrator,
33161
33212
  name: 'platform-application-administrator',
33162
33213
  title: 'Platform Application Administrator',
33163
33214
  description: 'Full platform application access with all administrative privileges',
@@ -33177,7 +33228,7 @@ const mockRoleDefinitions = [
33177
33228
  },
33178
33229
  },
33179
33230
  {
33180
- id: uuid$k(),
33231
+ id: MOCK_ROLE_IDS.admin,
33181
33232
  name: 'admin',
33182
33233
  title: 'Administrator',
33183
33234
  description: 'Full system access with all administrative privileges',
@@ -33198,7 +33249,7 @@ const mockRoleDefinitions = [
33198
33249
  },
33199
33250
  },
33200
33251
  {
33201
- id: uuid$k(),
33252
+ id: MOCK_ROLE_IDS.manager,
33202
33253
  name: 'manager',
33203
33254
  title: 'Manager',
33204
33255
  description: 'Manages users and has access to most system features',
@@ -33216,7 +33267,7 @@ const mockRoleDefinitions = [
33216
33267
  },
33217
33268
  },
33218
33269
  {
33219
- id: uuid$k(),
33270
+ id: MOCK_ROLE_IDS.user,
33220
33271
  name: 'user',
33221
33272
  title: 'Regular User',
33222
33273
  description: 'Standard user with basic system access',
@@ -33236,7 +33287,7 @@ const mockRoleDefinitions = [
33236
33287
  },
33237
33288
  },
33238
33289
  {
33239
- id: uuid$k(),
33290
+ id: MOCK_ROLE_IDS.support,
33240
33291
  name: 'support',
33241
33292
  title: 'Support Staff',
33242
33293
  description: 'Customer support and ticket management access',
@@ -33254,7 +33305,7 @@ const mockRoleDefinitions = [
33254
33305
  },
33255
33306
  },
33256
33307
  {
33257
- id: uuid$k(),
33308
+ id: MOCK_ROLE_IDS.hr,
33258
33309
  name: 'hr',
33259
33310
  title: 'Human Resources',
33260
33311
  description: 'Access to HR-related features and user management',
@@ -33272,7 +33323,7 @@ const mockRoleDefinitions = [
33272
33323
  },
33273
33324
  },
33274
33325
  {
33275
- id: uuid$k(),
33326
+ id: MOCK_ROLE_IDS.finance,
33276
33327
  name: 'finance',
33277
33328
  title: 'Finance',
33278
33329
  description: 'Access to financial reports and invoicing features',
@@ -33290,7 +33341,7 @@ const mockRoleDefinitions = [
33290
33341
  },
33291
33342
  },
33292
33343
  {
33293
- id: uuid$k(),
33344
+ id: MOCK_ROLE_IDS.dev,
33294
33345
  name: 'dev',
33295
33346
  title: 'Developer',
33296
33347
  description: 'Technical access to development and debugging features',
@@ -33312,7 +33363,7 @@ const mockRoleDefinitions = [
33312
33363
  },
33313
33364
  },
33314
33365
  {
33315
- id: uuid$k(),
33366
+ id: MOCK_ROLE_IDS.accountHolder,
33316
33367
  name: 'account-holder',
33317
33368
  title: 'Account Holder',
33318
33369
  description: 'Primary account owner with full tenant management privileges',
@@ -33332,7 +33383,7 @@ const mockRoleDefinitions = [
33332
33383
  },
33333
33384
  },
33334
33385
  {
33335
- id: uuid$k(),
33386
+ id: MOCK_ROLE_IDS.tenantAdministrator,
33336
33387
  name: 'tenant-administrator',
33337
33388
  title: 'Tenant Administrator',
33338
33389
  description: 'Tenant-level administrator with full CRUD access to users and roles',
@@ -33380,7 +33431,7 @@ const mockRoleDefinitions = [
33380
33431
  },
33381
33432
  },
33382
33433
  {
33383
- id: 'a0000001-0000-4000-a000-000000000099',
33434
+ id: MOCK_ROLE_IDS.conversationOnly,
33384
33435
  name: 'conversation-only',
33385
33436
  title: 'Conversation Only',
33386
33437
  description: 'Conversation access only for MAGFA commerce',
@@ -35222,8 +35273,8 @@ const visibilityFilterMiddleware = {
35222
35273
  if (bypassVisibility && bypassOwnership) {
35223
35274
  return;
35224
35275
  }
35225
- // Filter function to check visibility (async to allow tenant loading)
35226
- const isVisible = async (record) => {
35276
+ // Filter function to check visibility
35277
+ const isVisible = (record) => {
35227
35278
  // Check stateInfo visibility flags (unless bypassed)
35228
35279
  if (!bypassVisibility && record?.stateInfo) {
35229
35280
  const { isHidden } = record.stateInfo;
@@ -35234,36 +35285,15 @@ const visibilityFilterMiddleware = {
35234
35285
  // Check ownershipInfo for tenant and application filtering (unless bypassed)
35235
35286
  if (!bypassOwnership && record?.ownershipInfo) {
35236
35287
  const { tenantId, applicationId } = record.ownershipInfo;
35237
- // Filter by tenant: check both session tenant and user's ownership tenant
35238
- // Show record if:
35239
- // - Record has no tenantId (global record)
35240
- // - Session tenant matches record tenant
35241
- // - User's ownership tenant matches record tenant (fallback if session tenant not set or different)
35242
- // - Neither session nor user tenant is set (show all)
35243
- // - Current user is a platform user (root/root2/super-root) and record is from platform tenant
35288
+ // Filter by tenant: session tenant is authoritative when set; otherwise fall back to the
35289
+ // signed-in user's ownership tenant (e.g. before tenant chooser completes).
35244
35290
  if (tenantId) {
35245
- const sessionTenantMatches = currentTenantId && tenantId === currentTenantId;
35246
- const userTenantMatches = currentUserTenantId && tenantId === currentUserTenantId;
35247
- const noTenantSet = !currentTenantId && !currentUserTenantId;
35248
- // Check if current user is a platform user (root/root2)
35249
- const isPlatformUser = session.user?.name === 'root' || session.user?.name === 'root2' || session.user?.name === 'super-root';
35250
- // If user is platform user, try to load tenant to check if it's platform tenant by name
35251
- let isPlatformTenant = false;
35252
- if (isPlatformUser && tenantId) {
35253
- try {
35254
- const tenantEntityName = 'TenantManagement.Tenant';
35255
- const tenant = await backend.getOne(tenantEntityName, tenantId);
35256
- if (tenant && (tenant.name === 'acorex-tenant' || tenant.name === 'platform-tenant')) {
35257
- isPlatformTenant = true;
35258
- }
35259
- }
35260
- catch (error) {
35261
- // If we can't load tenant, continue without platform tenant check
35291
+ if (currentTenantId) {
35292
+ if (tenantId !== currentTenantId) {
35293
+ return false;
35262
35294
  }
35263
35295
  }
35264
- // Filter out if tenant is set and doesn't match either session or user tenant
35265
- // Exception: platform users can see platform tenant records
35266
- if (!sessionTenantMatches && !userTenantMatches && !noTenantSet && !isPlatformTenant) {
35296
+ else if (currentUserTenantId && tenantId !== currentUserTenantId) {
35267
35297
  return false;
35268
35298
  }
35269
35299
  }
@@ -35297,8 +35327,7 @@ const visibilityFilterMiddleware = {
35297
35327
  take: Number.MAX_SAFE_INTEGER, // Get all records
35298
35328
  });
35299
35329
  // Filter all records with visibility filter
35300
- const visibilityResults = await Promise.all(allFilteredRecordsResult.items.map((record) => isVisible(record)));
35301
- const filteredAllRecords = allFilteredRecordsResult.items.filter((_, index) => visibilityResults[index]);
35330
+ const filteredAllRecords = allFilteredRecordsResult.items.filter((record) => isVisible(record));
35302
35331
  // Update total count based on filtered records
35303
35332
  const filteredTotal = filteredAllRecords.length;
35304
35333
  // Re-apply pagination to filtered records
@@ -35312,8 +35341,7 @@ const visibilityFilterMiddleware = {
35312
35341
  // For getAll operation, result is a plain array
35313
35342
  if (Array.isArray(ctx.result)) {
35314
35343
  // Filter all records
35315
- const visibilityResults = await Promise.all(ctx.result.map((record) => isVisible(record)));
35316
- ctx.result = ctx.result.filter((_, index) => visibilityResults[index]);
35344
+ ctx.result = ctx.result.filter((record) => isVisible(record));
35317
35345
  }
35318
35346
  }
35319
35347
  },
@@ -35644,7 +35672,7 @@ class MockTenantLoader {
35644
35672
  ],
35645
35673
  };
35646
35674
  // Get all active tenants
35647
- const tenantsResult = await tenantService.query({ skip: 0, take: 1000, filter: tenantFilter });
35675
+ const tenantsResult = await tenantService.query(bypassAllFilters({ skip: 0, take: 1000, filter: tenantFilter }));
35648
35676
  // Get active subscriptions for tenants
35649
35677
  const subscriptionFilter = {
35650
35678
  logic: 'and',
@@ -35661,7 +35689,7 @@ class MockTenantLoader {
35661
35689
  },
35662
35690
  ],
35663
35691
  };
35664
- const subscriptionsResult = await subscriptionService.query({ skip: 0, take: 1000, filter: subscriptionFilter });
35692
+ const subscriptionsResult = await subscriptionService.query(bypassAllFilters({ skip: 0, take: 1000, filter: subscriptionFilter }));
35665
35693
  // If user is in context, also filter by TenantUser membership
35666
35694
  if (context.user?.id) {
35667
35695
  const tenantUserFilter = {
@@ -35679,7 +35707,7 @@ class MockTenantLoader {
35679
35707
  },
35680
35708
  ],
35681
35709
  };
35682
- const tenantUsersResult = await tenantUserService.query({ skip: 0, take: 1000, filter: tenantUserFilter });
35710
+ const tenantUsersResult = await tenantUserService.query(bypassAllFilters({ skip: 0, take: 1000, filter: tenantUserFilter }));
35683
35711
  // Get unique tenant IDs that have active subscriptions
35684
35712
  const tenantIdsWithSubscriptions = new Set(subscriptionsResult.items.map((sub) => sub.subscriberId).filter((id) => !!id));
35685
35713
  // Get unique tenant IDs where user is a member
@@ -40187,15 +40215,6 @@ class AXCConversationMockConversationApi extends AXMChatConversationApi {
40187
40215
  lastMessageAt: new Date(),
40188
40216
  unreadCount: 0,
40189
40217
  status: { isTyping: false, typingUsers: [] },
40190
- permissions: {
40191
- canSendMessages: true,
40192
- canSendMedia: true,
40193
- canDeleteMessages: true,
40194
- canAddMembers: data.type !== 'private',
40195
- canRemoveMembers: data.type !== 'private',
40196
- canEditInfo: data.type !== 'private',
40197
- canPinMessages: true,
40198
- },
40199
40218
  settings: { notifications: true, showPreview: true },
40200
40219
  archived: false,
40201
40220
  metadata: storedMetadata,
@@ -40357,12 +40376,12 @@ class AXCConversationMockConversationApi extends AXMChatConversationApi {
40357
40376
  }
40358
40377
  //#endregion
40359
40378
  //#region ---- Permissions ----
40360
- async getConversationPermissions(_conversationId) {
40361
- return { canSendMessages: true, canSendMedia: true, canDeleteMessages: true };
40362
- }
40363
- async updateConversationPermissions(_conversationId, _permissions) {
40364
- await Promise.resolve();
40365
- }
40379
+ // async getConversationPermissions(_conversationId: string): Promise<Record<string, boolean>> {
40380
+ // return { canSendMessages: true, canSendMedia: true, canDeleteMessages: true };
40381
+ // }
40382
+ // async updateConversationPermissions(_conversationId: string, _permissions: Record<string, boolean>): Promise<void> {
40383
+ // await Promise.resolve();
40384
+ // }
40366
40385
  //#endregion
40367
40386
  //#region ---- Draft Management ----
40368
40387
  async saveDraft(_conversationId, _draft) {
@@ -40405,9 +40424,7 @@ class AXCConversationMockConversationApi extends AXMChatConversationApi {
40405
40424
  avatar: typeof avatar === 'string' ? avatar : undefined,
40406
40425
  status: 'online',
40407
40426
  lastSeen: new Date(),
40408
- metadata: directAgentId
40409
- ? { directAgentId, kind: 'agent-assist' }
40410
- : { assistId: catalogPeerId, kind: 'assist' },
40427
+ metadata: directAgentId ? { directAgentId, kind: 'agent-assist' } : { assistId: catalogPeerId, kind: 'assist' },
40411
40428
  };
40412
40429
  conversationSharedStorage.participants.set(participantId, participant);
40413
40430
  await axConversationIndexedDbStorage.putParticipant(participant);
@@ -41128,9 +41145,7 @@ class AXCConversationMockMessageApi extends AXMChatMessageApi {
41128
41145
  const contextAiMessageCount = messages.length;
41129
41146
  const demisSessionUuid = await this.resolveDemisSessionUuidForConversation(conversationId, modelEntityId);
41130
41147
  const runResult = await this.aiEngine.run({
41131
- ...(target.directAgentId
41132
- ? { directAgentId: target.directAgentId }
41133
- : { assistId: target.assistId }),
41148
+ ...(target.directAgentId ? { directAgentId: target.directAgentId } : { assistId: target.assistId }),
41134
41149
  messages,
41135
41150
  modelEntityId,
41136
41151
  ...(demisSessionUuid ? { demisSessionUuid } : {}),
@@ -41138,7 +41153,7 @@ class AXCConversationMockMessageApi extends AXMChatMessageApi {
41138
41153
  AXMAiRuleMarkdownName,
41139
41154
  // AXMAiRuleWorkflowNarrationName
41140
41155
  ],
41141
- includeAgents: [AXPAI_CONVERSATION_FOLLOW_UP_AGENT_NAME],
41156
+ // includeAgents: [AXPAI_CONVERSATION_FOLLOW_UP_AGENT_NAME],
41142
41157
  onRunEvent: (event) => {
41143
41158
  switch (event.type) {
41144
41159
  case 'assistant_stream_reset':
@@ -41385,8 +41400,7 @@ class AXCConversationMockMessageApi extends AXMChatMessageApi {
41385
41400
  return null;
41386
41401
  }
41387
41402
  turnTranscriptHasFollowUpSegment(transcript) {
41388
- return transcript.some((m) => m.role === 'assistant' &&
41389
- m.responses.some((r) => r.type === 'followUp' && r.content.length > 0));
41403
+ return transcript.some((m) => m.role === 'assistant' && m.responses.some((r) => r.type === 'followUp' && r.content.length > 0));
41390
41404
  }
41391
41405
  appendFollowUpToDemisAssistantTurn(transcript, followUp) {
41392
41406
  const out = transcript.map((m) => ({ ...m, responses: [...m.responses] }));
@@ -41705,9 +41719,7 @@ class AXCConversationMockMessageApi extends AXMChatMessageApi {
41705
41719
  */
41706
41720
  async resolveModelDisplayTitle(modelEntityId, target) {
41707
41721
  try {
41708
- const models = await this.modelCatalog.listModels(target.directAgentId
41709
- ? { directAgentId: target.directAgentId }
41710
- : { assistId: target.assistId ?? '' });
41722
+ const models = await this.modelCatalog.listModels(target.directAgentId ? { directAgentId: target.directAgentId } : { assistId: target.assistId ?? '' });
41711
41723
  const hit = models.find((m) => m.id === modelEntityId);
41712
41724
  if (!hit) {
41713
41725
  return modelEntityId;
@@ -42352,15 +42364,6 @@ const chatMock = [
42352
42364
  lastMessageAt: new Date(now$2.getTime() - 60000),
42353
42365
  unreadCount: 2,
42354
42366
  status: { isTyping: false, typingUsers: [] },
42355
- permissions: {
42356
- canSendMessages: true,
42357
- canSendMedia: true,
42358
- canDeleteMessages: true,
42359
- canAddMembers: false,
42360
- canRemoveMembers: false,
42361
- canEditInfo: false,
42362
- canPinMessages: true,
42363
- },
42364
42367
  settings: { notifications: true, showPreview: true },
42365
42368
  archived: false,
42366
42369
  metadata: {
@@ -42381,15 +42384,6 @@ const chatMock = [
42381
42384
  lastMessageAt: new Date(now$2.getTime() - 7200000),
42382
42385
  unreadCount: 0,
42383
42386
  status: { isTyping: false, typingUsers: [] },
42384
- permissions: {
42385
- canSendMessages: true,
42386
- canSendMedia: true,
42387
- canDeleteMessages: true,
42388
- canAddMembers: false,
42389
- canRemoveMembers: false,
42390
- canEditInfo: false,
42391
- canPinMessages: true,
42392
- },
42393
42387
  settings: { notifications: true, showPreview: true },
42394
42388
  archived: false,
42395
42389
  metadata: {
@@ -42416,15 +42410,6 @@ const chatMock = [
42416
42410
  lastMessageAt: new Date(now$2.getTime() - 3600000),
42417
42411
  unreadCount: 1,
42418
42412
  status: { isTyping: false, typingUsers: [] },
42419
- permissions: {
42420
- canSendMessages: true,
42421
- canSendMedia: true,
42422
- canDeleteMessages: true,
42423
- canAddMembers: true,
42424
- canRemoveMembers: true,
42425
- canEditInfo: true,
42426
- canPinMessages: true,
42427
- },
42428
42413
  settings: { notifications: true, showPreview: true },
42429
42414
  archived: false,
42430
42415
  metadata: {
@@ -42459,15 +42444,6 @@ const chatMock = [
42459
42444
  lastMessageAt: new Date(now$2.getTime() - 10800000),
42460
42445
  unreadCount: 0,
42461
42446
  status: { isTyping: false, typingUsers: [] },
42462
- permissions: {
42463
- canSendMessages: true,
42464
- canSendMedia: true,
42465
- canDeleteMessages: true,
42466
- canAddMembers: true,
42467
- canRemoveMembers: true,
42468
- canEditInfo: true,
42469
- canPinMessages: true,
42470
- },
42471
42447
  settings: { notifications: true, showPreview: true },
42472
42448
  archived: false,
42473
42449
  metadata: {
@@ -43024,80 +43000,9 @@ const MESSAGES = Array.from({ length: 100 }).map(() => {
43024
43000
  class AXPMessageDataSeeder {
43025
43001
  constructor() {
43026
43002
  this.storageService = inject(AXPEntityStorageService);
43027
- this.chatService = inject(AXMChatManagementService);
43028
- this.chatRealtimeService = inject(AXMChatRealtimeService);
43029
- this.commentService = inject(AXMCommentManagementService);
43030
- this.commentRealtimeService = inject(AXMCommentRealtimeService);
43031
- this.usersService = inject(AXMUsersEntityService);
43032
- this.sessionService = inject(AXPSessionService);
43033
- this.userNameCache = new Map();
43034
- }
43035
- async getUserName(userId) {
43036
- if (this.userNameCache.has(userId)) {
43037
- return this.userNameCache.get(userId);
43038
- }
43039
- try {
43040
- const user = await this.usersService.getOne(userId);
43041
- const fullName = `${user.displayName}`.trim();
43042
- this.userNameCache.set(userId, fullName);
43043
- return fullName;
43044
- }
43045
- catch {
43046
- return 'Unknown User';
43047
- }
43048
43003
  }
43049
43004
  async seed() {
43050
43005
  await this.storageService.initial(`${RootConfig$a.module.name}.${RootConfig$a.entities.message.name}`, MESSAGES);
43051
- this.sessionService.user$
43052
- .pipe(filter((user) => !!user), take(1))
43053
- .subscribe((user) => {
43054
- const currentUserId = user.id;
43055
- this.chatRealtimeService.message$
43056
- .pipe(filter((event) => event.type === 'add'), map((event) => event.payload), filter((message) => message.author.id === currentUserId), throttleTime(1000))
43057
- .subscribe(async (message) => {
43058
- try {
43059
- const room = await this.chatService.getRoom(message.roomId);
43060
- const otherMembers = room.members.filter((member) => member.id !== message.author.id);
43061
- if (otherMembers.length === 0) {
43062
- return;
43063
- }
43064
- const randomMember = otherMembers[Math.floor(Math.random() * otherMembers.length)];
43065
- const { items: messageHistory } = await this.chatService.getMessages(room.id, 0, 99);
43066
- messageHistory.reverse();
43067
- const formattedHistory = await Promise.all(messageHistory.map(async (msg) => {
43068
- const authorName = await this.getUserName(msg.author.id);
43069
- return `${authorName}: ${msg.message.content}`;
43070
- }));
43071
- const conversationLog = formattedHistory.join('\n');
43072
- // Previous implementation used an AI responder service to generate
43073
- // automatic replies in the mock conversation. That dependency has
43074
- // been removed in favor of the new AI infrastructure, so we no
43075
- // longer generate automatic replies here.
43076
- }
43077
- catch (error) {
43078
- console.error('Error seeding mock message:', error);
43079
- }
43080
- });
43081
- this.commentRealtimeService.comment$
43082
- .pipe(filter((event) => event.type === 'add'), map((event) => event.payload), filter((comment) => comment.author.id === currentUserId), throttleTime(1000), take(3))
43083
- .subscribe(async (comment) => {
43084
- try {
43085
- const { items: allUsers } = await this.usersService.query({ skip: 0, take: 100 });
43086
- const otherUsers = allUsers.filter((u) => u.id !== comment.author.id);
43087
- if (otherUsers.length === 0) {
43088
- return;
43089
- }
43090
- const randomUser = otherUsers[Math.floor(Math.random() * otherUsers.length)];
43091
- // Previous implementation used an AI responder service to generate
43092
- // automatic replies in the mock comments. That dependency has
43093
- // been removed in favor of the new AI infrastructure, so we no
43094
- // longer generate automatic replies here.
43095
- }
43096
- catch (error) {
43097
- console.error('Error seeding mock comment:', error);
43098
- }
43099
- });
43100
- });
43101
43006
  }
43102
43007
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXPMessageDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
43103
43008
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXPMessageDataSeeder }); }
@@ -50366,6 +50271,161 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
50366
50271
  type: Injectable
50367
50272
  }] });
50368
50273
 
50274
+ function generateLeaveType() {
50275
+ const uuid = AXPDataGenerator.uuid;
50276
+ const M = createMultiLanguageString;
50277
+ return [
50278
+ {
50279
+ id: uuid(),
50280
+ title: M('Annual Leave', 'مرخصی سالانه'),
50281
+ description: M('Paid time off for vacation, rest, or personal activities', 'مرخصی استحقاقی برای استراحت یا امور شخصی'),
50282
+ color: '#3b82f6',
50283
+ },
50284
+ {
50285
+ id: uuid(),
50286
+ title: M("Sick & Carer's Leave", 'مرخصی استعلاجی و مراقبت'),
50287
+ description: M('Time off for personal illness or to care for sick family members', 'غیبت به دلیل بیماری یا مراقبت از بیمار خانواده'),
50288
+ color: '#ef4444',
50289
+ },
50290
+ {
50291
+ id: uuid(),
50292
+ title: M('Rostered Day off', 'روز تعطیل برنامه‌ریزی‌شده'),
50293
+ description: M('Scheduled day off as part of the regular work roster', 'روز تعطیل طبق برنامه نوبت کاری'),
50294
+ color: '#8b5cf6',
50295
+ },
50296
+ {
50297
+ id: uuid(),
50298
+ title: M('Training', 'آموزش'),
50299
+ description: M('Time allocated for professional development, courses, or skill enhancement', 'زمان توسعه حرفه‌ای و دوره‌ها'),
50300
+ color: '#06b6d4',
50301
+ },
50302
+ {
50303
+ id: uuid(),
50304
+ title: M('Compassionate & Bereavement Leave', 'مرخصی انسانی و سوگ'),
50305
+ description: M('Time off granted for family emergencies or the death of a loved one', 'مرخصی برای فوت نزدیکان یا شرایط اضطراری خانوادگی'),
50306
+ color: '#6366f1',
50307
+ },
50308
+ {
50309
+ id: uuid(),
50310
+ title: M('Time Off In Lieu', 'مرخصی جبرانی'),
50311
+ description: M('Compensatory time off earned for working additional hours beyond normal schedule', 'جبران ساعت اضافه‌کاری'),
50312
+ color: '#10b981',
50313
+ },
50314
+ {
50315
+ id: uuid(),
50316
+ title: M('Community Service Leave', 'مرخصی خدمت اجتماعی'),
50317
+ description: M('Paid leave for volunteer work or community service activities', 'مرخصی برای داوطلبی و خدمات اجتماعی'),
50318
+ color: '#059669',
50319
+ },
50320
+ {
50321
+ id: uuid(),
50322
+ title: M('Family & Domestic Violence Leave', 'مرخصی خشونت خانگی'),
50323
+ description: M('Paid leave for employees experiencing family or domestic violence situations', 'مرخصی حمایتی برای کارکنان در معرض خشونت خانگی'),
50324
+ color: '#ec4899',
50325
+ },
50326
+ {
50327
+ id: uuid(),
50328
+ title: M('Long Service Leave', 'مرخصی سنوات'),
50329
+ description: M('Extended paid leave granted after many years of continuous service', 'مرخصی طولانی پس از سال‌ها خدمت'),
50330
+ color: '#f59e0b',
50331
+ },
50332
+ {
50333
+ id: uuid(),
50334
+ title: M('Maternity & Paternal Leave', 'مرخصی زایمان و پدری'),
50335
+ description: M('Time off for new parents to care for and bond with their newborn child', 'مرخصی والدین برای مراقبت از نوزاد'),
50336
+ color: '#f472b6',
50337
+ },
50338
+ {
50339
+ id: uuid(),
50340
+ title: M("Public Holiday's", 'تعطیلات رسمی'),
50341
+ description: M('Recognized public holidays and national observances', 'تعطیلات رسمی و مناسبت‌های ملی'),
50342
+ color: '#eab308',
50343
+ },
50344
+ {
50345
+ id: uuid(),
50346
+ title: M('Unpaid Leave', 'مرخصی بدون حقوق'),
50347
+ description: M('Leave without pay for personal reasons or extended time off', 'بدون حقوق به دلایل شخصی'),
50348
+ color: '#6b7280',
50349
+ },
50350
+ {
50351
+ id: uuid(),
50352
+ title: M("Work's Compensation Leave", 'مرخصی بیمه کار'),
50353
+ description: M('Leave due to work-related injury or illness covered by workers compensation', 'مرخصی ناشی از آسیب یا بیماری شغلی'),
50354
+ color: '#dc2626',
50355
+ },
50356
+ ];
50357
+ }
50358
+ const LEAVE_TYPES_MOCK = generateLeaveType();
50359
+
50360
+ class AXMLeaveTypeDataSeeder {
50361
+ constructor() {
50362
+ this.storageService = inject(AXPEntityStorageService);
50363
+ }
50364
+ async seed() {
50365
+ await this.storageService.initial(RootConfig$j.entities.leaveType.source, LEAVE_TYPES_MOCK);
50366
+ }
50367
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveTypeDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
50368
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveTypeDataSeeder }); }
50369
+ }
50370
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveTypeDataSeeder, decorators: [{
50371
+ type: Injectable
50372
+ }] });
50373
+
50374
+ const uuid$9 = AXPDataGenerator.uuid;
50375
+ const LEAVE_REQUEST_STATUS_DEFINITIONS = [
50376
+ AXPSystemStatuses.Pending,
50377
+ AXPSystemStatuses.Approved,
50378
+ AXPSystemStatuses.Rejected,
50379
+ AXPSystemStatuses.Cancelled,
50380
+ ];
50381
+ function buildLeaveRequests() {
50382
+ const results = [];
50383
+ EMPLOYEES_MOCK.forEach((employee) => {
50384
+ // Generate 2 leave requests per employee
50385
+ const count = Math.floor(Math.random() * 2);
50386
+ for (let i = 0; i < count; i++) {
50387
+ const leaveType = LEAVE_TYPES_MOCK[Math.floor(Math.random() * LEAVE_TYPES_MOCK.length)];
50388
+ const duration = Math.floor(Math.random() * 5) + 1; // 1-5 days
50389
+ // Spread start/end across past, today, and future (inclusive) relative to "now"
50390
+ const startDayOffset = Math.floor(Math.random() * 211) - 120; // -120 .. +90 days
50391
+ const start = new Date();
50392
+ start.setDate(start.getDate() + startDayOffset);
50393
+ const end = new Date(start);
50394
+ end.setDate(start.getDate() + duration);
50395
+ const statusDefinition = LEAVE_REQUEST_STATUS_DEFINITIONS[Math.floor(Math.random() * LEAVE_REQUEST_STATUS_DEFINITIONS.length)];
50396
+ results.push({
50397
+ id: uuid$9(),
50398
+ employeeId: employee.id,
50399
+ employee,
50400
+ leaveTypeId: leaveType.id,
50401
+ leaveType,
50402
+ startDate: start,
50403
+ endDate: end,
50404
+ durationDays: duration,
50405
+ reason: `Request for ${leaveType.title}`,
50406
+ statusId: statusDefinition.name,
50407
+ status: { id: statusDefinition.name, title: statusDefinition.title },
50408
+ });
50409
+ }
50410
+ });
50411
+ return results;
50412
+ }
50413
+ const LEAVE_REQUESTS_MOCK = buildLeaveRequests();
50414
+
50415
+ class AXMLeaveRequestDataSeeder {
50416
+ constructor() {
50417
+ this.storageService = inject(AXPEntityStorageService);
50418
+ }
50419
+ async seed() {
50420
+ await this.storageService.initial(RootConfig$j.entities.leaveRequest.source, LEAVE_REQUESTS_MOCK);
50421
+ }
50422
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveRequestDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
50423
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveRequestDataSeeder }); }
50424
+ }
50425
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveRequestDataSeeder, decorators: [{
50426
+ type: Injectable
50427
+ }] });
50428
+
50369
50429
  //#region ---- Types ----
50370
50430
  const WORKFLOW_DEFINITION_ENTITY_SCHEMA = 'https://elsaworkflows.io/schemas/workflow-definition/v3.0.0/schema.json';
50371
50431
  const DEFAULT_TOOL_VERSION = '3.2.0.0';
@@ -50400,79 +50460,116 @@ function createWorkflowDefinitionEntityMock(def, options) {
50400
50460
  //#endregion
50401
50461
 
50402
50462
  const M$q = createMultiLanguageString;
50463
+ //#region ---- Workflow property interfaces ----
50464
+ const workflowLookup = (entity, textField, options) => ({
50465
+ type: 'lookup-editor',
50466
+ options: {
50467
+ entity,
50468
+ textField,
50469
+ valueField: options?.valueField ?? 'id',
50470
+ look: 'select',
50471
+ ...(options?.columns ? { columns: options.columns } : {}),
50472
+ },
50473
+ });
50474
+ const workflowDate = () => ({
50475
+ type: 'date-time-editor',
50476
+ options: { showTime: false },
50477
+ });
50478
+ //#endregion
50403
50479
  /**
50404
- * Generic employee lifecycle workflow: capture process row (dialog) → questionnaire → line-manager confirmation → employee status update.
50405
- * Caller passes employeeId, display names for tasks (employeeDisplayName, lifecycleProcessTypeTitle), questionnaireId,
50406
- * lifecycleProcessTypeId, targetEmployeeStatusId, and optional effectiveDate (ISO date) for the create dialog.
50480
+ * Generic employee lifecycle event workflow: capture event row (dialog) → questionnaire → line-manager confirmation → employee status update.
50481
+ * Caller passes employeeId, display names for tasks (employeeDisplayName, eventTypeTitle), questionnaireId,
50482
+ * eventTypeId, targetEmployeeStatusId, and optional effectiveDate for the create dialog.
50407
50483
  */
50408
- const employeeLifecycleGuidedFlowWorkflowDefinition = {
50484
+ const employeeLifecycleEventFlowWorkflowDefinition = {
50409
50485
  schemaVersion: 'acorex-platform-workflow/v1',
50410
- name: 'employeeLifecycleGuidedFlow',
50411
- title: M$q('Employee lifecycle guided flow', 'جریان هدایت‌شده چرخه عمر کارمند'),
50412
- description: M$q('Opens Employee Lifecycle Process create (type hidden; employee readonly; assignee and effective date prefilled), persists the row, then runs the questionnaire and manager approval path; on approve updates HumanCapitalManagement.Employee.statusId to targetEmployeeStatusId.', 'فرایند ایجاد رکورد چرخه عمر کارمند (نوع مخفی؛ کارمند فقط‌خواندنی؛ مسئول و تاریخ اثر از پیش پر شده)، سپس پرسشنامه و تأیید مدیر؛ در صورت تأیید، وضعیت کارمند به مقدار هدف به‌روز می‌شود.'),
50486
+ name: 'employee-lifecycle-event-flow',
50487
+ title: M$q('Employee lifecycle event flow', 'جریان رویداد چرخه عمر کارمند'),
50488
+ description: M$q('Opens Lifecycle Event create (event type hidden; employee readonly; assignee and effective date prefilled), persists the row, then runs the questionnaire and manager approval path; on approve updates HumanCapitalManagement.Employee.statusId to targetEmployeeStatusId.', 'فرم ایجاد رویداد چرخه عمر (نوع رویداد مخفی؛ کارمند فقط‌خواندنی؛ مسئول و تاریخ اثر از پیش پر شده)، سپس پرسشنامه و تأیید مدیر؛ در صورت تأیید، وضعیت کارمند به‌روز می‌شود.'),
50413
50489
  variables: [
50414
50490
  {
50415
50491
  name: 'employeeId',
50416
- title: 'Employee ID',
50417
- description: 'Subject HumanCapitalManagement.Employee row id',
50492
+ title: 'Employee',
50493
+ description: 'Subject HumanCapitalManagement.Employee',
50418
50494
  dataType: 'string',
50419
- interface: { type: 'text-editor', options: {} },
50495
+ interface: workflowLookup('HumanCapitalManagement.Employee', 'person.fullName', {
50496
+ columns: ['person.fullName', 'employeeCode'],
50497
+ }),
50420
50498
  },
50421
50499
  {
50422
50500
  name: 'questionnaireId',
50423
- title: 'Questionnaire ID',
50424
- description: 'AssessmentManagement questionnaire id (from lifecycle process type)',
50501
+ title: 'Questionnaire',
50502
+ description: 'AssessmentManagement questionnaire (from lifecycle event type)',
50425
50503
  dataType: 'string',
50426
- interface: { type: 'text-editor', options: {} },
50504
+ interface: workflowLookup('AssessmentManagement.Questionnaire', 'title', {
50505
+ columns: ['name', 'title'],
50506
+ }),
50427
50507
  },
50428
50508
  {
50429
- name: 'lifecycleProcessTypeId',
50430
- title: 'Lifecycle process type ID',
50431
- description: 'Optional template id for task context / tracing',
50509
+ name: 'eventTypeId',
50510
+ title: 'Lifecycle event type',
50511
+ description: 'Lifecycle event type template',
50432
50512
  dataType: 'string',
50433
- interface: { type: 'text-editor', options: {} },
50513
+ interface: workflowLookup('HumanCapitalManagement.LifecycleEventType', 'title', {
50514
+ columns: ['name', 'title'],
50515
+ }),
50434
50516
  },
50435
50517
  {
50436
50518
  name: 'targetEmployeeStatusId',
50437
- title: 'Target employee status id',
50438
- description: 'Employee.statusId after approval (e.g. active, terminated, pending)',
50519
+ title: 'Target employee status',
50520
+ description: 'Employee.statusId after approval (e.g. active, terminated)',
50439
50521
  dataType: 'string',
50440
50522
  interface: { type: 'text-editor', options: {} },
50441
50523
  },
50442
50524
  {
50443
50525
  name: 'assigneeUserId',
50444
- title: 'Assignee user ID',
50445
- description: 'Platform user id for subject employee',
50526
+ title: 'Assignee',
50527
+ description: 'Platform user for the subject employee',
50446
50528
  dataType: 'string',
50447
- interface: { type: 'text-editor', options: {} },
50529
+ interface: workflowLookup('SecurityManagement.User', 'displayName', {
50530
+ columns: ['displayName', 'username'],
50531
+ }),
50448
50532
  },
50449
50533
  {
50450
50534
  name: 'managerUserId',
50451
- title: 'Manager user ID',
50452
- description: 'Line manager login user id',
50535
+ title: 'Manager',
50536
+ description: 'Line manager user',
50453
50537
  dataType: 'string',
50454
- interface: { type: 'text-editor', options: {} },
50538
+ interface: workflowLookup('SecurityManagement.User', 'displayName', {
50539
+ columns: ['displayName', 'username'],
50540
+ }),
50455
50541
  },
50456
50542
  {
50457
50543
  name: 'initiatorUserId',
50458
- title: 'Initiator user ID',
50544
+ title: 'Initiator',
50459
50545
  description: 'Workflow starter; fallback when manager cannot be resolved',
50460
50546
  dataType: 'string',
50461
- interface: { type: 'text-editor', options: {} },
50547
+ interface: workflowLookup('SecurityManagement.User', 'displayName', {
50548
+ columns: ['displayName', 'username'],
50549
+ }),
50462
50550
  },
50463
50551
  {
50464
- name: 'employeeLifecycleProcessId',
50465
- title: 'Employee lifecycle process ID',
50466
- description: 'HumanCapitalManagement.EmployeeLifecycleProcess row id after the capture dialog and persistence step',
50552
+ name: 'lifecycleEventId',
50553
+ title: 'Lifecycle event',
50554
+ description: 'HumanCapitalManagement.LifecycleEvent row after capture and persistence',
50555
+ dataType: 'string',
50556
+ interface: workflowLookup('HumanCapitalManagement.LifecycleEvent', 'eventType.title', {
50557
+ columns: ['eventTypeId', 'effectiveDate', 'statusId'],
50558
+ }),
50559
+ },
50560
+ {
50561
+ name: 'lifecycleEventStatusId',
50562
+ title: 'Lifecycle event status',
50563
+ description: 'HumanCapitalManagement.LifecycleEvent.statusId mirrored for task board display',
50467
50564
  dataType: 'string',
50468
50565
  interface: { type: 'text-editor', options: {} },
50469
50566
  },
50470
50567
  {
50471
50568
  name: 'effectiveDate',
50472
50569
  title: 'Effective date',
50473
- description: 'Prefilled effective date for the lifecycle process create dialog (ISO yyyy-mm-dd)',
50474
- dataType: 'string',
50475
- interface: { type: 'text-editor', options: {} },
50570
+ description: 'Effective date for the lifecycle event',
50571
+ dataType: 'date',
50572
+ interface: workflowDate(),
50476
50573
  },
50477
50574
  {
50478
50575
  name: 'employeeDisplayName',
@@ -50482,52 +50579,65 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50482
50579
  interface: { type: 'text-editor', options: {} },
50483
50580
  },
50484
50581
  {
50485
- name: 'lifecycleProcessTypeTitle',
50486
- title: 'Lifecycle process type title',
50487
- description: 'Resolved lifecycle process type label in the active locale',
50582
+ name: 'eventTypeTitle',
50583
+ title: 'Lifecycle event type title',
50584
+ description: 'Resolved lifecycle event type label in the active locale',
50488
50585
  dataType: 'string',
50489
50586
  interface: { type: 'text-editor', options: {} },
50490
50587
  },
50491
50588
  {
50492
- name: 'assessmentCaseId',
50493
- title: 'Assessment case ID',
50494
- description: 'AssessmentManagement.AssessmentCase row for this lifecycle questionnaire',
50589
+ name: 'assessmentCaseTitle',
50590
+ title: 'Assessment case title',
50591
+ description: 'Friendly label for AssessmentManagement.AssessmentCase list and fill viewer',
50495
50592
  dataType: 'string',
50496
50593
  interface: { type: 'text-editor', options: {} },
50497
50594
  },
50595
+ {
50596
+ name: 'assessmentCaseId',
50597
+ title: 'Assessment case',
50598
+ description: 'AssessmentManagement.AssessmentCase for this lifecycle questionnaire',
50599
+ dataType: 'string',
50600
+ interface: workflowLookup('AssessmentManagement.AssessmentCase', 'title'),
50601
+ },
50498
50602
  {
50499
50603
  name: 'assessmentSessionId',
50500
- title: 'Assessment session ID',
50501
- description: 'AssessmentManagement.AssessmentSession row for the assignee responder',
50604
+ title: 'Assessment session',
50605
+ description: 'AssessmentManagement.AssessmentSession for the assignee responder',
50502
50606
  dataType: 'string',
50503
- interface: { type: 'text-editor', options: {} },
50607
+ interface: workflowLookup('AssessmentManagement.AssessmentSession', 'id'),
50504
50608
  },
50505
50609
  ],
50506
50610
  inputs: [
50507
50611
  {
50508
50612
  name: 'employeeId',
50509
- title: 'Employee ID',
50510
- description: 'Subject employee row id',
50613
+ title: 'Employee',
50614
+ description: 'Subject employee',
50511
50615
  dataType: 'string',
50512
- interface: { type: 'text-editor', options: {} },
50616
+ interface: workflowLookup('HumanCapitalManagement.Employee', 'person.fullName', {
50617
+ columns: ['person.fullName', 'employeeCode'],
50618
+ }),
50513
50619
  },
50514
50620
  {
50515
50621
  name: 'questionnaireId',
50516
- title: 'Questionnaire ID',
50517
- description: 'From lifecycle process type template',
50622
+ title: 'Questionnaire',
50623
+ description: 'From lifecycle event type template',
50518
50624
  dataType: 'string',
50519
- interface: { type: 'text-editor', options: {} },
50625
+ interface: workflowLookup('AssessmentManagement.Questionnaire', 'title', {
50626
+ columns: ['name', 'title'],
50627
+ }),
50520
50628
  },
50521
50629
  {
50522
- name: 'lifecycleProcessTypeId',
50523
- title: 'Lifecycle process type ID',
50524
- description: 'Optional; forwarded to task context',
50630
+ name: 'eventTypeId',
50631
+ title: 'Lifecycle event type',
50632
+ description: 'Lifecycle event type template',
50525
50633
  dataType: 'string',
50526
- interface: { type: 'text-editor', options: {} },
50634
+ interface: workflowLookup('HumanCapitalManagement.LifecycleEventType', 'title', {
50635
+ columns: ['name', 'title'],
50636
+ }),
50527
50637
  },
50528
50638
  {
50529
50639
  name: 'targetEmployeeStatusId',
50530
- title: 'Target employee status id',
50640
+ title: 'Target employee status',
50531
50641
  description: 'Applied to Employee.statusId when manager approves',
50532
50642
  dataType: 'string',
50533
50643
  interface: { type: 'text-editor', options: {} },
@@ -50535,9 +50645,9 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50535
50645
  {
50536
50646
  name: 'effectiveDate',
50537
50647
  title: 'Effective date',
50538
- description: 'Prefilled on the lifecycle process create form (ISO yyyy-mm-dd); optional',
50539
- dataType: 'string',
50540
- interface: { type: 'text-editor', options: {} },
50648
+ description: 'Prefilled on the lifecycle event create form; optional',
50649
+ dataType: 'date',
50650
+ interface: workflowDate(),
50541
50651
  },
50542
50652
  {
50543
50653
  name: 'employeeDisplayName',
@@ -50547,9 +50657,16 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50547
50657
  interface: { type: 'text-editor', options: {} },
50548
50658
  },
50549
50659
  {
50550
- name: 'lifecycleProcessTypeTitle',
50551
- title: 'Lifecycle process type title',
50552
- description: 'Lifecycle process type label in the active locale',
50660
+ name: 'eventTypeTitle',
50661
+ title: 'Lifecycle event type title',
50662
+ description: 'Lifecycle event type label in the active locale',
50663
+ dataType: 'string',
50664
+ interface: { type: 'text-editor', options: {} },
50665
+ },
50666
+ {
50667
+ name: 'assessmentCaseTitle',
50668
+ title: 'Assessment case title',
50669
+ description: 'Friendly label for AssessmentManagement.AssessmentCase and fill viewer',
50553
50670
  dataType: 'string',
50554
50671
  interface: { type: 'text-editor', options: {} },
50555
50672
  },
@@ -50566,11 +50683,12 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50566
50683
  variables: [
50567
50684
  { variableName: 'employeeId', value: '{{ inputs.employeeId }}' },
50568
50685
  { variableName: 'questionnaireId', value: '{{ inputs.questionnaireId }}' },
50569
- { variableName: 'lifecycleProcessTypeId', value: '{{ inputs.lifecycleProcessTypeId }}' },
50686
+ { variableName: 'eventTypeId', value: '{{ inputs.eventTypeId }}' },
50570
50687
  { variableName: 'targetEmployeeStatusId', value: '{{ inputs.targetEmployeeStatusId }}' },
50571
50688
  { variableName: 'effectiveDate', value: '{{ inputs.effectiveDate }}' },
50572
50689
  { variableName: 'employeeDisplayName', value: '{{ inputs.employeeDisplayName }}' },
50573
- { variableName: 'lifecycleProcessTypeTitle', value: '{{ inputs.lifecycleProcessTypeTitle }}' },
50690
+ { variableName: 'eventTypeTitle', value: '{{ inputs.eventTypeTitle }}' },
50691
+ { variableName: 'assessmentCaseTitle', value: '{{ inputs.assessmentCaseTitle || inputs.employeeDisplayName }}' },
50574
50692
  ],
50575
50693
  },
50576
50694
  },
@@ -50602,39 +50720,39 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50602
50720
  },
50603
50721
  },
50604
50722
  {
50605
- id: 'captureLifecycleProcessDetailsForm',
50723
+ id: 'captureLifecycleEventDetailsForm',
50606
50724
  name: 'workflow-activity:create-entity-form',
50607
50725
  inputs: {
50608
50726
  module: 'HumanCapitalManagement',
50609
- entity: 'EmployeeLifecycleProcess',
50727
+ entity: 'LifecycleEvent',
50610
50728
  persistInWorkflow: true,
50611
- excludes: ['lifecycleProcessTypeId'],
50729
+ excludes: ['eventTypeId'],
50612
50730
  readonlys: ['employeeId'],
50613
50731
  data: {
50614
50732
  employeeId: '{{ variables.employeeId }}',
50615
- lifecycleProcessTypeId: '{{ variables.lifecycleProcessTypeId }}',
50616
- processAssigneeUserId: '{{ variables.managerUserId || variables.initiatorUserId }}',
50617
- effectiveDate: '{{ variables.effectiveDate }}',
50733
+ eventTypeId: '{{ variables.eventTypeId }}',
50734
+ assignedToUserId: '{{ variables.managerUserId || variables.initiatorUserId }}',
50618
50735
  notes: '',
50619
50736
  },
50620
50737
  },
50621
50738
  },
50622
50739
  {
50623
- id: 'createEmployeeLifecycleProcessRecord',
50740
+ id: 'createLifecycleEventRecord',
50624
50741
  name: 'workflow-activity:entity-create',
50625
50742
  inputs: {
50626
- entity: 'HumanCapitalManagement.EmployeeLifecycleProcess',
50743
+ entity: 'HumanCapitalManagement.LifecycleEvent',
50627
50744
  data: {
50628
50745
  employeeId: '{{ variables.employeeId }}',
50629
- lifecycleProcessTypeId: '{{ variables.lifecycleProcessTypeId }}',
50630
- processAssigneeUserId: '{{ outputs.result.processAssigneeUserId }}',
50631
- effectiveDate: '{{ outputs.result.effectiveDate }}',
50632
- notes: '{{ outputs.result.notes }}',
50746
+ eventTypeId: '{{ variables.eventTypeId }}',
50747
+ assignedToUserId: '{{ variables.assignedToUserId }}',
50748
+ effectiveDate: '{{ variables.effectiveDate }}',
50749
+ notes: '{{ variables.notes }}',
50633
50750
  statusId: 'in-progress',
50634
50751
  },
50635
50752
  },
50636
50753
  outputToVariables: {
50637
- employeeLifecycleProcessId: 'id',
50754
+ lifecycleEventId: 'id',
50755
+ lifecycleEventStatusId: 'statusId',
50638
50756
  },
50639
50757
  },
50640
50758
  {
@@ -50644,8 +50762,7 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50644
50762
  entity: 'AssessmentManagement.AssessmentCase',
50645
50763
  data: {
50646
50764
  questionnaireId: '{{ variables.questionnaireId }}',
50647
- title: '{{ variables.lifecycleProcessTypeTitle }} — {{ variables.employeeDisplayName }}',
50648
- description: 'Employee lifecycle process {{ variables.employeeLifecycleProcessId }}',
50765
+ title: '{{ variables.assessmentCaseTitle || variables.employeeDisplayName }}',
50649
50766
  subjectRef: {
50650
50767
  type: 'HumanCapitalManagement.Employee',
50651
50768
  id: '{{ variables.employeeId }}',
@@ -50680,7 +50797,7 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50680
50797
  id: 'showLifecycleStartCancelledToast',
50681
50798
  name: 'workflow-activity:show-toast',
50682
50799
  inputs: {
50683
- message: '@human-capital-management:employee-lifecycle-processes.messages.lifecycle-start-cancelled',
50800
+ message: '@human-capital-management:lifecycle-events.messages.lifecycle-start-cancelled',
50684
50801
  type: 'info',
50685
50802
  },
50686
50803
  },
@@ -50688,20 +50805,24 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50688
50805
  id: 'subjectFillQuestionnaireTask',
50689
50806
  name: 'workflow-activity:human-task',
50690
50807
  inputs: {
50691
- title: '@human-capital-management:employee-lifecycle-processes.tasks.task-title',
50692
- description: '@human-capital-management:employee-lifecycle-processes.tasks.questionnaire.description',
50808
+ title: '@human-capital-management:lifecycle-events.tasks.task-title',
50809
+ description: '@human-capital-management:lifecycle-events.tasks.questionnaire.description',
50693
50810
  assignedUserIds: '{{ variables.managerUserId || variables.initiatorUserId }}',
50694
50811
  context: {
50695
50812
  employeeId: '{{ variables.employeeId }}',
50696
50813
  questionnaireId: '{{ variables.questionnaireId }}',
50697
- lifecycleProcessTypeId: '{{ variables.lifecycleProcessTypeId }}',
50814
+ eventTypeId: '{{ variables.eventTypeId }}',
50815
+ effectiveDate: '{{ variables.effectiveDate }}',
50816
+ lifecycleEventId: '{{ variables.lifecycleEventId }}',
50817
+ statusId: '{{ variables.lifecycleEventStatusId }}',
50818
+ entityType: 'HumanCapitalManagement.LifecycleEvent',
50698
50819
  _taskI18n: {
50699
50820
  employeeDisplayName: '{{ variables.employeeDisplayName }}',
50700
- lifecycleProcessTypeTitle: '{{ variables.lifecycleProcessTypeTitle }}',
50821
+ eventTypeTitle: '{{ variables.eventTypeTitle }}',
50701
50822
  effectiveDate: '{{ variables.effectiveDate }}',
50702
50823
  },
50703
50824
  _taskTitleParts: [
50704
- '{{ variables.lifecycleProcessTypeTitle }}',
50825
+ '{{ variables.eventTypeTitle }}',
50705
50826
  '{{ variables.employeeDisplayName }}',
50706
50827
  ],
50707
50828
  },
@@ -50724,38 +50845,47 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50724
50845
  inputs: {
50725
50846
  caseId: '{{ variables.assessmentCaseId }}',
50726
50847
  sessionId: '{{ variables.assessmentSessionId }}',
50848
+ title: '{{ variables.assessmentCaseTitle || variables.employeeDisplayName }}',
50727
50849
  showAs: 'popup',
50728
50850
  },
50729
50851
  },
50730
50852
  {
50731
- id: 'markLifecycleAwaitingManagerApproval',
50853
+ id: 'markLifecycleEventAwaitingManagerApproval',
50732
50854
  name: 'workflow-activity:entity-update',
50733
50855
  inputs: {
50734
- entity: 'HumanCapitalManagement.EmployeeLifecycleProcess',
50735
- id: '{{ variables.employeeLifecycleProcessId }}',
50856
+ entity: 'HumanCapitalManagement.LifecycleEvent',
50857
+ id: '{{ variables.lifecycleEventId }}',
50736
50858
  data: {
50737
50859
  notes: 'Questionnaire completed; awaiting manager approval.',
50860
+ statusId: AXPSystemStatusType.WaitingSignOff,
50738
50861
  },
50739
50862
  },
50863
+ outputToVariables: {
50864
+ lifecycleEventStatusId: 'data.statusId',
50865
+ },
50740
50866
  },
50741
50867
  {
50742
50868
  id: 'managerApproveEmployeeStatusTask',
50743
50869
  name: 'workflow-activity:human-task',
50744
50870
  inputs: {
50745
- title: '@human-capital-management:employee-lifecycle-processes.tasks.task-title',
50746
- description: '@human-capital-management:employee-lifecycle-processes.tasks.manager-approval.description',
50871
+ title: '@human-capital-management:lifecycle-events.tasks.task-title',
50872
+ description: '@human-capital-management:lifecycle-events.tasks.manager-approval.description',
50747
50873
  assignedUserIds: '{{ variables.managerUserId || variables.initiatorUserId }}',
50748
50874
  context: {
50749
50875
  employeeId: '{{ variables.employeeId }}',
50750
50876
  questionnaireId: '{{ variables.questionnaireId }}',
50751
50877
  targetEmployeeStatusId: '{{ variables.targetEmployeeStatusId }}',
50878
+ effectiveDate: '{{ variables.effectiveDate }}',
50879
+ lifecycleEventId: '{{ variables.lifecycleEventId }}',
50880
+ statusId: '{{ variables.lifecycleEventStatusId }}',
50881
+ entityType: 'HumanCapitalManagement.LifecycleEvent',
50752
50882
  _taskI18n: {
50753
50883
  employeeDisplayName: '{{ variables.employeeDisplayName }}',
50754
- lifecycleProcessTypeTitle: '{{ variables.lifecycleProcessTypeTitle }}',
50884
+ eventTypeTitle: '{{ variables.eventTypeTitle }}',
50755
50885
  effectiveDate: '{{ variables.effectiveDate }}',
50756
50886
  },
50757
50887
  _taskTitleParts: [
50758
- '{{ variables.lifecycleProcessTypeTitle }}',
50888
+ '{{ variables.eventTypeTitle }}',
50759
50889
  '{{ variables.employeeDisplayName }}',
50760
50890
  ],
50761
50891
  },
@@ -50791,11 +50921,11 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50791
50921
  },
50792
50922
  },
50793
50923
  {
50794
- id: 'updateEmployeeLifecycleProcessCompleted',
50924
+ id: 'updateLifecycleEventCompleted',
50795
50925
  name: 'workflow-activity:entity-update',
50796
50926
  inputs: {
50797
- entity: 'HumanCapitalManagement.EmployeeLifecycleProcess',
50798
- id: '{{ variables.employeeLifecycleProcessId }}',
50927
+ entity: 'HumanCapitalManagement.LifecycleEvent',
50928
+ id: '{{ variables.lifecycleEventId }}',
50799
50929
  data: {
50800
50930
  statusId: 'completed',
50801
50931
  },
@@ -50821,11 +50951,11 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50821
50951
  },
50822
50952
  },
50823
50953
  {
50824
- id: 'updateEmployeeLifecycleProcessCancelled',
50954
+ id: 'updateLifecycleEventCancelled',
50825
50955
  name: 'workflow-activity:entity-update',
50826
50956
  inputs: {
50827
- entity: 'HumanCapitalManagement.EmployeeLifecycleProcess',
50828
- id: '{{ variables.employeeLifecycleProcessId }}',
50957
+ entity: 'HumanCapitalManagement.LifecycleEvent',
50958
+ id: '{{ variables.lifecycleEventId }}',
50829
50959
  data: {
50830
50960
  statusId: 'cancelled',
50831
50961
  },
@@ -50846,7 +50976,7 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50846
50976
  id: 'showLifecycleRejectedToast',
50847
50977
  name: 'workflow-activity:show-toast',
50848
50978
  inputs: {
50849
- message: 'Employee lifecycle process was rejected by manager.',
50979
+ message: 'Lifecycle event was rejected by manager.',
50850
50980
  type: 'warning',
50851
50981
  },
50852
50982
  },
@@ -50866,18 +50996,18 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50866
50996
  },
50867
50997
  {
50868
50998
  source: { activtyName: 'resolveManagerFromSubjectEmployee', port: 'done' },
50869
- target: { activtyName: 'captureLifecycleProcessDetailsForm' },
50999
+ target: { activtyName: 'captureLifecycleEventDetailsForm' },
50870
51000
  },
50871
51001
  {
50872
- source: { activtyName: 'captureLifecycleProcessDetailsForm', port: 'Submitted' },
50873
- target: { activtyName: 'createEmployeeLifecycleProcessRecord' },
51002
+ source: { activtyName: 'captureLifecycleEventDetailsForm', port: 'Submitted' },
51003
+ target: { activtyName: 'createLifecycleEventRecord' },
50874
51004
  },
50875
51005
  {
50876
- source: { activtyName: 'captureLifecycleProcessDetailsForm', port: 'Cancelled' },
51006
+ source: { activtyName: 'captureLifecycleEventDetailsForm', port: 'Cancelled' },
50877
51007
  target: { activtyName: 'showLifecycleStartCancelledToast' },
50878
51008
  },
50879
51009
  {
50880
- source: { activtyName: 'createEmployeeLifecycleProcessRecord', port: 'Done' },
51010
+ source: { activtyName: 'createLifecycleEventRecord', port: 'Done' },
50881
51011
  target: { activtyName: 'createAssessmentCaseForLifecycle' },
50882
51012
  },
50883
51013
  {
@@ -50894,7 +51024,7 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50894
51024
  },
50895
51025
  {
50896
51026
  source: { activtyName: 'fillLifecycleQuestionnaire', port: 'Submitted' },
50897
- target: { activtyName: 'markLifecycleAwaitingManagerApproval' },
51027
+ target: { activtyName: 'markLifecycleEventAwaitingManagerApproval' },
50898
51028
  },
50899
51029
  {
50900
51030
  source: { activtyName: 'fillLifecycleQuestionnaire', port: 'Saved' },
@@ -50905,7 +51035,7 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50905
51035
  target: { activtyName: 'subjectFillQuestionnaireTask' },
50906
51036
  },
50907
51037
  {
50908
- source: { activtyName: 'markLifecycleAwaitingManagerApproval', port: 'Done' },
51038
+ source: { activtyName: 'markLifecycleEventAwaitingManagerApproval', port: 'Done' },
50909
51039
  target: { activtyName: 'managerApproveEmployeeStatusTask' },
50910
51040
  },
50911
51041
  {
@@ -50914,10 +51044,10 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50914
51044
  },
50915
51045
  {
50916
51046
  source: { activtyName: 'managerApproveEmployeeStatusTask', port: 'reject' },
50917
- target: { activtyName: 'updateEmployeeLifecycleProcessCancelled' },
51047
+ target: { activtyName: 'updateLifecycleEventCancelled' },
50918
51048
  },
50919
51049
  {
50920
- source: { activtyName: 'updateEmployeeLifecycleProcessCancelled', port: 'Done' },
51050
+ source: { activtyName: 'updateLifecycleEventCancelled', port: 'Done' },
50921
51051
  target: { activtyName: 'cancelAssessmentCaseOnReject' },
50922
51052
  },
50923
51053
  {
@@ -50926,10 +51056,10 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50926
51056
  },
50927
51057
  {
50928
51058
  source: { activtyName: 'updateEmployeeTargetStatus', port: 'Done' },
50929
- target: { activtyName: 'updateEmployeeLifecycleProcessCompleted' },
51059
+ target: { activtyName: 'updateLifecycleEventCompleted' },
50930
51060
  },
50931
51061
  {
50932
- source: { activtyName: 'updateEmployeeLifecycleProcessCompleted', port: 'Done' },
51062
+ source: { activtyName: 'updateLifecycleEventCompleted', port: 'Done' },
50933
51063
  target: { activtyName: 'closeAssessmentCaseOnApprove' },
50934
51064
  },
50935
51065
  {
@@ -50939,14 +51069,14 @@ const employeeLifecycleGuidedFlowWorkflowDefinition = {
50939
51069
  ],
50940
51070
  },
50941
51071
  };
50942
- const employeeLifecycleGuidedFlowWorkflowName = 'employeeLifecycleGuidedFlow';
50943
- /** Stable id so lifecycle process type mocks and seeds resolve the workflow row predictably. */
50944
- const EMPLOYEE_LIFECYCLE_GUIDED_FLOW_WORKFLOW_DEFINITION_ID = '7f000010-0010-4111-a111-0e0e0e0e0e0e';
51072
+ const employeeLifecycleEventFlowWorkflowName = 'employee-lifecycle-event-flow';
51073
+ /** Stable id so lifecycle event type mocks and seeds resolve the workflow row predictably. */
51074
+ const EMPLOYEE_LIFECYCLE_EVENT_FLOW_WORKFLOW_DEFINITION_ID = '7f000010-0010-4111-a111-0e0e0e0e0e0e';
50945
51075
  /**
50946
51076
  * Workflow definition entity row for WorkflowManagement.WorkflowDefinition seeding.
50947
51077
  */
50948
- const employeeLifecycleGuidedFlowWorkflowEntityMock = createWorkflowDefinitionEntityMock(employeeLifecycleGuidedFlowWorkflowDefinition, {
50949
- id: EMPLOYEE_LIFECYCLE_GUIDED_FLOW_WORKFLOW_DEFINITION_ID,
51078
+ const employeeLifecycleEventFlowWorkflowEntityMock = createWorkflowDefinitionEntityMock(employeeLifecycleEventFlowWorkflowDefinition, {
51079
+ id: EMPLOYEE_LIFECYCLE_EVENT_FLOW_WORKFLOW_DEFINITION_ID,
50950
51080
  statusId: AXPSystemStatusType.Published,
50951
51081
  });
50952
51082
 
@@ -50954,12 +51084,12 @@ const employeeLifecycleGuidedFlowWorkflowEntityMock = createWorkflowDefinitionEn
50954
51084
  //#endregion
50955
51085
  //#region ---- Stable demo IDs ----
50956
51086
  /** Stable ids so seeds and related mocks resolve types predictably. */
50957
- const MOCK_LIFECYCLE_PROCESS_TYPE_ONBOARDING_ID = '7f000001-0001-4111-a111-010101010101';
50958
- const MOCK_LIFECYCLE_PROCESS_TYPE_SEPARATION_ID = '7f000002-0002-4111-a111-020202020202';
50959
- const MOCK_LIFECYCLE_PROCESS_TYPE_PROMOTION_ID = '7f000003-0003-4111-a111-030303030303';
50960
- const MOCK_LIFECYCLE_PROCESS_TYPE_TRANSFER_ID = '7f000004-0004-4111-a111-040404040404';
50961
- const MOCK_LIFECYCLE_PROCESS_TYPE_RETURN_TO_WORK_ID = '7f000005-0005-4111-a111-050505050505';
50962
- const MOCK_LIFECYCLE_PROCESS_TYPE_LEAVE_OF_ABSENCE_ID = '7f000006-0006-4111-a111-060606060606';
51087
+ const MOCK_LIFECYCLE_EVENT_TYPE_ONBOARDING_ID = '7f000001-0001-4111-a111-010101010101';
51088
+ const MOCK_LIFECYCLE_EVENT_TYPE_SEPARATION_ID = '7f000002-0002-4111-a111-020202020202';
51089
+ const MOCK_LIFECYCLE_EVENT_TYPE_PROMOTION_ID = '7f000003-0003-4111-a111-030303030303';
51090
+ const MOCK_LIFECYCLE_EVENT_TYPE_TRANSFER_ID = '7f000004-0004-4111-a111-040404040404';
51091
+ const MOCK_LIFECYCLE_EVENT_TYPE_RETURN_TO_WORK_ID = '7f000005-0005-4111-a111-050505050505';
51092
+ const MOCK_LIFECYCLE_EVENT_TYPE_LEAVE_OF_ABSENCE_ID = '7f000006-0006-4111-a111-060606060606';
50963
51093
  //#endregion
50964
51094
  //#region ---- Meta-data builder payloads ----
50965
51095
  const M$p = createMultiLanguageString;
@@ -50995,22 +51125,22 @@ const separationQuestionnaireStub = {
50995
51125
  id: QUESTIONNAIRE_ID_EMPLOYEE_SEPARATION_CHECKLIST,
50996
51126
  title: M$p('Employee separation checklist', 'چک‌لیست جدایی کارمند'),
50997
51127
  };
50998
- function employeeLifecycleGuidedFlowStub() {
51128
+ function employeeLifecycleEventFlowStub() {
50999
51129
  return {
51000
- id: EMPLOYEE_LIFECYCLE_GUIDED_FLOW_WORKFLOW_DEFINITION_ID,
51001
- title: employeeLifecycleGuidedFlowWorkflowEntityMock.title ?? undefined,
51130
+ id: EMPLOYEE_LIFECYCLE_EVENT_FLOW_WORKFLOW_DEFINITION_ID,
51131
+ title: employeeLifecycleEventFlowWorkflowEntityMock.title ?? undefined,
51002
51132
  };
51003
51133
  }
51004
51134
  //#endregion
51005
51135
  //#region ---- Mock data ----
51006
- const LIFECYCLE_PROCESS_TYPES_MOCK = [
51136
+ const LIFECYCLE_EVENT_TYPES_MOCK = [
51007
51137
  {
51008
- id: MOCK_LIFECYCLE_PROCESS_TYPE_ONBOARDING_ID,
51009
- name: 'ONBOARDING_DEFAULT',
51010
- title: M$p('Default onboarding', 'استخدام و ورود پیش‌فرض'),
51138
+ id: MOCK_LIFECYCLE_EVENT_TYPE_ONBOARDING_ID,
51139
+ name: 'ONBOARDING',
51140
+ title: M$p('Onboarding', 'استخدام و ورود'),
51011
51141
  description: M$p('Standard new-hire path: profile capture, provisioning checklist, and employee induction questionnaire.', 'مسیر استاندارد کارکنان جدید: ثبت مشخصات، چک‌لیست دسترسی و پرسشنامه آشنایی کارمند.'),
51012
- workflowDefinitionId: EMPLOYEE_LIFECYCLE_GUIDED_FLOW_WORKFLOW_DEFINITION_ID,
51013
- workflowDefinition: employeeLifecycleGuidedFlowStub(),
51142
+ workflowDefinitionId: EMPLOYEE_LIFECYCLE_EVENT_FLOW_WORKFLOW_DEFINITION_ID,
51143
+ workflowDefinition: employeeLifecycleEventFlowStub(),
51014
51144
  questionnaireId: QUESTIONNAIRE_ID_HR_EMPLOYEE_INDUCTION,
51015
51145
  questionnaire: onboardingQuestionnaireStub,
51016
51146
  icon: 'fa-light fa-user-plus',
@@ -51062,12 +51192,12 @@ const LIFECYCLE_PROCESS_TYPES_MOCK = [
51062
51192
  ]),
51063
51193
  },
51064
51194
  {
51065
- id: MOCK_LIFECYCLE_PROCESS_TYPE_SEPARATION_ID,
51195
+ id: MOCK_LIFECYCLE_EVENT_TYPE_SEPARATION_ID,
51066
51196
  name: 'SEPARATION_DEFAULT',
51067
51197
  title: M$p('Offboarding / separation', 'خروج از سازمان / جدایی'),
51068
51198
  description: M$p('Exit checklist: access removal, asset return, employee separation questionnaire, and final approvals.', 'چک‌لیست خروج: حذف دسترسی، بازگشت دارایی، پرسشنامه جدایی کارمند و تأییدهای نهایی.'),
51069
- workflowDefinitionId: EMPLOYEE_LIFECYCLE_GUIDED_FLOW_WORKFLOW_DEFINITION_ID,
51070
- workflowDefinition: employeeLifecycleGuidedFlowStub(),
51199
+ workflowDefinitionId: EMPLOYEE_LIFECYCLE_EVENT_FLOW_WORKFLOW_DEFINITION_ID,
51200
+ workflowDefinition: employeeLifecycleEventFlowStub(),
51071
51201
  questionnaireId: QUESTIONNAIRE_ID_EMPLOYEE_SEPARATION_CHECKLIST,
51072
51202
  questionnaire: separationQuestionnaireStub,
51073
51203
  icon: 'fa-light fa-door-open',
@@ -51113,7 +51243,7 @@ const LIFECYCLE_PROCESS_TYPES_MOCK = [
51113
51243
  ]),
51114
51244
  },
51115
51245
  {
51116
- id: MOCK_LIFECYCLE_PROCESS_TYPE_PROMOTION_ID,
51246
+ id: MOCK_LIFECYCLE_EVENT_TYPE_PROMOTION_ID,
51117
51247
  name: 'PROMOTION_DEFAULT',
51118
51248
  title: M$p('Promotion', 'ارتقای شغلی'),
51119
51249
  description: M$p('Title or grade change with effective date and compensation band capture.', 'تغییر عنوان یا پایه با تاریخ اثر و ثبت بازهٔ حقوق و مزایا.'),
@@ -51156,7 +51286,7 @@ const LIFECYCLE_PROCESS_TYPES_MOCK = [
51156
51286
  ]),
51157
51287
  },
51158
51288
  {
51159
- id: MOCK_LIFECYCLE_PROCESS_TYPE_TRANSFER_ID,
51289
+ id: MOCK_LIFECYCLE_EVENT_TYPE_TRANSFER_ID,
51160
51290
  name: 'TRANSFER_DEFAULT',
51161
51291
  title: M$p('Transfer', 'انتقال سازمانی'),
51162
51292
  description: M$p('Move between business units or locations with manager and desk assignments.', 'جابه‌جایی بین واحد یا محل با مدیر و میز کار.'),
@@ -51199,7 +51329,7 @@ const LIFECYCLE_PROCESS_TYPES_MOCK = [
51199
51329
  ]),
51200
51330
  },
51201
51331
  {
51202
- id: MOCK_LIFECYCLE_PROCESS_TYPE_RETURN_TO_WORK_ID,
51332
+ id: MOCK_LIFECYCLE_EVENT_TYPE_RETURN_TO_WORK_ID,
51203
51333
  name: 'RETURN_TO_WORK_DEFAULT',
51204
51334
  title: M$p('Return to work', 'بازگشت به کار'),
51205
51335
  description: M$p('Medical or parental leave return: clearance, restrictions, and phased schedule.', 'بازگشت پس از مرخصی استعلاجی یا زایمان: مجوز، محدودیت‌ها و برنامه تدریجی.'),
@@ -51242,7 +51372,7 @@ const LIFECYCLE_PROCESS_TYPES_MOCK = [
51242
51372
  ]),
51243
51373
  },
51244
51374
  {
51245
- id: MOCK_LIFECYCLE_PROCESS_TYPE_LEAVE_OF_ABSENCE_ID,
51375
+ id: MOCK_LIFECYCLE_EVENT_TYPE_LEAVE_OF_ABSENCE_ID,
51246
51376
  name: 'LEAVE_OF_ABSENCE_DEFAULT',
51247
51377
  title: M$p('Leave of absence', 'مرخصی بلندمدت / غیبت موقت'),
51248
51378
  description: M$p('Structured absence workflow placeholder; leave entitlement stays on Leave Request records.', 'جریان مرخصی بلندمدت؛ محاسبه استحقاق مرخصی همچنان در رکورد درخواست مرخصی.'),
@@ -51290,229 +51420,17 @@ const LIFECYCLE_PROCESS_TYPES_MOCK = [
51290
51420
  ];
51291
51421
  //#endregion
51292
51422
 
51293
- //#region ---- Imports ----
51294
- //#endregion
51295
- //#region ---- Mock data ----
51296
- const onboardingType = LIFECYCLE_PROCESS_TYPES_MOCK.find((t) => t.id === MOCK_LIFECYCLE_PROCESS_TYPE_ONBOARDING_ID);
51297
- const separationType = LIFECYCLE_PROCESS_TYPES_MOCK.find((t) => t.id === MOCK_LIFECYCLE_PROCESS_TYPE_SEPARATION_ID);
51298
- /** Sample workflow-step assignee for list column demos (not Rod Jensen's login user). */
51299
- const demoProcessAssignee = mockUsers.find((u) => u.displayName === 'Sarah Johnson') ?? mockUsers[0];
51300
- const EMPLOYEE_LIFECYCLE_PROCESSES_MOCK = [
51301
- {
51302
- id: AXPDataGenerator.uuid(),
51303
- employeeId: EMPLOYEES_MOCK[0].id,
51304
- lifecycleProcessTypeId: onboardingType.id,
51305
- lifecycleProcessType: {
51306
- id: onboardingType.id,
51307
- name: onboardingType.name,
51308
- title: onboardingType.title,
51309
- },
51310
- processAssigneeUserId: demoProcessAssignee.id,
51311
- processAssigneeUser: { id: demoProcessAssignee.id, displayName: demoProcessAssignee.displayName },
51312
- effectiveDate: new Date(),
51313
- notes: 'Demo onboarding process instance.',
51314
- statusId: AXPSystemStatuses.Draft.name,
51315
- status: { id: AXPSystemStatuses.Draft.name, title: AXPSystemStatuses.Draft.title },
51316
- },
51317
- {
51318
- id: AXPDataGenerator.uuid(),
51319
- employeeId: EMPLOYEES_MOCK[1].id,
51320
- lifecycleProcessTypeId: separationType.id,
51321
- lifecycleProcessType: {
51322
- id: separationType.id,
51323
- name: separationType.name,
51324
- title: separationType.title,
51325
- },
51326
- processAssigneeUserId: demoProcessAssignee.id,
51327
- processAssigneeUser: { id: demoProcessAssignee.id, displayName: demoProcessAssignee.displayName },
51328
- effectiveDate: new Date(),
51329
- notes: 'Demo separation process instance.',
51330
- statusId: AXPSystemStatuses.InProgress.name,
51331
- status: { id: AXPSystemStatuses.InProgress.name, title: AXPSystemStatuses.InProgress.title },
51332
- },
51333
- ];
51334
- //#endregion
51335
-
51336
- class AXMEmployeeLifecycleProcessDataSeeder {
51423
+ class AXMLifecycleEventTypeDataSeeder {
51337
51424
  constructor() {
51338
51425
  this.storageService = inject(AXPEntityStorageService);
51339
51426
  }
51340
51427
  async seed() {
51341
- await this.storageService.initial(RootConfig$j.entities.employeeLifecycleProcess.source, EMPLOYEE_LIFECYCLE_PROCESSES_MOCK);
51428
+ await this.storageService.initial(RootConfig$j.entities.lifecycleEventType.source, LIFECYCLE_EVENT_TYPES_MOCK);
51342
51429
  }
51343
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMEmployeeLifecycleProcessDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
51344
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMEmployeeLifecycleProcessDataSeeder }); }
51430
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLifecycleEventTypeDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
51431
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLifecycleEventTypeDataSeeder }); }
51345
51432
  }
51346
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMEmployeeLifecycleProcessDataSeeder, decorators: [{
51347
- type: Injectable
51348
- }] });
51349
-
51350
- function generateLeaveType() {
51351
- const uuid = AXPDataGenerator.uuid;
51352
- const M = createMultiLanguageString;
51353
- return [
51354
- {
51355
- id: uuid(),
51356
- title: M('Annual Leave', 'مرخصی سالانه'),
51357
- description: M('Paid time off for vacation, rest, or personal activities', 'مرخصی استحقاقی برای استراحت یا امور شخصی'),
51358
- color: '#3b82f6',
51359
- },
51360
- {
51361
- id: uuid(),
51362
- title: M("Sick & Carer's Leave", 'مرخصی استعلاجی و مراقبت'),
51363
- description: M('Time off for personal illness or to care for sick family members', 'غیبت به دلیل بیماری یا مراقبت از بیمار خانواده'),
51364
- color: '#ef4444',
51365
- },
51366
- {
51367
- id: uuid(),
51368
- title: M('Rostered Day off', 'روز تعطیل برنامه‌ریزی‌شده'),
51369
- description: M('Scheduled day off as part of the regular work roster', 'روز تعطیل طبق برنامه نوبت کاری'),
51370
- color: '#8b5cf6',
51371
- },
51372
- {
51373
- id: uuid(),
51374
- title: M('Training', 'آموزش'),
51375
- description: M('Time allocated for professional development, courses, or skill enhancement', 'زمان توسعه حرفه‌ای و دوره‌ها'),
51376
- color: '#06b6d4',
51377
- },
51378
- {
51379
- id: uuid(),
51380
- title: M('Compassionate & Bereavement Leave', 'مرخصی انسانی و سوگ'),
51381
- description: M('Time off granted for family emergencies or the death of a loved one', 'مرخصی برای فوت نزدیکان یا شرایط اضطراری خانوادگی'),
51382
- color: '#6366f1',
51383
- },
51384
- {
51385
- id: uuid(),
51386
- title: M('Time Off In Lieu', 'مرخصی جبرانی'),
51387
- description: M('Compensatory time off earned for working additional hours beyond normal schedule', 'جبران ساعت اضافه‌کاری'),
51388
- color: '#10b981',
51389
- },
51390
- {
51391
- id: uuid(),
51392
- title: M('Community Service Leave', 'مرخصی خدمت اجتماعی'),
51393
- description: M('Paid leave for volunteer work or community service activities', 'مرخصی برای داوطلبی و خدمات اجتماعی'),
51394
- color: '#059669',
51395
- },
51396
- {
51397
- id: uuid(),
51398
- title: M('Family & Domestic Violence Leave', 'مرخصی خشونت خانگی'),
51399
- description: M('Paid leave for employees experiencing family or domestic violence situations', 'مرخصی حمایتی برای کارکنان در معرض خشونت خانگی'),
51400
- color: '#ec4899',
51401
- },
51402
- {
51403
- id: uuid(),
51404
- title: M('Long Service Leave', 'مرخصی سنوات'),
51405
- description: M('Extended paid leave granted after many years of continuous service', 'مرخصی طولانی پس از سال‌ها خدمت'),
51406
- color: '#f59e0b',
51407
- },
51408
- {
51409
- id: uuid(),
51410
- title: M('Maternity & Paternal Leave', 'مرخصی زایمان و پدری'),
51411
- description: M('Time off for new parents to care for and bond with their newborn child', 'مرخصی والدین برای مراقبت از نوزاد'),
51412
- color: '#f472b6',
51413
- },
51414
- {
51415
- id: uuid(),
51416
- title: M("Public Holiday's", 'تعطیلات رسمی'),
51417
- description: M('Recognized public holidays and national observances', 'تعطیلات رسمی و مناسبت‌های ملی'),
51418
- color: '#eab308',
51419
- },
51420
- {
51421
- id: uuid(),
51422
- title: M('Unpaid Leave', 'مرخصی بدون حقوق'),
51423
- description: M('Leave without pay for personal reasons or extended time off', 'بدون حقوق به دلایل شخصی'),
51424
- color: '#6b7280',
51425
- },
51426
- {
51427
- id: uuid(),
51428
- title: M("Work's Compensation Leave", 'مرخصی بیمه کار'),
51429
- description: M('Leave due to work-related injury or illness covered by workers compensation', 'مرخصی ناشی از آسیب یا بیماری شغلی'),
51430
- color: '#dc2626',
51431
- },
51432
- ];
51433
- }
51434
- const LEAVE_TYPES_MOCK = generateLeaveType();
51435
-
51436
- class AXMLeaveTypeDataSeeder {
51437
- constructor() {
51438
- this.storageService = inject(AXPEntityStorageService);
51439
- }
51440
- async seed() {
51441
- await this.storageService.initial(RootConfig$j.entities.leaveType.source, LEAVE_TYPES_MOCK);
51442
- }
51443
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveTypeDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
51444
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveTypeDataSeeder }); }
51445
- }
51446
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveTypeDataSeeder, decorators: [{
51447
- type: Injectable
51448
- }] });
51449
-
51450
- const uuid$9 = AXPDataGenerator.uuid;
51451
- const LEAVE_REQUEST_STATUS_DEFINITIONS = [
51452
- AXPSystemStatuses.Pending,
51453
- AXPSystemStatuses.Approved,
51454
- AXPSystemStatuses.Rejected,
51455
- AXPSystemStatuses.Cancelled,
51456
- ];
51457
- function buildLeaveRequests() {
51458
- const results = [];
51459
- EMPLOYEES_MOCK.forEach((employee) => {
51460
- // Generate 2 leave requests per employee
51461
- const count = Math.floor(Math.random() * 2);
51462
- for (let i = 0; i < count; i++) {
51463
- const leaveType = LEAVE_TYPES_MOCK[Math.floor(Math.random() * LEAVE_TYPES_MOCK.length)];
51464
- const duration = Math.floor(Math.random() * 5) + 1; // 1-5 days
51465
- // Spread start/end across past, today, and future (inclusive) relative to "now"
51466
- const startDayOffset = Math.floor(Math.random() * 211) - 120; // -120 .. +90 days
51467
- const start = new Date();
51468
- start.setDate(start.getDate() + startDayOffset);
51469
- const end = new Date(start);
51470
- end.setDate(start.getDate() + duration);
51471
- const statusDefinition = LEAVE_REQUEST_STATUS_DEFINITIONS[Math.floor(Math.random() * LEAVE_REQUEST_STATUS_DEFINITIONS.length)];
51472
- results.push({
51473
- id: uuid$9(),
51474
- employeeId: employee.id,
51475
- employee,
51476
- leaveTypeId: leaveType.id,
51477
- leaveType,
51478
- startDate: start,
51479
- endDate: end,
51480
- durationDays: duration,
51481
- reason: `Request for ${leaveType.title}`,
51482
- statusId: statusDefinition.name,
51483
- status: { id: statusDefinition.name, title: statusDefinition.title },
51484
- });
51485
- }
51486
- });
51487
- return results;
51488
- }
51489
- const LEAVE_REQUESTS_MOCK = buildLeaveRequests();
51490
-
51491
- class AXMLeaveRequestDataSeeder {
51492
- constructor() {
51493
- this.storageService = inject(AXPEntityStorageService);
51494
- }
51495
- async seed() {
51496
- await this.storageService.initial(RootConfig$j.entities.leaveRequest.source, LEAVE_REQUESTS_MOCK);
51497
- }
51498
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveRequestDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
51499
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveRequestDataSeeder }); }
51500
- }
51501
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLeaveRequestDataSeeder, decorators: [{
51502
- type: Injectable
51503
- }] });
51504
-
51505
- class AXMLifecycleProcessTypeDataSeeder {
51506
- constructor() {
51507
- this.storageService = inject(AXPEntityStorageService);
51508
- }
51509
- async seed() {
51510
- await this.storageService.initial(RootConfig$j.entities.lifecycleProcessType.source, LIFECYCLE_PROCESS_TYPES_MOCK);
51511
- }
51512
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLifecycleProcessTypeDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
51513
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLifecycleProcessTypeDataSeeder }); }
51514
- }
51515
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLifecycleProcessTypeDataSeeder, decorators: [{
51433
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMLifecycleEventTypeDataSeeder, decorators: [{
51516
51434
  type: Injectable
51517
51435
  }] });
51518
51436
 
@@ -51960,7 +51878,7 @@ const createLeaveRequestWorkflowEntityMock = createWorkflowDefinitionEntityMock(
51960
51878
 
51961
51879
  /** Human Capital Management workflow definition entity rows seeded into WorkflowManagement.WorkflowDefinition. */
51962
51880
  const humanCapitalManagementWorkflowDefinitionEntityMocks = [
51963
- employeeLifecycleGuidedFlowWorkflowEntityMock,
51881
+ employeeLifecycleEventFlowWorkflowEntityMock,
51964
51882
  createLeaveRequestWorkflowEntityMock,
51965
51883
  ];
51966
51884
  class AXCHumanCapitalManagementWorkflowDefinitionDataSeeder {
@@ -52243,9 +52161,8 @@ class AXCHumanCapitalManagementMockModule {
52243
52161
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMEmployeeDataSeeder, multi: true },
52244
52162
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMPositionAssignmentDataSeeder, multi: true },
52245
52163
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLeaveTypeDataSeeder, multi: true },
52246
- { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLifecycleProcessTypeDataSeeder, multi: true },
52164
+ { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLifecycleEventTypeDataSeeder, multi: true },
52247
52165
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLeaveRequestDataSeeder, multi: true },
52248
- { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMEmployeeLifecycleProcessDataSeeder, multi: true },
52249
52166
  {
52250
52167
  provide: AXP_DATA_SEEDER_TOKEN,
52251
52168
  useClass: AXCHumanCapitalManagementWorkflowDefinitionDataSeeder,
@@ -52264,9 +52181,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
52264
52181
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMEmployeeDataSeeder, multi: true },
52265
52182
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMPositionAssignmentDataSeeder, multi: true },
52266
52183
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLeaveTypeDataSeeder, multi: true },
52267
- { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLifecycleProcessTypeDataSeeder, multi: true },
52184
+ { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLifecycleEventTypeDataSeeder, multi: true },
52268
52185
  { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMLeaveRequestDataSeeder, multi: true },
52269
- { provide: AXP_DATA_SEEDER_TOKEN, useClass: AXMEmployeeLifecycleProcessDataSeeder, multi: true },
52270
52186
  {
52271
52187
  provide: AXP_DATA_SEEDER_TOKEN,
52272
52188
  useClass: AXCHumanCapitalManagementWorkflowDefinitionDataSeeder,
@@ -53600,7 +53516,6 @@ const learningManagementEnrollmentMocks = [
53600
53516
  title: learningManagementTrainingMocks[0].course.title,
53601
53517
  },
53602
53518
  status: 'Approved',
53603
- workflowInstanceId: null,
53604
53519
  notes: null,
53605
53520
  },
53606
53521
  {
@@ -53615,7 +53530,6 @@ const learningManagementEnrollmentMocks = [
53615
53530
  title: learningManagementTrainingMocks[0].course.title,
53616
53531
  },
53617
53532
  status: 'Requested',
53618
- workflowInstanceId: null,
53619
53533
  notes: null,
53620
53534
  },
53621
53535
  ];
@@ -58342,7 +58256,7 @@ const primaryMiddleware = {
58342
58256
  };
58343
58257
 
58344
58258
  /** Keys to omit from version snapshots so we don't duplicate audit metadata in the version store. */
58345
- const VERSION_SNAPSHOT_OMIT_KEYS = ['auditInfo', 'stateInfo', 'ownershipInfo'];
58259
+ const VERSION_SNAPSHOT_OMIT_KEYS = ['auditInfo', 'stateInfo', 'ownershipInfo', 'workflowInfo'];
58346
58260
  function snapshotForVersion(record) {
58347
58261
  if (record == null) {
58348
58262
  return null;
@@ -58356,7 +58270,7 @@ function snapshotForVersion(record) {
58356
58270
  /**
58357
58271
  * Combined middleware: enriches entity records with audit info (who/when) and records
58358
58272
  * version history for the "Change history" timeline. Version snapshots exclude auditInfo
58359
- * (and stateInfo, ownershipInfo) so we don't log audit metadata again in the version store.
58273
+ * (and stateInfo, ownershipInfo, workflowInfo) so we don't log platform metadata again in the version store.
58360
58274
  */
58361
58275
  const historyMiddleware = {
58362
58276
  target: { ops: ['create', 'update', 'delete'], order: 15 },
@@ -59396,8 +59310,8 @@ class AXCMiddlewaresModule {
59396
59310
  { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: childCountMiddleware },
59397
59311
  { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: createFileCastMiddleware },
59398
59312
  { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: primaryMiddleware },
59313
+ { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: visibilityFilterMiddleware }, // order: 20
59399
59314
  // { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: firestoreRequestLoggerMiddleware }, // order: 200 - runs last before backend, logs request/response
59400
- //{ provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: visibilityFilterMiddleware }, // order: 20
59401
59315
  //{ provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: signatureLoaderMiddleware },
59402
59316
  // Sample entity event listener to show logs for all entity.* events
59403
59317
  //{ provide: AXP_DISTRIBUTED_EVENT_LISTENER_PROVIDER, multi: true, useValue: AXCMockEntityLogListener },
@@ -59423,8 +59337,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
59423
59337
  { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: childCountMiddleware },
59424
59338
  { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: createFileCastMiddleware },
59425
59339
  { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: primaryMiddleware },
59340
+ { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: visibilityFilterMiddleware }, // order: 20
59426
59341
  // { provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: firestoreRequestLoggerMiddleware }, // order: 200 - runs last before backend, logs request/response
59427
- //{ provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: visibilityFilterMiddleware }, // order: 20
59428
59342
  //{ provide: AXP_ENTITY_STORAGE_MIDDLEWARE, multi: true, useValue: signatureLoaderMiddleware },
59429
59343
  // Sample entity event listener to show logs for all entity.* events
59430
59344
  //{ provide: AXP_DISTRIBUTED_EVENT_LISTENER_PROVIDER, multi: true, useValue: AXCMockEntityLogListener },
@@ -67136,19 +67050,23 @@ class AXPSecurityManagementRoleDataSeeder {
67136
67050
  const roles = mockRoleDefinitions.map((role) => ({
67137
67051
  ...role,
67138
67052
  }));
67139
- await this.storageService.initial(entityName, roles);
67053
+ await this.storageService.initial(entityName, roles, {
67054
+ mergeType: 'merge',
67055
+ uniqueKeys: ['name'],
67056
+ });
67140
67057
  // Dexie `initial()` skips the whole batch when any role name already exists,
67141
67058
  // so permission changes in role.mock.ts would never reach IndexedDB without this sync.
67142
67059
  await this.syncRolePermissionsFromMock(entityName);
67143
67060
  }
67144
67061
  /**
67145
67062
  * Updates permissions (and metadata) on seeded roles when mock definitions change.
67063
+ * Skips system/immutable roles — policy middleware rejects those updates on app startup.
67146
67064
  */
67147
67065
  async syncRolePermissionsFromMock(entityName) {
67148
67066
  const storedRoles = await this.storageService.getAll(entityName);
67149
67067
  for (const mockRole of mockRoleDefinitions) {
67150
67068
  const existing = storedRoles.find((role) => role.name === mockRole.name);
67151
- if (!existing?.id) {
67069
+ if (!existing?.id || this.isPolicyProtectedRole(existing) || this.isPolicyProtectedRole(mockRole)) {
67152
67070
  continue;
67153
67071
  }
67154
67072
  await this.storageService.updateOne(entityName, existing.id, {
@@ -67158,6 +67076,9 @@ class AXPSecurityManagementRoleDataSeeder {
67158
67076
  });
67159
67077
  }
67160
67078
  }
67079
+ isPolicyProtectedRole(role) {
67080
+ return role.stateInfo?.isImmutable === true || role.stateInfo?.isSystem === true;
67081
+ }
67161
67082
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXPSecurityManagementRoleDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
67162
67083
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXPSecurityManagementRoleDataSeeder }); }
67163
67084
  }
@@ -67180,20 +67101,59 @@ class AXPSecurityManagementUserDataSeeder {
67180
67101
  }
67181
67102
  async seed() {
67182
67103
  const entityName = `${RootConfig$6.module.name}.${RootConfig$6.entities.users.name}`;
67183
- await this.storageService.initial(entityName, mockUsers);
67104
+ await this.storageService.initial(entityName, mockUsers, {
67105
+ mergeType: 'merge',
67106
+ uniqueKeys: ['username'],
67107
+ });
67108
+ await this.syncMissingUsersFromMock(entityName);
67109
+ await this.syncOwnershipInfoFromMock(entityName);
67184
67110
  await this.syncCollaborationDemoUserRoles(entityName);
67185
67111
  }
67112
+ /**
67113
+ * Inserts mock users added after the first IndexedDB seed (e.g. demo accounts for new features).
67114
+ */
67115
+ async syncMissingUsersFromMock(usersEntityName) {
67116
+ const storedUsers = await this.backend.getAll(usersEntityName);
67117
+ for (const mockUser of mockUsers) {
67118
+ const exists = storedUsers.some((user) => user.username === mockUser.username);
67119
+ if (exists) {
67120
+ continue;
67121
+ }
67122
+ await this.storageService.insertOne(usersEntityName, mockUser);
67123
+ }
67124
+ }
67125
+ /**
67126
+ * Aligns stored user ownership with mock data so tenant-scoped list filtering works after re-seeds.
67127
+ */
67128
+ async syncOwnershipInfoFromMock(usersEntityName) {
67129
+ const storedUsers = await this.backend.getAll(usersEntityName);
67130
+ for (const mockUser of mockUsers) {
67131
+ if (!mockUser.ownershipInfo) {
67132
+ continue;
67133
+ }
67134
+ const storedUser = storedUsers.find((user) => user.username === mockUser.username);
67135
+ if (!storedUser?.id) {
67136
+ continue;
67137
+ }
67138
+ if (storedUser.ownershipInfo?.tenantId === mockUser.ownershipInfo.tenantId) {
67139
+ continue;
67140
+ }
67141
+ await this.storageService.updateOne(usersEntityName, storedUser.id, {
67142
+ ownershipInfo: mockUser.ownershipInfo,
67143
+ });
67144
+ }
67145
+ }
67186
67146
  /**
67187
67147
  * Keeps MAGFA collaboration demo user aligned with the conversation-only role in storage.
67188
67148
  */
67189
67149
  async syncCollaborationDemoUserRoles(usersEntityName) {
67190
67150
  const rolesEntityName = `${RootConfig$6.module.name}.${RootConfig$6.entities.roles.name}`;
67191
- const storedRoles = await this.storageService.getAll(rolesEntityName);
67151
+ const storedRoles = await this.backend.getAll(rolesEntityName);
67192
67152
  const conversationOnlyRole = storedRoles.find((role) => role.name === 'conversation-only');
67193
67153
  if (!conversationOnlyRole?.id) {
67194
67154
  return;
67195
67155
  }
67196
- const storedUsers = await this.storageService.getAll(usersEntityName);
67156
+ const storedUsers = await this.backend.getAll(usersEntityName);
67197
67157
  const demoUser = storedUsers.find((u) => u.username === 'mohamad.pour.ghorban');
67198
67158
  if (!demoUser?.id) {
67199
67159
  return;
@@ -67457,7 +67417,7 @@ class AXCSecurityManagementMockModule {
67457
67417
  provideQuerySetups([
67458
67418
  {
67459
67419
  key: 'SecurityManagement:User:RolesForListColumn',
67460
- loader: () => import('./acorex-connectivity-mock-user-roles-for-list-column.query-vEJew9Py.mjs').then((m) => m.UserRolesForListColumnQuery),
67420
+ loader: () => import('./acorex-connectivity-mock-user-roles-for-list-column.query-CAhDQnWv.mjs').then((m) => m.UserRolesForListColumnQuery),
67461
67421
  },
67462
67422
  ]),
67463
67423
  ] }); }
@@ -67501,7 +67461,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
67501
67461
  provideQuerySetups([
67502
67462
  {
67503
67463
  key: 'SecurityManagement:User:RolesForListColumn',
67504
- loader: () => import('./acorex-connectivity-mock-user-roles-for-list-column.query-vEJew9Py.mjs').then((m) => m.UserRolesForListColumnQuery),
67464
+ loader: () => import('./acorex-connectivity-mock-user-roles-for-list-column.query-CAhDQnWv.mjs').then((m) => m.UserRolesForListColumnQuery),
67505
67465
  },
67506
67466
  ]),
67507
67467
  ],
@@ -68017,6 +67977,22 @@ function generateTenants() {
68017
67977
  }
68018
67978
  const tenantMocks = generateTenants();
68019
67979
 
67980
+ //#region ---- Subscription Plan ID Constants ----
67981
+ /**
67982
+ * Stable subscription plan primary keys keyed by plan `code`.
67983
+ */
67984
+ const MOCK_SUBSCRIPTION_PLAN_IDS = {
67985
+ 'PREM-001': 'f0000005-0000-4000-a000-000000000001',
67986
+ 'STD-SUB-001': 'f0000005-0000-4000-a000-000000000002',
67987
+ 'ENT-001': 'f0000005-0000-4000-a000-000000000003',
67988
+ 'ORD-STD-001': 'f0000005-0000-4000-a000-000000000004',
67989
+ 'PC-001': 'f0000005-0000-4000-a000-000000000005',
67990
+ 'SM-BASIC-001': 'f0000005-0000-4000-a000-000000000006',
67991
+ 'CM-ENT-001': 'f0000005-0000-4000-a000-000000000007',
67992
+ 'MAGFA-001': 'f0000005-0000-4000-a000-000000000008',
67993
+ };
67994
+ //#endregion
67995
+
68020
67996
  function generateSubscriptionPlans() {
68021
67997
  const plans = [];
68022
67998
  // Get edition IDs from mock data
@@ -68025,7 +68001,10 @@ function generateSubscriptionPlans() {
68025
68001
  const financeEdition = EDITIONS.find((e) => e.title === 'Finance Enterprise');
68026
68002
  // Helper function to create subscription plan
68027
68003
  const createPlan = (title, code, description, isDisabled = false) => {
68028
- const planId = AXPDataGenerator.uuid();
68004
+ const planId = MOCK_SUBSCRIPTION_PLAN_IDS[code];
68005
+ if (!planId) {
68006
+ throw new Error(`Missing stable subscription plan id for code: ${code}`);
68007
+ }
68029
68008
  const plan = {
68030
68009
  id: planId,
68031
68010
  title,
@@ -68125,12 +68104,90 @@ function generateSubscriptions() {
68125
68104
  }
68126
68105
  const SUBSCRIPTIONS_MOCK = generateSubscriptions();
68127
68106
 
68107
+ //#region ---- Imports ----
68108
+ //#endregion
68109
+ //#region ---- Subscription Seeder ----
68110
+ /**
68111
+ * Seeds tenant subscriptions for the mock tenant loader.
68112
+ *
68113
+ * Dexie `initial()` defaults to `uniqueKeys: ['name']`, but subscription rows have no `name` field.
68114
+ * Subscriber and plan ids in mock files can also drift from IndexedDB after reloads, so rows are
68115
+ * resolved against stored tenants (by tenant `name`) and stored plans (by `code`) before insert/sync.
68116
+ */
68128
68117
  class AXCSubscriptionSeeder {
68129
68118
  constructor() {
68130
68119
  this.storageService = inject(AXPEntityStorageService);
68131
68120
  }
68132
68121
  async seed() {
68133
- await this.storageService.initial(RootConfig$x.entities.subscription.source, SUBSCRIPTIONS_MOCK);
68122
+ const entityName = RootConfig$x.entities.subscription.source;
68123
+ const resolvedMocks = await this.resolveMockSubscriptions();
68124
+ await this.storageService.initial(entityName, resolvedMocks, {
68125
+ mergeType: 'merge',
68126
+ uniqueKeys: ['subscriberId', 'planId'],
68127
+ });
68128
+ await this.syncSubscriptionsFromMock(entityName, resolvedMocks);
68129
+ }
68130
+ async resolveMockSubscriptions() {
68131
+ const tenantEntityName = `${RootConfig$y.module.name}.${RootConfig$y.entities.tenant.name}`;
68132
+ const planEntityName = RootConfig$x.entities.subscriptionPlan.source;
68133
+ const [storedTenants, storedPlans] = await Promise.all([
68134
+ this.storageService.getAll(tenantEntityName),
68135
+ this.storageService.getAll(planEntityName),
68136
+ ]);
68137
+ const resolved = [];
68138
+ for (const mock of SUBSCRIPTIONS_MOCK) {
68139
+ const mockTenantDef = tenantMocks.find((tenant) => tenant.id === mock.subscriberId);
68140
+ const storedTenant = storedTenants.find((tenant) => tenant.id === mock.subscriberId ||
68141
+ (!!mockTenantDef?.name && tenant.name === mockTenantDef.name));
68142
+ if (!storedTenant?.id) {
68143
+ continue;
68144
+ }
68145
+ const mockPlanDef = SUBSCRIPTION_PLANS_MOCK.find((plan) => plan.id === mock.planId);
68146
+ const storedPlan = storedPlans.find((plan) => plan.id === mock.planId || (!!mockPlanDef?.code && plan.code === mockPlanDef.code));
68147
+ if (!storedPlan?.id) {
68148
+ continue;
68149
+ }
68150
+ resolved.push({
68151
+ ...mock,
68152
+ subscriberId: storedTenant.id,
68153
+ subscriber: {
68154
+ id: storedTenant.id,
68155
+ title: storedTenant.title,
68156
+ displayName: storedTenant.title,
68157
+ },
68158
+ planId: storedPlan.id,
68159
+ plan: {
68160
+ id: storedPlan.id,
68161
+ title: storedPlan.title,
68162
+ },
68163
+ });
68164
+ }
68165
+ return resolved;
68166
+ }
68167
+ async syncSubscriptionsFromMock(entityName, resolvedMocks) {
68168
+ const storedSubscriptions = await this.storageService.getAll(entityName);
68169
+ for (const mock of resolvedMocks) {
68170
+ const existing = storedSubscriptions.find((subscription) => subscription.subscriberId === mock.subscriberId && subscription.planId === mock.planId);
68171
+ if (!existing?.id) {
68172
+ await this.storageService.insertOne(entityName, {
68173
+ ...mock,
68174
+ id: mock.id ?? AXPDataGenerator.uuid(),
68175
+ });
68176
+ continue;
68177
+ }
68178
+ const subscriberChanged = existing.subscriberId !== mock.subscriberId;
68179
+ const planChanged = existing.planId !== mock.planId;
68180
+ const statusChanged = existing.statusId !== mock.statusId;
68181
+ if (subscriberChanged || planChanged || statusChanged) {
68182
+ await this.storageService.updateOne(entityName, existing.id, {
68183
+ subscriberId: mock.subscriberId,
68184
+ subscriber: mock.subscriber,
68185
+ planId: mock.planId,
68186
+ plan: mock.plan,
68187
+ statusId: mock.statusId,
68188
+ });
68189
+ }
68190
+ }
68134
68191
  }
68135
68192
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSubscriptionSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68136
68193
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSubscriptionSeeder }); }
@@ -68144,7 +68201,10 @@ class AXCSubscriptionPlanSeeder {
68144
68201
  this.storageService = inject(AXPEntityStorageService);
68145
68202
  }
68146
68203
  async seed() {
68147
- await this.storageService.initial(RootConfig$x.entities.subscriptionPlan.source, SUBSCRIPTION_PLANS_MOCK);
68204
+ await this.storageService.initial(RootConfig$x.entities.subscriptionPlan.source, SUBSCRIPTION_PLANS_MOCK, {
68205
+ mergeType: 'merge',
68206
+ uniqueKeys: ['code'],
68207
+ });
68148
68208
  }
68149
68209
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSubscriptionPlanSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68150
68210
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSubscriptionPlanSeeder }); }
@@ -68291,7 +68351,7 @@ class AXCSupplierCategorySeeder {
68291
68351
  this.storageService = inject(AXPEntityStorageService);
68292
68352
  }
68293
68353
  async seed() {
68294
- await this.storageService.initial(`${RootConfig$y.module.name}.${RootConfig$y.entities.supplier.name}Category`, supplierCategoryMocks);
68354
+ await this.storageService.initial(`${RootConfig$z.module.name}.${RootConfig$z.entities.supplier.name}Category`, supplierCategoryMocks);
68295
68355
  }
68296
68356
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSupplierCategorySeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68297
68357
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSupplierCategorySeeder }); }
@@ -68305,7 +68365,7 @@ class AXCSupplierDataSeeder {
68305
68365
  this.storageService = inject(AXPEntityStorageService);
68306
68366
  }
68307
68367
  async seed() {
68308
- await this.storageService.initial(RootConfig$y.entities.supplier.source, SUPPLIERS_MOCK);
68368
+ await this.storageService.initial(RootConfig$z.entities.supplier.source, SUPPLIERS_MOCK);
68309
68369
  }
68310
68370
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSupplierDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68311
68371
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCSupplierDataSeeder }); }
@@ -68748,7 +68808,7 @@ class AXMTaskTypeDataSeeder {
68748
68808
  this.storageService = inject(AXPEntityStorageService);
68749
68809
  }
68750
68810
  async seed() {
68751
- await this.storageService.initial(`${RootConfig$z.module.name}.${RootConfig$z.entities.taskType.name}`, taskTypeMock);
68811
+ await this.storageService.initial(`${RootConfig$A.module.name}.${RootConfig$A.entities.taskType.name}`, taskTypeMock);
68752
68812
  }
68753
68813
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskTypeDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68754
68814
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskTypeDataSeeder }); }
@@ -68895,7 +68955,7 @@ class AXMTaskStatusDataSeeder {
68895
68955
  this.storageService = inject(AXPEntityStorageService);
68896
68956
  }
68897
68957
  async seed() {
68898
- await this.storageService.initial(`${RootConfig$z.module.name}.${RootConfig$z.entities.taskStatus.name}`, taskStatusMock);
68958
+ await this.storageService.initial(`${RootConfig$A.module.name}.${RootConfig$A.entities.taskStatus.name}`, taskStatusMock);
68899
68959
  }
68900
68960
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskStatusDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68901
68961
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskStatusDataSeeder }); }
@@ -69066,7 +69126,7 @@ class AXMTaskDataSeeder {
69066
69126
  this.storageService = inject(AXPEntityStorageService);
69067
69127
  }
69068
69128
  async seed() {
69069
- await this.storageService.initial(`${RootConfig$z.module.name}.${RootConfig$z.entities.task.name}`, taskMock);
69129
+ await this.storageService.initial(`${RootConfig$A.module.name}.${RootConfig$A.entities.task.name}`, taskMock);
69070
69130
  }
69071
69131
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
69072
69132
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskDataSeeder }); }
@@ -69174,7 +69234,7 @@ class AXMTaskTemplateDataSeeder {
69174
69234
  this.storageService = inject(AXPEntityStorageService);
69175
69235
  }
69176
69236
  async seed() {
69177
- await this.storageService.initial(`${RootConfig$z.module.name}.${RootConfig$z.entities.taskTemplate.name}`, taskTemplateMock);
69237
+ await this.storageService.initial(`${RootConfig$A.module.name}.${RootConfig$A.entities.taskTemplate.name}`, taskTemplateMock);
69178
69238
  }
69179
69239
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskTemplateDataSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
69180
69240
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXMTaskTemplateDataSeeder }); }
@@ -69242,7 +69302,7 @@ class AXCTenantSeeder {
69242
69302
  this.storageService = inject(AXPEntityStorageService);
69243
69303
  }
69244
69304
  async seed() {
69245
- await this.storageService.initial(RootConfig$A.entities.tenant.source, tenantMocks);
69305
+ await this.storageService.initial(RootConfig$y.entities.tenant.source, tenantMocks);
69246
69306
  }
69247
69307
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCTenantSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
69248
69308
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCTenantSeeder }); }
@@ -69418,12 +69478,113 @@ const tenantUserMocks = generateTenantUsers();
69418
69478
  //#region ---- Imports ----
69419
69479
  //#endregion
69420
69480
  //#region ---- Tenant User Seeder ----
69481
+ /**
69482
+ * Seeds `TenantManagement.TenantUser` mock memberships.
69483
+ *
69484
+ * Dexie `initial()` defaults to `uniqueKeys: ['name']`, but TenantUser rows have no `name` field.
69485
+ * User and tenant ids in mock files can drift from IndexedDB after reloads, so rows are resolved
69486
+ * against stored users (by `username`) and stored tenants (by tenant `name`) before insert/sync.
69487
+ */
69421
69488
  class AXCTenantUserSeeder {
69422
69489
  constructor() {
69423
69490
  this.storageService = inject(AXPEntityStorageService);
69491
+ this.backend = inject(AXP_ENTITY_STORAGE_BACKEND);
69424
69492
  }
69425
69493
  async seed() {
69426
- await this.storageService.initial(`${RootConfig$A.module.name}.${RootConfig$A.entities.tenantUser.name}`, tenantUserMocks);
69494
+ const entityName = `${RootConfig$y.module.name}.${RootConfig$y.entities.tenantUser.name}`;
69495
+ const resolvedMocks = await this.resolveMockTenantUsers();
69496
+ await this.storageService.initial(entityName, resolvedMocks, {
69497
+ mergeType: 'merge',
69498
+ uniqueKeys: ['userId', 'tenantId'],
69499
+ });
69500
+ await this.syncTenantUsersFromMock(entityName, resolvedMocks);
69501
+ }
69502
+ /**
69503
+ * Maps mock tenant-user rows to user/tenant/role ids currently stored in IndexedDB.
69504
+ */
69505
+ async resolveMockTenantUsers() {
69506
+ const tenantEntityName = `${RootConfig$y.module.name}.${RootConfig$y.entities.tenant.name}`;
69507
+ const userEntityName = `${RootConfig$6.module.name}.${RootConfig$6.entities.users.name}`;
69508
+ const roleEntityName = `${RootConfig$6.module.name}.${RootConfig$6.entities.roles.name}`;
69509
+ const [storedTenants, storedUsers, storedRoles] = await Promise.all([
69510
+ this.backend.getAll(tenantEntityName),
69511
+ this.backend.getAll(userEntityName),
69512
+ this.backend.getAll(roleEntityName),
69513
+ ]);
69514
+ const resolved = [];
69515
+ for (const mock of tenantUserMocks) {
69516
+ const username = mock.user?.username;
69517
+ if (!username) {
69518
+ continue;
69519
+ }
69520
+ const storedUser = storedUsers.find((user) => user.username === username);
69521
+ if (!storedUser?.id) {
69522
+ continue;
69523
+ }
69524
+ const mockTenantDef = tenantMocks.find((tenant) => tenant.id === mock.tenantId || tenant.id === mock.tenant?.id);
69525
+ const storedTenant = storedTenants.find((tenant) => tenant.id === mock.tenantId ||
69526
+ (!!mockTenantDef?.name && tenant.name === mockTenantDef.name));
69527
+ if (!storedTenant?.id) {
69528
+ continue;
69529
+ }
69530
+ const roleName = mock.role?.name;
69531
+ const storedRole = roleName ? storedRoles.find((role) => role.name === roleName) : undefined;
69532
+ resolved.push({
69533
+ ...mock,
69534
+ userId: storedUser.id,
69535
+ user: {
69536
+ id: storedUser.id,
69537
+ username: storedUser.username,
69538
+ displayName: storedUser.displayName,
69539
+ },
69540
+ tenantId: storedTenant.id,
69541
+ tenant: { id: storedTenant.id, title: storedTenant.title },
69542
+ roleId: storedRole?.id ?? mock.roleId,
69543
+ role: storedRole
69544
+ ? { id: storedRole.id, name: storedRole.name, title: storedRole.title }
69545
+ : mock.role,
69546
+ });
69547
+ }
69548
+ return resolved;
69549
+ }
69550
+ /**
69551
+ * Inserts or updates tenant-user rows when mock membership definitions change.
69552
+ */
69553
+ async syncTenantUsersFromMock(entityName, resolvedMocks) {
69554
+ const storedLinks = await this.backend.getAll(entityName);
69555
+ for (const mock of resolvedMocks) {
69556
+ const existing = this.findExistingTenantUserLink(storedLinks, mock);
69557
+ if (!existing?.id) {
69558
+ await this.storageService.insertOne(entityName, {
69559
+ ...mock,
69560
+ id: mock.id ?? AXPDataGenerator.uuid(),
69561
+ });
69562
+ continue;
69563
+ }
69564
+ const userChanged = existing.userId !== mock.userId;
69565
+ const roleChanged = existing.roleId !== mock.roleId;
69566
+ const statusChanged = existing.statusId !== mock.statusId;
69567
+ if (userChanged || roleChanged || statusChanged) {
69568
+ await this.storageService.updateOne(entityName, existing.id, {
69569
+ userId: mock.userId,
69570
+ user: mock.user,
69571
+ roleId: mock.roleId,
69572
+ role: mock.role,
69573
+ statusId: mock.statusId,
69574
+ });
69575
+ }
69576
+ }
69577
+ }
69578
+ findExistingTenantUserLink(storedLinks, mock) {
69579
+ const byIds = storedLinks.find((link) => link.userId === mock.userId && link.tenantId === mock.tenantId);
69580
+ if (byIds) {
69581
+ return byIds;
69582
+ }
69583
+ const username = mock.user?.username;
69584
+ if (!username) {
69585
+ return undefined;
69586
+ }
69587
+ return storedLinks.find((link) => link.user?.username === username && link.tenantId === mock.tenantId);
69427
69588
  }
69428
69589
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCTenantUserSeeder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
69429
69590
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXCTenantUserSeeder }); }
@@ -69454,7 +69615,7 @@ class AXMCreateTenantUserCommand {
69454
69615
  };
69455
69616
  }
69456
69617
  // Check if account holder already exists for this tenant
69457
- const tenantUserEntityName = `${RootConfig$A.module.name}.${RootConfig$A.entities.tenantUser.name}`;
69618
+ const tenantUserEntityName = `${RootConfig$y.module.name}.${RootConfig$y.entities.tenantUser.name}`;
69458
69619
  const accountHolderResult = await this.storageService.query(tenantUserEntityName, {
69459
69620
  skip: 0,
69460
69621
  take: 1,
@@ -70840,8 +71001,8 @@ class AXCUserPassStrategyMock extends AXPAuthStrategy {
70840
71001
  try {
70841
71002
  let user = null;
70842
71003
  const func = entityRef?.queries?.list?.execute;
70843
- // Bypass visibility filter for authentication (system users need to be accessible)
70844
- const users = await func(bypassVisibilityFilter({
71004
+ // Bypass tenant/visibility filters for authentication (system users must be discoverable)
71005
+ const users = await func(bypassAllFilters({
70845
71006
  skip: 0,
70846
71007
  take: 1000,
70847
71008
  }));
@@ -71812,6 +71973,13 @@ function generateActivityDefinitions() {
71812
71973
  dataType: 'string',
71813
71974
  interface: { type: AXPWidgetsList.Editors.TextBox, options: {} },
71814
71975
  },
71976
+ {
71977
+ name: 'title',
71978
+ title: 'Viewer title',
71979
+ description: 'Optional popup title; defaults to assessment case title when omitted',
71980
+ dataType: 'string',
71981
+ interface: { type: AXPWidgetsList.Editors.TextBox, options: {} },
71982
+ },
71815
71983
  {
71816
71984
  name: 'showAs',
71817
71985
  title: 'Show as',
@@ -73198,6 +73366,63 @@ const documentWorkflowTriggerMiddleware = {
73198
73366
  },
73199
73367
  };
73200
73368
 
73369
+ const AXC_WORKFLOW_EXECUTION_STORE = new InjectionToken('AXC_WORKFLOW_EXECUTION_STORE');
73370
+
73371
+ //#region ---- Imports ----
73372
+ //#endregion
73373
+ //#region ---- Sync ----
73374
+ /**
73375
+ * Writes {@link AXPRecordWorkflowInfo} on a domain row and links the workflow instance entity ref.
73376
+ * Uses the workflow-trigger guard so entity update middleware does not re-start workflows.
73377
+ */
73378
+ async function syncEntityRecordWorkflowInfo(storage, store, params) {
73379
+ const entityType = params.entityType?.trim();
73380
+ const entityId = params.entityId?.trim();
73381
+ const instanceId = params.instanceId?.trim();
73382
+ if (!entityType || !entityId || !instanceId) {
73383
+ return;
73384
+ }
73385
+ const manageGuard = params.manageWorkflowTriggerGuard !== false;
73386
+ if (manageGuard) {
73387
+ setWorkflowStartInProgress(true);
73388
+ }
73389
+ try {
73390
+ const workflowInfo = buildAXPRecordWorkflowInfo({
73391
+ instanceId,
73392
+ definitionId: params.definitionId,
73393
+ correlationId: params.correlationId,
73394
+ pinnedVersion: params.pinnedVersion,
73395
+ });
73396
+ const instance = await store.getInstance(instanceId);
73397
+ if (instance) {
73398
+ instance.entityRefId = entityId;
73399
+ instance.entityRefType = entityType;
73400
+ await store.putInstance(instance);
73401
+ }
73402
+ let existingWorkflowInfo;
73403
+ try {
73404
+ const existing = await storage.getOne(entityType, entityId);
73405
+ existingWorkflowInfo = existing?.workflowInfo;
73406
+ }
73407
+ catch {
73408
+ /* record may not exist yet */
73409
+ }
73410
+ await storage.updateOne(entityType, entityId, {
73411
+ workflowInfo: {
73412
+ ...existingWorkflowInfo,
73413
+ ...workflowInfo,
73414
+ pinnedVersion: workflowInfo.pinnedVersion ?? existingWorkflowInfo?.pinnedVersion ?? null,
73415
+ },
73416
+ });
73417
+ }
73418
+ finally {
73419
+ if (manageGuard) {
73420
+ setWorkflowStartInProgress(false);
73421
+ }
73422
+ }
73423
+ }
73424
+ //#endregion
73425
+
73201
73426
  /**
73202
73427
  * Workflow Trigger Middleware
73203
73428
  *
@@ -73236,6 +73461,7 @@ const workflowTriggerMiddleware = {
73236
73461
  const workflowManager = inject(AXPWorkflowManager);
73237
73462
  const storageService = inject(AXPEntityStorageService);
73238
73463
  const workflowDefinitionService = inject(AXPWorkflowDefinitionService);
73464
+ const workflowExecutionStore = inject(AXC_WORKFLOW_EXECUTION_STORE);
73239
73465
  await next();
73240
73466
  if (!ctx.result) {
73241
73467
  return;
@@ -73422,6 +73648,14 @@ const workflowTriggerMiddleware = {
73422
73648
  if (!startResult.success || !startResult.instanceId) {
73423
73649
  continue;
73424
73650
  }
73651
+ await syncEntityRecordWorkflowInfo(storageService, workflowExecutionStore, {
73652
+ entityType: ctx.entityName,
73653
+ entityId: recordId,
73654
+ instanceId: startResult.instanceId,
73655
+ definitionId: workflow.name,
73656
+ correlationId,
73657
+ manageWorkflowTriggerGuard: false,
73658
+ });
73425
73659
  }
73426
73660
  catch {
73427
73661
  // Continue with other workflows
@@ -74430,8 +74664,6 @@ class AXCWorkflowExecutionDB extends Dexie {
74430
74664
  const axWorkflowExecutionDB = new AXCWorkflowExecutionDB();
74431
74665
  //#endregion
74432
74666
 
74433
- const AXC_WORKFLOW_EXECUTION_STORE = new InjectionToken('AXC_WORKFLOW_EXECUTION_STORE');
74434
-
74435
74667
  class AXCWorkflowExecutionStoreDexie {
74436
74668
  constructor() {
74437
74669
  this.db = axWorkflowExecutionDB;
@@ -74842,7 +75074,7 @@ class AXCWorkflowEngine {
74842
75074
  },
74843
75075
  ]
74844
75076
  : [],
74845
- input: workflowInput,
75077
+ input: { ...workflowInput, _workflowInstanceId: instanceId },
74846
75078
  output: {},
74847
75079
  properties: {},
74848
75080
  createdAt: now,
@@ -75084,6 +75316,33 @@ class AXCWorkflowEngine {
75084
75316
  lastActivityOutput,
75085
75317
  };
75086
75318
  }
75319
+ /**
75320
+ * Terminates a non-finished workflow instance (e.g. superseded lifecycle run).
75321
+ */
75322
+ async cancelInstance(instanceId, reason) {
75323
+ const instance = await this.getInstance(instanceId);
75324
+ if (!instance || instance.status === 'Finished') {
75325
+ return;
75326
+ }
75327
+ const now = new Date().toISOString();
75328
+ instance.status = 'Finished';
75329
+ instance.subStatus = 'Cancelled';
75330
+ instance.updatedAt = now;
75331
+ instance.finishedAt = now;
75332
+ instance.workflowState.status = 'Finished';
75333
+ instance.workflowState.subStatus = 'Cancelled';
75334
+ instance.workflowState.updatedAt = now;
75335
+ instance.workflowState.finishedAt = now;
75336
+ if (reason) {
75337
+ instance.workflowState.properties = {
75338
+ ...(instance.workflowState.properties ?? {}),
75339
+ cancelReason: reason,
75340
+ };
75341
+ }
75342
+ await this.store.updateInstance(instance);
75343
+ await this.updateInstanceInEntityService(instance);
75344
+ console.log(`[AXCWorkflowEngine] 🛑 Cancelled workflow instance: ${instanceId}`, { reason });
75345
+ }
75087
75346
  /**
75088
75347
  * Find activity in Graph by ID.
75089
75348
  */
@@ -75161,6 +75420,71 @@ class AXCWorkflowEngine {
75161
75420
  return { ...value };
75162
75421
  return { value };
75163
75422
  }
75423
+ /**
75424
+ * Extracts persisted create-entity-form payload (`data.result`) from a frontend step output.
75425
+ */
75426
+ extractPersistedEntityFormResult(output) {
75427
+ const result = output['result'];
75428
+ if (result && typeof result === 'object' && !Array.isArray(result)) {
75429
+ return result;
75430
+ }
75431
+ return null;
75432
+ }
75433
+ /**
75434
+ * Coerces date-like workflow values to a {@link Date} (local calendar date when input is `yyyy-mm-dd`).
75435
+ */
75436
+ coerceWorkflowDateValue(value) {
75437
+ if (value == null) {
75438
+ return null;
75439
+ }
75440
+ if (value instanceof Date) {
75441
+ return Number.isNaN(value.getTime()) ? null : value;
75442
+ }
75443
+ if (typeof value === 'string') {
75444
+ const trimmed = value.trim();
75445
+ const dateOnlyMatch = /^(\d{4})-(\d{2})-(\d{2})/.exec(trimmed);
75446
+ if (dateOnlyMatch) {
75447
+ const year = Number(dateOnlyMatch[1]);
75448
+ const month = Number(dateOnlyMatch[2]);
75449
+ const day = Number(dateOnlyMatch[3]);
75450
+ const local = new Date(year, month - 1, day);
75451
+ return Number.isNaN(local.getTime()) ? null : local;
75452
+ }
75453
+ const parsed = new Date(trimmed);
75454
+ return Number.isNaN(parsed.getTime()) ? null : parsed;
75455
+ }
75456
+ return null;
75457
+ }
75458
+ /**
75459
+ * Promotes `create-entity-form` submit payload (`output.result`) onto workflow variables
75460
+ * so downstream steps and human tasks see form values (e.g. effectiveDate), not start inputs.
75461
+ */
75462
+ buildPersistedEntityFormVariablePromotions(output, activityName, outcome) {
75463
+ if (activityName !== 'workflow-activity:create-entity-form' || outcome !== 'Submitted') {
75464
+ return {};
75465
+ }
75466
+ const form = this.extractPersistedEntityFormResult(output);
75467
+ if (!form) {
75468
+ return {};
75469
+ }
75470
+ const promoted = {};
75471
+ for (const [key, value] of Object.entries(form)) {
75472
+ if (value == null || key === 'id') {
75473
+ continue;
75474
+ }
75475
+ if (key === 'effectiveDate') {
75476
+ const coerced = this.coerceWorkflowDateValue(value);
75477
+ if (coerced) {
75478
+ promoted[key] = coerced;
75479
+ }
75480
+ continue;
75481
+ }
75482
+ if (typeof value === 'string' || typeof value === 'number' || typeof value === 'boolean') {
75483
+ promoted[key] = value;
75484
+ }
75485
+ }
75486
+ return promoted;
75487
+ }
75164
75488
  /**
75165
75489
  * Resume a suspended workflow instance.
75166
75490
  *
@@ -76472,6 +76796,34 @@ class AXCWorkflowEngine {
76472
76796
  }
76473
76797
  //#endregion
76474
76798
  //#region ---- Backend Activity Executors ----
76799
+ /**
76800
+ * Evaluates activity inputs against current workflow scope (same as backend execution).
76801
+ */
76802
+ async evaluateActivityInputs(activity, state, lastOutput) {
76803
+ const scope = this.expressionScopeService.buildScopeFromState(state, this.ensureOutputsForScope(lastOutput));
76804
+ return this.expressionEvaluator.evaluate(activity.inputs || {}, scope);
76805
+ }
76806
+ /**
76807
+ * After entity-create: link instance entity ref and persist {@link AXPRecordWorkflowInfo} on the row.
76808
+ */
76809
+ async linkEntityRecordAfterCreate(instanceId, activity, state, lastOutput, entityId) {
76810
+ const properties = await this.evaluateActivityInputs(activity, state, lastOutput);
76811
+ const entityType = typeof properties['entity'] === 'string' ? properties['entity'].trim() : '';
76812
+ const recordId = entityId?.trim();
76813
+ if (!entityType || !recordId) {
76814
+ return;
76815
+ }
76816
+ const instance = await this.store.getInstance(instanceId);
76817
+ const definitionId = instance?.definitionId ?? instance?.workflowState?.definitionId ?? state.workflowId ?? null;
76818
+ const correlationId = instance?.correlationId ?? instance?.workflowState?.correlationId ?? null;
76819
+ await syncEntityRecordWorkflowInfo(this.entityStorageService, this.store, {
76820
+ entityType,
76821
+ entityId: recordId,
76822
+ instanceId,
76823
+ definitionId: definitionId != null ? String(definitionId) : null,
76824
+ correlationId: correlationId != null ? String(correlationId) : null,
76825
+ });
76826
+ }
76475
76827
  /**
76476
76828
  * Execute backend activities locally using CommandBus.
76477
76829
  *
@@ -76516,6 +76868,13 @@ class AXCWorkflowEngine {
76516
76868
  output,
76517
76869
  outcomes,
76518
76870
  };
76871
+ if (activityType === 'workflow-activity:entity-create' &&
76872
+ outcomes['Done'] &&
76873
+ output &&
76874
+ typeof output === 'object' &&
76875
+ typeof output['id'] === 'string') {
76876
+ await this.linkEntityRecordAfterCreate(state.instanceId, activity, state, lastOutput, output['id']);
76877
+ }
76519
76878
  return finalResult;
76520
76879
  }
76521
76880
  catch (error) {
@@ -77083,40 +77442,24 @@ class AXCWorkflowEngine {
77083
77442
  const allowedOutcomes = await this.getActivityAllowedOutcomes(workflow, request.activityNode);
77084
77443
  const outcome = this.normalizeOutcome(request.outcome ?? 'Done', allowedOutcomes, request.activityNode);
77085
77444
  // Apply frontend output: only last activity output is kept (overwritten each step)
77086
- const output = request.output || {};
77445
+ const output = (request.output || {});
77087
77446
  let lastActivityOutput = output;
77088
77447
  // Apply outputToVariables for the completed frontend activity (e.g. leaveRequestForm → leaveRequestId: 'id')
77089
77448
  const variableUpdatesFromOutput = this.getVariableUpdatesFromOutput(workflow, request.activityNode, output);
77449
+ const completedActivity = this.findActivityInGraph(workflow.graph, request.activityNode);
77450
+ const formResultPromotions = this.buildPersistedEntityFormVariablePromotions(output, completedActivity?.name, outcome);
77090
77451
  state = {
77091
77452
  ...state,
77092
77453
  variables: {
77093
77454
  ...state.variables,
77094
77455
  ...output, // Merge frontend output into variables
77456
+ ...formResultPromotions, // Promote capture-form fields (e.g. effectiveDate) onto variables
77095
77457
  ...variableUpdatesFromOutput, // Map output paths to variable names (e.g. id → leaveRequestId)
77096
77458
  [`${request.activityNode}_outcome`]: outcome, // Keep outcome for reference (normalized)
77097
77459
  },
77098
77460
  lastActivityOutput,
77099
77461
  lastUpdated: new Date(),
77100
77462
  };
77101
- // 🎯 Update entityRefId and entityRefType if entity was created
77102
- // Check if this activity created an entity (workflow-activity:create-entity)
77103
- const completedActivity = this.findActivityInGraph(workflow.graph, request.activityNode);
77104
- if (completedActivity?.name === 'workflow-activity:create-entity' && output['id']) {
77105
- // Extract entity type from activity inputs
77106
- const entityModule = completedActivity.inputs?.module || '';
77107
- const entityName = completedActivity.inputs?.entity || '';
77108
- const entityType = entityModule && entityName ? `${entityModule}.${entityName}` : null;
77109
- const entityId = output['id'];
77110
- if (entityId && entityType) {
77111
- // Update workflow instance with entity reference
77112
- const instance = await this.store.getInstance(request.instanceId);
77113
- if (instance) {
77114
- instance.entityRefId = entityId;
77115
- instance.entityRefType = entityType;
77116
- await this.store.putInstance(instance);
77117
- }
77118
- }
77119
- }
77120
77463
  // Find next activity based on outcome from frontend (use normalized outcome)
77121
77464
  const nextConnection = connections.find((conn) => conn.source.activtyName === request.activityNode &&
77122
77465
  (conn.source.port === outcome || (!conn.source.port && outcome === 'Done')));
@@ -77424,7 +77767,7 @@ class AXCWorkflowManagementMockModule {
77424
77767
  if (engine && typeof engine.resumeStaleNonHumanTaskSuspensions === 'function') {
77425
77768
  appInitService.registerTask({
77426
77769
  name: 'WorkflowStaleSuspensions',
77427
- statusText: 'Resuming stale workflow suspensions...',
77770
+ statusText: '@workflow-management:app-startup.resuming-stale-suspensions',
77428
77771
  priority: 10,
77429
77772
  run: async () => {
77430
77773
  await engine.resumeStaleNonHumanTaskSuspensions();
@@ -77448,7 +77791,7 @@ class AXCWorkflowManagementMockModule {
77448
77791
  provideCommandSetups([
77449
77792
  {
77450
77793
  key: 'workflow-activity:assign-to-manager',
77451
- command: () => import('./acorex-connectivity-mock-assign-to-manager.activity-DZKQcO6f.mjs').then((c) => c.AssignToManagerActivity),
77794
+ command: () => import('./acorex-connectivity-mock-assign-to-manager.activity-BF9U-Hd6.mjs').then((c) => c.AssignToManagerActivity),
77452
77795
  },
77453
77796
  {
77454
77797
  key: 'workflow-activity:get-current-user-manager',
@@ -77484,7 +77827,7 @@ class AXCWorkflowManagementMockModule {
77484
77827
  },
77485
77828
  {
77486
77829
  key: 'workflow-activity:entity-create',
77487
- command: () => import('./acorex-connectivity-mock-entity-create.activity-Ca19tIj4.mjs').then((c) => c.EntityCreateActivity),
77830
+ command: () => import('./acorex-connectivity-mock-entity-create.activity-CdoUzUvF.mjs').then((c) => c.EntityCreateActivity),
77488
77831
  },
77489
77832
  {
77490
77833
  key: 'workflow-activity:entity-read',
@@ -77559,7 +77902,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
77559
77902
  provideCommandSetups([
77560
77903
  {
77561
77904
  key: 'workflow-activity:assign-to-manager',
77562
- command: () => import('./acorex-connectivity-mock-assign-to-manager.activity-DZKQcO6f.mjs').then((c) => c.AssignToManagerActivity),
77905
+ command: () => import('./acorex-connectivity-mock-assign-to-manager.activity-BF9U-Hd6.mjs').then((c) => c.AssignToManagerActivity),
77563
77906
  },
77564
77907
  {
77565
77908
  key: 'workflow-activity:get-current-user-manager',
@@ -77595,7 +77938,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
77595
77938
  },
77596
77939
  {
77597
77940
  key: 'workflow-activity:entity-create',
77598
- command: () => import('./acorex-connectivity-mock-entity-create.activity-Ca19tIj4.mjs').then((c) => c.EntityCreateActivity),
77941
+ command: () => import('./acorex-connectivity-mock-entity-create.activity-CdoUzUvF.mjs').then((c) => c.EntityCreateActivity),
77599
77942
  },
77600
77943
  {
77601
77944
  key: 'workflow-activity:entity-read',
@@ -81584,7 +81927,7 @@ class AXCMockModule {
81584
81927
  const seederService = injector.get(AXPDataSeederService);
81585
81928
  appInitService.registerTask({
81586
81929
  name: 'Mock',
81587
- statusText: 'Seed Data ...',
81930
+ statusText: '@general:app-startup.seeding-data',
81588
81931
  priority: 1,
81589
81932
  run: async () => {
81590
81933
  if (backendType === 'firestore') {
@@ -81599,7 +81942,7 @@ class AXCMockModule {
81599
81942
  const entityDefSeeder = injector.get(AXCEntityDefinitionSeederService);
81600
81943
  appInitService.registerTask({
81601
81944
  name: 'Entity Definitions',
81602
- statusText: 'Seed Entity Definitions ...',
81945
+ statusText: '@general:app-startup.seeding-entity-definitions',
81603
81946
  priority: 2,
81604
81947
  run: async () => {
81605
81948
  await entityDefSeeder.seed();
@@ -81619,6 +81962,7 @@ class AXCMockModule {
81619
81962
  AXCSupplierManagementMockModule,
81620
81963
  AXCProcurementManagementMockModule,
81621
81964
  AXCOrderManagementMockModule,
81965
+ AXCTenantManagementMockModule,
81622
81966
  AXCSubscriptionManagementMockModule,
81623
81967
  AXCLocationManagementMockModule,
81624
81968
  AXCContactCoreMockModule,
@@ -81634,7 +81978,6 @@ class AXCMockModule {
81634
81978
  AXCAiManagementMockModule,
81635
81979
  AXCPlatformManagementMockModule,
81636
81980
  AXCApplicationManagementMockModule,
81637
- AXCTenantManagementMockModule,
81638
81981
  AXCLearningManagementMockModule,
81639
81982
  AXCAssetManagementMockModule,
81640
81983
  AXCProjectManagementMockModule,
@@ -81679,6 +82022,7 @@ class AXCMockModule {
81679
82022
  AXCSupplierManagementMockModule,
81680
82023
  AXCProcurementManagementMockModule,
81681
82024
  AXCOrderManagementMockModule,
82025
+ AXCTenantManagementMockModule,
81682
82026
  AXCSubscriptionManagementMockModule,
81683
82027
  AXCLocationManagementMockModule,
81684
82028
  AXCContactCoreMockModule,
@@ -81694,7 +82038,6 @@ class AXCMockModule {
81694
82038
  AXCAiManagementMockModule,
81695
82039
  AXCPlatformManagementMockModule,
81696
82040
  AXCApplicationManagementMockModule,
81697
- AXCTenantManagementMockModule,
81698
82041
  AXCLearningManagementMockModule,
81699
82042
  AXCAssetManagementMockModule,
81700
82043
  AXCProjectManagementMockModule,
@@ -81736,6 +82079,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
81736
82079
  AXCSupplierManagementMockModule,
81737
82080
  AXCProcurementManagementMockModule,
81738
82081
  AXCOrderManagementMockModule,
82082
+ AXCTenantManagementMockModule,
81739
82083
  AXCSubscriptionManagementMockModule,
81740
82084
  AXCLocationManagementMockModule,
81741
82085
  AXCContactCoreMockModule,
@@ -81751,7 +82095,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
81751
82095
  AXCAiManagementMockModule,
81752
82096
  AXCPlatformManagementMockModule,
81753
82097
  AXCApplicationManagementMockModule,
81754
- AXCTenantManagementMockModule,
81755
82098
  AXCLearningManagementMockModule,
81756
82099
  AXCAssetManagementMockModule,
81757
82100
  AXCProjectManagementMockModule,
@@ -81897,4 +82240,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImpor
81897
82240
  */
81898
82241
 
81899
82242
  export { AXCFileStorageServiceFirestore as $, AXCAiChatRouterService as A, AXCAuthMockModule as B, AXCCalendarDataSeeder as C, AXCCalendarEventDataSeeder as D, AXCCalendarManagementMockModule as E, AXCCommandRegistryDataSeeder as F, AXCCommonMockModule as G, AXCContactCoreMockModule as H, AXCContentManagementMockModule as I, AXCConversationDataSeeder as J, AXCConversationMockConversationApi as K, AXCConversationMockMessageApi as L, AXCConversationMockModule as M, AXCConversationMockRealtimeApi as N, AXCConversationMockUserApi as O, AXCCustomerManagementMockModule as P, AXCDashboardManagementMockModule as Q, AXCDataManagementMockModule as R, AXCDexieEntityStorageService as S, AXCDocumentManagementMockModule as T, AXCEditionDataSeeder as U, AXCEntityDefinitionSeederService as V, AXCEntityDefinitionsModule as W, AXCEntityStorageInsertCommand as X, AXCEntityStorageModule as Y, AXCEntityStorageQueryQuery as Z, AXCFileStorageServiceDexie as _, AXMAiModelStableIds as a, AXMCalendarEventTypeSeeder as a$, AXCFinancialCoreMockModule as a0, AXCFirestoreEntityStorageService as a1, AXCFormTemplateManagementMockModule as a2, AXCGoogleStrategyMock as a3, AXCHealthCoreMockModule as a4, AXCHelpDeskMockModule as a5, AXCHumanCapitalManagementMockModule as a6, AXCIdentifierManagementMockModule as a7, AXCImageCaptchaChallengeProviderMock as a8, AXCLearningManagementMockModule as a9, AXCTaskManagementMockModule as aA, AXCTenantManagementMockModule as aB, AXCTenantSeeder as aC, AXCTextTemplateRenderBackend as aD, AXCTokensDataSeeder as aE, AXCUserPassStrategyMock as aF, AXCVersionDB as aG, AXCVersioningService as aH, AXCWidgetCatalogDataSeeder as aI, AXCWorkflowCategorySeeder as aJ, AXCWorkflowDefinitionDataSeeder as aK, AXCWorkflowEngine as aL, AXCWorkflowExecutionDB as aM, AXCWorkflowExecutionStoreDexie as aN, AXCWorkflowExecutionStoreFirestore as aO, AXCWorkflowInstanceCartableDemoSeeder as aP, AXCWorkflowManagementMockModule as aQ, AXC_ENTITY_STORAGE_BACKEND_TYPE as aR, AXC_FIRESTORE_CONFIG as aS, AXC_FIRESTORE_DB as aT, AXC_WORKFLOW_EXECUTION_STORE as aU, AXMAiDemisAssistAgentUuid as aV, AXMAiDemisAssistId as aW, AXMAiDemisGeneralAssistId as aX, AXMAiPlatformAssistantAssistId as aY, AXMAutomationDataSeeder as aZ, AXMBusinessUnitDataSeeder as a_, AXCLocaleManagementMockModule as aa, AXCLocationManagementMockModule as ab, AXCLockService as ac, AXCMeasurementCoreMockModule as ad, AXCMeetingManagementMockModule as ae, AXCMetaDataDefinitionDataSeeder as af, AXCMetadataCategorySeeder as ag, AXCMiddlewaresModule as ah, AXCMockCaptchaChallengeComponent as ai, AXCMockEntityLogListener as aj, AXCMockModule as ak, AXCMockShowMetaDataFormPopupCommand as al, AXCNotificationManagementMockModule as am, AXCOrderManagementMockModule as an, AXCOrganizationManagementMockModule as ao, AXCPersonCoreMockModule as ap, AXCPlatformManagementMockModule as aq, AXCProcurementManagementMockModule as ar, AXCProductCatalogMockModule as as, AXCProjectManagementMockModule as at, AXCQueryRegistryDataSeeder as au, AXCReportManagementMockModule as av, AXCSecurityManagementMockModule as aw, AXCStoredEntityDefinitionLoader as ax, AXCSubscriptionManagementMockModule as ay, AXCSupplierManagementMockModule as az, resolveAssistSpeechModelId as b, FINANCE_ENTERPRISE as b$, AXMDashboardChartDataSourceDefinition as b0, AXMEmployeeDataSeeder as b1, AXMEmploymentTypeDataSeeder as b2, AXMFormDataSourcesProvider as b3, AXMJobDefinitionDataSeeder as b4, AXMJobLevelDataSeeder as b5, AXMLeaveRequestDataSeeder as b6, AXMMeetingDataSeeder as b7, AXMMeetingFilesDataSeeder as b8, AXMMeetingParticipantDataSeeder as b9, AXPMockIdentifierService as bA, AXPMockLookupProvider as bB, AXPMockPolicyProvider as bC, AXPMockSequenceProvider as bD, AXPRoomDataSeeder as bE, AXPSecurityManagementRoleDataSeeder as bF, AXPSecurityManagementUserDataSeeder as bG, AXPTaskBoardPlatformManagementTaskProvider as bH, AXPTaskBoardProjectManagementTaskProvider as bI, AXVChangeType as bJ, BCC as bK, BOC as bL, BUSINESS_UNITS_MOCK as bM, CHAT_LAST_MESSAGE_IDS as bN, COLLABORATION_STANDARD as bO, COSTMANAGER_ENTERPRISE as bP, COSTMANAGER_PROFESSIONAL as bQ, COSTMANAGER_STANDARD as bR, CP as bS, CRM_ENTERPRISE as bT, DASHBOARDS as bU, EDITIONS as bV, EMPLOYEES_MOCK as bW, EMPLOYMENT_TYPES_MOCK as bX, ENTITY_DEFINITION_MAP as bY, ENTITY_REGISTRY as bZ, FINANCE_BASIC as b_, AXMMeetingRoleTypeDataSeeder as ba, AXMMeetingSessionDataSeeder as bb, AXMMeetingTypeDataSeeder as bc, AXMMeetingTypeFileTemplateDataSeeder as bd, AXMPositionAssignmentDataSeeder as be, AXMPositionDataSeeder as bf, AXMQuestionBankItemCategoryDataSeeder as bg, AXMQuestionBankItemDataSeeder as bh, AXMQuestionnaireCalculationDataSeeder as bi, AXMQuestionnaireCategoryDataSeeder as bj, AXMQuestionnaireDataSeeder as bk, AXMResponsibilityDataSeeder as bl, AXMTagDataSeeder as bm, AXMTeamBusinessUnitDataSeeder as bn, AXMTeamDataSeeder as bo, AXMTeamMemberDataSeeder as bp, AXMTeamMemberRoleDataSeeder as bq, AXMWorkflowDashboardChartDataSourceDefinition as br, AXM_AI_REGISTRY_COMMAND_NAME as bs, AXM_AI_REGISTRY_QUERY_NAME as bt, AXM_CORPORATE_BUSINESS_UNIT_ID as bu, AXPDashboardDataSeeder as bv, AXPIdentifierDB as bw, AXPMessageDataSeeder as bx, AXPMockChecksumProvider as by, AXPMockClockProvider as bz, resolveDelegatedAssistOptionString as c, WS as c$, FINANCE_PRO as c0, G as c1, HR_ENTERPRISE as c2, HW as c3, JOB_DEFINITIONS_CATEGORY_MOCK as c4, JOB_DEFINITIONS_MOCK as c5, JOB_DEFINITION_CATEGORY_KEY_TO_ID as c6, JOB_LEVELS_MOCK as c7, LASER_PLUMBING_TENANT_ID as c8, LEAVE_REQUESTS_MOCK as c9, QWS as cA, RESPONSIBILITIES_CATEGORY_MOCK as cB, RESPONSIBILITIES_MOCK as cC, RESPONSIBILITY_CATEGORY_KEY_TO_ID as cD, SAFETYMINDER_BASIC as cE, SAFETYMINDER_ENTERPRISE as cF, SAFETYMINDER_PROFESSIONAL as cG, SHOP_BASIC as cH, SHOP_ENTERPRISE as cI, SHOP_PRO as cJ, TAGS_MOCK as cK, TASKS as cL, TASK_STATUSES as cM, TASK_TEMPLATES as cN, TASK_TYPES as cO, TEAMS_CATEGORY_MOCK as cP, TEAMS_MOCK as cQ, TEAM_BUSINESS_UNITS_MOCK as cR, TEAM_CATEGORY_KEY_TO_ID as cS, TEAM_MEMBERS_MOCK as cT, TEAM_MEMBER_ROLES_MOCK as cU, TIMEPLICITY_TENANT_ID as cV, TLA as cW, TOKENS as cX, TPC as cY, VISIBILITY_FILTER_BYPASS as cZ, WORKFLOW_CATEGORIES as c_, MAGFA_COMMERCE_STANDARD as ca, MAGFA_CONVERSATION_DASHBOARD as cb, MAGFA_TENANT_ID as cc, METADATA_CATEGORY_IDS as cd, METADATA_GENERAL_CATEGORY_REFS as ce, METADATA_SYSTEM_CATEGORY_REFS as cf, MLC as cg, OHR as ch, ORDERING_BASIC as ci, ORDERING_ENTERPRISE as cj, ORDERING_STANDARD as ck, OWNERSHIP_FILTER_BYPASS as cl, PLATFORM_CONSOLE as cm, PLATFORM_TENANT_ID as cn, PM as co, POSITIONS_CATEGORY_MOCK as cp, POSITIONS_MOCK as cq, POSITION_ASSIGNMENTS_MOCK as cr, QCP as cs, QGEN as ct, QHW as cu, QOHR as cv, QPM as cw, QTLE as cx, QUESTIONNAIRE_CATEGORY_MOCK as cy, QUESTION_BANK_ITEM_CATEGORY_MOCK as cz, axcSyncSingleEmployeeDenormalizedOrgFields as d, meetingRoleTypeMock as d$, activityCategoryMocks as d0, activityDefinitionEntityMock as d1, applyEntityDefinitionFirestoreSnapshot as d2, automationCommandMiddleware as d3, automationMock as d4, avatarInterface as d5, awaitConversationMockSharedStorage as d6, axVersionDB as d7, axWorkflowExecutionDB as d8, axcPatchEmployeeActivePrimaryBusinessUnitRefsFromRows as d9, createWorkflowDefinitionEntityMock as dA, dateInterface as dB, dateTimeInterface as dC, descriptionInterface as dD, documentFolderSyncMiddleware as dE, emailInterface as dF, entityDefDb as dG, entityValidationMiddleware as dH, fileUploaderInterface as dI, finalizeActivityCategoryItemCounts as dJ, findEmployeeById as dK, folderStorageMiddleware as dL, groupOrderItemCalculatorMiddleware as dM, historyMiddleware as dN, identifierCommitMiddleware as dO, imageInterface as dP, inspectionOkXNaInterface as dQ, loadMockPropertyDefinitions as dR, lockGuardMiddleware as dS, longTextAnswerInterface as dT, lookupInterface as dU, lookupResolverMiddleware as dV, mapInterface as dW, meetingFilesMock as dX, meetingIds as dY, meetingMock as dZ, meetingParticipantMock as d_, axcPatchEmployeeActivePrimaryPositionRefsFromRows as da, axcPatchEmployeeManagerRefsFromRows as db, axcResolveCommandRegistrySeedId as dc, axcResolveQueryRegistrySeedId as dd, axcResolveWidgetCatalogSeedId as de, bankCategory as df, buildEntityStorageQuickSearchFilter as dg, buildWorkflowInstanceCartableDemoRows as dh, bypassAllFilters as di, bypassOwnershipFilter as dj, bypassVisibilityFilter as dk, calendarEventMock as dl, calendarEventTypeMockData as dm, calendarMock as dn, chatMessageMock as dp, chatMock as dq, checkboxInterface as dr, childCountMiddleware as ds, clearEntityDefinitionFirestoreCollections as dt, colorInterface as du, computeDiff as dv, contactInterface as dw, conversationDemoSeedUserIds as dx, createFileCastMiddleware as dy, createWidgetLayoutConfig as dz, ACTIVITY_CATEGORIES as e, meetingSessionMock as e0, meetingTimeSlotMock as e1, meetingTypeFileTemplateMock as e2, meetingTypeMock as e3, mergeDetailRelationMiddleware as e4, mergeQuickSearchIntoRequest as e5, metadataCategoryMocks as e6, mockParticipantIndexForSecurityUserId as e7, mockQuestionBankItemByName as e8, mockRoleDefinitions as e9, selectionListInterface as eA, sexAtBirthInterface as eB, signatureInterface as eC, signatureLoaderMiddleware as eD, statusDefaultMiddleware as eE, tagInterface as eF, tenantMocks as eG, textAreaInterface as eH, textInterface as eI, timeDurationInterface as eJ, titleInterface as eK, toUiRows as eL, toggleInterface as eM, tokenCategoryIds as eN, tokenCategoryMocks as eO, urlInterface as eP, versionInterface as eQ, visibilityFilterMiddleware as eR, workflowDefinitionEntityMock as eS, workflowDefinitionIds as eT, workflowDefinitionMock as eU, yesNoInterface as eV, multipleChoiceInterface as ea, multipleSelectInterface as eb, normalizeAnyFileArrayForView as ec, normalizeSnapshotFileFieldsForView as ed, numberInterface as ee, parseEntityStorageInsertData as ef, parseEntityStorageQueryRequest as eg, participantIds as eh, participantMock as ei, passwordInterface as ej, personIdentifierTypeMock as ek, personIds as el, personLegalIds as em, personMock as en, personNaturalIds as eo, phoneInterface as ep, primaryMiddleware as eq, provideMockPropertySetups as er, qrcodeInterface as es, questionBankItemMock as et, questionnaireCalculationMock as eu, questionnaireMock as ev, ratingInterface as ew, richTextInterface as ex, scaleInterface as ey, selectInterface as ez, ACTIVITY_CATEGORY_ID_BY_KEY as f, ACTIVITY_DEFINITIONS as g, AI_ASSIST_MOCK as h, AI_MODEL_MOCK as i, APPLICATIONS as j, APPLICATION_CATEGORY_IDS as k, APPLICATION_CATEGORY_MOCKS as l, mockUsers as m, AXCActivityCategorySeeder as n, AXCActivityDefinitionSeeder as o, AXCAiAssistSeeder as p, AXCAiManagementMockModule as q, resolveDelegatedAssistOptionModel as r, AXCAiModelSeeder as s, AXCAppTermDataSeeder as t, AXCAppVersionDataSeeder as u, AXCApplicationCategoryDataSeeder as v, AXCApplicationDataSeeder as w, AXCApplicationManagementMockModule as x, AXCAssessmentManagementMockModule as y, AXCAssetManagementMockModule as z };
81900
- //# sourceMappingURL=acorex-connectivity-mock-acorex-connectivity-mock-DjTpf9Cv.mjs.map
82243
+ //# sourceMappingURL=acorex-connectivity-mock-acorex-connectivity-mock-SjZSega-.mjs.map