@acorex-platform/extension-project-management-aroflo-client 2.0.0-next.50 → 2.0.0-next.54
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/{acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-Cu-5eOic.mjs → acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-MCmGDYDK.mjs} +19 -46
- package/fesm2022/acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-MCmGDYDK.mjs.map +1 -0
- package/fesm2022/acorex-platform-extension-project-management-aroflo-client-contracts.mjs +31 -11
- package/fesm2022/acorex-platform-extension-project-management-aroflo-client-contracts.mjs.map +1 -1
- package/fesm2022/acorex-platform-extension-project-management-aroflo-client.mjs +9 -29
- package/fesm2022/acorex-platform-extension-project-management-aroflo-client.mjs.map +1 -1
- package/i18n/en-AU/extensions-aroflo.json +8 -19
- package/i18n/en-US/extensions-aroflo.json +8 -19
- package/i18n/fa-IR/extensions-aroflo.json +8 -19
- package/package.json +2 -2
- package/types/acorex-platform-extension-project-management-aroflo-client-contracts.d.ts +74 -32
- package/fesm2022/acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-Cu-5eOic.mjs.map +0 -1
|
@@ -69,11 +69,7 @@ class ConnectAroFloCommand {
|
|
|
69
69
|
title: title ?? 'Connect AroFlo',
|
|
70
70
|
context: {
|
|
71
71
|
displayName: existing?.displayName ?? 'AroFlo',
|
|
72
|
-
|
|
73
|
-
pEncoded: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',
|
|
74
|
-
orgEncoded: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',
|
|
75
|
-
secretKey: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',
|
|
76
|
-
hostIp: existingConfig.hostIp ?? '',
|
|
72
|
+
apiToken: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',
|
|
77
73
|
},
|
|
78
74
|
existing,
|
|
79
75
|
existingConfig,
|
|
@@ -83,11 +79,7 @@ class ConnectAroFloCommand {
|
|
|
83
79
|
}
|
|
84
80
|
// 1. Validate with a lightweight users page before anything is stored.
|
|
85
81
|
const validation = await this.aroFloHttp.validate({
|
|
86
|
-
|
|
87
|
-
pEncoded: form.pEncoded,
|
|
88
|
-
orgEncoded: form.orgEncoded,
|
|
89
|
-
secretKey: form.secretKey,
|
|
90
|
-
hostIp: form.hostIp,
|
|
82
|
+
apiToken: form.apiToken,
|
|
91
83
|
});
|
|
92
84
|
if (!validation.valid) {
|
|
93
85
|
return {
|
|
@@ -97,11 +89,7 @@ class ConnectAroFloCommand {
|
|
|
97
89
|
}
|
|
98
90
|
// 2. Create / update the connection as Connected.
|
|
99
91
|
const config = {
|
|
100
|
-
|
|
101
|
-
pEncoded: form.pEncoded,
|
|
102
|
-
orgEncoded: form.orgEncoded,
|
|
103
|
-
secretKey: form.secretKey,
|
|
104
|
-
...(form.hostIp ? { hostIp: form.hostIp } : {}),
|
|
92
|
+
apiToken: form.apiToken,
|
|
105
93
|
jobsSync: existingConfig.jobsSync,
|
|
106
94
|
};
|
|
107
95
|
const connection = await this.connectionManager.upsertConnection({
|
|
@@ -156,14 +144,6 @@ class ConnectAroFloCommand {
|
|
|
156
144
|
//#endregion
|
|
157
145
|
//#region ----- Connect dialog -----
|
|
158
146
|
async openConnectDialog(input) {
|
|
159
|
-
const secretField = (field, path, placeholderKey) => {
|
|
160
|
-
field.path(path);
|
|
161
|
-
field.passwordBox({
|
|
162
|
-
placeholder: `${I18N}.connect.placeholders.${placeholderKey}`,
|
|
163
|
-
revealToggle: true,
|
|
164
|
-
validations: [{ rule: 'required' }],
|
|
165
|
-
});
|
|
166
|
-
};
|
|
167
147
|
const result = await this.layoutBuilder
|
|
168
148
|
.create()
|
|
169
149
|
.dialog((dialog) => {
|
|
@@ -183,13 +163,13 @@ class ConnectAroFloCommand {
|
|
|
183
163
|
field.path('displayName');
|
|
184
164
|
field.textBox({ placeholder: `${I18N}.connect.placeholders.display-name` });
|
|
185
165
|
})
|
|
186
|
-
.formField(`${I18N}.connect.fields.
|
|
187
|
-
.
|
|
188
|
-
.
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
166
|
+
.formField(`${I18N}.connect.fields.api-token`, (field) => {
|
|
167
|
+
field.path('apiToken');
|
|
168
|
+
field.passwordBox({
|
|
169
|
+
placeholder: `${I18N}.connect.placeholders.api-token`,
|
|
170
|
+
revealToggle: true,
|
|
171
|
+
validations: [{ rule: 'required' }],
|
|
172
|
+
});
|
|
193
173
|
});
|
|
194
174
|
})
|
|
195
175
|
.setActions((actions) => {
|
|
@@ -200,23 +180,16 @@ class ConnectAroFloCommand {
|
|
|
200
180
|
return null;
|
|
201
181
|
}
|
|
202
182
|
const ctx = ref.context();
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
}
|
|
211
|
-
return resolved;
|
|
212
|
-
};
|
|
183
|
+
let apiToken = trim(ctx.apiToken);
|
|
184
|
+
if (isMaskedIntegrationCredential(apiToken) && input.existing) {
|
|
185
|
+
apiToken = trim(input.existingConfig.apiToken ?? '');
|
|
186
|
+
}
|
|
187
|
+
if (!apiToken) {
|
|
188
|
+
throw new Error(`${I18N}.connect.errors.api-token-required`);
|
|
189
|
+
}
|
|
213
190
|
return {
|
|
214
191
|
displayName: trim(ctx.displayName) || input.existing?.displayName || 'AroFlo',
|
|
215
|
-
|
|
216
|
-
pEncoded: resolveSecret(ctx.pEncoded, input.existingConfig.pEncoded, 'p-encoded-required'),
|
|
217
|
-
orgEncoded: resolveSecret(ctx.orgEncoded, input.existingConfig.orgEncoded, 'org-encoded-required'),
|
|
218
|
-
secretKey: resolveSecret(ctx.secretKey, input.existingConfig.secretKey, 'secret-key-required'),
|
|
219
|
-
hostIp: trim(ctx.hostIp),
|
|
192
|
+
apiToken,
|
|
220
193
|
};
|
|
221
194
|
});
|
|
222
195
|
})
|
|
@@ -232,4 +205,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
232
205
|
}] });
|
|
233
206
|
|
|
234
207
|
export { ConnectAroFloCommand };
|
|
235
|
-
//# sourceMappingURL=acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-
|
|
208
|
+
//# sourceMappingURL=acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-MCmGDYDK.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-MCmGDYDK.mjs","sources":["../../../../libs/extensions/project-management/aroflo/client/src/lib/api/aroflo-http.client.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/connect/connect-aroflo.command.ts"],"sourcesContent":["//#region ---- Imports ----\n\nimport { commandMessageTextForError } from '@acorex-platform/framework-client/common';\nimport { AXPCommandService } from '@acorex-platform/framework-client/runtime';\nimport {\n AXEAroFloCommandKeys,\n type AXEAroFloConnectionLifecycleRequest,\n type AXEAroFloConnectionLifecycleResponse,\n type AXEAroFloValidateRequest,\n type AXEAroFloValidateResponse,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { inject, Injectable } from '@angular/core';\n\n//#endregion\n\n//#region ---- Client ----\n\n@Injectable({ providedIn: 'root' })\nexport class AXEAroFloHttpClient {\n //#region ----- Services & Dependencies -----\n\n private readonly commandService = inject(AXPCommandService);\n\n //#endregion\n\n //#region ----- Commands -----\n\n validate(body: AXEAroFloValidateRequest = {}): Promise<AXEAroFloValidateResponse> {\n return this.runCommand(AXEAroFloCommandKeys.ConnectionValidate, body);\n }\n\n lifecycle(body: AXEAroFloConnectionLifecycleRequest): Promise<AXEAroFloConnectionLifecycleResponse> {\n return this.runCommand(AXEAroFloCommandKeys.ConnectionLifecycle, body);\n }\n\n //#endregion\n\n //#region ----- Helpers -----\n\n private async runCommand<TInput, TResult>(key: string, input: TInput): Promise<TResult> {\n const result = await this.commandService.execute<TInput, TResult>(key, input);\n if (!result?.success) {\n throw new Error(commandMessageTextForError(result?.message?.text) || `AroFlo command failed: ${key}`);\n }\n return result.data as TResult;\n }\n\n //#endregion\n}\n\n//#endregion\n","//#region ---- Connect AroFlo (APIv2 Bearer token) ----\n\n//#region ----- Imports -----\n\nimport { AXPCommand, type AXPCommandExecuteResultPromise } from '@acorex-platform/framework-shared/runtime';\nimport {\n AXP_INTEGRATION_AUTH_METHOD_TYPE,\n AXP_INTEGRATION_CONNECTION_STATUS,\n type AXPIntegrationConnectionScope,\n createRandomUuid,\n} from '@acorex-platform/framework-shared/core';\nimport {\n AXMIntegrationConnectionManager,\n AXP_INTEGRATION_CREDENTIAL_MASK,\n isMaskedIntegrationCredential,\n toSafeIntegrationConnectionDto,\n type ConnectCommandResult,\n} from '@acorex-platform/module-integration-management-client';\nimport {\n AXPLayoutBuilderService,\n resolveLayoutBuilderDialogResult,\n type AXPDialogRef,\n type IActionBuilder,\n type IDialogBuilder,\n type IFlexContainerBuilder,\n type IFormFieldBuilder,\n} from '@acorex-platform/framework-client/layout/builder';\nimport { AXTranslationService } from '@acorex/core/translation';\nimport { Injectable, inject } from '@angular/core';\nimport { defaultTo, trim } from 'lodash-es';\nimport {\n AXE_AROFLO_API_BASE_URL,\n AXE_AROFLO_PROVIDER_ID,\n type AXEAroFloConnectionConfig,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport type { AXMIntegrationManagementIntegrationConnectionEntityModel } from '@acorex-platform/module-integration-management-client/contracts';\nimport { AXEAroFloHttpClient } from '../../api/aroflo-http.client';\n\n//#endregion\n\n//#region ----- Types -----\n\nconst I18N = '@extensions-aroflo:integration';\n\nexport interface ConnectAroFloCommandInput {\n providerId?: string;\n connectionScope?: AXPIntegrationConnectionScope;\n /** When set, reconfigure / reconnect this existing connection. */\n connectionId?: string;\n /** Optional explicit key; new connections get a generated key when omitted. */\n connectionKey?: string;\n}\n\ninterface AXEAroFloConnectForm {\n displayName: string;\n apiToken: string;\n}\n\n//#endregion\n\n@Injectable({ providedIn: 'root' })\nexport class ConnectAroFloCommand implements AXPCommand<ConnectAroFloCommandInput, ConnectCommandResult> {\n //#region ----- Services & Dependencies -----\n\n private readonly connectionManager = inject(AXMIntegrationConnectionManager);\n private readonly layoutBuilder = inject(AXPLayoutBuilderService);\n private readonly translationService = inject(AXTranslationService);\n private readonly aroFloHttp = inject(AXEAroFloHttpClient);\n\n //#endregion\n\n //#region ----- Execute -----\n\n async execute(input: ConnectAroFloCommandInput = {}): AXPCommandExecuteResultPromise<ConnectCommandResult> {\n try {\n const providerId = input.providerId ?? AXE_AROFLO_PROVIDER_ID;\n const connectionScope = input.connectionScope ?? 'tenant';\n const existing = await this.resolveExistingConnection(providerId, connectionScope, input);\n const isReconfigure = !!existing;\n const existingConfig = (existing?.config ?? {}) as AXEAroFloConnectionConfig;\n const connectionKey = existing?.connectionKey ?? (trim(input.connectionKey) || createRandomUuid());\n\n const title = await this.translationService.translateAsync(\n isReconfigure ? `${I18N}.connect.dialog.reconfigure-title` : `${I18N}.connect.dialog.title`,\n );\n\n const form = await this.openConnectDialog({\n title: title ?? 'Connect AroFlo',\n context: {\n displayName: existing?.displayName ?? 'AroFlo',\n apiToken: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',\n },\n existing,\n existingConfig,\n });\n\n if (!form) {\n return { success: true, kind: 'object', data: { outcome: 'cancelled' } };\n }\n\n // 1. Validate with a lightweight users page before anything is stored.\n const validation = await this.aroFloHttp.validate({\n apiToken: form.apiToken,\n });\n if (!validation.valid) {\n return {\n success: false,\n message: { text: validation.message ?? 'AroFlo credential validation failed.' },\n };\n }\n\n // 2. Create / update the connection as Connected.\n const config: AXEAroFloConnectionConfig = {\n apiToken: form.apiToken,\n jobsSync: existingConfig.jobsSync,\n };\n const connection = await this.connectionManager.upsertConnection({\n providerId,\n authMethodType: AXP_INTEGRATION_AUTH_METHOD_TYPE.Pat,\n connectionScope,\n connectionKey,\n displayName: defaultTo(trim(form.displayName), 'AroFlo'),\n instanceUrl: AXE_AROFLO_API_BASE_URL,\n externalAccountName: AXP_INTEGRATION_CREDENTIAL_MASK,\n config: config as Record<string, unknown>,\n status: AXP_INTEGRATION_CONNECTION_STATUS.Connected,\n lastValidatedAt: new Date().toISOString(),\n lastErrorCode: null,\n lastErrorMessage: null,\n isRevoked: false,\n isDisabled: false,\n });\n\n // 3. Create / activate the pull schedule for this connection.\n await this.aroFloHttp.lifecycle({ connectionId: connection.id, action: 'connected' });\n\n const refreshed = await this.connectionManager.getByIdForCurrentUser(connection.id);\n return {\n success: true,\n kind: 'object',\n data: {\n outcome: 'connected',\n connection: toSafeIntegrationConnectionDto(refreshed ?? connection),\n },\n };\n } catch (error: unknown) {\n const message = error instanceof Error ? error.message : 'Failed to connect AroFlo.';\n return { success: false, message: { text: message } };\n }\n }\n\n //#endregion\n\n //#region ----- Connection lookup -----\n\n private async resolveExistingConnection(\n providerId: string,\n connectionScope: AXPIntegrationConnectionScope,\n input: ConnectAroFloCommandInput,\n ): Promise<AXMIntegrationManagementIntegrationConnectionEntityModel | null> {\n if (input.connectionId) {\n const byId = await this.connectionManager.getByIdForCurrentUser(input.connectionId);\n if (!byId) {\n throw new Error('Connection not found or access denied.');\n }\n return byId;\n }\n\n const connectionKey = trim(input.connectionKey);\n if (!connectionKey) {\n return null;\n }\n\n return this.connectionManager.findByUniqueKey({ providerId, connectionScope, connectionKey });\n }\n\n //#endregion\n\n //#region ----- Connect dialog -----\n\n private async openConnectDialog(input: {\n title: string;\n context: AXEAroFloConnectForm;\n existing: AXMIntegrationManagementIntegrationConnectionEntityModel | null;\n existingConfig: AXEAroFloConnectionConfig;\n }): Promise<AXEAroFloConnectForm | null> {\n const result: unknown = await this.layoutBuilder\n .create()\n .dialog<AXEAroFloConnectForm | null>((dialog: IDialogBuilder<AXEAroFloConnectForm | null>) => {\n dialog\n .setTitle(input.title)\n .setSize('md')\n .setCloseButton(true)\n .setContext({ ...input.context })\n .content((flex: IFlexContainerBuilder) => {\n flex\n .setDirection('column')\n .setGap('12px')\n .customWidget('text-block-layout', {\n content: `${I18N}.connect.instructions`,\n })\n .formField(`${I18N}.connect.fields.display-name`, (field: IFormFieldBuilder) => {\n field.path('displayName');\n field.textBox({ placeholder: `${I18N}.connect.placeholders.display-name` });\n })\n .formField(`${I18N}.connect.fields.api-token`, (field: IFormFieldBuilder) => {\n field.path('apiToken');\n field.passwordBox({\n placeholder: `${I18N}.connect.placeholders.api-token`,\n revealToggle: true,\n validations: [{ rule: 'required' }],\n });\n });\n })\n .setActions((actions: IActionBuilder) => {\n actions.cancel('@general:actions.cancel.title').submit(`${I18N}.connect.actions.save`);\n })\n .onAction(async (ref: AXPDialogRef) => {\n if (ref.action() === 'cancel') {\n return null;\n }\n\n const ctx = ref.context() as AXEAroFloConnectForm;\n let apiToken = trim(ctx.apiToken);\n if (isMaskedIntegrationCredential(apiToken) && input.existing) {\n apiToken = trim(input.existingConfig.apiToken ?? '');\n }\n if (!apiToken) {\n throw new Error(`${I18N}.connect.errors.api-token-required`);\n }\n\n return {\n displayName: trim(ctx.displayName) || input.existing?.displayName || 'AroFlo',\n apiToken,\n };\n });\n })\n .show();\n\n return resolveLayoutBuilderDialogResult<AXEAroFloConnectForm>(result);\n }\n\n //#endregion\n}\n\n//#endregion\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;AAaA;AAEA;MAGa,mBAAmB,CAAA;AADhC,IAAA,WAAA,GAAA;;AAImB,QAAA,IAAA,CAAA,cAAc,GAAG,MAAM,CAAC,iBAAiB,CAAC;AA2B5D,IAAA;;;IArBC,QAAQ,CAAC,OAAiC,EAAE,EAAA;QAC1C,OAAO,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC,kBAAkB,EAAE,IAAI,CAAC;IACvE;AAEA,IAAA,SAAS,CAAC,IAAyC,EAAA;QACjD,OAAO,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC,mBAAmB,EA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,CAAC,QAAQ,CAAC,IAAI,KAAK,CAAC,QAAQ,EAAE;oBAC7D,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,QAAQ,IAAI,EAAE,CAAC;gBACtD;gBACA,IAAI,CAAC,QAAQ,EAAE;AACb,oBAAA,MAAM,IAAI,KAAK,CAAC,GAAG,IAAI,CAAA,kCAAA,CAAoC,CAAC;gBAC9D;gBAEA,OAAO;AACL,oBAAA,WAAW,EAAE,IAAI,CAAC,GAAG,CAAC,WAAW,CAAC,IAAI,KAAK,CAAC,QAAQ,EAAE,WAAW,IAAI,QAAQ;oBAC7E,QAAQ;iBACT;AACH,YAAA,CAAC,CAAC;AACN,QAAA,CAAC;AACA,aAAA,IAAI,EAAE;AAET,QAAA,OAAO,gCAAgC,CAAuB,MAAM,CAAC;IACvE;8GAnLW,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAApB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,oBAAoB,cADP,MAAM,EAAA,CAAA,CAAA;;2FACnB,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBADhC,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE;;;"}
|
|
@@ -60,24 +60,44 @@ const AXPAdministrationPermissionKeys = {
|
|
|
60
60
|
//#endregion
|
|
61
61
|
|
|
62
62
|
//#region ---- AroFlo API constants ----
|
|
63
|
-
/** REST API base URL stored on connection `instanceUrl
|
|
64
|
-
const AXE_AROFLO_API_BASE_URL = 'https://api.aroflo.com/';
|
|
63
|
+
/** REST API base URL stored on connection `instanceUrl` (APIv2). */
|
|
64
|
+
const AXE_AROFLO_API_BASE_URL = 'https://api.aroflo.com/v2';
|
|
65
65
|
/** Integration provider id (matches `AXE_PM_INTEGRATION_PROVIDER_AROFLO`). */
|
|
66
66
|
const AXE_AROFLO_PROVIDER_ID = 'aroflo';
|
|
67
|
-
/** `Accept` header
|
|
68
|
-
const AXE_AROFLO_ACCEPT = '
|
|
69
|
-
/**
|
|
70
|
-
|
|
67
|
+
/** `Accept` header for every AroFlo APIv2 request. */
|
|
68
|
+
const AXE_AROFLO_ACCEPT = 'application/json';
|
|
69
|
+
/**
|
|
70
|
+
* APIv2 list resources (`GET /v2/{resource}`).
|
|
71
|
+
*
|
|
72
|
+
* Naming vs cached IntegrationRemoteRecord:
|
|
73
|
+
* - APIv2 `projects` → resourceType `job`
|
|
74
|
+
* - APIv2 `clients` → resourceType `customer`
|
|
75
|
+
* - APIv2 `GET /clients/{id}/contacts` → resourceType `site`
|
|
76
|
+
* - APIv2 `users` → resourceType `employee`
|
|
77
|
+
*
|
|
78
|
+
* `projects` / `clients` / `users` require query `orgId` (business unit id).
|
|
79
|
+
* List `businessunits` first to discover org ids.
|
|
80
|
+
*/
|
|
81
|
+
const AXE_AROFLO_RESOURCES = {
|
|
71
82
|
Projects: 'projects',
|
|
72
83
|
Clients: 'clients',
|
|
73
|
-
Contacts: 'contacts',
|
|
74
84
|
Users: 'users',
|
|
85
|
+
BusinessUnits: 'businessunits',
|
|
86
|
+
};
|
|
87
|
+
/** @deprecated Use {@link AXE_AROFLO_RESOURCES}. Kept for older import paths. */
|
|
88
|
+
const AXE_AROFLO_ZONES = {
|
|
89
|
+
Projects: AXE_AROFLO_RESOURCES.Projects,
|
|
90
|
+
Clients: AXE_AROFLO_RESOURCES.Clients,
|
|
91
|
+
Contacts: 'contacts',
|
|
92
|
+
Users: AXE_AROFLO_RESOURCES.Users,
|
|
75
93
|
};
|
|
76
|
-
/** Default
|
|
94
|
+
/** Default page size when the API accepts `limit`. */
|
|
95
|
+
const AXE_AROFLO_PAGE_LIMIT = 100;
|
|
96
|
+
/** Default record cap per resource for one pull. */
|
|
77
97
|
const AXE_AROFLO_DEFAULT_MAX_RECORDS = 250;
|
|
78
|
-
/** Upper bound for `maxRecords` per
|
|
98
|
+
/** Upper bound for `maxRecords` per resource. */
|
|
79
99
|
const AXE_AROFLO_MAX_RECORDS = 5000;
|
|
80
|
-
/** Safety cap on page requests per
|
|
100
|
+
/** Safety cap on page requests per resource (guards against endless paging). */
|
|
81
101
|
const AXE_AROFLO_MAX_PAGES = 50;
|
|
82
102
|
//#endregion
|
|
83
103
|
|
|
@@ -85,5 +105,5 @@ const AXE_AROFLO_MAX_PAGES = 50;
|
|
|
85
105
|
* Generated bundle index. Do not edit.
|
|
86
106
|
*/
|
|
87
107
|
|
|
88
|
-
export { AXEAroFloCommandKeys, AXE_AROFLO_ACCEPT, AXE_AROFLO_API_BASE_URL, AXE_AROFLO_DEFAULT_MAX_RECORDS, AXE_AROFLO_MAX_PAGES, AXE_AROFLO_MAX_RECORDS, AXE_AROFLO_PROVIDER_ID, AXE_AROFLO_ZONES, AXPAdministrationPermissionKeys, AroFloExtensionManifest, RootConfig };
|
|
108
|
+
export { AXEAroFloCommandKeys, AXE_AROFLO_ACCEPT, AXE_AROFLO_API_BASE_URL, AXE_AROFLO_DEFAULT_MAX_RECORDS, AXE_AROFLO_MAX_PAGES, AXE_AROFLO_MAX_RECORDS, AXE_AROFLO_PAGE_LIMIT, AXE_AROFLO_PROVIDER_ID, AXE_AROFLO_RESOURCES, AXE_AROFLO_ZONES, AXPAdministrationPermissionKeys, AroFloExtensionManifest, RootConfig };
|
|
89
109
|
//# sourceMappingURL=acorex-platform-extension-project-management-aroflo-client-contracts.mjs.map
|
package/fesm2022/acorex-platform-extension-project-management-aroflo-client-contracts.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-platform-extension-project-management-aroflo-client-contracts.mjs","sources":["../../../../libs/extensions/project-management/aroflo/contracts/src/root-config.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/manifest.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/commands.keys.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/permission.keys.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/connection.types.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/project-sync.api.types.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/aroflo.constants.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/acorex-platform-extension-project-management-aroflo-client-contracts.ts"],"sourcesContent":["//#region ---- Module Config ----\n\nconst config = {\n i18n: 'extensions-aroflo',\n};\n\nconst MODULE_NAME = 'AroFloExtension';\n\nexport const RootConfig = {\n config,\n module: {\n name: MODULE_NAME,\n title: `@${config.i18n}:integration.display-name`,\n icon: 'fa-light fa-briefcase',\n },\n};\n\n//#endregion\n","//#region ---- Manifest ----\n\nimport { AXPModuleManifest } from '@acorex-platform/framework-shared/core';\nimport { RootConfig } from './root-config';\n\nexport const AroFloExtensionManifest: AXPModuleManifest = {\n name: RootConfig.module.name,\n version: '1.0.0',\n title: RootConfig.module.title,\n icon: RootConfig.module.icon,\n i18n: RootConfig.config.i18n,\n type: 'integration',\n domain: 'project-management',\n dependencies: [],\n};\n\n//#endregion\n","//#region ---- Command Keys ----\n\nexport const AXEAroFloCommandKeys = {\n ConnectionConnect: 'aroflo-extension.Connection:Connect',\n ConnectionValidate: 'aroflo-extension.Connection:Validate',\n ConnectionLifecycle: 'aroflo-extension.Connection:Lifecycle',\n ProjectImportFromAroFlo: 'aroflo-extension.Project:ImportFromAroFlo',\n CustomerImportFromAroFlo: 'aroflo-extension.Customer:ImportFromAroFlo',\n EmployeeSyncFromAroFlo: 'aroflo-extension.Employee:SyncFromAroFlo',\n EmployeeLinkFromAroFlo: 'aroflo-extension.Employee:LinkFromAroFlo',\n JobsPull: 'aroflo-extension.Jobs:Pull',\n JobsRefresh: 'aroflo-extension.Jobs:Refresh',\n} as const;\n\n//#endregion\n","//#region ---- Permission Keys ----\n\n/**\n * Administration capabilities used by this extension.\n * Root groups live in `AXPCommonPermissionGroupKeys` (common contracts).\n */\nexport const AXPAdministrationPermissionKeys = {\n ViewIntegrations: 'Administration:Permission:ViewIntegrations',\n MaintainConnections: 'Administration:Permission:MaintainConnections',\n ManageIntegrationActions: 'Administration:Permission:ManageIntegrationActions',\n} as const;\n\n//#endregion\n","//#region ---- AroFlo tenant connection config ----\n\n/**\n * Stored on IntegrationManagement connection `config` for tenant-scoped AroFlo.\n * AroFlo authenticates every request with HMAC-SHA512 (no OAuth).\n */\nexport interface AXEAroFloConnectionConfig {\n /** `uEncoded` credential from AroFlo (sent URI-encoded in `Authorization`). */\n uEncoded?: string;\n /** `pEncoded` credential from AroFlo. */\n pEncoded?: string;\n /** `orgEncoded` credential from AroFlo. */\n orgEncoded?: string;\n /** Secret key used to sign requests with HMAC-SHA512. */\n secretKey?: string;\n /** Optional host IP included in the signature payload. */\n hostIp?: string;\n /** Background pull sync state (server-managed). */\n jobsSync?: AXEAroFloJobsSyncState;\n}\n\n/** AroFlo pull sync state stored on the tenant connection `config.jobsSync`. */\nexport interface AXEAroFloJobsSyncState {\n /** ISO timestamp — last successful pull. */\n lastSyncAt?: string;\n /** ISO timestamp — last full snapshot reconcile (deactivation pass). */\n lastFullReconcileAt?: string;\n}\n\n//#endregion\n","import type { AXEAroFloProjectSyncStrategy } from './sync.types';\n\n//#region ---- Remote AroFlo DTOs (lowercase keys; readers also accept other casings) ----\n\n/** AroFlo `zone=projects` record → `resourceType=job`. */\nexport interface AXEAroFloRemoteProject {\n projectid?: string | number | null;\n projectname?: string | null;\n projectnumber?: string | null;\n location?: { locationid?: string | number | null; locationname?: string | null } | null;\n startdate?: string | null;\n enddate?: string | null;\n projecttype?: { projecttypeid?: string | number | null; projecttypename?: string | null } | null;\n client?: { orgid?: string | number | null; orgname?: string | null } | null;\n status?: string | null;\n description?: string | null;\n stages?: unknown;\n contactuser?: { userid?: string | number | null; username?: string | null } | null;\n custom?: unknown;\n [key: string]: unknown;\n}\n\n/** AroFlo `zone=clients` record → `resourceType=customer`. */\nexport interface AXEAroFloRemoteClient {\n clientid?: string | number | null;\n clientname?: string | null;\n shortname?: string | null;\n contacts?: unknown;\n locations?: unknown;\n phone?: string | null;\n mobile?: string | null;\n fax?: string | null;\n firstname?: string | null;\n surname?: string | null;\n email?: string | null;\n abn?: string | null;\n website?: string | null;\n datecreated?: string | null;\n mailingaddress?: Record<string, unknown> | null;\n address?: Record<string, unknown> | null;\n [key: string]: unknown;\n}\n\n/** AroFlo `zone=contacts` record → `resourceType=site`. */\nexport interface AXEAroFloRemoteContact {\n userid?: string | number | null;\n username?: string | null;\n givennames?: string | null;\n surname?: string | null;\n phone?: string | null;\n mobile?: string | null;\n contacttype?: string | null;\n email?: string | null;\n email2?: string | null;\n notes?: string | null;\n archived?: boolean | string | number | null;\n [key: string]: unknown;\n}\n\n/** AroFlo `zone=users` record → `resourceType=employee`. */\nexport interface AXEAroFloRemoteUser {\n userid?: string | number | null;\n username?: string | null;\n givennames?: string | null;\n surname?: string | null;\n phone?: string | null;\n mobile?: string | null;\n fax?: string | null;\n email?: string | null;\n email2?: string | null;\n notes?: string | null;\n createddatetimeutc?: string | null;\n lastupdatedutc?: string | null;\n userposition?: { positionid?: string | number | null; positionname?: string | null } | null;\n archived?: boolean | string | number | null;\n [key: string]: unknown;\n}\n\n//#endregion\n\n//#region ---- API request / response ----\n\n/** Credentials sent to `Connection:Validate` before the connection row is stored. */\nexport interface AXEAroFloValidateRequest {\n /** Validate stored credentials of this connection (secrets may be omitted). */\n connectionId?: string;\n uEncoded?: string;\n pEncoded?: string;\n orgEncoded?: string;\n secretKey?: string;\n hostIp?: string;\n}\n\nexport interface AXEAroFloValidateResponse {\n valid: boolean;\n message?: string;\n}\n\nexport interface AXEAroFloPullJobsRequest {\n /** Pulls for this AroFlo connection (required for multi-connection schedules). */\n connectionId?: string;\n /** Maximum records per zone (default 250, max 5000). */\n maxJobs?: number;\n /** Reserved for parity with other providers; v1 always pulls a full snapshot. */\n force?: boolean;\n}\n\nexport interface AXEAroFloPullJobsResponse {\n upserted: number;\n deactivated: number;\n /** v1 always runs a full snapshot per zone (capped by `maxJobs`). */\n syncMode?: 'full';\n /** Per data-type upsert counts (job / customer / site / employee). */\n byResourceType?: {\n job?: { upserted: number; deactivated: number };\n customer?: { upserted: number; deactivated: number };\n site?: { upserted: number; deactivated: number };\n employee?: { upserted: number; deactivated: number };\n };\n}\n\nexport interface AXEAroFloConnectionLifecycleRequest {\n connectionId: string;\n action: 'connected' | 'disconnected' | 'deleted' | 'enabled' | 'disabled';\n}\n\nexport interface AXEAroFloConnectionLifecycleResponse {\n ok: true;\n}\n\nexport interface AXEAroFloImportJobRequest {\n remoteRecordId: string;\n projectTypeId: string;\n syncStrategy: AXEAroFloProjectSyncStrategy;\n}\n\nexport interface AXEAroFloImportJobResponse {\n platformProjectId: string;\n created: boolean;\n}\n\nexport interface AXEAroFloImportCustomerRequest {\n remoteRecordId: string;\n}\n\nexport interface AXEAroFloImportCustomerResponse {\n platformCustomerId: string;\n created: boolean;\n}\n\n/** Username conflict: remote login username matches an unlinked platform employee's User. */\nexport interface AXEAroFloEmployeeUsernameConflict {\n remoteRecordId: string;\n remoteId: string;\n connectionId: string;\n username: string;\n remoteName: string;\n platformEmployeeId: string;\n platformEmployeeCode: string;\n platformEmployeeName?: string;\n}\n\nexport interface AXEAroFloSyncEmployeesRequest {\n connectionIds?: string[];\n}\n\nexport interface AXEAroFloSyncEmployeesResponse {\n created: number;\n updated: number;\n skipped: number;\n conflicts: AXEAroFloEmployeeUsernameConflict[];\n errors: Array<{ remoteId: string; message: string }>;\n}\n\nexport interface AXEAroFloLinkEmployeesRequest {\n links: Array<{ remoteRecordId: string; platformEmployeeId: string }>;\n}\n\nexport interface AXEAroFloLinkEmployeesResponse {\n linked: number;\n errors: Array<{ remoteRecordId: string; message: string }>;\n}\n\n//#endregion\n","//#region ---- AroFlo API constants ----\n\n/** REST API base URL stored on connection `instanceUrl`. */\nexport const AXE_AROFLO_API_BASE_URL = 'https://api.aroflo.com/';\n\n/** Integration provider id (matches `AXE_PM_INTEGRATION_PROVIDER_AROFLO`). */\nexport const AXE_AROFLO_PROVIDER_ID = 'aroflo';\n\n/** `Accept` header and signature input for every AroFlo request. */\nexport const AXE_AROFLO_ACCEPT = 'text/json';\n\n/** AroFlo list zones pulled in v1 (`?zone=<name>&page=<n>`). */\nexport const AXE_AROFLO_ZONES = {\n Projects: 'projects',\n Clients: 'clients',\n Contacts: 'contacts',\n Users: 'users',\n} as const;\n\nexport type AXEAroFloZone = (typeof AXE_AROFLO_ZONES)[keyof typeof AXE_AROFLO_ZONES];\n\n/** Default record cap per zone for one pull. */\nexport const AXE_AROFLO_DEFAULT_MAX_RECORDS = 250;\n\n/** Upper bound for `maxRecords` per zone. */\nexport const AXE_AROFLO_MAX_RECORDS = 5000;\n\n/** Safety cap on page requests per zone (guards against endless paging). */\nexport const AXE_AROFLO_MAX_PAGES = 50;\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAAA;AAEA,MAAM,MAAM,GAAG;AACb,IAAA,IAAI,EAAE,mBAAmB;CAC1B;AAED,MAAM,WAAW,GAAG,iBAAiB;AAE9B,MAAM,UAAU,GAAG;IACxB,MAAM;AACN,IAAA,MAAM,EAAE;AACN,QAAA,IAAI,EAAE,WAAW;AACjB,QAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,yBAAA,CAA2B;AACjD,QAAA,IAAI,EAAE,uBAAuB;AAC9B,KAAA;;AAGH;;ACjBA;AAKO,MAAM,uBAAuB,GAAsB;AACxD,IAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,IAAA,OAAO,EAAE,OAAO;AAChB,IAAA,KAAK,EAAE,UAAU,CAAC,MAAM,CAAC,KAAK;AAC9B,IAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,IAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,IAAA,IAAI,EAAE,aAAa;AACnB,IAAA,MAAM,EAAE,oBAAoB;AAC5B,IAAA,YAAY,EAAE,EAAE;;AAGlB;;AChBA;AAEO,MAAM,oBAAoB,GAAG;AAClC,IAAA,iBAAiB,EAAE,qCAAqC;AACxD,IAAA,kBAAkB,EAAE,sCAAsC;AAC1D,IAAA,mBAAmB,EAAE,uCAAuC;AAC5D,IAAA,uBAAuB,EAAE,2CAA2C;AACpE,IAAA,wBAAwB,EAAE,4CAA4C;AACtE,IAAA,sBAAsB,EAAE,0CAA0C;AAClE,IAAA,sBAAsB,EAAE,0CAA0C;AAClE,IAAA,QAAQ,EAAE,4BAA4B;AACtC,IAAA,WAAW,EAAE,+BAA+B;;AAG9C;;ACdA;AAEA;;;AAGG;AACI,MAAM,+BAA+B,GAAG;AAC7C,IAAA,gBAAgB,EAAE,4CAA4C;AAC9D,IAAA,mBAAmB,EAAE,+CAA+C;AACpE,IAAA,wBAAwB,EAAE,oDAAoD;;AAGhF;;ACZA;AA6BA;;AC0JA;;ACvLA;AAEA;AACO,MAAM,uBAAuB,GAAG;AAEvC;AACO,MAAM,sBAAsB,GAAG;AAEtC;AACO,MAAM,iBAAiB,GAAG;AAEjC;AACO,MAAM,gBAAgB,GAAG;AAC9B,IAAA,QAAQ,EAAE,UAAU;AACpB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,QAAQ,EAAE,UAAU;AACpB,IAAA,KAAK,EAAE,OAAO;;AAKhB;AACO,MAAM,8BAA8B,GAAG;AAE9C;AACO,MAAM,sBAAsB,GAAG;AAEtC;AACO,MAAM,oBAAoB,GAAG;AAEpC;;AC9BA;;AAEG;;"}
|
|
1
|
+
{"version":3,"file":"acorex-platform-extension-project-management-aroflo-client-contracts.mjs","sources":["../../../../libs/extensions/project-management/aroflo/contracts/src/root-config.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/manifest.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/commands.keys.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/permission.keys.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/connection.types.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/project-sync.api.types.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/aroflo.constants.ts","../../../../libs/extensions/project-management/aroflo/contracts/src/acorex-platform-extension-project-management-aroflo-client-contracts.ts"],"sourcesContent":["//#region ---- Module Config ----\n\nconst config = {\n i18n: 'extensions-aroflo',\n};\n\nconst MODULE_NAME = 'AroFloExtension';\n\nexport const RootConfig = {\n config,\n module: {\n name: MODULE_NAME,\n title: `@${config.i18n}:integration.display-name`,\n icon: 'fa-light fa-briefcase',\n },\n};\n\n//#endregion\n","//#region ---- Manifest ----\n\nimport { AXPModuleManifest } from '@acorex-platform/framework-shared/core';\nimport { RootConfig } from './root-config';\n\nexport const AroFloExtensionManifest: AXPModuleManifest = {\n name: RootConfig.module.name,\n version: '1.0.0',\n title: RootConfig.module.title,\n icon: RootConfig.module.icon,\n i18n: RootConfig.config.i18n,\n type: 'integration',\n domain: 'project-management',\n dependencies: [],\n};\n\n//#endregion\n","//#region ---- Command Keys ----\n\nexport const AXEAroFloCommandKeys = {\n ConnectionConnect: 'aroflo-extension.Connection:Connect',\n ConnectionValidate: 'aroflo-extension.Connection:Validate',\n ConnectionLifecycle: 'aroflo-extension.Connection:Lifecycle',\n ProjectImportFromAroFlo: 'aroflo-extension.Project:ImportFromAroFlo',\n CustomerImportFromAroFlo: 'aroflo-extension.Customer:ImportFromAroFlo',\n EmployeeSyncFromAroFlo: 'aroflo-extension.Employee:SyncFromAroFlo',\n EmployeeLinkFromAroFlo: 'aroflo-extension.Employee:LinkFromAroFlo',\n JobsPull: 'aroflo-extension.Jobs:Pull',\n JobsRefresh: 'aroflo-extension.Jobs:Refresh',\n} as const;\n\n//#endregion\n","//#region ---- Permission Keys ----\n\n/**\n * Administration capabilities used by this extension.\n * Root groups live in `AXPCommonPermissionGroupKeys` (common contracts).\n */\nexport const AXPAdministrationPermissionKeys = {\n ViewIntegrations: 'Administration:Permission:ViewIntegrations',\n MaintainConnections: 'Administration:Permission:MaintainConnections',\n ManageIntegrationActions: 'Administration:Permission:ManageIntegrationActions',\n} as const;\n\n//#endregion\n","//#region ---- AroFlo tenant connection config ----\n\n/**\n * Stored on IntegrationManagement connection `config` for tenant-scoped AroFlo.\n * APIv2 authenticates with a Bearer personal / partner access token.\n */\nexport interface AXEAroFloConnectionConfig {\n /** Personal or partner access token from Site Administration → AroFlo API → APIv2. */\n apiToken?: string;\n /** Background pull sync state (server-managed). */\n jobsSync?: AXEAroFloJobsSyncState;\n}\n\n/** AroFlo pull sync state stored on the tenant connection `config.jobsSync`. */\nexport interface AXEAroFloJobsSyncState {\n /** ISO timestamp — last successful pull. */\n lastSyncAt?: string;\n /** ISO timestamp — last full snapshot reconcile (deactivation pass). */\n lastFullReconcileAt?: string;\n}\n\n//#endregion\n","import type { AXEAroFloProjectSyncStrategy } from './sync.types';\n\n//#region ---- Remote AroFlo DTOs (lowercase keys; readers also accept other casings) ----\n\n/**\n * AroFlo APIv2 `projects` record (normalized) → `resourceType=job`.\n * Also accepts legacy zone field names when present on cached payloads.\n */\nexport interface AXEAroFloRemoteProject {\n project_id?: string | number | null;\n projectid?: string | number | null;\n name?: string | null;\n projectname?: string | null;\n project_number?: string | number | null;\n job_number?: string | null;\n projectnumber?: string | null;\n /** APIv2 list often returns a location name string; detail may nest an object. */\n location?: string | { locationid?: string | number | null; locationname?: string | null; name?: string | null } | null;\n startdate?: string | null;\n due_date?: string | null;\n enddate?: string | null;\n projecttype?: { projecttypeid?: string | number | null; projecttypename?: string | null } | null;\n task_type?: string | null;\n /**\n * APIv2 list may return a client name string; after pull enrichment / detail fetch\n * this is normalized to `{ orgid, orgname }` (orgid = client_id).\n */\n client?:\n | string\n | {\n orgid?: string | number | null;\n orgname?: string | null;\n client_id?: string | number | null;\n name?: string | null;\n }\n | null;\n client_id?: string | number | null;\n status?: string | null;\n description?: string | null;\n stages?: unknown;\n assigned_to?: string | null;\n contactuser?: { userid?: string | number | null; username?: string | null } | null;\n custom?: unknown;\n [key: string]: unknown;\n}\n\n/** AroFlo APIv2 `clients` record → `resourceType=customer`. */\nexport interface AXEAroFloRemoteClient {\n client_id?: string | number | null;\n clientid?: string | number | null;\n name?: string | null;\n clientname?: string | null;\n shortname?: string | null;\n contacts?: unknown;\n /** APIv2: array of location name strings (or objects). */\n locations?: unknown;\n phone?: string | null;\n mobile?: string | null;\n fax?: string | null;\n firstname?: string | null;\n first_name?: string | null;\n surname?: string | null;\n last_name?: string | null;\n email?: string | null;\n abn?: string | null;\n website?: string | null;\n datecreated?: string | null;\n mailingaddress?: Record<string, unknown> | null;\n address?: Record<string, unknown> | null;\n [key: string]: unknown;\n}\n\n/** Site / location remote (often synthesized from client `locations`) → `resourceType=site`. */\nexport interface AXEAroFloRemoteContact {\n userid?: string | number | null;\n username?: string | null;\n givennames?: string | null;\n first_name?: string | null;\n surname?: string | null;\n last_name?: string | null;\n phone?: string | null;\n mobile?: string | null;\n contacttype?: string | null;\n email?: string | null;\n email2?: string | null;\n notes?: string | null;\n archived?: boolean | string | number | null;\n client_id?: string | number | null;\n [key: string]: unknown;\n}\n\n/** AroFlo APIv2 `users` record → `resourceType=employee`. */\nexport interface AXEAroFloRemoteUser {\n user_id?: string | number | null;\n userid?: string | number | null;\n username?: string | null;\n name?: string | null;\n givennames?: string | null;\n first_name?: string | null;\n surname?: string | null;\n last_name?: string | null;\n phone?: string | null;\n mobile?: string | null;\n fax?: string | null;\n email?: string | null;\n email2?: string | null;\n notes?: string | null;\n createddatetimeutc?: string | null;\n lastupdatedutc?: string | null;\n userposition?: { positionid?: string | number | null; positionname?: string | null } | null;\n archived?: boolean | string | number | null;\n [key: string]: unknown;\n}\n\n//#endregion\n\n//#region ---- API request / response ----\n\n/** Credentials sent to `Connection:Validate` before the connection row is stored. */\nexport interface AXEAroFloValidateRequest {\n /** Validate stored credentials of this connection (secrets may be omitted). */\n connectionId?: string;\n /** APIv2 Bearer personal / partner access token. */\n apiToken?: string;\n}\n\nexport interface AXEAroFloValidateResponse {\n valid: boolean;\n message?: string;\n}\n\nexport interface AXEAroFloPullJobsRequest {\n /** Pulls for this AroFlo connection (required for multi-connection schedules). */\n connectionId?: string;\n /** Maximum records per zone (default 250, max 5000). */\n maxJobs?: number;\n /** Reserved for parity with other providers; v1 always pulls a full snapshot. */\n force?: boolean;\n}\n\nexport interface AXEAroFloPullJobsResponse {\n upserted: number;\n deactivated: number;\n /** v1 always runs a full snapshot per zone (capped by `maxJobs`). */\n syncMode?: 'full';\n /** Per data-type upsert counts (job / customer / site / employee). */\n byResourceType?: {\n job?: { upserted: number; deactivated: number };\n customer?: { upserted: number; deactivated: number };\n site?: { upserted: number; deactivated: number };\n employee?: { upserted: number; deactivated: number };\n };\n}\n\nexport interface AXEAroFloConnectionLifecycleRequest {\n connectionId: string;\n action: 'connected' | 'disconnected' | 'deleted' | 'enabled' | 'disabled';\n}\n\nexport interface AXEAroFloConnectionLifecycleResponse {\n ok: true;\n}\n\nexport interface AXEAroFloImportJobRequest {\n remoteRecordId: string;\n projectTypeId: string;\n syncStrategy: AXEAroFloProjectSyncStrategy;\n}\n\nexport interface AXEAroFloImportJobResponse {\n platformProjectId: string;\n created: boolean;\n}\n\nexport interface AXEAroFloImportCustomerRequest {\n remoteRecordId: string;\n}\n\nexport interface AXEAroFloImportCustomerResponse {\n platformCustomerId: string;\n created: boolean;\n}\n\n/** Username conflict: remote login username matches an unlinked platform employee's User. */\nexport interface AXEAroFloEmployeeUsernameConflict {\n remoteRecordId: string;\n remoteId: string;\n connectionId: string;\n username: string;\n remoteName: string;\n platformEmployeeId: string;\n platformEmployeeCode: string;\n platformEmployeeName?: string;\n}\n\nexport interface AXEAroFloSyncEmployeesRequest {\n connectionIds?: string[];\n}\n\nexport interface AXEAroFloSyncEmployeesResponse {\n created: number;\n updated: number;\n skipped: number;\n conflicts: AXEAroFloEmployeeUsernameConflict[];\n errors: Array<{ remoteId: string; message: string }>;\n}\n\nexport interface AXEAroFloLinkEmployeesRequest {\n links: Array<{ remoteRecordId: string; platformEmployeeId: string }>;\n}\n\nexport interface AXEAroFloLinkEmployeesResponse {\n linked: number;\n errors: Array<{ remoteRecordId: string; message: string }>;\n}\n\n//#endregion\n","//#region ---- AroFlo API constants ----\n\n/** REST API base URL stored on connection `instanceUrl` (APIv2). */\nexport const AXE_AROFLO_API_BASE_URL = 'https://api.aroflo.com/v2';\n\n/** Integration provider id (matches `AXE_PM_INTEGRATION_PROVIDER_AROFLO`). */\nexport const AXE_AROFLO_PROVIDER_ID = 'aroflo';\n\n/** `Accept` header for every AroFlo APIv2 request. */\nexport const AXE_AROFLO_ACCEPT = 'application/json';\n\n/**\n * APIv2 list resources (`GET /v2/{resource}`).\n *\n * Naming vs cached IntegrationRemoteRecord:\n * - APIv2 `projects` → resourceType `job`\n * - APIv2 `clients` → resourceType `customer`\n * - APIv2 `GET /clients/{id}/contacts` → resourceType `site`\n * - APIv2 `users` → resourceType `employee`\n *\n * `projects` / `clients` / `users` require query `orgId` (business unit id).\n * List `businessunits` first to discover org ids.\n */\nexport const AXE_AROFLO_RESOURCES = {\n Projects: 'projects',\n Clients: 'clients',\n Users: 'users',\n BusinessUnits: 'businessunits',\n} as const;\n\nexport type AXEAroFloResource = (typeof AXE_AROFLO_RESOURCES)[keyof typeof AXE_AROFLO_RESOURCES];\n\n/** @deprecated Use {@link AXE_AROFLO_RESOURCES}. Kept for older import paths. */\nexport const AXE_AROFLO_ZONES = {\n Projects: AXE_AROFLO_RESOURCES.Projects,\n Clients: AXE_AROFLO_RESOURCES.Clients,\n Contacts: 'contacts',\n Users: AXE_AROFLO_RESOURCES.Users,\n} as const;\n\n/** @deprecated Use {@link AXEAroFloResource}. */\nexport type AXEAroFloZone = (typeof AXE_AROFLO_ZONES)[keyof typeof AXE_AROFLO_ZONES];\n\n/** Default page size when the API accepts `limit`. */\nexport const AXE_AROFLO_PAGE_LIMIT = 100;\n\n/** Default record cap per resource for one pull. */\nexport const AXE_AROFLO_DEFAULT_MAX_RECORDS = 250;\n\n/** Upper bound for `maxRecords` per resource. */\nexport const AXE_AROFLO_MAX_RECORDS = 5000;\n\n/** Safety cap on page requests per resource (guards against endless paging). */\nexport const AXE_AROFLO_MAX_PAGES = 50;\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;AAAA;AAEA,MAAM,MAAM,GAAG;AACb,IAAA,IAAI,EAAE,mBAAmB;CAC1B;AAED,MAAM,WAAW,GAAG,iBAAiB;AAE9B,MAAM,UAAU,GAAG;IACxB,MAAM;AACN,IAAA,MAAM,EAAE;AACN,QAAA,IAAI,EAAE,WAAW;AACjB,QAAA,KAAK,EAAE,CAAA,CAAA,EAAI,MAAM,CAAC,IAAI,CAAA,yBAAA,CAA2B;AACjD,QAAA,IAAI,EAAE,uBAAuB;AAC9B,KAAA;;AAGH;;ACjBA;AAKO,MAAM,uBAAuB,GAAsB;AACxD,IAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,IAAA,OAAO,EAAE,OAAO;AAChB,IAAA,KAAK,EAAE,UAAU,CAAC,MAAM,CAAC,KAAK;AAC9B,IAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,IAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,IAAA,IAAI,EAAE,aAAa;AACnB,IAAA,MAAM,EAAE,oBAAoB;AAC5B,IAAA,YAAY,EAAE,EAAE;;AAGlB;;AChBA;AAEO,MAAM,oBAAoB,GAAG;AAClC,IAAA,iBAAiB,EAAE,qCAAqC;AACxD,IAAA,kBAAkB,EAAE,sCAAsC;AAC1D,IAAA,mBAAmB,EAAE,uCAAuC;AAC5D,IAAA,uBAAuB,EAAE,2CAA2C;AACpE,IAAA,wBAAwB,EAAE,4CAA4C;AACtE,IAAA,sBAAsB,EAAE,0CAA0C;AAClE,IAAA,sBAAsB,EAAE,0CAA0C;AAClE,IAAA,QAAQ,EAAE,4BAA4B;AACtC,IAAA,WAAW,EAAE,+BAA+B;;AAG9C;;ACdA;AAEA;;;AAGG;AACI,MAAM,+BAA+B,GAAG;AAC7C,IAAA,gBAAgB,EAAE,4CAA4C;AAC9D,IAAA,mBAAmB,EAAE,+CAA+C;AACpE,IAAA,wBAAwB,EAAE,oDAAoD;;AAGhF;;ACZA;AAqBA;;ACmMA;;ACxNA;AAEA;AACO,MAAM,uBAAuB,GAAG;AAEvC;AACO,MAAM,sBAAsB,GAAG;AAEtC;AACO,MAAM,iBAAiB,GAAG;AAEjC;;;;;;;;;;;AAWG;AACI,MAAM,oBAAoB,GAAG;AAClC,IAAA,QAAQ,EAAE,UAAU;AACpB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,aAAa,EAAE,eAAe;;AAKhC;AACO,MAAM,gBAAgB,GAAG;IAC9B,QAAQ,EAAE,oBAAoB,CAAC,QAAQ;IACvC,OAAO,EAAE,oBAAoB,CAAC,OAAO;AACrC,IAAA,QAAQ,EAAE,UAAU;IACpB,KAAK,EAAE,oBAAoB,CAAC,KAAK;;AAMnC;AACO,MAAM,qBAAqB,GAAG;AAErC;AACO,MAAM,8BAA8B,GAAG;AAE9C;AACO,MAAM,sBAAsB,GAAG;AAEtC;AACO,MAAM,oBAAoB,GAAG;AAEpC;;ACvDA;;AAEG;;"}
|
|
@@ -45,34 +45,14 @@ class AXEAroFloIntegrationProvider {
|
|
|
45
45
|
authMethods: [
|
|
46
46
|
{
|
|
47
47
|
type: AXP_INTEGRATION_AUTH_METHOD_TYPE.Pat,
|
|
48
|
-
label: `${I18N}.auth.
|
|
49
|
-
instructions: `${I18N}.auth.
|
|
48
|
+
label: `${I18N}.auth.api-token.label`,
|
|
49
|
+
instructions: `${I18N}.auth.api-token.instructions`,
|
|
50
50
|
supportsValidation: true,
|
|
51
51
|
fields: [
|
|
52
52
|
{
|
|
53
53
|
type: AXPWidgetsList.Editors.PasswordBox,
|
|
54
|
-
path: '
|
|
55
|
-
options: { placeholder: `${I18N}.connect.placeholders.
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
type: AXPWidgetsList.Editors.PasswordBox,
|
|
59
|
-
path: 'pEncoded',
|
|
60
|
-
options: { placeholder: `${I18N}.connect.placeholders.p-encoded` },
|
|
61
|
-
},
|
|
62
|
-
{
|
|
63
|
-
type: AXPWidgetsList.Editors.PasswordBox,
|
|
64
|
-
path: 'orgEncoded',
|
|
65
|
-
options: { placeholder: `${I18N}.connect.placeholders.org-encoded` },
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
type: AXPWidgetsList.Editors.PasswordBox,
|
|
69
|
-
path: 'secretKey',
|
|
70
|
-
options: { placeholder: `${I18N}.connect.placeholders.secret-key` },
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
type: AXPWidgetsList.Editors.TextBox,
|
|
74
|
-
path: 'hostIp',
|
|
75
|
-
options: { placeholder: `${I18N}.connect.placeholders.host-ip` },
|
|
54
|
+
path: 'apiToken',
|
|
55
|
+
options: { placeholder: `${I18N}.connect.placeholders.api-token` },
|
|
76
56
|
},
|
|
77
57
|
],
|
|
78
58
|
},
|
|
@@ -188,12 +168,12 @@ class AXEAroFloIntegrationRuntimeProvider {
|
|
|
188
168
|
}
|
|
189
169
|
async validateConnection(ctx) {
|
|
190
170
|
const config = (ctx.config ?? {});
|
|
191
|
-
const
|
|
192
|
-
if (!
|
|
171
|
+
const hasToken = Boolean(trim(defaultTo(config.apiToken, '')));
|
|
172
|
+
if (!hasToken) {
|
|
193
173
|
return {
|
|
194
174
|
valid: false,
|
|
195
175
|
status: AXP_INTEGRATION_CONNECTION_STATUS.Invalid,
|
|
196
|
-
errorMessage: 'AroFlo
|
|
176
|
+
errorMessage: 'AroFlo APIv2 token is required.',
|
|
197
177
|
};
|
|
198
178
|
}
|
|
199
179
|
return {
|
|
@@ -446,7 +426,7 @@ class AXEAroFloExtensionModule {
|
|
|
446
426
|
provideCommandSetups([
|
|
447
427
|
{
|
|
448
428
|
key: AXEAroFloCommandKeys.ConnectionConnect,
|
|
449
|
-
command: () => import('./acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-
|
|
429
|
+
command: () => import('./acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-MCmGDYDK.mjs').then((c) => c.ConnectAroFloCommand),
|
|
450
430
|
},
|
|
451
431
|
]),
|
|
452
432
|
], imports: [AXMIntegrationManagementModule] }); }
|
|
@@ -466,7 +446,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
466
446
|
provideCommandSetups([
|
|
467
447
|
{
|
|
468
448
|
key: AXEAroFloCommandKeys.ConnectionConnect,
|
|
469
|
-
command: () => import('./acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-
|
|
449
|
+
command: () => import('./acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-MCmGDYDK.mjs').then((c) => c.ConnectAroFloCommand),
|
|
470
450
|
},
|
|
471
451
|
]),
|
|
472
452
|
],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-platform-extension-project-management-aroflo-client.mjs","sources":["../../../../libs/extensions/project-management/aroflo/client/src/lib/brand/aroflo-logo-key.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo.integration.provider.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo-integration-settings-badges.util.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo.integration-runtime.provider.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo.connection-lifecycle.handler.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/brand/aroflo-logo.provider.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/project-management/project-aroflo.entity-modifier.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/customer-management/customer-aroflo.entity-modifier.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/human-capital/employee-aroflo.entity-modifier.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/aroflo-extension.module.ts","../../../../libs/extensions/project-management/aroflo/client/src/acorex-platform-extension-project-management-aroflo-client.ts"],"sourcesContent":["//#region ---- AroFlo logo registry key ----\n\nexport const axpAroFloLogoKey = 'aroflo' as const;\n\n/** Mark artwork; consuming apps copy to `assets/images/brand/integrations/`. */\nexport const AXE_AROFLO_MARK_SRC = 'assets/images/brand/integrations/aroflo-mark.png';\n\n/** Source mark is square (32×32). */\nexport const AXE_AROFLO_MARK_ASPECT = 1;\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_INTEGRATION_AUTH_METHOD_TYPE,\n AXP_INTEGRATION_CAPABILITY,\n AXP_INTEGRATION_CONNECTION_SCOPE,\n AXPWidgetsList,\n} from '@acorex-platform/framework-shared/core';\nimport { AXPIntegrationProvider, AXPIntegrationProviderContext } from '@acorex-platform/framework-client/common';\nimport { Injectable } from '@angular/core';\nimport {\n AXE_AROFLO_PROVIDER_ID,\n AXEAroFloCommandKeys,\n RootConfig,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { axpAroFloLogoKey } from '../brand/aroflo-logo-key';\n\n//#endregion\n\n//#region ---- Provider ----\n\n@Injectable()\nexport class AXEAroFloIntegrationProvider implements AXPIntegrationProvider {\n async provide(context: AXPIntegrationProviderContext): Promise<void> {\n const I18N = `@${RootConfig.config.i18n}:integration`;\n\n context.register({\n domainId: 'project-management',\n id: AXE_AROFLO_PROVIDER_ID,\n module: RootConfig.module.name,\n displayName: `${I18N}.display-name`,\n description: `${I18N}.description`,\n icon: RootConfig.module.icon,\n logoKey: axpAroFloLogoKey,\n capabilities: [AXP_INTEGRATION_CAPABILITY.Sync],\n connectionScopes: [AXP_INTEGRATION_CONNECTION_SCOPE.Tenant],\n allowMultipleConnections: true,\n defaultConnectionKey: 'default',\n connectCommandKey: AXEAroFloCommandKeys.ConnectionConnect,\n authMethods: [\n {\n type: AXP_INTEGRATION_AUTH_METHOD_TYPE.Pat,\n label: `${I18N}.auth.hmac.label`,\n instructions: `${I18N}.auth.hmac.instructions`,\n supportsValidation: true,\n fields: [\n {\n type: AXPWidgetsList.Editors.PasswordBox,\n path: 'uEncoded',\n options: { placeholder: `${I18N}.connect.placeholders.u-encoded` },\n },\n {\n type: AXPWidgetsList.Editors.PasswordBox,\n path: 'pEncoded',\n options: { placeholder: `${I18N}.connect.placeholders.p-encoded` },\n },\n {\n type: AXPWidgetsList.Editors.PasswordBox,\n path: 'orgEncoded',\n options: { placeholder: `${I18N}.connect.placeholders.org-encoded` },\n },\n {\n type: AXPWidgetsList.Editors.PasswordBox,\n path: 'secretKey',\n options: { placeholder: `${I18N}.connect.placeholders.secret-key` },\n },\n {\n type: AXPWidgetsList.Editors.TextBox,\n path: 'hostIp',\n options: { placeholder: `${I18N}.connect.placeholders.host-ip` },\n },\n ],\n },\n ],\n });\n }\n}\n\n//#endregion\n","//#region ---- AroFlo integration settings badges ----\n\nimport { AXFormatService } from '@acorex/core/format';\nimport { AXPSettingsService } from '@acorex-platform/framework-client/common';\nimport { AXPRegionalSetting } from '@acorex-platform/framework-shared/core';\nimport type {\n AXPIntegrationConnectionSettingsContext,\n AXPIntegrationSettingsRowBadge,\n} from '@acorex-platform/framework-shared/core';\nimport type { AXPBackgroundJobSchedule } from '@acorex-platform/framework-shared/background-job';\nimport type { AXEAroFloConnectionConfig } from '@acorex-platform/extension-project-management-aroflo-client/contracts';\n\nconst AROFLO_I18N = '@extensions-aroflo:integration.badges';\n\n/** Must match `AROFLO_PULL_JOBS_COMMAND_KEY` / schedule `command.key`. */\nexport const AROFLO_PULL_JOBS_SCHEDULE_COMMAND_KEY = 'aroflo-extension.jobs.pull';\n\nasync function formatSyncTimestamp(\n iso: string,\n formatService: AXFormatService,\n settingsService: AXPSettingsService,\n): Promise<string | undefined> {\n const parsed = Date.parse(iso);\n if (!Number.isFinite(parsed)) {\n return undefined;\n }\n\n const dateFormat = await settingsService.get(AXPRegionalSetting.ShortDate);\n const timeFormat = await settingsService.get(AXPRegionalSetting.ShortTime);\n const format = `${dateFormat} ${timeFormat}`.trim();\n\n return formatService.format(new Date(parsed), 'datetime', { format });\n}\n\nfunction isFailureNewer(schedule: AXPBackgroundJobSchedule): boolean {\n const failed = schedule.lastFailureAt ? Date.parse(schedule.lastFailureAt) : NaN;\n const succeeded = schedule.lastSuccessAt ? Date.parse(schedule.lastSuccessAt) : NaN;\n if (!Number.isFinite(failed)) {\n return false;\n }\n if (!Number.isFinite(succeeded)) {\n return true;\n }\n return failed >= succeeded;\n}\n\nexport async function resolveAroFloConnectionSettingsBadges(\n ctx: AXPIntegrationConnectionSettingsContext,\n formatService: AXFormatService,\n settingsService: AXPSettingsService,\n schedule?: AXPBackgroundJobSchedule | null,\n): Promise<AXPIntegrationSettingsRowBadge[]> {\n const config = (ctx.connection.config ?? {}) as AXEAroFloConnectionConfig;\n const lastSync = config.jobsSync?.lastSyncAt?.trim() ?? '';\n\n const badges: AXPIntegrationSettingsRowBadge[] = [];\n\n if (!lastSync) {\n badges.push({\n labelKey: `${AROFLO_I18N}.never-synced`,\n color: 'warning',\n });\n } else {\n const datetime = await formatSyncTimestamp(lastSync, formatService, settingsService);\n if (datetime) {\n badges.push({\n labelKey: `${AROFLO_I18N}.last-sync`,\n params: { datetime },\n color: 'success',\n });\n }\n }\n\n if (!schedule) {\n return badges;\n }\n\n if (schedule.status === 'pause') {\n badges.push({\n labelKey: `${AROFLO_I18N}.schedule-paused`,\n color: 'warning',\n });\n } else if (schedule.status === 'disabled') {\n badges.push({\n labelKey: `${AROFLO_I18N}.schedule-disabled`,\n color: 'warning',\n });\n }\n\n if (schedule.nextRunAt) {\n const datetime = await formatSyncTimestamp(schedule.nextRunAt, formatService, settingsService);\n if (datetime) {\n badges.push({\n labelKey: `${AROFLO_I18N}.next-run`,\n params: { datetime },\n color: 'secondary',\n });\n }\n }\n\n if (isFailureNewer(schedule) && schedule.lastFailureAt) {\n const datetime = await formatSyncTimestamp(schedule.lastFailureAt, formatService, settingsService);\n if (datetime) {\n badges.push({\n labelKey: `${AROFLO_I18N}.last-failure`,\n params: { datetime },\n color: 'danger',\n });\n }\n }\n\n return badges;\n}\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_INTEGRATION_CONNECTION_STATUS,\n runtimeQueryPayloadData,\n type AXPIntegrationProviderRuntimeHooks,\n type AXPIntegrationRuntimeContext,\n type AXPIntegrationValidationResult,\n} from '@acorex-platform/framework-shared/core';\nimport {\n AXP_INTEGRATION_RUNTIME_PROVIDER,\n AXPSettingsService,\n type AXPIntegrationRuntimeProvider,\n} from '@acorex-platform/framework-client/common';\nimport { AXPQueryService } from '@acorex-platform/framework-client/runtime';\nimport {\n AXPBackgroundJobQueryKeys,\n type AXPBackgroundJobSchedule,\n} from '@acorex-platform/framework-shared/background-job';\nimport { AXFormatService } from '@acorex/core/format';\nimport { Injectable, inject } from '@angular/core';\nimport { defaultTo, trim } from 'lodash-es';\nimport {\n AXE_AROFLO_PROVIDER_ID,\n type AXEAroFloConnectionConfig,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport {\n AROFLO_PULL_JOBS_SCHEDULE_COMMAND_KEY,\n resolveAroFloConnectionSettingsBadges,\n} from './aroflo-integration-settings-badges.util';\n\n//#endregion\n\n//#region ---- Runtime provider ----\n\n@Injectable()\nexport class AXEAroFloIntegrationRuntimeProvider implements AXPIntegrationRuntimeProvider {\n readonly providerId = AXE_AROFLO_PROVIDER_ID;\n\n private readonly formatService = inject(AXFormatService);\n private readonly settingsService = inject(AXPSettingsService);\n private readonly queryService = inject(AXPQueryService, { optional: true });\n\n async getHooks(): Promise<AXPIntegrationProviderRuntimeHooks> {\n return {\n validateConnection: (ctx) => this.validateConnection(ctx),\n getConnectionSettingsBadges: async (ctx) =>\n resolveAroFloConnectionSettingsBadges(\n ctx,\n this.formatService,\n this.settingsService,\n await this.loadPullSchedule(ctx.connection.id),\n ),\n };\n }\n\n private async validateConnection(ctx: AXPIntegrationRuntimeContext): Promise<AXPIntegrationValidationResult> {\n const config = (ctx.config ?? {}) as AXEAroFloConnectionConfig;\n const hasCredentials = [config.uEncoded, config.pEncoded, config.orgEncoded, config.secretKey].every((value) =>\n Boolean(trim(defaultTo(value, ''))),\n );\n\n if (!hasCredentials) {\n return {\n valid: false,\n status: AXP_INTEGRATION_CONNECTION_STATUS.Invalid,\n errorMessage: 'AroFlo uEncoded, pEncoded, orgEncoded, and secret key are required.',\n };\n }\n\n return {\n valid: true,\n status: AXP_INTEGRATION_CONNECTION_STATUS.Connected,\n externalAccountName: trim(defaultTo(ctx.instanceUrl, 'AroFlo')) || 'AroFlo',\n };\n }\n\n private async loadPullSchedule(connectionId: string): Promise<AXPBackgroundJobSchedule | null> {\n if (!this.queryService || !connectionId.trim()) {\n return null;\n }\n try {\n const result = await this.queryService.fetch<\n { commandKey: string; connectionId?: string },\n AXPBackgroundJobSchedule | null\n >(AXPBackgroundJobQueryKeys.ScheduleGetByScope, {\n commandKey: AROFLO_PULL_JOBS_SCHEDULE_COMMAND_KEY,\n connectionId,\n });\n return runtimeQueryPayloadData(result) ?? null;\n } catch {\n return null;\n }\n }\n}\n\nexport const provideAroFloIntegrationRuntimeProvider = {\n provide: AXP_INTEGRATION_RUNTIME_PROVIDER,\n useClass: AXEAroFloIntegrationRuntimeProvider,\n multi: true,\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_INTEGRATION_CONNECTION_LIFECYCLE,\n type AXPIntegrationConnectionLifecycleHandler,\n} from '@acorex-platform/framework-client/common';\nimport { AXP_INTEGRATION_CONNECTION_STATUS, type AXPSafeIntegrationConnectionDto } from '@acorex-platform/framework-shared/core';\nimport { AXPCommandService } from '@acorex-platform/framework-client/runtime';\nimport { AXEAroFloCommandKeys } from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { Injectable, inject } from '@angular/core';\n\n//#endregion\n\n//#region ---- Handler ----\n\n@Injectable()\nexport class AXEAroFloConnectionLifecycleHandler implements AXPIntegrationConnectionLifecycleHandler {\n readonly providerId = 'aroflo';\n\n private readonly commandService = inject(AXPCommandService);\n\n async onDisconnected(connection: AXPSafeIntegrationConnectionDto): Promise<void> {\n await this.runLifecycle(connection.id, 'disconnected');\n }\n\n async onDeleted(connection: AXPSafeIntegrationConnectionDto): Promise<void> {\n await this.runLifecycle(connection.id, 'deleted');\n }\n\n async onEnabledChanged(connection: AXPSafeIntegrationConnectionDto, enabled: boolean): Promise<void> {\n if (enabled) {\n if (connection.status === AXP_INTEGRATION_CONNECTION_STATUS.Connected) {\n await this.runLifecycle(connection.id, 'enabled');\n }\n return;\n }\n await this.runLifecycle(connection.id, 'disabled');\n }\n\n private async runLifecycle(\n connectionId: string,\n action: 'connected' | 'disconnected' | 'deleted' | 'enabled' | 'disabled',\n ): Promise<void> {\n await this.commandService.execute(AXEAroFloCommandKeys.ConnectionLifecycle, {\n connectionId,\n action,\n });\n }\n}\n\nexport const provideAroFloConnectionLifecycleHandler = {\n provide: AXP_INTEGRATION_CONNECTION_LIFECYCLE,\n useClass: AXEAroFloConnectionLifecycleHandler,\n multi: true,\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_LOGO_PROVIDER,\n type AXPLogoProvider,\n type AXPLogoRequest,\n type AXPLogoView,\n} from '@acorex-platform/framework-client/core';\nimport {\n AXE_AROFLO_MARK_ASPECT,\n AXE_AROFLO_MARK_SRC,\n axpAroFloLogoKey,\n} from './aroflo-logo-key';\n\n//#endregion\n\n//#region ---- Provider ----\n\nconst aroFloLogoProvider: AXPLogoProvider = {\n key: axpAroFloLogoKey,\n resolve: async (request: AXPLogoRequest): Promise<AXPLogoView> => ({\n kind: 'image',\n src: AXE_AROFLO_MARK_SRC,\n height: request.size,\n width: Math.round(request.size * AXE_AROFLO_MARK_ASPECT),\n }),\n};\n\nexport const AXE_AROFLO_LOGO_PROVIDER = {\n provide: AXP_LOGO_PROVIDER,\n useValue: aroFloLogoProvider,\n multi: true,\n} as const;\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXPSystemActionType } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityAction, AXPEntityCommandScope } from '@acorex-platform/framework-shared/entity';\nimport {\n actionExists,\n AXPEntityModifierProvider,\n ensureListActions,\n} from '@acorex-platform/framework-client/layout/entity';\nimport {\n AXEAroFloCommandKeys,\n AXPAdministrationPermissionKeys,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { RootConfig as PmRootConfig } from '@acorex-platform/module-project-management-client/contracts';\n\n//#endregion\n\nconst IMPORT_ORDER = 36;\n\nconst MANAGE_INTEGRATION_ACTIONS_HIDDEN = `{{ !permission.check(\"${AXPAdministrationPermissionKeys.ManageIntegrationActions}\") }}`;\n\nfunction buildImportAction(): AXPEntityAction {\n return {\n name: AXEAroFloCommandKeys.ProjectImportFromAroFlo,\n title: '@extensions-aroflo:actions.import-from-aroflo.title',\n command: { name: AXEAroFloCommandKeys.ProjectImportFromAroFlo },\n priority: 'secondary',\n type: AXPSystemActionType.Import,\n icon: 'fa-light fa-briefcase',\n scope: AXPEntityCommandScope.TypeLevel,\n order: IMPORT_ORDER,\n permissions: [AXPAdministrationPermissionKeys.ManageIntegrationActions],\n hidden: MANAGE_INTEGRATION_ACTIONS_HIDDEN,\n };\n}\n\n/** Adds AroFlo import action to ProjectManagement.Project list views. */\nexport const AXEAroFloProjectEntityModifier: AXPEntityModifierProvider = {\n entityName: PmRootConfig.entities.project.name,\n order: 50,\n modifier: (ctx) => {\n if (ctx.module.get() !== PmRootConfig.module.name) {\n return;\n }\n\n ensureListActions(ctx);\n\n ctx.interfaces.update((interfaces) => {\n const next = (interfaces ?? {}) as Record<string, unknown>;\n const master = (next['master'] ?? {}) as Record<string, unknown>;\n const list = (master['list'] ?? { actions: [], views: [] }) as Record<string, unknown>;\n const listActions = (list['actions'] ?? []) as AXPEntityAction[];\n\n if (!actionExists(listActions, AXEAroFloCommandKeys.ProjectImportFromAroFlo)) {\n listActions.push(buildImportAction());\n }\n list['actions'] = listActions;\n master['list'] = list;\n next['master'] = master;\n return next as typeof interfaces;\n });\n },\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXPSystemActionType } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityAction, AXPEntityCommandScope } from '@acorex-platform/framework-shared/entity';\nimport {\n actionExists,\n AXPEntityModifierProvider,\n ensureListActions,\n} from '@acorex-platform/framework-client/layout/entity';\nimport {\n AXEAroFloCommandKeys,\n AXPAdministrationPermissionKeys,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { RootConfig as CustomerRootConfig } from '@acorex-platform/module-customer-management-client/contracts';\n\n//#endregion\n\n//#region ----- Constants -----\n\nconst IMPORT_ORDER = 36;\n\nconst MANAGE_INTEGRATION_ACTIONS_HIDDEN = `{{ !permission.check(\"${AXPAdministrationPermissionKeys.ManageIntegrationActions}\") }}`;\n\n//#endregion\n\n//#region ----- Actions -----\n\nfunction buildImportAction(): AXPEntityAction {\n return {\n name: AXEAroFloCommandKeys.CustomerImportFromAroFlo,\n title: '@extensions-aroflo:actions.import-from-aroflo.title',\n command: { name: AXEAroFloCommandKeys.CustomerImportFromAroFlo },\n priority: 'secondary',\n type: AXPSystemActionType.Import,\n icon: 'fa-light fa-briefcase',\n scope: AXPEntityCommandScope.TypeLevel,\n order: IMPORT_ORDER,\n permissions: [AXPAdministrationPermissionKeys.ManageIntegrationActions],\n hidden: MANAGE_INTEGRATION_ACTIONS_HIDDEN,\n };\n}\n\n//#endregion\n\n//#region ----- Modifier -----\n\n/** Adds AroFlo import action to CustomerManagement.Customer list views. */\nexport const AXEAroFloCustomerEntityModifier: AXPEntityModifierProvider = {\n entityName: CustomerRootConfig.entities.customer.name,\n order: 50,\n modifier: (ctx) => {\n if (ctx.module.get() !== CustomerRootConfig.module.name) {\n return;\n }\n\n ensureListActions(ctx);\n\n ctx.interfaces.master.list.update((list) => {\n const next = list ?? { actions: [], views: [] };\n const listActions = [...(next.actions ?? [])];\n if (!actionExists(listActions, AXEAroFloCommandKeys.CustomerImportFromAroFlo)) {\n listActions.push(buildImportAction());\n }\n return {\n ...next,\n actions: listActions,\n };\n });\n },\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXPSystemActionType } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityAction, AXPEntityCommandScope } from '@acorex-platform/framework-shared/entity';\nimport {\n actionExists,\n AXPEntityModifierProvider,\n ensureListActions,\n} from '@acorex-platform/framework-client/layout/entity';\nimport {\n AXEAroFloCommandKeys,\n AXPAdministrationPermissionKeys,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { RootConfig as HcmRootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';\n\n//#endregion\n\n//#region ----- Constants -----\n\nconst SYNC_ORDER = 40;\n\nconst MANAGE_INTEGRATION_ACTIONS_HIDDEN = `{{ !permission.check(\"${AXPAdministrationPermissionKeys.ManageIntegrationActions}\") }}`;\n\n//#endregion\n\n//#region ----- Actions -----\n\nfunction buildSyncEmployeesAction(): AXPEntityAction {\n return {\n name: AXEAroFloCommandKeys.EmployeeSyncFromAroFlo,\n title: '@extensions-aroflo:actions.sync-employees-from-aroflo.title',\n command: { name: AXEAroFloCommandKeys.EmployeeSyncFromAroFlo },\n priority: 'secondary',\n type: AXPSystemActionType.Import,\n icon: 'fa-light fa-user-hard-hat',\n scope: AXPEntityCommandScope.TypeLevel,\n order: SYNC_ORDER,\n permissions: [AXPAdministrationPermissionKeys.ManageIntegrationActions],\n hidden: MANAGE_INTEGRATION_ACTIONS_HIDDEN,\n };\n}\n\n//#endregion\n\n//#region ----- Modifier -----\n\n/** Adds AroFlo employee sync action to HumanCapitalManagement.Employee list views. */\nexport const AXEAroFloEmployeeEntityModifier: AXPEntityModifierProvider = {\n entityName: HcmRootConfig.entities.employee.name,\n order: 54,\n modifier: (ctx) => {\n if (ctx.module.get() !== HcmRootConfig.module.name) {\n return;\n }\n\n ensureListActions(ctx);\n\n ctx.interfaces.update((interfaces) => {\n const next = (interfaces ?? {}) as Record<string, unknown>;\n const master = (next['master'] ?? {}) as Record<string, unknown>;\n const list = (master['list'] ?? { actions: [], views: [] }) as Record<string, unknown>;\n const listActions = (list['actions'] ?? []) as AXPEntityAction[];\n\n if (!actionExists(listActions, AXEAroFloCommandKeys.EmployeeSyncFromAroFlo)) {\n listActions.push(buildSyncEmployeesAction());\n }\n list['actions'] = listActions;\n master['list'] = list;\n next['master'] = master;\n return next as typeof interfaces;\n });\n },\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXMIntegrationManagementModule } from '@acorex-platform/module-integration-management-client';\nimport { AXP_INTEGRATION_PROVIDER } from '@acorex-platform/framework-client/common';\nimport { AXP_ENTITY_MODIFIER } from '@acorex-platform/framework-client/layout/entity';\nimport { provideCommandSetups } from '@acorex-platform/framework-client/runtime';\nimport { NgModule } from '@angular/core';\nimport { AXEAroFloCommandKeys } from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { AXEAroFloIntegrationProvider } from './integration/aroflo.integration.provider';\nimport { provideAroFloIntegrationRuntimeProvider } from './integration/aroflo.integration-runtime.provider';\nimport { provideAroFloConnectionLifecycleHandler } from './integration/aroflo.connection-lifecycle.handler';\nimport { AXE_AROFLO_LOGO_PROVIDER } from './brand/aroflo-logo.provider';\nimport { AXEAroFloProjectEntityModifier } from './features/project-management/project-aroflo.entity-modifier';\nimport { AXEAroFloCustomerEntityModifier } from './features/customer-management/customer-aroflo.entity-modifier';\nimport { AXEAroFloEmployeeEntityModifier } from './features/human-capital/employee-aroflo.entity-modifier';\n\n//#endregion\n\n//#region ---- Module ----\n\n@NgModule({\n imports: [AXMIntegrationManagementModule],\n providers: [\n AXE_AROFLO_LOGO_PROVIDER,\n { provide: AXP_INTEGRATION_PROVIDER, useClass: AXEAroFloIntegrationProvider, multi: true },\n { provide: AXP_ENTITY_MODIFIER, useValue: AXEAroFloProjectEntityModifier, multi: true },\n { provide: AXP_ENTITY_MODIFIER, useValue: AXEAroFloCustomerEntityModifier, multi: true },\n { provide: AXP_ENTITY_MODIFIER, useValue: AXEAroFloEmployeeEntityModifier, multi: true },\n provideAroFloIntegrationRuntimeProvider,\n provideAroFloConnectionLifecycleHandler,\n provideCommandSetups([\n {\n key: AXEAroFloCommandKeys.ConnectionConnect,\n command: () => import('./features/connect/connect-aroflo.command').then((c) => c.ConnectAroFloCommand),\n },\n ]),\n ],\n})\nexport class AXEAroFloExtensionModule {}\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["IMPORT_ORDER","MANAGE_INTEGRATION_ACTIONS_HIDDEN","buildImportAction","PmRootConfig","CustomerRootConfig","HcmRootConfig"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAEO,MAAM,gBAAgB,GAAG;AAEhC;AACO,MAAM,mBAAmB,GAAG;AAEnC;AACO,MAAM,sBAAsB,GAAG;AAEtC;;ACVA;AAiBA;AAEA;MAGa,4BAA4B,CAAA;IACvC,MAAM,OAAO,CAAC,OAAsC,EAAA;QAClD,MAAM,IAAI,GAAG,CAAA,CAAA,EAAI,UAAU,CAAC,MAAM,CAAC,IAAI,CAAA,YAAA,CAAc;QAErD,OAAO,CAAC,QAAQ,CAAC;AACf,YAAA,QAAQ,EAAE,oBAAoB;AAC9B,YAAA,EAAE,EAAE,sBAAsB;AAC1B,YAAA,MAAM,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;YAC9B,WAAW,EAAE,CAAA,EAAG,IAAI,CAAA,aAAA,CAAe;YACnC,WAAW,EAAE,CAAA,EAAG,IAAI,CAAA,YAAA,CAAc;AAClC,YAAA,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;AAC5B,YAAA,OAAO,EAAE,gBAAgB;AACzB,YAAA,YAAY,EAAE,CAAC,0BAA0B,CAAC,IAAI,CAAC;AAC/C,YAAA,gBAAgB,EAAE,CAAC,gCAAgC,CAAC,MAAM,CAAC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AAmB,EAAE,QAAQ,EAAE,8BAA8B,EAAE,KAAK,EAAE,IAAI,EAAE;wBACvF,EAAE,OAAO,EAAE,mBAAmB,EAAE,QAAQ,EAAE,+BAA+B,EAAE,KAAK,EAAE,IAAI,EAAE;wBACxF,EAAE,OAAO,EAAE,mBAAmB,EAAE,QAAQ,EAAE,+BAA+B,EAAE,KAAK,EAAE,IAAI,EAAE;wBACxF,uCAAuC;wBACvC,uCAAuC;AACvC,wBAAA,oBAAoB,CAAC;AACnB,4BAAA;gCACE,GAAG,EAAE,oBAAoB,CAAC,iBAAiB;AAC3C,gCAAA,OAAO,EAAE,MAAM,OAAO,kGAA2C,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,oBAAoB,CAAC;AACvG,6BAAA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA;;;ACrCD;;AAEG;;"}
|
|
1
|
+
{"version":3,"file":"acorex-platform-extension-project-management-aroflo-client.mjs","sources":["../../../../libs/extensions/project-management/aroflo/client/src/lib/brand/aroflo-logo-key.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo.integration.provider.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo-integration-settings-badges.util.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo.integration-runtime.provider.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/integration/aroflo.connection-lifecycle.handler.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/brand/aroflo-logo.provider.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/project-management/project-aroflo.entity-modifier.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/customer-management/customer-aroflo.entity-modifier.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/human-capital/employee-aroflo.entity-modifier.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/aroflo-extension.module.ts","../../../../libs/extensions/project-management/aroflo/client/src/acorex-platform-extension-project-management-aroflo-client.ts"],"sourcesContent":["//#region ---- AroFlo logo registry key ----\n\nexport const axpAroFloLogoKey = 'aroflo' as const;\n\n/** Mark artwork; consuming apps copy to `assets/images/brand/integrations/`. */\nexport const AXE_AROFLO_MARK_SRC = 'assets/images/brand/integrations/aroflo-mark.png';\n\n/** Source mark is square (32×32). */\nexport const AXE_AROFLO_MARK_ASPECT = 1;\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_INTEGRATION_AUTH_METHOD_TYPE,\n AXP_INTEGRATION_CAPABILITY,\n AXP_INTEGRATION_CONNECTION_SCOPE,\n AXPWidgetsList,\n} from '@acorex-platform/framework-shared/core';\nimport { AXPIntegrationProvider, AXPIntegrationProviderContext } from '@acorex-platform/framework-client/common';\nimport { Injectable } from '@angular/core';\nimport {\n AXE_AROFLO_PROVIDER_ID,\n AXEAroFloCommandKeys,\n RootConfig,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { axpAroFloLogoKey } from '../brand/aroflo-logo-key';\n\n//#endregion\n\n//#region ---- Provider ----\n\n@Injectable()\nexport class AXEAroFloIntegrationProvider implements AXPIntegrationProvider {\n async provide(context: AXPIntegrationProviderContext): Promise<void> {\n const I18N = `@${RootConfig.config.i18n}:integration`;\n\n context.register({\n domainId: 'project-management',\n id: AXE_AROFLO_PROVIDER_ID,\n module: RootConfig.module.name,\n displayName: `${I18N}.display-name`,\n description: `${I18N}.description`,\n icon: RootConfig.module.icon,\n logoKey: axpAroFloLogoKey,\n capabilities: [AXP_INTEGRATION_CAPABILITY.Sync],\n connectionScopes: [AXP_INTEGRATION_CONNECTION_SCOPE.Tenant],\n allowMultipleConnections: true,\n defaultConnectionKey: 'default',\n connectCommandKey: AXEAroFloCommandKeys.ConnectionConnect,\n authMethods: [\n {\n type: AXP_INTEGRATION_AUTH_METHOD_TYPE.Pat,\n label: `${I18N}.auth.api-token.label`,\n instructions: `${I18N}.auth.api-token.instructions`,\n supportsValidation: true,\n fields: [\n {\n type: AXPWidgetsList.Editors.PasswordBox,\n path: 'apiToken',\n options: { placeholder: `${I18N}.connect.placeholders.api-token` },\n },\n ],\n },\n ],\n });\n }\n}\n\n//#endregion\n","//#region ---- AroFlo integration settings badges ----\n\nimport { AXFormatService } from '@acorex/core/format';\nimport { AXPSettingsService } from '@acorex-platform/framework-client/common';\nimport { AXPRegionalSetting } from '@acorex-platform/framework-shared/core';\nimport type {\n AXPIntegrationConnectionSettingsContext,\n AXPIntegrationSettingsRowBadge,\n} from '@acorex-platform/framework-shared/core';\nimport type { AXPBackgroundJobSchedule } from '@acorex-platform/framework-shared/background-job';\nimport type { AXEAroFloConnectionConfig } from '@acorex-platform/extension-project-management-aroflo-client/contracts';\n\nconst AROFLO_I18N = '@extensions-aroflo:integration.badges';\n\n/** Must match `AROFLO_PULL_JOBS_COMMAND_KEY` / schedule `command.key`. */\nexport const AROFLO_PULL_JOBS_SCHEDULE_COMMAND_KEY = 'aroflo-extension.jobs.pull';\n\nasync function formatSyncTimestamp(\n iso: string,\n formatService: AXFormatService,\n settingsService: AXPSettingsService,\n): Promise<string | undefined> {\n const parsed = Date.parse(iso);\n if (!Number.isFinite(parsed)) {\n return undefined;\n }\n\n const dateFormat = await settingsService.get(AXPRegionalSetting.ShortDate);\n const timeFormat = await settingsService.get(AXPRegionalSetting.ShortTime);\n const format = `${dateFormat} ${timeFormat}`.trim();\n\n return formatService.format(new Date(parsed), 'datetime', { format });\n}\n\nfunction isFailureNewer(schedule: AXPBackgroundJobSchedule): boolean {\n const failed = schedule.lastFailureAt ? Date.parse(schedule.lastFailureAt) : NaN;\n const succeeded = schedule.lastSuccessAt ? Date.parse(schedule.lastSuccessAt) : NaN;\n if (!Number.isFinite(failed)) {\n return false;\n }\n if (!Number.isFinite(succeeded)) {\n return true;\n }\n return failed >= succeeded;\n}\n\nexport async function resolveAroFloConnectionSettingsBadges(\n ctx: AXPIntegrationConnectionSettingsContext,\n formatService: AXFormatService,\n settingsService: AXPSettingsService,\n schedule?: AXPBackgroundJobSchedule | null,\n): Promise<AXPIntegrationSettingsRowBadge[]> {\n const config = (ctx.connection.config ?? {}) as AXEAroFloConnectionConfig;\n const lastSync = config.jobsSync?.lastSyncAt?.trim() ?? '';\n\n const badges: AXPIntegrationSettingsRowBadge[] = [];\n\n if (!lastSync) {\n badges.push({\n labelKey: `${AROFLO_I18N}.never-synced`,\n color: 'warning',\n });\n } else {\n const datetime = await formatSyncTimestamp(lastSync, formatService, settingsService);\n if (datetime) {\n badges.push({\n labelKey: `${AROFLO_I18N}.last-sync`,\n params: { datetime },\n color: 'success',\n });\n }\n }\n\n if (!schedule) {\n return badges;\n }\n\n if (schedule.status === 'pause') {\n badges.push({\n labelKey: `${AROFLO_I18N}.schedule-paused`,\n color: 'warning',\n });\n } else if (schedule.status === 'disabled') {\n badges.push({\n labelKey: `${AROFLO_I18N}.schedule-disabled`,\n color: 'warning',\n });\n }\n\n if (schedule.nextRunAt) {\n const datetime = await formatSyncTimestamp(schedule.nextRunAt, formatService, settingsService);\n if (datetime) {\n badges.push({\n labelKey: `${AROFLO_I18N}.next-run`,\n params: { datetime },\n color: 'secondary',\n });\n }\n }\n\n if (isFailureNewer(schedule) && schedule.lastFailureAt) {\n const datetime = await formatSyncTimestamp(schedule.lastFailureAt, formatService, settingsService);\n if (datetime) {\n badges.push({\n labelKey: `${AROFLO_I18N}.last-failure`,\n params: { datetime },\n color: 'danger',\n });\n }\n }\n\n return badges;\n}\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_INTEGRATION_CONNECTION_STATUS,\n runtimeQueryPayloadData,\n type AXPIntegrationProviderRuntimeHooks,\n type AXPIntegrationRuntimeContext,\n type AXPIntegrationValidationResult,\n} from '@acorex-platform/framework-shared/core';\nimport {\n AXP_INTEGRATION_RUNTIME_PROVIDER,\n AXPSettingsService,\n type AXPIntegrationRuntimeProvider,\n} from '@acorex-platform/framework-client/common';\nimport { AXPQueryService } from '@acorex-platform/framework-client/runtime';\nimport {\n AXPBackgroundJobQueryKeys,\n type AXPBackgroundJobSchedule,\n} from '@acorex-platform/framework-shared/background-job';\nimport { AXFormatService } from '@acorex/core/format';\nimport { Injectable, inject } from '@angular/core';\nimport { defaultTo, trim } from 'lodash-es';\nimport {\n AXE_AROFLO_PROVIDER_ID,\n type AXEAroFloConnectionConfig,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport {\n AROFLO_PULL_JOBS_SCHEDULE_COMMAND_KEY,\n resolveAroFloConnectionSettingsBadges,\n} from './aroflo-integration-settings-badges.util';\n\n//#endregion\n\n//#region ---- Runtime provider ----\n\n@Injectable()\nexport class AXEAroFloIntegrationRuntimeProvider implements AXPIntegrationRuntimeProvider {\n readonly providerId = AXE_AROFLO_PROVIDER_ID;\n\n private readonly formatService = inject(AXFormatService);\n private readonly settingsService = inject(AXPSettingsService);\n private readonly queryService = inject(AXPQueryService, { optional: true });\n\n async getHooks(): Promise<AXPIntegrationProviderRuntimeHooks> {\n return {\n validateConnection: (ctx) => this.validateConnection(ctx),\n getConnectionSettingsBadges: async (ctx) =>\n resolveAroFloConnectionSettingsBadges(\n ctx,\n this.formatService,\n this.settingsService,\n await this.loadPullSchedule(ctx.connection.id),\n ),\n };\n }\n\n private async validateConnection(ctx: AXPIntegrationRuntimeContext): Promise<AXPIntegrationValidationResult> {\n const config = (ctx.config ?? {}) as AXEAroFloConnectionConfig;\n const hasToken = Boolean(trim(defaultTo(config.apiToken, '')));\n\n if (!hasToken) {\n return {\n valid: false,\n status: AXP_INTEGRATION_CONNECTION_STATUS.Invalid,\n errorMessage: 'AroFlo APIv2 token is required.',\n };\n }\n\n return {\n valid: true,\n status: AXP_INTEGRATION_CONNECTION_STATUS.Connected,\n externalAccountName: trim(defaultTo(ctx.instanceUrl, 'AroFlo')) || 'AroFlo',\n };\n }\n\n private async loadPullSchedule(connectionId: string): Promise<AXPBackgroundJobSchedule | null> {\n if (!this.queryService || !connectionId.trim()) {\n return null;\n }\n try {\n const result = await this.queryService.fetch<\n { commandKey: string; connectionId?: string },\n AXPBackgroundJobSchedule | null\n >(AXPBackgroundJobQueryKeys.ScheduleGetByScope, {\n commandKey: AROFLO_PULL_JOBS_SCHEDULE_COMMAND_KEY,\n connectionId,\n });\n return runtimeQueryPayloadData(result) ?? null;\n } catch {\n return null;\n }\n }\n}\n\nexport const provideAroFloIntegrationRuntimeProvider = {\n provide: AXP_INTEGRATION_RUNTIME_PROVIDER,\n useClass: AXEAroFloIntegrationRuntimeProvider,\n multi: true,\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_INTEGRATION_CONNECTION_LIFECYCLE,\n type AXPIntegrationConnectionLifecycleHandler,\n} from '@acorex-platform/framework-client/common';\nimport { AXP_INTEGRATION_CONNECTION_STATUS, type AXPSafeIntegrationConnectionDto } from '@acorex-platform/framework-shared/core';\nimport { AXPCommandService } from '@acorex-platform/framework-client/runtime';\nimport { AXEAroFloCommandKeys } from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { Injectable, inject } from '@angular/core';\n\n//#endregion\n\n//#region ---- Handler ----\n\n@Injectable()\nexport class AXEAroFloConnectionLifecycleHandler implements AXPIntegrationConnectionLifecycleHandler {\n readonly providerId = 'aroflo';\n\n private readonly commandService = inject(AXPCommandService);\n\n async onDisconnected(connection: AXPSafeIntegrationConnectionDto): Promise<void> {\n await this.runLifecycle(connection.id, 'disconnected');\n }\n\n async onDeleted(connection: AXPSafeIntegrationConnectionDto): Promise<void> {\n await this.runLifecycle(connection.id, 'deleted');\n }\n\n async onEnabledChanged(connection: AXPSafeIntegrationConnectionDto, enabled: boolean): Promise<void> {\n if (enabled) {\n if (connection.status === AXP_INTEGRATION_CONNECTION_STATUS.Connected) {\n await this.runLifecycle(connection.id, 'enabled');\n }\n return;\n }\n await this.runLifecycle(connection.id, 'disabled');\n }\n\n private async runLifecycle(\n connectionId: string,\n action: 'connected' | 'disconnected' | 'deleted' | 'enabled' | 'disabled',\n ): Promise<void> {\n await this.commandService.execute(AXEAroFloCommandKeys.ConnectionLifecycle, {\n connectionId,\n action,\n });\n }\n}\n\nexport const provideAroFloConnectionLifecycleHandler = {\n provide: AXP_INTEGRATION_CONNECTION_LIFECYCLE,\n useClass: AXEAroFloConnectionLifecycleHandler,\n multi: true,\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXP_LOGO_PROVIDER,\n type AXPLogoProvider,\n type AXPLogoRequest,\n type AXPLogoView,\n} from '@acorex-platform/framework-client/core';\nimport {\n AXE_AROFLO_MARK_ASPECT,\n AXE_AROFLO_MARK_SRC,\n axpAroFloLogoKey,\n} from './aroflo-logo-key';\n\n//#endregion\n\n//#region ---- Provider ----\n\nconst aroFloLogoProvider: AXPLogoProvider = {\n key: axpAroFloLogoKey,\n resolve: async (request: AXPLogoRequest): Promise<AXPLogoView> => ({\n kind: 'image',\n src: AXE_AROFLO_MARK_SRC,\n height: request.size,\n width: Math.round(request.size * AXE_AROFLO_MARK_ASPECT),\n }),\n};\n\nexport const AXE_AROFLO_LOGO_PROVIDER = {\n provide: AXP_LOGO_PROVIDER,\n useValue: aroFloLogoProvider,\n multi: true,\n} as const;\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXPSystemActionType } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityAction, AXPEntityCommandScope } from '@acorex-platform/framework-shared/entity';\nimport {\n actionExists,\n AXPEntityModifierProvider,\n ensureListActions,\n} from '@acorex-platform/framework-client/layout/entity';\nimport {\n AXEAroFloCommandKeys,\n AXPAdministrationPermissionKeys,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { RootConfig as PmRootConfig } from '@acorex-platform/module-project-management-client/contracts';\n\n//#endregion\n\nconst IMPORT_ORDER = 36;\n\nconst MANAGE_INTEGRATION_ACTIONS_HIDDEN = `{{ !permission.check(\"${AXPAdministrationPermissionKeys.ManageIntegrationActions}\") }}`;\n\nfunction buildImportAction(): AXPEntityAction {\n return {\n name: AXEAroFloCommandKeys.ProjectImportFromAroFlo,\n title: '@extensions-aroflo:actions.import-from-aroflo.title',\n command: { name: AXEAroFloCommandKeys.ProjectImportFromAroFlo },\n priority: 'secondary',\n type: AXPSystemActionType.Import,\n icon: 'fa-light fa-briefcase',\n scope: AXPEntityCommandScope.TypeLevel,\n order: IMPORT_ORDER,\n permissions: [AXPAdministrationPermissionKeys.ManageIntegrationActions],\n hidden: MANAGE_INTEGRATION_ACTIONS_HIDDEN,\n };\n}\n\n/** Adds AroFlo import action to ProjectManagement.Project list views. */\nexport const AXEAroFloProjectEntityModifier: AXPEntityModifierProvider = {\n entityName: PmRootConfig.entities.project.name,\n order: 50,\n modifier: (ctx) => {\n if (ctx.module.get() !== PmRootConfig.module.name) {\n return;\n }\n\n ensureListActions(ctx);\n\n ctx.interfaces.update((interfaces) => {\n const next = (interfaces ?? {}) as Record<string, unknown>;\n const master = (next['master'] ?? {}) as Record<string, unknown>;\n const list = (master['list'] ?? { actions: [], views: [] }) as Record<string, unknown>;\n const listActions = (list['actions'] ?? []) as AXPEntityAction[];\n\n if (!actionExists(listActions, AXEAroFloCommandKeys.ProjectImportFromAroFlo)) {\n listActions.push(buildImportAction());\n }\n list['actions'] = listActions;\n master['list'] = list;\n next['master'] = master;\n return next as typeof interfaces;\n });\n },\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXPSystemActionType } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityAction, AXPEntityCommandScope } from '@acorex-platform/framework-shared/entity';\nimport {\n actionExists,\n AXPEntityModifierProvider,\n ensureListActions,\n} from '@acorex-platform/framework-client/layout/entity';\nimport {\n AXEAroFloCommandKeys,\n AXPAdministrationPermissionKeys,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { RootConfig as CustomerRootConfig } from '@acorex-platform/module-customer-management-client/contracts';\n\n//#endregion\n\n//#region ----- Constants -----\n\nconst IMPORT_ORDER = 36;\n\nconst MANAGE_INTEGRATION_ACTIONS_HIDDEN = `{{ !permission.check(\"${AXPAdministrationPermissionKeys.ManageIntegrationActions}\") }}`;\n\n//#endregion\n\n//#region ----- Actions -----\n\nfunction buildImportAction(): AXPEntityAction {\n return {\n name: AXEAroFloCommandKeys.CustomerImportFromAroFlo,\n title: '@extensions-aroflo:actions.import-from-aroflo.title',\n command: { name: AXEAroFloCommandKeys.CustomerImportFromAroFlo },\n priority: 'secondary',\n type: AXPSystemActionType.Import,\n icon: 'fa-light fa-briefcase',\n scope: AXPEntityCommandScope.TypeLevel,\n order: IMPORT_ORDER,\n permissions: [AXPAdministrationPermissionKeys.ManageIntegrationActions],\n hidden: MANAGE_INTEGRATION_ACTIONS_HIDDEN,\n };\n}\n\n//#endregion\n\n//#region ----- Modifier -----\n\n/** Adds AroFlo import action to CustomerManagement.Customer list views. */\nexport const AXEAroFloCustomerEntityModifier: AXPEntityModifierProvider = {\n entityName: CustomerRootConfig.entities.customer.name,\n order: 50,\n modifier: (ctx) => {\n if (ctx.module.get() !== CustomerRootConfig.module.name) {\n return;\n }\n\n ensureListActions(ctx);\n\n ctx.interfaces.master.list.update((list) => {\n const next = list ?? { actions: [], views: [] };\n const listActions = [...(next.actions ?? [])];\n if (!actionExists(listActions, AXEAroFloCommandKeys.CustomerImportFromAroFlo)) {\n listActions.push(buildImportAction());\n }\n return {\n ...next,\n actions: listActions,\n };\n });\n },\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXPSystemActionType } from '@acorex-platform/framework-shared/core';\nimport { AXPEntityAction, AXPEntityCommandScope } from '@acorex-platform/framework-shared/entity';\nimport {\n actionExists,\n AXPEntityModifierProvider,\n ensureListActions,\n} from '@acorex-platform/framework-client/layout/entity';\nimport {\n AXEAroFloCommandKeys,\n AXPAdministrationPermissionKeys,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { RootConfig as HcmRootConfig } from '@acorex-platform/module-human-capital-management-client/contracts';\n\n//#endregion\n\n//#region ----- Constants -----\n\nconst SYNC_ORDER = 40;\n\nconst MANAGE_INTEGRATION_ACTIONS_HIDDEN = `{{ !permission.check(\"${AXPAdministrationPermissionKeys.ManageIntegrationActions}\") }}`;\n\n//#endregion\n\n//#region ----- Actions -----\n\nfunction buildSyncEmployeesAction(): AXPEntityAction {\n return {\n name: AXEAroFloCommandKeys.EmployeeSyncFromAroFlo,\n title: '@extensions-aroflo:actions.sync-employees-from-aroflo.title',\n command: { name: AXEAroFloCommandKeys.EmployeeSyncFromAroFlo },\n priority: 'secondary',\n type: AXPSystemActionType.Import,\n icon: 'fa-light fa-user-hard-hat',\n scope: AXPEntityCommandScope.TypeLevel,\n order: SYNC_ORDER,\n permissions: [AXPAdministrationPermissionKeys.ManageIntegrationActions],\n hidden: MANAGE_INTEGRATION_ACTIONS_HIDDEN,\n };\n}\n\n//#endregion\n\n//#region ----- Modifier -----\n\n/** Adds AroFlo employee sync action to HumanCapitalManagement.Employee list views. */\nexport const AXEAroFloEmployeeEntityModifier: AXPEntityModifierProvider = {\n entityName: HcmRootConfig.entities.employee.name,\n order: 54,\n modifier: (ctx) => {\n if (ctx.module.get() !== HcmRootConfig.module.name) {\n return;\n }\n\n ensureListActions(ctx);\n\n ctx.interfaces.update((interfaces) => {\n const next = (interfaces ?? {}) as Record<string, unknown>;\n const master = (next['master'] ?? {}) as Record<string, unknown>;\n const list = (master['list'] ?? { actions: [], views: [] }) as Record<string, unknown>;\n const listActions = (list['actions'] ?? []) as AXPEntityAction[];\n\n if (!actionExists(listActions, AXEAroFloCommandKeys.EmployeeSyncFromAroFlo)) {\n listActions.push(buildSyncEmployeesAction());\n }\n list['actions'] = listActions;\n master['list'] = list;\n next['master'] = master;\n return next as typeof interfaces;\n });\n },\n};\n\n//#endregion\n","//#region ---- Imports ----\n\nimport { AXMIntegrationManagementModule } from '@acorex-platform/module-integration-management-client';\nimport { AXP_INTEGRATION_PROVIDER } from '@acorex-platform/framework-client/common';\nimport { AXP_ENTITY_MODIFIER } from '@acorex-platform/framework-client/layout/entity';\nimport { provideCommandSetups } from '@acorex-platform/framework-client/runtime';\nimport { NgModule } from '@angular/core';\nimport { AXEAroFloCommandKeys } from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { AXEAroFloIntegrationProvider } from './integration/aroflo.integration.provider';\nimport { provideAroFloIntegrationRuntimeProvider } from './integration/aroflo.integration-runtime.provider';\nimport { provideAroFloConnectionLifecycleHandler } from './integration/aroflo.connection-lifecycle.handler';\nimport { AXE_AROFLO_LOGO_PROVIDER } from './brand/aroflo-logo.provider';\nimport { AXEAroFloProjectEntityModifier } from './features/project-management/project-aroflo.entity-modifier';\nimport { AXEAroFloCustomerEntityModifier } from './features/customer-management/customer-aroflo.entity-modifier';\nimport { AXEAroFloEmployeeEntityModifier } from './features/human-capital/employee-aroflo.entity-modifier';\n\n//#endregion\n\n//#region ---- Module ----\n\n@NgModule({\n imports: [AXMIntegrationManagementModule],\n providers: [\n AXE_AROFLO_LOGO_PROVIDER,\n { provide: AXP_INTEGRATION_PROVIDER, useClass: AXEAroFloIntegrationProvider, multi: true },\n { provide: AXP_ENTITY_MODIFIER, useValue: AXEAroFloProjectEntityModifier, multi: true },\n { provide: AXP_ENTITY_MODIFIER, useValue: AXEAroFloCustomerEntityModifier, multi: true },\n { provide: AXP_ENTITY_MODIFIER, useValue: AXEAroFloEmployeeEntityModifier, multi: true },\n provideAroFloIntegrationRuntimeProvider,\n provideAroFloConnectionLifecycleHandler,\n provideCommandSetups([\n {\n key: AXEAroFloCommandKeys.ConnectionConnect,\n command: () => import('./features/connect/connect-aroflo.command').then((c) => c.ConnectAroFloCommand),\n },\n ]),\n ],\n})\nexport class AXEAroFloExtensionModule {}\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["IMPORT_ORDER","MANAGE_INTEGRATION_ACTIONS_HIDDEN","buildImportAction","PmRootConfig","CustomerRootConfig","HcmRootConfig"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAEO,MAAM,gBAAgB,GAAG;AAEhC;AACO,MAAM,mBAAmB,GAAG;AAEnC;AACO,MAAM,sBAAsB,GAAG;A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AI,EAAE;wBACxF,uCAAuC;wBACvC,uCAAuC;AACvC,wBAAA,oBAAoB,CAAC;AACnB,4BAAA;gCACE,GAAG,EAAE,oBAAoB,CAAC,iBAAiB;AAC3C,gCAAA,OAAO,EAAE,MAAM,OAAO,kGAA2C,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,oBAAoB,CAAC;AACvG,6BAAA;yBACF,CAAC;AACH,qBAAA;AACF,iBAAA;;;ACrCD;;AAEG;;"}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
},
|
|
6
6
|
"integration": {
|
|
7
7
|
"display-name": "AroFlo",
|
|
8
|
-
"description": "Connect to AroFlo to pull projects, clients, contacts, and users into the platform.",
|
|
8
|
+
"description": "Connect to AroFlo APIv2 to pull projects, clients, contacts, and users into the platform.",
|
|
9
9
|
"badges": {
|
|
10
10
|
"last-sync": "Last Sync: {{datetime}}",
|
|
11
11
|
"never-synced": "Not Synced Yet",
|
|
@@ -15,41 +15,30 @@
|
|
|
15
15
|
"schedule-disabled": "Pull Schedule Disabled"
|
|
16
16
|
},
|
|
17
17
|
"auth": {
|
|
18
|
-
"
|
|
19
|
-
"label": "API
|
|
20
|
-
"instructions": "
|
|
18
|
+
"api-token": {
|
|
19
|
+
"label": "API Token (APIv2)",
|
|
20
|
+
"instructions": "Generate a personal or partner access token in Site Administration → Settings → AroFlo API → APIv2. Requests use Authorization: Bearer <token> against https://api.aroflo.com/v2."
|
|
21
21
|
}
|
|
22
22
|
},
|
|
23
23
|
"connect": {
|
|
24
|
-
"instructions": "<p>
|
|
24
|
+
"instructions": "<p>Paste your <strong>APIv2 access token</strong> from Site Administration → Settings → AroFlo API → APIv2. The token is validated with a lightweight call before the connection is saved. Legacy HMAC credentials are not used.</p>",
|
|
25
25
|
"dialog": {
|
|
26
26
|
"title": "Connect AroFlo",
|
|
27
27
|
"reconfigure-title": "Reconfigure AroFlo"
|
|
28
28
|
},
|
|
29
29
|
"fields": {
|
|
30
30
|
"display-name": "Display Name",
|
|
31
|
-
"
|
|
32
|
-
"p-encoded": "pEncoded",
|
|
33
|
-
"org-encoded": "orgEncoded",
|
|
34
|
-
"secret-key": "Secret Key",
|
|
35
|
-
"host-ip": "Host IP (Optional)"
|
|
31
|
+
"api-token": "API Token"
|
|
36
32
|
},
|
|
37
33
|
"placeholders": {
|
|
38
34
|
"display-name": "AroFlo",
|
|
39
|
-
"
|
|
40
|
-
"p-encoded": "Paste Your AroFlo pEncoded Value",
|
|
41
|
-
"org-encoded": "Paste Your AroFlo orgEncoded Value",
|
|
42
|
-
"secret-key": "Paste Your AroFlo Secret Key",
|
|
43
|
-
"host-ip": "Leave Empty Unless AroFlo Requires It"
|
|
35
|
+
"api-token": "Paste Your AroFlo APIv2 Token"
|
|
44
36
|
},
|
|
45
37
|
"actions": {
|
|
46
38
|
"save": "Save Connection"
|
|
47
39
|
},
|
|
48
40
|
"errors": {
|
|
49
|
-
"
|
|
50
|
-
"p-encoded-required": "pEncoded is required.",
|
|
51
|
-
"org-encoded-required": "orgEncoded is required.",
|
|
52
|
-
"secret-key-required": "Secret Key is required."
|
|
41
|
+
"api-token-required": "API token is required."
|
|
53
42
|
}
|
|
54
43
|
}
|
|
55
44
|
},
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
},
|
|
6
6
|
"integration": {
|
|
7
7
|
"display-name": "AroFlo",
|
|
8
|
-
"description": "Connect to AroFlo to pull projects, clients, contacts, and users into the platform.",
|
|
8
|
+
"description": "Connect to AroFlo APIv2 to pull projects, clients, contacts, and users into the platform.",
|
|
9
9
|
"badges": {
|
|
10
10
|
"last-sync": "Last Sync: {{datetime}}",
|
|
11
11
|
"never-synced": "Not Synced Yet",
|
|
@@ -15,41 +15,30 @@
|
|
|
15
15
|
"schedule-disabled": "Pull Schedule Disabled"
|
|
16
16
|
},
|
|
17
17
|
"auth": {
|
|
18
|
-
"
|
|
19
|
-
"label": "API
|
|
20
|
-
"instructions": "
|
|
18
|
+
"api-token": {
|
|
19
|
+
"label": "API Token (APIv2)",
|
|
20
|
+
"instructions": "Generate a personal or partner access token in Site Administration → Settings → AroFlo API → APIv2. Requests use Authorization: Bearer <token> against https://api.aroflo.com/v2."
|
|
21
21
|
}
|
|
22
22
|
},
|
|
23
23
|
"connect": {
|
|
24
|
-
"instructions": "<p>
|
|
24
|
+
"instructions": "<p>Paste your <strong>APIv2 access token</strong> from Site Administration → Settings → AroFlo API → APIv2. The token is validated with a lightweight call before the connection is saved. Legacy HMAC credentials are not used.</p>",
|
|
25
25
|
"dialog": {
|
|
26
26
|
"title": "Connect AroFlo",
|
|
27
27
|
"reconfigure-title": "Reconfigure AroFlo"
|
|
28
28
|
},
|
|
29
29
|
"fields": {
|
|
30
30
|
"display-name": "Display Name",
|
|
31
|
-
"
|
|
32
|
-
"p-encoded": "pEncoded",
|
|
33
|
-
"org-encoded": "orgEncoded",
|
|
34
|
-
"secret-key": "Secret Key",
|
|
35
|
-
"host-ip": "Host IP (Optional)"
|
|
31
|
+
"api-token": "API Token"
|
|
36
32
|
},
|
|
37
33
|
"placeholders": {
|
|
38
34
|
"display-name": "AroFlo",
|
|
39
|
-
"
|
|
40
|
-
"p-encoded": "Paste Your AroFlo pEncoded Value",
|
|
41
|
-
"org-encoded": "Paste Your AroFlo orgEncoded Value",
|
|
42
|
-
"secret-key": "Paste Your AroFlo Secret Key",
|
|
43
|
-
"host-ip": "Leave Empty Unless AroFlo Requires It"
|
|
35
|
+
"api-token": "Paste Your AroFlo APIv2 Token"
|
|
44
36
|
},
|
|
45
37
|
"actions": {
|
|
46
38
|
"save": "Save Connection"
|
|
47
39
|
},
|
|
48
40
|
"errors": {
|
|
49
|
-
"
|
|
50
|
-
"p-encoded-required": "pEncoded is required.",
|
|
51
|
-
"org-encoded-required": "orgEncoded is required.",
|
|
52
|
-
"secret-key-required": "Secret Key is required."
|
|
41
|
+
"api-token-required": "API token is required."
|
|
53
42
|
}
|
|
54
43
|
}
|
|
55
44
|
},
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
},
|
|
6
6
|
"integration": {
|
|
7
7
|
"display-name": "AroFlo",
|
|
8
|
-
"description": "اتصال به AroFlo برای دریافت پروژهها، مشتریها، مخاطبان و کاربران در پلتفرم.",
|
|
8
|
+
"description": "اتصال به AroFlo APIv2 برای دریافت پروژهها، مشتریها، مخاطبان و کاربران در پلتفرم.",
|
|
9
9
|
"badges": {
|
|
10
10
|
"last-sync": "آخرین همگامسازی: {{datetime}}",
|
|
11
11
|
"never-synced": "هنوز همگامسازی نشده",
|
|
@@ -15,41 +15,30 @@
|
|
|
15
15
|
"schedule-disabled": "زمانبندی دریافت غیرفعال است"
|
|
16
16
|
},
|
|
17
17
|
"auth": {
|
|
18
|
-
"
|
|
19
|
-
"label": "
|
|
20
|
-
"instructions": "
|
|
18
|
+
"api-token": {
|
|
19
|
+
"label": "توکن API (نسخه ۲)",
|
|
20
|
+
"instructions": "از Site Administration → Settings → AroFlo API → APIv2 یک توکن شخصی یا شریک بسازید. درخواستها با Authorization: Bearer به https://api.aroflo.com/v2 ارسال میشوند."
|
|
21
21
|
}
|
|
22
22
|
},
|
|
23
23
|
"connect": {
|
|
24
|
-
"instructions": "<p
|
|
24
|
+
"instructions": "<p>توکن دسترسی <strong>APIv2</strong> را از Site Administration → Settings → AroFlo API → APIv2 وارد کنید. توکن پیش از ذخیره اتصال با یک فراخوانی سبک بررسی میشود. اعتبارنامههای HMAC قدیمی استفاده نمیشوند.</p>",
|
|
25
25
|
"dialog": {
|
|
26
26
|
"title": "اتصال AroFlo",
|
|
27
27
|
"reconfigure-title": "پیکربندی مجدد AroFlo"
|
|
28
28
|
},
|
|
29
29
|
"fields": {
|
|
30
30
|
"display-name": "نام نمایشی",
|
|
31
|
-
"
|
|
32
|
-
"p-encoded": "pEncoded",
|
|
33
|
-
"org-encoded": "orgEncoded",
|
|
34
|
-
"secret-key": "کلید محرمانه",
|
|
35
|
-
"host-ip": "آدرس IP میزبان (اختیاری)"
|
|
31
|
+
"api-token": "توکن API"
|
|
36
32
|
},
|
|
37
33
|
"placeholders": {
|
|
38
34
|
"display-name": "AroFlo",
|
|
39
|
-
"
|
|
40
|
-
"p-encoded": "مقدار pEncoded در AroFlo را وارد کنید",
|
|
41
|
-
"org-encoded": "مقدار orgEncoded در AroFlo را وارد کنید",
|
|
42
|
-
"secret-key": "کلید محرمانه AroFlo را وارد کنید",
|
|
43
|
-
"host-ip": "فقط در صورت نیاز AroFlo وارد کنید"
|
|
35
|
+
"api-token": "توکن APIv2 آروفلو را وارد کنید"
|
|
44
36
|
},
|
|
45
37
|
"actions": {
|
|
46
38
|
"save": "ذخیره اتصال"
|
|
47
39
|
},
|
|
48
40
|
"errors": {
|
|
49
|
-
"
|
|
50
|
-
"p-encoded-required": "مقدار pEncoded الزامی است.",
|
|
51
|
-
"org-encoded-required": "مقدار orgEncoded الزامی است.",
|
|
52
|
-
"secret-key-required": "کلید محرمانه الزامی است."
|
|
41
|
+
"api-token-required": "توکن API الزامی است."
|
|
53
42
|
}
|
|
54
43
|
}
|
|
55
44
|
},
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@acorex-platform/extension-project-management-aroflo-client",
|
|
3
|
-
"version": "2.0.0-next.
|
|
3
|
+
"version": "2.0.0-next.54",
|
|
4
4
|
"sideEffects": false,
|
|
5
5
|
"peerDependencies": {
|
|
6
|
-
"@acorex-platform/extension-project-management-core-client": "2.0.0-next.
|
|
6
|
+
"@acorex-platform/extension-project-management-core-client": "2.0.0-next.54",
|
|
7
7
|
"@angular/common": "^21.0.0 || ^22.0.0",
|
|
8
8
|
"@angular/core": "^21.0.0 || ^22.0.0"
|
|
9
9
|
},
|
|
@@ -39,19 +39,11 @@ declare const AXPAdministrationPermissionKeys: {
|
|
|
39
39
|
|
|
40
40
|
/**
|
|
41
41
|
* Stored on IntegrationManagement connection `config` for tenant-scoped AroFlo.
|
|
42
|
-
*
|
|
42
|
+
* APIv2 authenticates with a Bearer personal / partner access token.
|
|
43
43
|
*/
|
|
44
44
|
interface AXEAroFloConnectionConfig {
|
|
45
|
-
/**
|
|
46
|
-
|
|
47
|
-
/** `pEncoded` credential from AroFlo. */
|
|
48
|
-
pEncoded?: string;
|
|
49
|
-
/** `orgEncoded` credential from AroFlo. */
|
|
50
|
-
orgEncoded?: string;
|
|
51
|
-
/** Secret key used to sign requests with HMAC-SHA512. */
|
|
52
|
-
secretKey?: string;
|
|
53
|
-
/** Optional host IP included in the signature payload. */
|
|
54
|
-
hostIp?: string;
|
|
45
|
+
/** Personal or partner access token from Site Administration → AroFlo API → APIv2. */
|
|
46
|
+
apiToken?: string;
|
|
55
47
|
/** Background pull sync state (server-managed). */
|
|
56
48
|
jobsSync?: AXEAroFloJobsSyncState;
|
|
57
49
|
}
|
|
@@ -63,28 +55,47 @@ interface AXEAroFloJobsSyncState {
|
|
|
63
55
|
lastFullReconcileAt?: string;
|
|
64
56
|
}
|
|
65
57
|
|
|
66
|
-
/**
|
|
58
|
+
/**
|
|
59
|
+
* AroFlo APIv2 `projects` record (normalized) → `resourceType=job`.
|
|
60
|
+
* Also accepts legacy zone field names when present on cached payloads.
|
|
61
|
+
*/
|
|
67
62
|
interface AXEAroFloRemoteProject {
|
|
63
|
+
project_id?: string | number | null;
|
|
68
64
|
projectid?: string | number | null;
|
|
65
|
+
name?: string | null;
|
|
69
66
|
projectname?: string | null;
|
|
67
|
+
project_number?: string | number | null;
|
|
68
|
+
job_number?: string | null;
|
|
70
69
|
projectnumber?: string | null;
|
|
71
|
-
location
|
|
70
|
+
/** APIv2 list often returns a location name string; detail may nest an object. */
|
|
71
|
+
location?: string | {
|
|
72
72
|
locationid?: string | number | null;
|
|
73
73
|
locationname?: string | null;
|
|
74
|
+
name?: string | null;
|
|
74
75
|
} | null;
|
|
75
76
|
startdate?: string | null;
|
|
77
|
+
due_date?: string | null;
|
|
76
78
|
enddate?: string | null;
|
|
77
79
|
projecttype?: {
|
|
78
80
|
projecttypeid?: string | number | null;
|
|
79
81
|
projecttypename?: string | null;
|
|
80
82
|
} | null;
|
|
81
|
-
|
|
83
|
+
task_type?: string | null;
|
|
84
|
+
/**
|
|
85
|
+
* APIv2 list may return a client name string; after pull enrichment / detail fetch
|
|
86
|
+
* this is normalized to `{ orgid, orgname }` (orgid = client_id).
|
|
87
|
+
*/
|
|
88
|
+
client?: string | {
|
|
82
89
|
orgid?: string | number | null;
|
|
83
90
|
orgname?: string | null;
|
|
91
|
+
client_id?: string | number | null;
|
|
92
|
+
name?: string | null;
|
|
84
93
|
} | null;
|
|
94
|
+
client_id?: string | number | null;
|
|
85
95
|
status?: string | null;
|
|
86
96
|
description?: string | null;
|
|
87
97
|
stages?: unknown;
|
|
98
|
+
assigned_to?: string | null;
|
|
88
99
|
contactuser?: {
|
|
89
100
|
userid?: string | number | null;
|
|
90
101
|
username?: string | null;
|
|
@@ -92,18 +103,23 @@ interface AXEAroFloRemoteProject {
|
|
|
92
103
|
custom?: unknown;
|
|
93
104
|
[key: string]: unknown;
|
|
94
105
|
}
|
|
95
|
-
/** AroFlo `
|
|
106
|
+
/** AroFlo APIv2 `clients` record → `resourceType=customer`. */
|
|
96
107
|
interface AXEAroFloRemoteClient {
|
|
108
|
+
client_id?: string | number | null;
|
|
97
109
|
clientid?: string | number | null;
|
|
110
|
+
name?: string | null;
|
|
98
111
|
clientname?: string | null;
|
|
99
112
|
shortname?: string | null;
|
|
100
113
|
contacts?: unknown;
|
|
114
|
+
/** APIv2: array of location name strings (or objects). */
|
|
101
115
|
locations?: unknown;
|
|
102
116
|
phone?: string | null;
|
|
103
117
|
mobile?: string | null;
|
|
104
118
|
fax?: string | null;
|
|
105
119
|
firstname?: string | null;
|
|
120
|
+
first_name?: string | null;
|
|
106
121
|
surname?: string | null;
|
|
122
|
+
last_name?: string | null;
|
|
107
123
|
email?: string | null;
|
|
108
124
|
abn?: string | null;
|
|
109
125
|
website?: string | null;
|
|
@@ -112,12 +128,14 @@ interface AXEAroFloRemoteClient {
|
|
|
112
128
|
address?: Record<string, unknown> | null;
|
|
113
129
|
[key: string]: unknown;
|
|
114
130
|
}
|
|
115
|
-
/**
|
|
131
|
+
/** Site / location remote (often synthesized from client `locations`) → `resourceType=site`. */
|
|
116
132
|
interface AXEAroFloRemoteContact {
|
|
117
133
|
userid?: string | number | null;
|
|
118
134
|
username?: string | null;
|
|
119
135
|
givennames?: string | null;
|
|
136
|
+
first_name?: string | null;
|
|
120
137
|
surname?: string | null;
|
|
138
|
+
last_name?: string | null;
|
|
121
139
|
phone?: string | null;
|
|
122
140
|
mobile?: string | null;
|
|
123
141
|
contacttype?: string | null;
|
|
@@ -125,14 +143,19 @@ interface AXEAroFloRemoteContact {
|
|
|
125
143
|
email2?: string | null;
|
|
126
144
|
notes?: string | null;
|
|
127
145
|
archived?: boolean | string | number | null;
|
|
146
|
+
client_id?: string | number | null;
|
|
128
147
|
[key: string]: unknown;
|
|
129
148
|
}
|
|
130
|
-
/** AroFlo `
|
|
149
|
+
/** AroFlo APIv2 `users` record → `resourceType=employee`. */
|
|
131
150
|
interface AXEAroFloRemoteUser {
|
|
151
|
+
user_id?: string | number | null;
|
|
132
152
|
userid?: string | number | null;
|
|
133
153
|
username?: string | null;
|
|
154
|
+
name?: string | null;
|
|
134
155
|
givennames?: string | null;
|
|
156
|
+
first_name?: string | null;
|
|
135
157
|
surname?: string | null;
|
|
158
|
+
last_name?: string | null;
|
|
136
159
|
phone?: string | null;
|
|
137
160
|
mobile?: string | null;
|
|
138
161
|
fax?: string | null;
|
|
@@ -152,11 +175,8 @@ interface AXEAroFloRemoteUser {
|
|
|
152
175
|
interface AXEAroFloValidateRequest {
|
|
153
176
|
/** Validate stored credentials of this connection (secrets may be omitted). */
|
|
154
177
|
connectionId?: string;
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
orgEncoded?: string;
|
|
158
|
-
secretKey?: string;
|
|
159
|
-
hostIp?: string;
|
|
178
|
+
/** APIv2 Bearer personal / partner access token. */
|
|
179
|
+
apiToken?: string;
|
|
160
180
|
}
|
|
161
181
|
interface AXEAroFloValidateResponse {
|
|
162
182
|
valid: boolean;
|
|
@@ -256,26 +276,48 @@ interface AXEAroFloLinkEmployeesResponse {
|
|
|
256
276
|
}>;
|
|
257
277
|
}
|
|
258
278
|
|
|
259
|
-
/** REST API base URL stored on connection `instanceUrl
|
|
260
|
-
declare const AXE_AROFLO_API_BASE_URL = "https://api.aroflo.com/";
|
|
279
|
+
/** REST API base URL stored on connection `instanceUrl` (APIv2). */
|
|
280
|
+
declare const AXE_AROFLO_API_BASE_URL = "https://api.aroflo.com/v2";
|
|
261
281
|
/** Integration provider id (matches `AXE_PM_INTEGRATION_PROVIDER_AROFLO`). */
|
|
262
282
|
declare const AXE_AROFLO_PROVIDER_ID = "aroflo";
|
|
263
|
-
/** `Accept` header
|
|
264
|
-
declare const AXE_AROFLO_ACCEPT = "
|
|
265
|
-
/**
|
|
283
|
+
/** `Accept` header for every AroFlo APIv2 request. */
|
|
284
|
+
declare const AXE_AROFLO_ACCEPT = "application/json";
|
|
285
|
+
/**
|
|
286
|
+
* APIv2 list resources (`GET /v2/{resource}`).
|
|
287
|
+
*
|
|
288
|
+
* Naming vs cached IntegrationRemoteRecord:
|
|
289
|
+
* - APIv2 `projects` → resourceType `job`
|
|
290
|
+
* - APIv2 `clients` → resourceType `customer`
|
|
291
|
+
* - APIv2 `GET /clients/{id}/contacts` → resourceType `site`
|
|
292
|
+
* - APIv2 `users` → resourceType `employee`
|
|
293
|
+
*
|
|
294
|
+
* `projects` / `clients` / `users` require query `orgId` (business unit id).
|
|
295
|
+
* List `businessunits` first to discover org ids.
|
|
296
|
+
*/
|
|
297
|
+
declare const AXE_AROFLO_RESOURCES: {
|
|
298
|
+
readonly Projects: "projects";
|
|
299
|
+
readonly Clients: "clients";
|
|
300
|
+
readonly Users: "users";
|
|
301
|
+
readonly BusinessUnits: "businessunits";
|
|
302
|
+
};
|
|
303
|
+
type AXEAroFloResource = (typeof AXE_AROFLO_RESOURCES)[keyof typeof AXE_AROFLO_RESOURCES];
|
|
304
|
+
/** @deprecated Use {@link AXE_AROFLO_RESOURCES}. Kept for older import paths. */
|
|
266
305
|
declare const AXE_AROFLO_ZONES: {
|
|
267
306
|
readonly Projects: "projects";
|
|
268
307
|
readonly Clients: "clients";
|
|
269
308
|
readonly Contacts: "contacts";
|
|
270
309
|
readonly Users: "users";
|
|
271
310
|
};
|
|
311
|
+
/** @deprecated Use {@link AXEAroFloResource}. */
|
|
272
312
|
type AXEAroFloZone = (typeof AXE_AROFLO_ZONES)[keyof typeof AXE_AROFLO_ZONES];
|
|
273
|
-
/** Default
|
|
313
|
+
/** Default page size when the API accepts `limit`. */
|
|
314
|
+
declare const AXE_AROFLO_PAGE_LIMIT = 100;
|
|
315
|
+
/** Default record cap per resource for one pull. */
|
|
274
316
|
declare const AXE_AROFLO_DEFAULT_MAX_RECORDS = 250;
|
|
275
|
-
/** Upper bound for `maxRecords` per
|
|
317
|
+
/** Upper bound for `maxRecords` per resource. */
|
|
276
318
|
declare const AXE_AROFLO_MAX_RECORDS = 5000;
|
|
277
|
-
/** Safety cap on page requests per
|
|
319
|
+
/** Safety cap on page requests per resource (guards against endless paging). */
|
|
278
320
|
declare const AXE_AROFLO_MAX_PAGES = 50;
|
|
279
321
|
|
|
280
|
-
export { AXEAroFloCommandKeys, AXE_AROFLO_ACCEPT, AXE_AROFLO_API_BASE_URL, AXE_AROFLO_DEFAULT_MAX_RECORDS, AXE_AROFLO_MAX_PAGES, AXE_AROFLO_MAX_RECORDS, AXE_AROFLO_PROVIDER_ID, AXE_AROFLO_ZONES, AXPAdministrationPermissionKeys, AroFloExtensionManifest, RootConfig };
|
|
281
|
-
export type { AXEAroFloConnectionConfig, AXEAroFloConnectionLifecycleRequest, AXEAroFloConnectionLifecycleResponse, AXEAroFloEmployeeUsernameConflict, AXEAroFloImportCustomerRequest, AXEAroFloImportCustomerResponse, AXEAroFloImportJobRequest, AXEAroFloImportJobResponse, AXEAroFloJobsSyncState, AXEAroFloLinkEmployeesRequest, AXEAroFloLinkEmployeesResponse, AXEAroFloPullJobsRequest, AXEAroFloPullJobsResponse, AXEAroFloRemoteClient, AXEAroFloRemoteContact, AXEAroFloRemoteProject, AXEAroFloRemoteUser, AXEAroFloSyncEmployeesRequest, AXEAroFloSyncEmployeesResponse, AXEAroFloValidateRequest, AXEAroFloValidateResponse, AXEAroFloZone };
|
|
322
|
+
export { AXEAroFloCommandKeys, AXE_AROFLO_ACCEPT, AXE_AROFLO_API_BASE_URL, AXE_AROFLO_DEFAULT_MAX_RECORDS, AXE_AROFLO_MAX_PAGES, AXE_AROFLO_MAX_RECORDS, AXE_AROFLO_PAGE_LIMIT, AXE_AROFLO_PROVIDER_ID, AXE_AROFLO_RESOURCES, AXE_AROFLO_ZONES, AXPAdministrationPermissionKeys, AroFloExtensionManifest, RootConfig };
|
|
323
|
+
export type { AXEAroFloConnectionConfig, AXEAroFloConnectionLifecycleRequest, AXEAroFloConnectionLifecycleResponse, AXEAroFloEmployeeUsernameConflict, AXEAroFloImportCustomerRequest, AXEAroFloImportCustomerResponse, AXEAroFloImportJobRequest, AXEAroFloImportJobResponse, AXEAroFloJobsSyncState, AXEAroFloLinkEmployeesRequest, AXEAroFloLinkEmployeesResponse, AXEAroFloPullJobsRequest, AXEAroFloPullJobsResponse, AXEAroFloRemoteClient, AXEAroFloRemoteContact, AXEAroFloRemoteProject, AXEAroFloRemoteUser, AXEAroFloResource, AXEAroFloSyncEmployeesRequest, AXEAroFloSyncEmployeesResponse, AXEAroFloValidateRequest, AXEAroFloValidateResponse, AXEAroFloZone };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-platform-extension-project-management-aroflo-client-connect-aroflo.command-Cu-5eOic.mjs","sources":["../../../../libs/extensions/project-management/aroflo/client/src/lib/api/aroflo-http.client.ts","../../../../libs/extensions/project-management/aroflo/client/src/lib/features/connect/connect-aroflo.command.ts"],"sourcesContent":["//#region ---- Imports ----\n\nimport { commandMessageTextForError } from '@acorex-platform/framework-client/common';\nimport { AXPCommandService } from '@acorex-platform/framework-client/runtime';\nimport {\n AXEAroFloCommandKeys,\n type AXEAroFloConnectionLifecycleRequest,\n type AXEAroFloConnectionLifecycleResponse,\n type AXEAroFloValidateRequest,\n type AXEAroFloValidateResponse,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport { inject, Injectable } from '@angular/core';\n\n//#endregion\n\n//#region ---- Client ----\n\n@Injectable({ providedIn: 'root' })\nexport class AXEAroFloHttpClient {\n //#region ----- Services & Dependencies -----\n\n private readonly commandService = inject(AXPCommandService);\n\n //#endregion\n\n //#region ----- Commands -----\n\n validate(body: AXEAroFloValidateRequest = {}): Promise<AXEAroFloValidateResponse> {\n return this.runCommand(AXEAroFloCommandKeys.ConnectionValidate, body);\n }\n\n lifecycle(body: AXEAroFloConnectionLifecycleRequest): Promise<AXEAroFloConnectionLifecycleResponse> {\n return this.runCommand(AXEAroFloCommandKeys.ConnectionLifecycle, body);\n }\n\n //#endregion\n\n //#region ----- Helpers -----\n\n private async runCommand<TInput, TResult>(key: string, input: TInput): Promise<TResult> {\n const result = await this.commandService.execute<TInput, TResult>(key, input);\n if (!result?.success) {\n throw new Error(commandMessageTextForError(result?.message?.text) || `AroFlo command failed: ${key}`);\n }\n return result.data as TResult;\n }\n\n //#endregion\n}\n\n//#endregion\n","//#region ---- Connect AroFlo (HMAC credentials) ----\n\n//#region ----- Imports -----\n\nimport { AXPCommand, type AXPCommandExecuteResultPromise } from '@acorex-platform/framework-shared/runtime';\nimport {\n AXP_INTEGRATION_AUTH_METHOD_TYPE,\n AXP_INTEGRATION_CONNECTION_STATUS,\n type AXPIntegrationConnectionScope,\n createRandomUuid,\n} from '@acorex-platform/framework-shared/core';\nimport {\n AXMIntegrationConnectionManager,\n AXP_INTEGRATION_CREDENTIAL_MASK,\n isMaskedIntegrationCredential,\n toSafeIntegrationConnectionDto,\n type ConnectCommandResult,\n} from '@acorex-platform/module-integration-management-client';\nimport {\n AXPLayoutBuilderService,\n resolveLayoutBuilderDialogResult,\n type AXPDialogRef,\n type IActionBuilder,\n type IDialogBuilder,\n type IFlexContainerBuilder,\n type IFormFieldBuilder,\n} from '@acorex-platform/framework-client/layout/builder';\nimport { AXTranslationService } from '@acorex/core/translation';\nimport { Injectable, inject } from '@angular/core';\nimport { defaultTo, trim } from 'lodash-es';\nimport {\n AXE_AROFLO_API_BASE_URL,\n AXE_AROFLO_PROVIDER_ID,\n type AXEAroFloConnectionConfig,\n} from '@acorex-platform/extension-project-management-aroflo-client/contracts';\nimport type { AXMIntegrationManagementIntegrationConnectionEntityModel } from '@acorex-platform/module-integration-management-client/contracts';\nimport { AXEAroFloHttpClient } from '../../api/aroflo-http.client';\n\n//#endregion\n\n//#region ----- Types -----\n\nconst I18N = '@extensions-aroflo:integration';\n\nexport interface ConnectAroFloCommandInput {\n providerId?: string;\n connectionScope?: AXPIntegrationConnectionScope;\n /** When set, reconfigure / reconnect this existing connection. */\n connectionId?: string;\n /** Optional explicit key; new connections get a generated key when omitted. */\n connectionKey?: string;\n}\n\ninterface AXEAroFloConnectForm {\n displayName: string;\n uEncoded: string;\n pEncoded: string;\n orgEncoded: string;\n secretKey: string;\n hostIp: string;\n}\n\n//#endregion\n\n@Injectable({ providedIn: 'root' })\nexport class ConnectAroFloCommand implements AXPCommand<ConnectAroFloCommandInput, ConnectCommandResult> {\n //#region ----- Services & Dependencies -----\n\n private readonly connectionManager = inject(AXMIntegrationConnectionManager);\n private readonly layoutBuilder = inject(AXPLayoutBuilderService);\n private readonly translationService = inject(AXTranslationService);\n private readonly aroFloHttp = inject(AXEAroFloHttpClient);\n\n //#endregion\n\n //#region ----- Execute -----\n\n async execute(input: ConnectAroFloCommandInput = {}): AXPCommandExecuteResultPromise<ConnectCommandResult> {\n try {\n const providerId = input.providerId ?? AXE_AROFLO_PROVIDER_ID;\n const connectionScope = input.connectionScope ?? 'tenant';\n const existing = await this.resolveExistingConnection(providerId, connectionScope, input);\n const isReconfigure = !!existing;\n const existingConfig = (existing?.config ?? {}) as AXEAroFloConnectionConfig;\n const connectionKey = existing?.connectionKey ?? (trim(input.connectionKey) || createRandomUuid());\n\n const title = await this.translationService.translateAsync(\n isReconfigure ? `${I18N}.connect.dialog.reconfigure-title` : `${I18N}.connect.dialog.title`,\n );\n\n const form = await this.openConnectDialog({\n title: title ?? 'Connect AroFlo',\n context: {\n displayName: existing?.displayName ?? 'AroFlo',\n uEncoded: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',\n pEncoded: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',\n orgEncoded: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',\n secretKey: isReconfigure ? AXP_INTEGRATION_CREDENTIAL_MASK : '',\n hostIp: existingConfig.hostIp ?? '',\n },\n existing,\n existingConfig,\n });\n\n if (!form) {\n return { success: true, kind: 'object', data: { outcome: 'cancelled' } };\n }\n\n // 1. Validate with a lightweight users page before anything is stored.\n const validation = await this.aroFloHttp.validate({\n uEncoded: form.uEncoded,\n pEncoded: form.pEncoded,\n orgEncoded: form.orgEncoded,\n secretKey: form.secretKey,\n hostIp: form.hostIp,\n });\n if (!validation.valid) {\n return {\n success: false,\n message: { text: validation.message ?? 'AroFlo credential validation failed.' },\n };\n }\n\n // 2. Create / update the connection as Connected.\n const config: AXEAroFloConnectionConfig = {\n uEncoded: form.uEncoded,\n pEncoded: form.pEncoded,\n orgEncoded: form.orgEncoded,\n secretKey: form.secretKey,\n ...(form.hostIp ? { hostIp: form.hostIp } : {}),\n jobsSync: existingConfig.jobsSync,\n };\n const connection = await this.connectionManager.upsertConnection({\n providerId,\n authMethodType: AXP_INTEGRATION_AUTH_METHOD_TYPE.Pat,\n connectionScope,\n connectionKey,\n displayName: defaultTo(trim(form.displayName), 'AroFlo'),\n instanceUrl: AXE_AROFLO_API_BASE_URL,\n externalAccountName: AXP_INTEGRATION_CREDENTIAL_MASK,\n config: config as Record<string, unknown>,\n status: AXP_INTEGRATION_CONNECTION_STATUS.Connected,\n lastValidatedAt: new Date().toISOString(),\n lastErrorCode: null,\n lastErrorMessage: null,\n isRevoked: false,\n isDisabled: false,\n });\n\n // 3. Create / activate the pull schedule for this connection.\n await this.aroFloHttp.lifecycle({ connectionId: connection.id, action: 'connected' });\n\n const refreshed = await this.connectionManager.getByIdForCurrentUser(connection.id);\n return {\n success: true,\n kind: 'object',\n data: {\n outcome: 'connected',\n connection: toSafeIntegrationConnectionDto(refreshed ?? connection),\n },\n };\n } catch (error: unknown) {\n const message = error instanceof Error ? error.message : 'Failed to connect AroFlo.';\n return { success: false, message: { text: message } };\n }\n }\n\n //#endregion\n\n //#region ----- Connection lookup -----\n\n private async resolveExistingConnection(\n providerId: string,\n connectionScope: AXPIntegrationConnectionScope,\n input: ConnectAroFloCommandInput,\n ): Promise<AXMIntegrationManagementIntegrationConnectionEntityModel | null> {\n if (input.connectionId) {\n const byId = await this.connectionManager.getByIdForCurrentUser(input.connectionId);\n if (!byId) {\n throw new Error('Connection not found or access denied.');\n }\n return byId;\n }\n\n const connectionKey = trim(input.connectionKey);\n if (!connectionKey) {\n return null;\n }\n\n return this.connectionManager.findByUniqueKey({ providerId, connectionScope, connectionKey });\n }\n\n //#endregion\n\n //#region ----- Connect dialog -----\n\n private async openConnectDialog(input: {\n title: string;\n context: AXEAroFloConnectForm;\n existing: AXMIntegrationManagementIntegrationConnectionEntityModel | null;\n existingConfig: AXEAroFloConnectionConfig;\n }): Promise<AXEAroFloConnectForm | null> {\n const secretField = (field: IFormFieldBuilder, path: keyof AXEAroFloConnectForm, placeholderKey: string) => {\n field.path(path);\n field.passwordBox({\n placeholder: `${I18N}.connect.placeholders.${placeholderKey}`,\n revealToggle: true,\n validations: [{ rule: 'required' }],\n });\n };\n\n const result: unknown = await this.layoutBuilder\n .create()\n .dialog<AXEAroFloConnectForm | null>((dialog: IDialogBuilder<AXEAroFloConnectForm | null>) => {\n dialog\n .setTitle(input.title)\n .setSize('md')\n .setCloseButton(true)\n .setContext({ ...input.context })\n .content((flex: IFlexContainerBuilder) => {\n flex\n .setDirection('column')\n .setGap('12px')\n .customWidget('text-block-layout', {\n content: `${I18N}.connect.instructions`,\n })\n .formField(`${I18N}.connect.fields.display-name`, (field: IFormFieldBuilder) => {\n field.path('displayName');\n field.textBox({ placeholder: `${I18N}.connect.placeholders.display-name` });\n })\n .formField(`${I18N}.connect.fields.u-encoded`, (field: IFormFieldBuilder) =>\n secretField(field, 'uEncoded', 'u-encoded'),\n )\n .formField(`${I18N}.connect.fields.p-encoded`, (field: IFormFieldBuilder) =>\n secretField(field, 'pEncoded', 'p-encoded'),\n )\n .formField(`${I18N}.connect.fields.org-encoded`, (field: IFormFieldBuilder) =>\n secretField(field, 'orgEncoded', 'org-encoded'),\n )\n .formField(`${I18N}.connect.fields.secret-key`, (field: IFormFieldBuilder) =>\n secretField(field, 'secretKey', 'secret-key'),\n )\n .formField(`${I18N}.connect.fields.host-ip`, (field: IFormFieldBuilder) => {\n field.path('hostIp');\n field.textBox({ placeholder: `${I18N}.connect.placeholders.host-ip` });\n });\n })\n .setActions((actions: IActionBuilder) => {\n actions.cancel('@general:actions.cancel.title').submit(`${I18N}.connect.actions.save`);\n })\n .onAction(async (ref: AXPDialogRef) => {\n if (ref.action() === 'cancel') {\n return null;\n }\n\n const ctx = ref.context() as AXEAroFloConnectForm;\n const resolveSecret = (value: string, stored: string | undefined, errorKey: string): string => {\n let resolved = trim(value);\n if (isMaskedIntegrationCredential(resolved) && input.existing) {\n resolved = trim(stored ?? '');\n }\n if (!resolved) {\n throw new Error(`${I18N}.connect.errors.${errorKey}`);\n }\n return resolved;\n };\n\n return {\n displayName: trim(ctx.displayName) || input.existing?.displayName || 'AroFlo',\n uEncoded: resolveSecret(ctx.uEncoded, input.existingConfig.uEncoded, 'u-encoded-required'),\n pEncoded: resolveSecret(ctx.pEncoded, input.existingConfig.pEncoded, 'p-encoded-required'),\n orgEncoded: resolveSecret(ctx.orgEncoded, input.existingConfig.orgEncoded, 'org-encoded-required'),\n secretKey: resolveSecret(ctx.secretKey, input.existingConfig.secretKey, 'secret-key-required'),\n hostIp: trim(ctx.hostIp),\n };\n });\n })\n .show();\n\n return resolveLayoutBuilderDialogResult<AXEAroFloConnectForm>(result);\n }\n\n //#endregion\n}\n\n//#endregion\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;AAaA;AAEA;MAGa,mBAAmB,CAAA;AADhC,IAAA,WAAA,GAAA;;AAImB,QAAA,IAAA,CAAA,cAAc,GAAG,MAAM,CAAC,iBAAiB,CAAC;AA2B5D,IAAA;;;IArBC,QAAQ,CAAC,OAAiC,EAAE,EAAA;QAC1C,OAAO,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC,kBAAkB,EAAE,IAAI,CAAC;IACvE;AAEA,IAAA,SAAS,CAAC,IAAyC,EAAA;QACjD,OAAO,IAAI,CAAC,UAAU,CAAC,oBAAoB,CAAC,mBAAmB,EAAE,IAAI,CAAC;IACxE;;;AAMQ,IAAA,MAAM,UAAU,CAAkB,GAAW,EAAE,KAAa,EAAA;AAClE,QAAA,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,OAAO,CAAkB,GAAG,EAAE,KAAK,CAAC;AAC7E,QAAA,IAAI,CAAC,MAAM,EAAE,OAAO,EAAE;AACpB,YAAA,MAAM,IAAI,KAAK,CAAC,0BAA0B,CAAC,MAAM,EAAE,OAAO,EAAE,IAAI,CAAC,IAAI,CAAA,uBAAA,EAA0B,GAAG,CAAA,CAAE,CAAC;QACvG;QACA,OAAO,MAAM,CAAC,IAAe;IAC/B;8GA3BW,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAnB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,E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