@acorex-platform/module-human-capital-management-client 0.0.21

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 (31) hide show
  1. package/fesm2022/acorex-platform-module-human-capital-management-client-acorex-platform-module-human-capital-management-client-DlWna0Lz.mjs +2297 -0
  2. package/fesm2022/acorex-platform-module-human-capital-management-client-acorex-platform-module-human-capital-management-client-DlWna0Lz.mjs.map +1 -0
  3. package/fesm2022/acorex-platform-module-human-capital-management-client-approve-leave-request.command-Om_S0k9L.mjs +58 -0
  4. package/fesm2022/acorex-platform-module-human-capital-management-client-approve-leave-request.command-Om_S0k9L.mjs.map +1 -0
  5. package/fesm2022/acorex-platform-module-human-capital-management-client-assign-position-assignment.command-2iHIogn6.mjs +111 -0
  6. package/fesm2022/acorex-platform-module-human-capital-management-client-assign-position-assignment.command-2iHIogn6.mjs.map +1 -0
  7. package/fesm2022/acorex-platform-module-human-capital-management-client-cancel-leave-request.command-DGriRFiQ.mjs +58 -0
  8. package/fesm2022/acorex-platform-module-human-capital-management-client-cancel-leave-request.command-DGriRFiQ.mjs.map +1 -0
  9. package/fesm2022/acorex-platform-module-human-capital-management-client-contracts.mjs +193 -0
  10. package/fesm2022/acorex-platform-module-human-capital-management-client-contracts.mjs.map +1 -0
  11. package/fesm2022/acorex-platform-module-human-capital-management-client-edit-personal-info.command-DK947cW5.mjs +241 -0
  12. package/fesm2022/acorex-platform-module-human-capital-management-client-edit-personal-info.command-DK947cW5.mjs.map +1 -0
  13. package/fesm2022/acorex-platform-module-human-capital-management-client-edit-signature.command-CKrcMxqr.mjs +76 -0
  14. package/fesm2022/acorex-platform-module-human-capital-management-client-edit-signature.command-CKrcMxqr.mjs.map +1 -0
  15. package/fesm2022/acorex-platform-module-human-capital-management-client-profile-documents-panel.component-DrRuKQ6Q.mjs +87 -0
  16. package/fesm2022/acorex-platform-module-human-capital-management-client-profile-documents-panel.component-DrRuKQ6Q.mjs.map +1 -0
  17. package/fesm2022/acorex-platform-module-human-capital-management-client-profile-documents-panel.component.provider-DPH0YiDP.mjs +23 -0
  18. package/fesm2022/acorex-platform-module-human-capital-management-client-profile-documents-panel.component.provider-DPH0YiDP.mjs.map +1 -0
  19. package/fesm2022/acorex-platform-module-human-capital-management-client-reject-leave-request.command-O9gipd8g.mjs +61 -0
  20. package/fesm2022/acorex-platform-module-human-capital-management-client-reject-leave-request.command-O9gipd8g.mjs.map +1 -0
  21. package/fesm2022/acorex-platform-module-human-capital-management-client-revoke-position-assignment.command-DmVlDQ8_.mjs +108 -0
  22. package/fesm2022/acorex-platform-module-human-capital-management-client-revoke-position-assignment.command-DmVlDQ8_.mjs.map +1 -0
  23. package/fesm2022/acorex-platform-module-human-capital-management-client-start-leave-request-flow.command-BcyCI_vr.mjs +248 -0
  24. package/fesm2022/acorex-platform-module-human-capital-management-client-start-leave-request-flow.command-BcyCI_vr.mjs.map +1 -0
  25. package/fesm2022/acorex-platform-module-human-capital-management-client-start-lifecycle-event-flow.command-Cp_7ZyWU.mjs +250 -0
  26. package/fesm2022/acorex-platform-module-human-capital-management-client-start-lifecycle-event-flow.command-Cp_7ZyWU.mjs.map +1 -0
  27. package/fesm2022/acorex-platform-module-human-capital-management-client.mjs +2 -0
  28. package/fesm2022/acorex-platform-module-human-capital-management-client.mjs.map +1 -0
  29. package/package.json +28 -0
  30. package/types/acorex-platform-module-human-capital-management-client-contracts.d.ts +331 -0
  31. package/types/acorex-platform-module-human-capital-management-client.d.ts +114 -0
@@ -0,0 +1,76 @@
1
+ import { AXToastService } from '@acorex/components/toast';
2
+ import { AXTranslationService } from '@acorex/core/translation';
3
+ import { AXPSignatureEditorService } from '@acorex-platform/framework-client/layout/components';
4
+ import { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';
5
+ import * as i0 from '@angular/core';
6
+ import { inject, Injectable } from '@angular/core';
7
+ import { isNil, defaultTo, isEmpty, trim } from 'lodash';
8
+ import { RootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';
9
+ import { A as AXMHcmProfileContextService } from './acorex-platform-module-human-capital-management-client-acorex-platform-module-human-capital-management-client-DlWna0Lz.mjs';
10
+
11
+ //#region ---- Edit signature command ----
12
+ /** Opens the shared signature editor for the current employee record. */
13
+ class AXMHcmEditSignatureCommand {
14
+ constructor() {
15
+ //#region ---- Services & Dependencies ----
16
+ this.signatureEditorService = inject(AXPSignatureEditorService);
17
+ this.entityService = inject(AXPEntityService);
18
+ this.profileContextService = inject(AXMHcmProfileContextService);
19
+ this.toastService = inject(AXToastService);
20
+ this.translateService = inject(AXTranslationService);
21
+ }
22
+ //#endregion
23
+ //#region ---- Command ----
24
+ async execute() {
25
+ const profileContext = await this.profileContextService.resolve();
26
+ if (isNil(profileContext)) {
27
+ return {
28
+ success: false,
29
+ message: {
30
+ text: await this.translateService.translateAsync('@human-capital-management:profile-page.commands.edit-signature.messages.no-employee'),
31
+ },
32
+ };
33
+ }
34
+ const employeeData = this.entityService
35
+ .withEntity(RootConfig.module.name, RootConfig.entities.employee.name)
36
+ .data();
37
+ const employee = await employeeData.byKey(profileContext.employeeId);
38
+ if (isNil(employee)) {
39
+ return {
40
+ success: false,
41
+ message: {
42
+ text: await this.translateService.translateAsync('@human-capital-management:profile-page.commands.edit-signature.messages.employee-not-found'),
43
+ },
44
+ };
45
+ }
46
+ const existingSignature = defaultTo(employee.signature, '');
47
+ const submitActionKey = isEmpty(existingSignature)
48
+ ? '@general:actions.save.title'
49
+ : '@general:actions.update.title';
50
+ const dialogTitle = await this.translateService.translateAsync('@human-capital-management:profile-page.commands.edit-signature.dialog.title');
51
+ const result = await this.signatureEditorService.open({
52
+ title: dialogTitle,
53
+ value: existingSignature,
54
+ submitActionKey,
55
+ });
56
+ if (result.action === 'cancel') {
57
+ return { success: false };
58
+ }
59
+ const signature = trim(defaultTo(result.value, ''));
60
+ await employeeData.update(profileContext.employeeId, { signature });
61
+ const successTitle = await this.translateService.translateAsync(isEmpty(signature)
62
+ ? '@human-capital-management:profile-page.commands.edit-signature.messages.removed'
63
+ : '@human-capital-management:profile-page.commands.edit-signature.messages.success');
64
+ this.toastService.show({ color: 'success', title: successTitle });
65
+ return { success: true, kind: 'object', data: undefined };
66
+ }
67
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmEditSignatureCommand, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
68
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmEditSignatureCommand, providedIn: 'root' }); }
69
+ }
70
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmEditSignatureCommand, decorators: [{
71
+ type: Injectable,
72
+ args: [{ providedIn: 'root' }]
73
+ }] });
74
+
75
+ export { AXMHcmEditSignatureCommand };
76
+ //# sourceMappingURL=acorex-platform-module-human-capital-management-client-edit-signature.command-CKrcMxqr.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"acorex-platform-module-human-capital-management-client-edit-signature.command-CKrcMxqr.mjs","sources":["../../../../libs/modules/human-capital-management/client/src/lib/features/profile-page/commands/edit-signature.command.ts"],"sourcesContent":["import { AXPCommand, type AXPCommandExecuteResultPromise } from '@acorex-platform/framework-shared/runtime';\nimport { AXToastService } from '@acorex/components/toast';\nimport { AXTranslationService } from '@acorex/core/translation';\nimport { AXPRuntimeCommandResult } from '@acorex-platform/framework-shared/core';\nimport { AXPSignatureEditorService } from '@acorex-platform/framework-client/layout/components';\nimport { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';\n\nimport { inject, Injectable } from '@angular/core';\nimport { defaultTo, isEmpty, isNil, trim } from 'lodash';\n\nimport { RootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';\nimport { AXMHumanCapitalManagementEmployeeEntityModel } from '@acorex-platform/module-human-capital-management-client/contracts';\nimport { AXMHcmProfileContextService } from '../profile-context.service';\n\n//#region ---- Edit signature command ----\n\n/** Opens the shared signature editor for the current employee record. */\n@Injectable({ providedIn: 'root' })\nexport class AXMHcmEditSignatureCommand implements AXPCommand {\n //#region ---- Services & Dependencies ----\n\n private readonly signatureEditorService = inject(AXPSignatureEditorService);\n private readonly entityService = inject(AXPEntityService);\n private readonly profileContextService = inject(AXMHcmProfileContextService);\n private readonly toastService = inject(AXToastService);\n private readonly translateService = inject(AXTranslationService);\n\n //#endregion\n\n //#region ---- Command ----\n\n async execute(): AXPCommandExecuteResultPromise<void> {\n const profileContext = await this.profileContextService.resolve();\n if (isNil(profileContext)) {\n return {\n success: false,\n message: {\n text: await this.translateService.translateAsync(\n '@human-capital-management:profile-page.commands.edit-signature.messages.no-employee',\n ),\n },\n };\n }\n\n const employeeData = this.entityService\n .withEntity(RootConfig.module.name, RootConfig.entities.employee.name)\n .data<string, AXMHumanCapitalManagementEmployeeEntityModel>();\n\n const employee = await employeeData.byKey(profileContext.employeeId);\n if (isNil(employee)) {\n return {\n success: false,\n message: {\n text: await this.translateService.translateAsync(\n '@human-capital-management:profile-page.commands.edit-signature.messages.employee-not-found',\n ),\n },\n };\n }\n\n const existingSignature = defaultTo(employee.signature, '');\n const submitActionKey = isEmpty(existingSignature)\n ? '@general:actions.save.title'\n : '@general:actions.update.title';\n\n const dialogTitle = await this.translateService.translateAsync(\n '@human-capital-management:profile-page.commands.edit-signature.dialog.title',\n );\n\n const result = await this.signatureEditorService.open({\n title: dialogTitle,\n value: existingSignature,\n submitActionKey,\n });\n\n if (result.action === 'cancel') {\n return { success: false };\n }\n\n const signature = trim(defaultTo(result.value, ''));\n await employeeData.update(profileContext.employeeId, { signature });\n\n const successTitle = await this.translateService.translateAsync(\n isEmpty(signature)\n ? '@human-capital-management:profile-page.commands.edit-signature.messages.removed'\n : '@human-capital-management:profile-page.commands.edit-signature.messages.success',\n );\n this.toastService.show({ color: 'success', title: successTitle });\n return { success: true, kind: 'object', data: undefined };\n }\n\n //#endregion\n}\n\n//#endregion\n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AAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,0BAA0B,cADb,MAAM,EAAA,CAAA,CAAA;;2FACnB,0BAA0B,EAAA,UAAA,EAAA,CAAA;kBADtC,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE;;;;;"}
@@ -0,0 +1,87 @@
1
+ import { AXPQueryService } from '@acorex-platform/framework-client/runtime';
2
+ import { AXPPageLayoutBaseComponent, AXPPageComponentRendererDirective, AXPPageLayoutBase } from '@acorex-platform/framework-client/layout/views';
3
+ import * as i1 from '@acorex/components/loading';
4
+ import { AXLoadingModule } from '@acorex/components/loading';
5
+ import * as i4 from '@acorex/core/translation';
6
+ import { AXTranslationModule } from '@acorex/core/translation';
7
+ import { runtimeQueryPayloadData } from '@acorex-platform/framework-shared/core';
8
+ import { AsyncPipe } from '@angular/common';
9
+ import * as i0 from '@angular/core';
10
+ import { input, inject, signal, ViewEncapsulation, ChangeDetectionStrategy, Component } from '@angular/core';
11
+ import { AXPHumanCapitalManagementQueryKeys } from '@acorex-platform/module-human-capital-management-client/contracts';
12
+ import { D as DOCUMENT_DRIVE_PAGE_COMPONENT_KEY } from './acorex-platform-module-human-capital-management-client-acorex-platform-module-human-capital-management-client-DlWna0Lz.mjs';
13
+
14
+ //#region ----- Imports -----
15
+ //#endregion
16
+ //#region ----- Component -----
17
+ /** Fetches the employee document-drive context, then mounts the EDMS page. */
18
+ class AXMHcmProfileDocumentsPanelComponent extends AXPPageLayoutBaseComponent {
19
+ constructor() {
20
+ super(...arguments);
21
+ //#region ----- Inputs -----
22
+ this.rootContext = input({}, /* @ts-ignore */
23
+ ...(ngDevMode ? [{ debugName: "rootContext" }] : /* istanbul ignore next */ []));
24
+ this.pageConfig = input(/* @ts-ignore */
25
+ ...(ngDevMode ? [undefined, { debugName: "pageConfig" }] : /* istanbul ignore next */ []));
26
+ this.options = input({}, /* @ts-ignore */
27
+ ...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
28
+ //#endregion
29
+ //#region ----- Services & Dependencies -----
30
+ this.queryService = inject(AXPQueryService);
31
+ //#endregion
32
+ //#region ----- State Signals -----
33
+ this.isLoading = signal(true, /* @ts-ignore */
34
+ ...(ngDevMode ? [{ debugName: "isLoading" }] : /* istanbul ignore next */ []));
35
+ this.drivePageConfig = signal(null, /* @ts-ignore */
36
+ ...(ngDevMode ? [{ debugName: "drivePageConfig" }] : /* istanbul ignore next */ []));
37
+ this.driveComponentKey = DOCUMENT_DRIVE_PAGE_COMPONENT_KEY;
38
+ }
39
+ //#endregion
40
+ //#region ----- Lifecycle -----
41
+ async ngOnInit() {
42
+ await this.loadDriveContext();
43
+ }
44
+ getPageTitle() {
45
+ return '';
46
+ }
47
+ //#endregion
48
+ //#region ----- Data Loading -----
49
+ async loadDriveContext() {
50
+ this.isLoading.set(true);
51
+ try {
52
+ const result = await this.queryService.fetch(AXPHumanCapitalManagementQueryKeys.Profile.GetMyDocumentDriveContext, undefined);
53
+ const context = runtimeQueryPayloadData(result);
54
+ if (!context?.refType || !context?.refId) {
55
+ this.drivePageConfig.set(null);
56
+ return;
57
+ }
58
+ this.drivePageConfig.set({
59
+ refType: context.refType,
60
+ refId: context.refId,
61
+ allowedDocumentTypeNames: context.documentTypeNames,
62
+ });
63
+ }
64
+ finally {
65
+ this.isLoading.set(false);
66
+ }
67
+ }
68
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmProfileDocumentsPanelComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
69
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: AXMHcmProfileDocumentsPanelComponent, isStandalone: true, selector: "axm-hcm-profile-documents-panel", inputs: { rootContext: { classPropertyName: "rootContext", publicName: "rootContext", isSignal: true, isRequired: false, transformFunction: null }, pageConfig: { classPropertyName: "pageConfig", publicName: "pageConfig", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "axm-hcm-profile-documents-panel" }, providers: [
70
+ {
71
+ provide: AXPPageLayoutBase,
72
+ useExisting: AXMHcmProfileDocumentsPanelComponent,
73
+ },
74
+ ], usesInheritance: true, ngImport: i0, template: "@if (isLoading()) {\n <div class=\"__loading\">\n <ax-loading></ax-loading>\n </div>\n} @else if (drivePageConfig(); as config) {\n <div\n axp-page-component-renderer\n [componentKey]=\"driveComponentKey\"\n [pageConfig]=\"config\"\n [rootContext]=\"rootContext()\"\n [options]=\"options()\"\n ></div>\n} @else {\n <p class=\"__empty\">{{ '@human-capital-management:profile-page.groups.documents.empty' | translate | async }}</p>\n}\n", styles: ["@layer properties;.axm-hcm-profile-documents-panel{display:block;width:100%}.axm-hcm-profile-documents-panel .__loading{display:flex;min-height:calc(var(--spacing, .25rem) * 64);align-items:center;justify-content:center}.axm-hcm-profile-documents-panel .__empty{margin:0;border-radius:var(--radius-2xl, 1rem);border-style:var(--tw-border-style);border-width:1px;--tw-border-style: dashed;border-style:dashed;padding-block:calc(var(--spacing, .25rem) * 12);text-align:center;--tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 1px 2px -1px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);background-color:var(--color-lightest);color:var(--color-on-lightest);border-color:var(--color-border-lightest);color:rgb(var(--ax-sys-color-on-lighter-surface));border-color:rgb(var(--ax-sys-color-border-lighter-surface))}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid;--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: AXLoadingModule }, { kind: "component", type: i1.AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "directive", type: AXPPageComponentRendererDirective, selector: "[axp-page-component-renderer]", inputs: ["componentKey", "rootContext", "pageConfig", "options"], outputs: ["componentReady"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: i4.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
75
+ }
76
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmProfileDocumentsPanelComponent, decorators: [{
77
+ type: Component,
78
+ args: [{ selector: 'axm-hcm-profile-documents-panel', imports: [AsyncPipe, AXLoadingModule, AXTranslationModule, AXPPageComponentRendererDirective], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: { class: 'axm-hcm-profile-documents-panel' }, providers: [
79
+ {
80
+ provide: AXPPageLayoutBase,
81
+ useExisting: AXMHcmProfileDocumentsPanelComponent,
82
+ },
83
+ ], template: "@if (isLoading()) {\n <div class=\"__loading\">\n <ax-loading></ax-loading>\n </div>\n} @else if (drivePageConfig(); as config) {\n <div\n axp-page-component-renderer\n [componentKey]=\"driveComponentKey\"\n [pageConfig]=\"config\"\n [rootContext]=\"rootContext()\"\n [options]=\"options()\"\n ></div>\n} @else {\n <p class=\"__empty\">{{ '@human-capital-management:profile-page.groups.documents.empty' | translate | async }}</p>\n}\n", styles: ["@layer properties;.axm-hcm-profile-documents-panel{display:block;width:100%}.axm-hcm-profile-documents-panel .__loading{display:flex;min-height:calc(var(--spacing, .25rem) * 64);align-items:center;justify-content:center}.axm-hcm-profile-documents-panel .__empty{margin:0;border-radius:var(--radius-2xl, 1rem);border-style:var(--tw-border-style);border-width:1px;--tw-border-style: dashed;border-style:dashed;padding-block:calc(var(--spacing, .25rem) * 12);text-align:center;--tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 1px 2px -1px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow);background-color:var(--color-lightest);color:var(--color-on-lightest);border-color:var(--color-border-lightest);color:rgb(var(--ax-sys-color-on-lighter-surface));border-color:rgb(var(--ax-sys-color-border-lighter-surface))}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid;--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000}}}\n/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */\n"] }]
84
+ }], propDecorators: { rootContext: [{ type: i0.Input, args: [{ isSignal: true, alias: "rootContext", required: false }] }], pageConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "pageConfig", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: false }] }] } });
85
+
86
+ export { AXMHcmProfileDocumentsPanelComponent };
87
+ //# sourceMappingURL=acorex-platform-module-human-capital-management-client-profile-documents-panel.component-DrRuKQ6Q.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"acorex-platform-module-human-capital-management-client-profile-documents-panel.component-DrRuKQ6Q.mjs","sources":["../../../../libs/modules/human-capital-management/client/src/lib/features/profile-page/profile-documents-panel.component.ts","../../../../libs/modules/human-capital-management/client/src/lib/features/profile-page/profile-documents-panel.component.html"],"sourcesContent":["//#region ----- Imports -----\n\nimport { AXPQueryService } from '@acorex-platform/framework-client/runtime';\nimport {\n AXPPageComponentRendererDirective,\n AXPPageLayoutBase,\n AXPPageLayoutBaseComponent,\n} from '@acorex-platform/framework-client/layout/views';\nimport { AXLoadingModule } from '@acorex/components/loading';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { runtimeQueryPayloadData } from '@acorex-platform/framework-shared/core';\nimport { AsyncPipe } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n inject,\n input,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport {\n AXPHumanCapitalManagementQueryKeys,\n type AXMHcmProfileDocumentDriveContext,\n} from '@acorex-platform/module-human-capital-management-client/contracts';\nimport { DOCUMENT_DRIVE_PAGE_COMPONENT_KEY } from './profile-documents-panel.constants';\n\n//#endregion\n\n//#region ----- Component -----\n\n/** Fetches the employee document-drive context, then mounts the EDMS page. */\n@Component({\n selector: 'axm-hcm-profile-documents-panel',\n imports: [AsyncPipe, AXLoadingModule, AXTranslationModule, AXPPageComponentRendererDirective],\n templateUrl: './profile-documents-panel.component.html',\n styleUrl: './profile-documents-panel.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n host: { class: 'axm-hcm-profile-documents-panel' },\n providers: [\n {\n provide: AXPPageLayoutBase,\n useExisting: AXMHcmProfileDocumentsPanelComponent,\n },\n ],\n})\nexport class AXMHcmProfileDocumentsPanelComponent extends AXPPageLayoutBaseComponent {\n //#region ----- Inputs -----\n\n rootContext = input<Record<string, unknown>>({});\n pageConfig = input<Record<string, unknown>>();\n options = input<Record<string, unknown>>({});\n\n //#endregion\n\n //#region ----- Services & Dependencies -----\n\n private readonly queryService = inject(AXPQueryService);\n\n //#endregion\n\n //#region ----- State Signals -----\n\n protected readonly isLoading = signal(true);\n protected readonly drivePageConfig = signal<Record<string, unknown> | null>(null);\n protected readonly driveComponentKey = DOCUMENT_DRIVE_PAGE_COMPONENT_KEY;\n\n //#endregion\n\n //#region ----- Lifecycle -----\n\n override async ngOnInit(): Promise<void> {\n await this.loadDriveContext();\n }\n\n protected override getPageTitle(): string {\n return '';\n }\n\n //#endregion\n\n //#region ----- Data Loading -----\n\n private async loadDriveContext(): Promise<void> {\n this.isLoading.set(true);\n try {\n const result = await this.queryService.fetch<void, AXMHcmProfileDocumentDriveContext | null>(\n AXPHumanCapitalManagementQueryKeys.Profile.GetMyDocumentDriveContext,\n undefined as void,\n );\n const context = runtimeQueryPayloadData(result);\n if (!context?.refType || !context?.refId) {\n this.drivePageConfig.set(null);\n return;\n }\n\n this.drivePageConfig.set({\n refType: context.refType,\n refId: context.refId,\n allowedDocumentTypeNames: context.documentTypeNames,\n });\n } finally {\n this.isLoading.set(false);\n }\n }\n\n //#endregion\n}\n\n//#endregion\n","@if (isLoading()) {\n <div class=\"__loading\">\n <ax-loading></ax-loading>\n </div>\n} @else if (drivePageConfig(); as config) {\n <div\n axp-page-component-renderer\n [componentKey]=\"driveComponentKey\"\n [pageConfig]=\"config\"\n [rootContext]=\"rootContext()\"\n [options]=\"options()\"\n ></div>\n} @else {\n <p class=\"__empty\">{{ '@human-capital-management:profile-page.groups.documents.empty' | translate | async }}</p>\n}\n"],"names":["i2"],"mappings":";;;;;;;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AA,EAAA,MAAA,EAAA,CAAA,SAAA,EAAA,MAAA,EAAA,SAAA,CAAA,EAAA,OAAA,EAAA,CAAA,eAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAE,mBAAmB,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAE,iCAAiC,oKAAlF,SAAS,EAAA,IAAA,EAAA,OAAA,EAAA,EAAA,EAAA,IAAA,EAAA,MAAA,EAAA,IAAA,EAAAA,EAAA,CAAA,gBAAA,EAAA,IAAA,EAAA,WAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;2FAaR,oCAAoC,EAAA,UAAA,EAAA,CAAA;kBAfhD,SAAS;+BACE,iCAAiC,EAAA,OAAA,EAClC,CAAC,SAAS,EAAE,eAAe,EAAE,mBAAmB,EAAE,iCAAiC,CAAC,EAAA,eAAA,EAG5E,uBAAuB,CAAC,MAAM,EAAA,aAAA,EAChC,iBAAiB,CAAC,IAAI,EAAA,IAAA,EAC/B,EAAE,KAAK,EAAE,iCAAiC,EAAE,EAAA,SAAA,EACvC;AACT,wBAAA;AACE,4BAAA,OAAO,EAAE,iBAAiB;AAC1B,4BAAA,WAAW,EAAA,oCAAsC;AAClD,yBAAA;AACF,qBAAA,EAAA,QAAA,EAAA,2cAAA,EAAA,MAAA,EAAA,CAAA,gwFAAA,CAAA,EAAA;;;;;"}
@@ -0,0 +1,23 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Injectable } from '@angular/core';
3
+ import { P as PROFILE_DOCUMENTS_PANEL_COMPONENT_KEY } from './acorex-platform-module-human-capital-management-client-acorex-platform-module-human-capital-management-client-DlWna0Lz.mjs';
4
+
5
+ //#region ----- Profile documents panel provider -----
6
+ class AXMHcmProfileDocumentsPanelComponentProvider {
7
+ async components() {
8
+ return [
9
+ {
10
+ key: PROFILE_DOCUMENTS_PANEL_COMPONENT_KEY,
11
+ loader: () => import('./acorex-platform-module-human-capital-management-client-profile-documents-panel.component-DrRuKQ6Q.mjs').then((module) => module.AXMHcmProfileDocumentsPanelComponent),
12
+ },
13
+ ];
14
+ }
15
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmProfileDocumentsPanelComponentProvider, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
16
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmProfileDocumentsPanelComponentProvider }); }
17
+ }
18
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMHcmProfileDocumentsPanelComponentProvider, decorators: [{
19
+ type: Injectable
20
+ }] });
21
+
22
+ export { AXMHcmProfileDocumentsPanelComponentProvider };
23
+ //# sourceMappingURL=acorex-platform-module-human-capital-management-client-profile-documents-panel.component.provider-DPH0YiDP.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"acorex-platform-module-human-capital-management-client-profile-documents-panel.component.provider-DPH0YiDP.mjs","sources":["../../../../libs/modules/human-capital-management/client/src/lib/features/profile-page/profile-documents-panel.component.provider.ts"],"sourcesContent":["import {\n AXPPageComponentDefinition,\n AXPPageComponentProvider,\n} from '@acorex-platform/framework-client/layout/components';\nimport { Injectable } from '@angular/core';\nimport { PROFILE_DOCUMENTS_PANEL_COMPONENT_KEY } from './profile-documents-panel.constants';\n\n//#region ----- Profile documents panel provider -----\n\n@Injectable()\nexport class AXMHcmProfileDocumentsPanelComponentProvider implements AXPPageComponentProvider {\n async components(): Promise<AXPPageComponentDefinition[]> {\n return [\n {\n key: PROFILE_DOCUMENTS_PANEL_COMPONENT_KEY,\n loader: () =>\n import('./profile-documents-panel.component').then((module) => module.AXMHcmProfileDocumentsPanelComponent),\n },\n ];\n }\n}\n\n//#endregion\n"],"names":[],"mappings":";;;;AAOA;MAGa,4CAA4C,CAAA;AACvD,IAAA,MAAM,UAAU,GAAA;QACd,OAAO;AACL,YAAA;AACE,gBAAA,GAAG,EAAE,qCAAqC;AAC1C,gBAAA,MAAM,EAAE,MACN,OAAO,yGAAqC,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,KAAK,MAAM,CAAC,oCAAoC,CAAC;AAC9G,aAAA;SACF;IACH;8GATW,4CAA4C,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;kHAA5C,4CAA4C,EAAA,CAAA,CAAA;;2FAA5C,4CAA4C,EAAA,UAAA,EAAA,CAAA;kBADxD;;;;;"}
@@ -0,0 +1,61 @@
1
+ import { AXPSystemStatuses } from '@acorex-platform/framework-shared/core';
2
+ import { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';
3
+ import * as i0 from '@angular/core';
4
+ import { inject, Injectable } from '@angular/core';
5
+ import { RootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';
6
+
7
+ //#endregion
8
+ /**
9
+ * Reject Leave Request Command
10
+ * Updates the leave request status to Rejected
11
+ */
12
+ class RejectLeaveRequestCommand {
13
+ constructor() {
14
+ //#region ---- Services ----
15
+ this.entityService = inject(AXPEntityService);
16
+ }
17
+ //#endregion
18
+ //#region ---- Command Implementation ----
19
+ async execute(input) {
20
+ try {
21
+ console.log('[RejectLeaveRequestCommand] Executing with input:', input);
22
+ const dataAccessor = this.entityService
23
+ .withEntity(RootConfig.module.name, RootConfig.entities.leaveRequest.name)
24
+ .data();
25
+ // Update the leave request status to Rejected
26
+ const updateData = {
27
+ statusId: AXPSystemStatuses.Rejected.name,
28
+ };
29
+ // Add reason/note if provided (these fields might not exist in entity model)
30
+ if (input.reason) {
31
+ updateData.reason = input.reason;
32
+ }
33
+ if (input.note) {
34
+ updateData.note = input.note;
35
+ }
36
+ console.log('[RejectLeaveRequestCommand] Updating entity with:', updateData);
37
+ await dataAccessor.update(input.id, updateData);
38
+ console.log('[RejectLeaveRequestCommand] Update successful');
39
+ return { success: true, kind: 'object', data: undefined,
40
+ };
41
+ }
42
+ catch (error) {
43
+ console.error('[RejectLeaveRequestCommand] Error:', error);
44
+ return {
45
+ success: false,
46
+ message: {
47
+ text: error.message || 'Failed to reject leave request',
48
+ },
49
+ };
50
+ }
51
+ }
52
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: RejectLeaveRequestCommand, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
53
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: RejectLeaveRequestCommand, providedIn: 'root' }); }
54
+ }
55
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: RejectLeaveRequestCommand, decorators: [{
56
+ type: Injectable,
57
+ args: [{ providedIn: 'root' }]
58
+ }] });
59
+
60
+ export { RejectLeaveRequestCommand };
61
+ //# sourceMappingURL=acorex-platform-module-human-capital-management-client-reject-leave-request.command-O9gipd8g.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"acorex-platform-module-human-capital-management-client-reject-leave-request.command-O9gipd8g.mjs","sources":["../../../../libs/modules/human-capital-management/client/src/lib/features/leave-request/commands/reject-leave-request.command.ts"],"sourcesContent":["\n\nimport { AXPCommand, type AXPCommandExecuteResultPromise } from '@acorex-platform/framework-shared/runtime';\nimport { AXPRuntimeCommandResult, AXPSystemStatuses } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';\n\nimport { Injectable, inject } from '@angular/core';\nimport { RootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';\n\n//#region ---- Types ----\n\nexport interface RejectLeaveRequestInput {\n id: string;\n reason?: string;\n note?: string;\n}\n\n//#endregion\n\n/**\n * Reject Leave Request Command\n * Updates the leave request status to Rejected\n */\n@Injectable({ providedIn: 'root' })\nexport class RejectLeaveRequestCommand implements AXPCommand<RejectLeaveRequestInput, void> {\n //#region ---- Services ----\n\n private readonly entityService = inject(AXPEntityService);\n\n //#endregion\n\n //#region ---- Command Implementation ----\n\n async execute(input: RejectLeaveRequestInput): AXPCommandExecuteResultPromise<void> {\n try {\n console.log('[RejectLeaveRequestCommand] Executing with input:', input);\n\n const dataAccessor = this.entityService\n .withEntity(RootConfig.module.name, RootConfig.entities.leaveRequest.name)\n .data<string, any>();\n\n // Update the leave request status to Rejected\n const updateData: any = {\n statusId: AXPSystemStatuses.Rejected.name,\n };\n\n // Add reason/note if provided (these fields might not exist in entity model)\n if (input.reason) {\n updateData.reason = input.reason;\n }\n if (input.note) {\n updateData.note = input.note;\n }\n\n console.log('[RejectLeaveRequestCommand] Updating entity with:', updateData);\n\n await dataAccessor.update(input.id, updateData);\n\n console.log('[RejectLeaveRequestCommand] Update successful');\n\n return { success: true, kind: 'object', data: undefined,\n };\n } catch (error: any) {\n console.error('[RejectLeaveRequestCommand] Error:', error);\n return {\n success: false,\n message: {\n text: error.message || 'Failed to reject leave request',\n },\n };\n }\n }\n\n //#endregion\n}\n"],"names":[],"mappings":";;;;;;AAiBA;AAEA;;;AAGG;MAEU,yBAAyB,CAAA;AADtC,IAAA,WAAA,GAAA;;AAImB,QAAA,IAAA,CAAA,aAAa,GAAG,MAAM,CAAC,gBAAgB,CAAC;AA+C1D,IAAA;;;IAzCC,MAAM,OAAO,CAAC,KAA8B,EAAA;AAC1C,QAAA,IAAI;AACF,YAAA,OAAO,CAAC,GAAG,CAAC,mDAAmD,EAAE,KAAK,CAAC;AAEvE,YAAA,MAAM,YAAY,GAAG,IAAI,CAAC;AACvB,iBAAA,UAAU,CAAC,UAAU,CAAC,MAAM,CAAC,IAAI,EAAE,UAAU,CAAC,QAAQ,CAAC,YAAY,CAAC,IAAI;AACxE,iBAAA,IAAI,EAAe;;AAGtB,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0,0 +1,108 @@
1
+ import { AXDialogService } from '@acorex/components/dialog';
2
+ import { AXTranslationService } from '@acorex/core/translation';
3
+ import { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';
4
+ import * as i0 from '@angular/core';
5
+ import { inject, Injectable } from '@angular/core';
6
+ import { AXM_POSITION_ASSIGNMENT_STATUS, RootConfig, AXM_POSITION_ASSIGNMENT_OVERLAPPING_STATUS_IDS } from '@acorex-platform/module-human-capital-management-client/contracts';
7
+
8
+ class AXMRevokePositionAssignmentByIdCommand {
9
+ constructor() {
10
+ this.dialogService = inject(AXDialogService);
11
+ this.translationService = inject(AXTranslationService);
12
+ this.entityService = inject(AXPEntityService);
13
+ }
14
+ async execute(input) {
15
+ let ids = this.extractIds(input);
16
+ if (!ids.length && input.positionId && input.employeeId) {
17
+ ids = await this.findOverlappingLifecycleAssignmentIds(input.positionId, input.employeeId, input.businessUnitId);
18
+ }
19
+ if (!ids.length) {
20
+ if (input.skipConfirmation) {
21
+ return { success: true, kind: 'object', data: { revokedCount: 0 } };
22
+ }
23
+ return { success: false };
24
+ }
25
+ if (!input.skipConfirmation) {
26
+ const confirmed = await this.confirmRevoke();
27
+ if (!confirmed) {
28
+ return { success: false };
29
+ }
30
+ }
31
+ const payload = {
32
+ endDate: new Date().toISOString(),
33
+ statusId: AXM_POSITION_ASSIGNMENT_STATUS.revoked,
34
+ };
35
+ const data = this.entityService
36
+ .withEntity(RootConfig.module.name, RootConfig.entities.positionAssignment.name)
37
+ .data();
38
+ for (const id of ids) {
39
+ await data.update(id, payload);
40
+ }
41
+ return { success: true, kind: 'object', data: { revokedCount: ids.length } };
42
+ }
43
+ async confirmRevoke() {
44
+ const title = await this.translationService.translateAsync('@human-capital-management:position-assignments.entities.position-assignment.actions.revoke.confirm.title');
45
+ const message = await this.translationService.translateAsync('@human-capital-management:position-assignments.entities.position-assignment.actions.revoke.confirm.message');
46
+ const result = await this.dialogService.confirm(title, message, 'danger', 'horizontal', false, 'cancel');
47
+ return result.result === true;
48
+ }
49
+ extractIds(input) {
50
+ const raw = input?.data ?? input?.data ?? input?.id ?? input;
51
+ const values = Array.isArray(raw) ? raw : [raw];
52
+ return values
53
+ .map((value) => {
54
+ if (typeof value === 'string') {
55
+ return value;
56
+ }
57
+ if (value && typeof value === 'object') {
58
+ const id = value['id'];
59
+ return typeof id === 'string' ? id : '';
60
+ }
61
+ return '';
62
+ })
63
+ .filter((id) => id.trim().length > 0);
64
+ }
65
+ /**
66
+ * Resolves assignment rows that still participate in overlap checks (active + scheduled).
67
+ * Revoking only `active` left future-dated `scheduled` rows and blocked new assignments.
68
+ */
69
+ async findOverlappingLifecycleAssignmentIds(positionId, employeeId, businessUnitId) {
70
+ const filters = [
71
+ { field: 'positionId', operator: { type: 'equal' }, value: positionId },
72
+ { field: 'employeeId', operator: { type: 'equal' }, value: employeeId },
73
+ { field: 'statusId', operator: { type: 'in' }, value: [...AXM_POSITION_ASSIGNMENT_OVERLAPPING_STATUS_IDS] },
74
+ ];
75
+ if (businessUnitId) {
76
+ filters.push({ field: 'businessUnitId', operator: { type: 'equal' }, value: businessUnitId });
77
+ }
78
+ const result = await this.entityService
79
+ .withEntity(RootConfig.module.name, RootConfig.entities.positionAssignment.name)
80
+ .data()
81
+ .query({
82
+ skip: 0,
83
+ take: 50,
84
+ sort: [{ field: 'startDate', dir: 'desc' }],
85
+ filter: { logic: 'and', filters },
86
+ });
87
+ const items = (result.items ?? []);
88
+ const seen = new Set();
89
+ const ids = [];
90
+ for (const item of items) {
91
+ const id = typeof item.id === 'string' && item.id.trim().length > 0 ? item.id.trim() : '';
92
+ if (id && !seen.has(id)) {
93
+ seen.add(id);
94
+ ids.push(id);
95
+ }
96
+ }
97
+ return ids;
98
+ }
99
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMRevokePositionAssignmentByIdCommand, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
100
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMRevokePositionAssignmentByIdCommand, providedIn: 'root' }); }
101
+ }
102
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXMRevokePositionAssignmentByIdCommand, decorators: [{
103
+ type: Injectable,
104
+ args: [{ providedIn: 'root' }]
105
+ }] });
106
+
107
+ export { AXMRevokePositionAssignmentByIdCommand };
108
+ //# sourceMappingURL=acorex-platform-module-human-capital-management-client-revoke-position-assignment.command-DmVlDQ8_.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"acorex-platform-module-human-capital-management-client-revoke-position-assignment.command-DmVlDQ8_.mjs","sources":["../../../../libs/modules/human-capital-management/client/src/lib/features/organization-chart/commands/revoke-position-assignment.command.ts"],"sourcesContent":["import { AXPCommand, type AXPCommandExecuteResultPromise } from '@acorex-platform/framework-shared/runtime';\nimport { AXDataSourceFilterOption } from '@acorex/cdk/common';\nimport { AXDialogService } from '@acorex/components/dialog';\nimport { AXTranslationService } from '@acorex/core/translation';\nimport { AXPRuntimeCommandResult } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';\n\nimport { inject, Injectable } from '@angular/core';\nimport { RootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';\nimport {\n AXM_POSITION_ASSIGNMENT_OVERLAPPING_STATUS_IDS,\n AXM_POSITION_ASSIGNMENT_STATUS,\n} from '@acorex-platform/module-human-capital-management-client/contracts';\n\nexport interface AXMRevokePositionAssignmentByIdInput {\n data?: unknown;\n id?: unknown;\n positionId?: string;\n employeeId?: string;\n businessUnitId?: string;\n /** When true, do not show the revoke confirmation (caller already confirmed). */\n skipConfirmation?: boolean;\n}\n\n@Injectable({ providedIn: 'root' })\nexport class AXMRevokePositionAssignmentByIdCommand\n implements AXPCommand<AXMRevokePositionAssignmentByIdInput, { revokedCount: number }>\n{\n private readonly dialogService = inject(AXDialogService);\n private readonly translationService = inject(AXTranslationService);\n private readonly entityService = inject(AXPEntityService);\n\n async execute(\n input: AXMRevokePositionAssignmentByIdInput,\n ): AXPCommandExecuteResultPromise<{ revokedCount: number }> {\n let ids = this.extractIds(input);\n if (!ids.length && input.positionId && input.employeeId) {\n ids = await this.findOverlappingLifecycleAssignmentIds(\n input.positionId,\n input.employeeId,\n input.businessUnitId,\n );\n }\n if (!ids.length) {\n if (input.skipConfirmation) {\n return { success: true, kind: 'object', data: { revokedCount: 0 } };\n }\n return { success: false };\n }\n\n if (!input.skipConfirmation) {\n const confirmed = await this.confirmRevoke();\n if (!confirmed) {\n return { success: false };\n }\n }\n\n const payload: Record<string, unknown> = {\n endDate: new Date().toISOString(),\n statusId: AXM_POSITION_ASSIGNMENT_STATUS.revoked,\n };\n const data = this.entityService\n .withEntity(RootConfig.module.name, RootConfig.entities.positionAssignment.name)\n .data();\n for (const id of ids) {\n await data.update(id, payload as never);\n }\n\n return { success: true, kind: 'object', data: { revokedCount: ids.length } };\n }\n\n private async confirmRevoke(): Promise<boolean> {\n const title = await this.translationService.translateAsync(\n '@human-capital-management:position-assignments.entities.position-assignment.actions.revoke.confirm.title',\n );\n const message = await this.translationService.translateAsync(\n '@human-capital-management:position-assignments.entities.position-assignment.actions.revoke.confirm.message',\n );\n const result = await this.dialogService.confirm(title, message, 'danger', 'horizontal', false, 'cancel');\n return result.result === true;\n }\n\n private extractIds(input: AXMRevokePositionAssignmentByIdInput): string[] {\n const raw = input?.data ?? input?.data ?? input?.id ?? input;\n const values = Array.isArray(raw) ? raw : [raw];\n return values\n .map((value) => {\n if (typeof value === 'string') {\n return value;\n }\n if (value && typeof value === 'object') {\n const id = (value as { id?: unknown })['id'];\n return typeof id === 'string' ? id : '';\n }\n return '';\n })\n .filter((id) => id.trim().length > 0);\n }\n\n /**\n * Resolves assignment rows that still participate in overlap checks (active + scheduled).\n * Revoking only `active` left future-dated `scheduled` rows and blocked new assignments.\n */\n private async findOverlappingLifecycleAssignmentIds(\n positionId: string,\n employeeId: string,\n businessUnitId?: string,\n ): Promise<string[]> {\n const filters: AXDataSourceFilterOption[] = [\n { field: 'positionId', operator: { type: 'equal' }, value: positionId },\n { field: 'employeeId', operator: { type: 'equal' }, value: employeeId },\n { field: 'statusId', operator: { type: 'in' }, value: [...AXM_POSITION_ASSIGNMENT_OVERLAPPING_STATUS_IDS] },\n ];\n if (businessUnitId) {\n filters.push({ field: 'businessUnitId', operator: { type: 'equal' }, value: businessUnitId });\n }\n\n const result = await this.entityService\n .withEntity(RootConfig.module.name, RootConfig.entities.positionAssignment.name)\n .data()\n .query({\n skip: 0,\n take: 50,\n sort: [{ field: 'startDate', dir: 'desc' }],\n filter: { logic: 'and', filters },\n });\n\n const items = (result.items ?? []) as Array<{ id?: string }>;\n const seen = new Set<string>();\n const ids: string[] = [];\n for (const item of items) {\n const id = typeof item.id === 'string' && item.id.trim().length > 0 ? item.id.trim() : '';\n if (id && !seen.has(id)) {\n seen.add(id);\n ids.push(id);\n }\n }\n return ids;\n }\n}\n\n"],"names":[],"mappings":";;;;;;;MAyBa,sCAAsC,CAAA;AADnD,IAAA,WAAA,GAAA;AAImB,QAAA,IAAA,CAAA,aAAa,GAAG,MAAM,CAAC,eAAe,CAAC;AACvC,QAAA,IAAA,CAAA,kBAAkB,GAAG,MAAM,CAAC,oBAAoB,CAAC;AACjD,QAAA,IAAA,CAAA,aAAa,GAAG,MAAM,CAAC,gBAAgB,CAAC;AA6G1D,IAAA;IA3GC,MAAM,OAAO,CACX,KAA2C,EAAA;QAE3C,IAAI,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC;AAChC,QAAA,IAAI,CAAC,GAAG,CAAC,MAAM,IAAI,KAAK,CAAC,UAAU,IAAI,KAAK,CAAC,UAAU,EAAE;AACvD,YAAA,GAAG,GAAG,MAAM,IAAI,CAAC,qCAAqC,CACpD,KAAK,CAAC,UAAU,EAChB,KAAK,CAAC,UAAU,EAChB,KAAK,CAAC,cAAc,CAC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