@aristid/leav-types 1.12.0-ca805ec3 → 1.12.0-cbe931d4
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/CLAUDE.md +42 -0
- package/apps/core/config/default.d.ts +4 -0
- package/apps/core/config/development.d.ts +4 -0
- package/apps/core/config/test.d.ts +4 -0
- package/apps/core/src/_types/automation.d.ts +42 -9
- package/apps/core/src/_types/config.d.ts +4 -0
- package/apps/core/src/_types/errors.d.ts +1 -0
- package/apps/core/src/_types/events.d.ts +1 -0
- package/apps/core/src/_types/eventsManager.d.ts +8 -0
- package/apps/core/src/_types/record.d.ts +1 -0
- package/apps/core/src/app/core/attributeApp/attributeApp.d.ts +2 -0
- package/apps/core/src/app/core/automationApp.d.ts +9 -4
- package/apps/core/src/app/core/eventsManagerApp.d.ts +2 -1
- package/apps/core/src/domain/automation/actions/conditionAction.d.ts +8 -0
- package/apps/core/src/domain/automation/actions/errorAction.d.ts +8 -0
- package/apps/core/src/domain/automation/actions/index.d.ts +3 -0
- package/apps/core/src/domain/automation/actions/logAction.d.ts +16 -0
- package/apps/core/src/domain/automation/automationDomain.d.ts +17 -2
- package/apps/core/src/domain/automation/fakeRulesToTrigger.d.ts +7 -0
- package/apps/core/src/domain/automation/index.d.ts +1 -0
- package/apps/core/src/domain/automation/pipelineExecutor.d.ts +16 -0
- package/apps/core/src/domain/automation/types.d.ts +22 -0
- package/apps/core/src/domain/discussion/discussionDomain.d.ts +3 -1
- package/apps/core/src/domain/record/helpers/createRecord.d.ts +3 -1
- package/apps/core/src/domain/record/helpers/getRecordIdentity.d.ts +27 -0
- package/apps/core/src/domain/record/helpers/index.d.ts +1 -0
- package/apps/core/src/domain/record/recordDomain.d.ts +3 -11
- package/apps/core/src/domain/value/helpers/formatValue.d.ts +17 -0
- package/apps/core/src/domain/value/helpers/getRecordFieldValue.d.ts +27 -0
- package/apps/core/src/domain/value/helpers/getValues.d.ts +26 -0
- package/apps/core/src/domain/value/helpers/index.d.ts +7 -0
- package/apps/core/src/domain/value/helpers/manageEventMetadata.d.ts +4 -0
- package/apps/core/src/domain/value/helpers/runActionsList.d.ts +10 -0
- package/apps/core/src/domain/value/valueDomain.d.ts +11 -1
- package/apps/core/src/infra/automation/automationRuleRepo.d.ts +8 -1
- package/apps/core/src/infra/db/dbUtils.d.ts +5 -1
- package/apps/core/src/pluginsLoader.d.ts +1 -0
- package/apps/core/tsconfig.types.tsbuildinfo +1 -1
- package/apps/core/vitest.integration.config.d.ts +2 -0
- package/apps/core/vitest.unit.config.d.ts +2 -0
- package/libs/utils/src/types/events.d.ts +1 -0
- package/libs/utils/src/types/helpers.d.ts +0 -3
- package/package.json +1 -1
- package/apps/core/scripts/build.d.ts +0 -2
- package/apps/core/scripts/utils.d.ts +0 -3
- package/apps/core/src/__tests__/e2e/_gqlTypes/index.d.ts +0 -1288
- package/apps/core/src/__tests__/e2e/api/_fixtures/applications/login/index-hashed.d.ts +0 -0
- package/apps/core/src/__tests__/e2e/api/_fixtures/fakeplugin/_types/_types.d.ts +0 -3
- package/apps/core/src/__tests__/e2e/api/_fixtures/fakeplugin/domain/fakeDomain.d.ts +0 -17
- package/apps/core/src/__tests__/e2e/api/_fixtures/fakeplugin/domain/index.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/_fixtures/fakeplugin/index.d.ts +0 -21
- package/apps/core/src/__tests__/e2e/api/actionLists/actionLists.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/actionLists/actions/inheritanceCalculationAction.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/actionLists/actions/replaceAnotherAttributeAction.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/apiKey/apiKey.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/applications/applications.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/attributes/attributes.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/auth/auth.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/automation/automation.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/constants.d.ts +0 -2
- package/apps/core/src/__tests__/e2e/api/discussions/discussions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/e2eUtils.d.ts +0 -156
- package/apps/core/src/__tests__/e2e/api/export/export.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/export/exportNestedAttributes.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/files/files.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/forms/forms.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/getConditionPart/getConditionPart.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/globalSettings/globalSettings.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/globalSetup.d.ts +0 -8
- package/apps/core/src/__tests__/e2e/api/globalSetupHook.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/graphql/graphql.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/import/import.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/joinLibraries/joinLibraries.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/joinLibraries/nestedJoinLibraries.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/libraries/libraries.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/mailpitUtils.d.ts +0 -37
- package/apps/core/src/__tests__/e2e/api/notificationUtils.d.ts +0 -7
- package/apps/core/src/__tests__/e2e/api/notifications/notifications.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/apiKeyAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/applicationsAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/attributesAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/formsAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/globalSettingsAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/librariesAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/permissionsAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/treesAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/admin/versionProfilesAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/applicationsPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/attributePermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/dependentValuesTreeAttributePermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/extendedLibraryPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/permissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/recordAttributePermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/recordPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/treeLibraryPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/treeNodePermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/permissions/treePermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/plugins/plugins.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/records/recordIdentity.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/records/records.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/records/recordsDeletion.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/records/searchFilters.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/task/taskSubscription.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/task/tasksAdminPermissions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/taskUtils.d.ts +0 -4
- package/apps/core/src/__tests__/e2e/api/teardown.d.ts +0 -2
- package/apps/core/src/__tests__/e2e/api/trees/treeNodeChildrenAndContentQuery.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/trees/trees.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/userData/maskUserPassword.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/userData/userData.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/values/listDistinctValues.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/values/metadata.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/values/purgeMultipleValues.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/values/saveValueBulk.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/values/values.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/values/versions.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/versionProfile/versionProfile.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/api/views/views.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/filesManager/filesManager/filesManager.test.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/filesManager/globalSetup.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/filesManager/globalSetupHook.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/indexationManager/globalSetup.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/indexationManager/globalSetupHook.d.ts +0 -1
- package/apps/core/src/__tests__/e2e/indexationManager/indexation.test.d.ts +0 -1
- package/apps/core/src/__tests__/global-setup.d.ts +0 -0
- package/apps/core/src/__tests__/integration/domain/tasksManagerDomain.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/globalSetup.d.ts +0 -1
- package/apps/core/src/__tests__/integration/globalSetupHook.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/attributeAdvancedLinkRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/attributeAdvancedRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/attributeSimpleLinkRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/attributeSimpleRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/attributeTreeRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/automationRuleRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/integrationTestRepoUtils.d.ts +0 -14
- package/apps/core/src/__tests__/integration/infra/notificationRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/permissionRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/ramService.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/recordRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/infra/treeRepo.test.d.ts +0 -1
- package/apps/core/src/__tests__/integration/integrationTestUtils.d.ts +0 -7
- package/apps/core/src/__tests__/integration/teardown.d.ts +0 -1
- package/apps/core/src/__tests__/jestUtils.d.ts +0 -12
- package/apps/core/src/__tests__/mockers/amqp.d.ts +0 -8
- package/apps/core/src/__tests__/mockers/logger.d.ts +0 -7
- package/apps/core/src/__tests__/mocks/actionsList.d.ts +0 -73
- package/apps/core/src/__tests__/mocks/apiKey.d.ts +0 -11
- package/apps/core/src/__tests__/mocks/application.d.ts +0 -3
- package/apps/core/src/__tests__/mocks/attribute.d.ts +0 -45
- package/apps/core/src/__tests__/mocks/cache.d.ts +0 -4
- package/apps/core/src/__tests__/mocks/file.d.ts +0 -29
- package/apps/core/src/__tests__/mocks/forms.d.ts +0 -4
- package/apps/core/src/__tests__/mocks/globalSettings.d.ts +0 -2
- package/apps/core/src/__tests__/mocks/graphql-upload.d.ts +0 -3
- package/apps/core/src/__tests__/mocks/library.d.ts +0 -4
- package/apps/core/src/__tests__/mocks/log.d.ts +0 -2
- package/apps/core/src/__tests__/mocks/plugins.d.ts +0 -2
- package/apps/core/src/__tests__/mocks/record.d.ts +0 -3
- package/apps/core/src/__tests__/mocks/shared.d.ts +0 -3
- package/apps/core/src/__tests__/mocks/task.d.ts +0 -2
- package/apps/core/src/__tests__/mocks/translator.d.ts +0 -3
- package/apps/core/src/__tests__/mocks/tree.d.ts +0 -3
- package/apps/core/src/__tests__/mocks/value.d.ts +0 -2
- package/apps/core/src/__tests__/mocks/versionProfile.d.ts +0 -2
- package/apps/core/src/__tests__/mocks/view.d.ts +0 -3
- package/apps/core/src/__tests__/setup.d.ts +0 -1
- package/apps/core/src/app/application/__tests__/applicationApp.spec.d.ts +0 -1
- package/apps/core/src/app/auth/__tests__/authApp.spec.d.ts +0 -1
- package/apps/core/src/app/core/coreApp.spec.d.ts +0 -1
- package/apps/core/src/app/endpoint/endpointApp.spec.d.ts +0 -1
- package/apps/core/src/app/graphql/customScalars/any/any.spec.d.ts +0 -1
- package/apps/core/src/app/graphql/customScalars/dateTime/dateTime.spec.d.ts +0 -1
- package/apps/core/src/app/graphql/customScalars/systemTranslation/systemTranslation.spec.d.ts +0 -1
- package/apps/core/src/app/graphql/graphqlApp.spec.d.ts +0 -1
- package/apps/core/src/app/helpers/convertOIDCIdentifier.spec.d.ts +0 -1
- package/apps/core/src/app/helpers/convertVersionFromGqlFormat.spec.d.ts +0 -1
- package/apps/core/src/app/helpers/validateRequestToken.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/dateRangeToNumberAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/encryptAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/excelCalculationAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/formatDateAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/formatDateRangeAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/formatNumberAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/inheritanceCalculationAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/maskValueAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/parseJSONAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/toBooleanAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/toJSONAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/toLowercaseAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/toNumberAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/toStringAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/toUppercaseAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/validateEmailAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/validateFormatAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/validateRegexAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actions/validateURLAction.spec.d.ts +0 -1
- package/apps/core/src/domain/actionsList/actionsListDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/apiKey/apiKeyDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/application/applicationDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/attribute/attributeDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/attribute/helpers/ifLibraryJoinLinkAttribute.spec.d.ts +0 -1
- package/apps/core/src/domain/core/coreDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/eventsManager/eventsManagerDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/export/exportDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/export/exportProfileDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/filesManager/filesManagerDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/filesManager/helpers/handleFileSystemEvent/handleFileSystemEvent.spec.d.ts +0 -1
- package/apps/core/src/domain/filesManager/helpers/messagesHandler/messagesHandler.spec.d.ts +0 -1
- package/apps/core/src/domain/form/formDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/globalSettings/globalSettingsDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/helpers/calculations/calculationVariable.spec.d.ts +0 -1
- package/apps/core/src/domain/helpers/calculations/calculationsVariableFunctions.spec.d.ts +0 -1
- package/apps/core/src/domain/import/importDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/indexationManager/indexationManagerDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/library/helpers/runPreDelete.spec.d.ts +0 -1
- package/apps/core/src/domain/library/libraryDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/log/logDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/adminPermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/applicationPermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/attributePermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/defaultPermission.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/getPermissionCacheKey.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/getPermissionCachePatternKey.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/globalPermission.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/permissionByUserGroups.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/permissionsByActions.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/reducePermissionsArray.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/simplePermission.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/helpers/treeBasedPermissions.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/libraryPermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/permissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/recordAttributePermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/recordPermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/treeLibraryPermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/treeNodePermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/permission/treePermissionDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/plugins/pluginsDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/record/helpers/findRecords.spec.d.ts +0 -1
- package/apps/core/src/domain/record/helpers/getRecordFieldValue.spec.d.ts +0 -0
- package/apps/core/src/domain/record/recordDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/tasksManager/cronTasksManagerDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/tasksManager/tasksManagerDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/tree/helpers/getDefaultElement.spec.d.ts +0 -1
- package/apps/core/src/domain/tree/helpers/handleRemovedLibraries.spec.d.ts +0 -1
- package/apps/core/src/domain/tree/helpers/treeDataValidation.spec.d.ts +0 -1
- package/apps/core/src/domain/tree/treeDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/user/userDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/value/helpers/areValuesIdentical.spec.d.ts +0 -1
- package/apps/core/src/domain/value/helpers/formatLogValue.spec.d.ts +0 -1
- package/apps/core/src/domain/value/valueDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/versionProfile/versionProfileDomain.spec.d.ts +0 -1
- package/apps/core/src/domain/view/viewDomain.spec.d.ts +0 -1
- package/apps/core/src/infra/apiKey/apiKeyRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/application/applicationRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attribute/attributeRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attributeTypes/attributeAdvancedLinkRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attributeTypes/attributeAdvancedRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attributeTypes/attributeSimpleLinkRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attributeTypes/attributeSimpleRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attributeTypes/attributeTreeRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/attributeTypes/attributeTypesRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/db/dbService.spec.d.ts +0 -1
- package/apps/core/src/infra/db/dbUtils.spec.d.ts +0 -1
- package/apps/core/src/infra/filesManager/filesManagerRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/form/formRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/globalSettings/globalSettingsRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/indexation/helpers/getSearchQuery.spec.d.ts +0 -1
- package/apps/core/src/infra/library/libraryRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/log/logRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/oidc/__tests__/oidcClient.spec.d.ts +0 -1
- package/apps/core/src/infra/oidc/__tests__/oidcClientService.spec.d.ts +0 -1
- package/apps/core/src/infra/permission/permissionRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/plugins/pluginsRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/record/helpers/filterTypes.spec.d.ts +0 -1
- package/apps/core/src/infra/record/helpers/getClassifyingFiltersVariableQueryPart.spec.d.ts +0 -1
- package/apps/core/src/infra/record/helpers/getSearchVariableName.spec.d.ts +0 -1
- package/apps/core/src/infra/record/helpers/getSearchVariablesQueryPart.spec.d.ts +0 -1
- package/apps/core/src/infra/record/recordRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/task/taskRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/tree/treeRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/userData/userDataRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/value/valueRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/versionProfile/versionProfileRepo.spec.d.ts +0 -1
- package/apps/core/src/infra/view/viewRepo.spec.d.ts +0 -1
- package/apps/core/src/interface/helpers/handleGraphqlError.spec.d.ts +0 -1
- package/apps/core/src/utils/dataloader.spec.d.ts +0 -1
- package/apps/core/src/utils/helpers/getValuesToDisplay.spec.d.ts +0 -1
- package/apps/core/src/utils/typeGuards/typeGuards.spec.d.ts +0 -1
- package/apps/core/src/utils/utils.spec.d.ts +0 -1
- /package/apps/core/{scripts/preload.d.ts → src/pluginsModuleResolver.d.ts} +0 -0
package/CLAUDE.md
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# libs/types — CLAUDE.md
|
|
2
|
+
|
|
3
|
+
`@aristid/leav-types` — Types TypeScript de `apps/core` publiés sur npm pour les plugins externes.
|
|
4
|
+
|
|
5
|
+
## Ce que c'est
|
|
6
|
+
|
|
7
|
+
Ce package ne contient **pas de code source** — c'est une projection des types générés
|
|
8
|
+
depuis `apps/core`, destinée aux **développeurs de plugins** qui étendent le core.
|
|
9
|
+
|
|
10
|
+
> ⚠️ Ce package **n'est pas utilisé dans le monorepo lui-même**. Il est uniquement
|
|
11
|
+
> consommé par des repos externes (plugins tiers du core).
|
|
12
|
+
|
|
13
|
+
## Publication CI (GitLab)
|
|
14
|
+
|
|
15
|
+
Publié automatiquement sur **npm public** (`@aristid/leav-types`) via GitLab CI,
|
|
16
|
+
déclenché par tout changement dans `apps/core/**/*` :
|
|
17
|
+
|
|
18
|
+
- **`next`** — à chaque push sur `develop`
|
|
19
|
+
- **`latest`** — sur les releases taguées
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
# Commande de génération (lancée par le CI)
|
|
23
|
+
yarn workspace @aristid/leav-types generate
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Problème connu : les enums ne sont pas exportés ⚠️
|
|
27
|
+
|
|
28
|
+
La commande `generate` (basée sur `build-types` du core) n'exporte pas les enums TypeScript.
|
|
29
|
+
Les consommateurs du package doivent **réécrire les enums manuellement** de leur côté —
|
|
30
|
+
ce qui est une source de désynchronisation et de maintenance coûteuse.
|
|
31
|
+
|
|
32
|
+
**Piste de résolution envisagée :** publier davantage de code du core directement
|
|
33
|
+
(pas uniquement les types), de façon à exposer les enums comme du code exécutable.
|
|
34
|
+
C'est un chantier à prioriser.
|
|
35
|
+
|
|
36
|
+
## Ne jamais modifier manuellement
|
|
37
|
+
|
|
38
|
+
Toujours régénérer via le CI ou :
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
yarn workspace @aristid/leav-types generate
|
|
42
|
+
```
|
|
@@ -287,4 +287,8 @@ export declare namespace logsCollector {
|
|
|
287
287
|
let queue: string;
|
|
288
288
|
}
|
|
289
289
|
export declare let pluginsPath: string[];
|
|
290
|
+
export declare namespace automation {
|
|
291
|
+
let enable_7: boolean;
|
|
292
|
+
export { enable_7 as enable };
|
|
293
|
+
}
|
|
290
294
|
export { debug_1 as debug, _export as export, _import as import };
|
|
@@ -1,15 +1,48 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type EventAction, type IDbPayload } from '@leav/utils';
|
|
2
2
|
export type IAutomationRule = ICoreEntity & {
|
|
3
|
+
createdAt: number;
|
|
4
|
+
createdBy: string;
|
|
5
|
+
modifiedAt: number;
|
|
6
|
+
modifiedBy: string;
|
|
3
7
|
id: string;
|
|
4
|
-
label:
|
|
5
|
-
description?:
|
|
8
|
+
label: string;
|
|
9
|
+
description?: string;
|
|
6
10
|
active: boolean;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
modifiedAt?: number;
|
|
10
|
-
modifiedBy?: string;
|
|
11
|
+
trigger: AutomationRuleTrigger;
|
|
12
|
+
pipeline: AutomationRulePipeline;
|
|
11
13
|
};
|
|
12
14
|
export type ICreateAutomationRule = {
|
|
13
|
-
label:
|
|
14
|
-
description?:
|
|
15
|
+
label: string;
|
|
16
|
+
description?: string;
|
|
17
|
+
trigger: AutomationRuleTrigger;
|
|
18
|
+
};
|
|
19
|
+
export type IUpdateAutomationRule = {
|
|
20
|
+
id: string;
|
|
21
|
+
label?: string;
|
|
22
|
+
description?: string;
|
|
23
|
+
active?: boolean;
|
|
24
|
+
trigger?: Partial<AutomationRuleTrigger>;
|
|
25
|
+
};
|
|
26
|
+
export declare enum SyncAutomationRuleEventAction {
|
|
27
|
+
RECORD_INIT = "RECORD_INIT"
|
|
28
|
+
}
|
|
29
|
+
export type AutomationRuleEventAction = EventAction | SyncAutomationRuleEventAction;
|
|
30
|
+
export type AutomationRulesEventTopic = IDbPayload['topic'];
|
|
31
|
+
export type AutomationRuleTrigger = {
|
|
32
|
+
synchronous: boolean;
|
|
33
|
+
eventAction: AutomationRuleEventAction;
|
|
34
|
+
eventTopic?: AutomationRulesEventTopic;
|
|
35
|
+
};
|
|
36
|
+
export type AutomationRulePipeline = {
|
|
37
|
+
steps: AutomationRulePipelineStep[];
|
|
38
|
+
};
|
|
39
|
+
export declare enum AutomationRuleActions {
|
|
40
|
+
LOG = "log",
|
|
41
|
+
CONDITION = "condition",
|
|
42
|
+
ERROR = "error"
|
|
43
|
+
}
|
|
44
|
+
export type AutomationRulePipelineStep = {
|
|
45
|
+
type: AutomationRuleActions | string;
|
|
46
|
+
name?: string;
|
|
47
|
+
params: Record<string, unknown>;
|
|
15
48
|
};
|
|
@@ -91,6 +91,7 @@ export declare enum Errors {
|
|
|
91
91
|
UNKNOWN_APPLICATION = "UNKNOWN_APPLICATION",
|
|
92
92
|
UNKNOWN_ATTRIBUTE = "UNKNOWN_ATTRIBUTE",
|
|
93
93
|
UNKNOWN_ATTRIBUTES = "UNKNOWN_ATTRIBUTES",
|
|
94
|
+
UNKNOWN_AUTOMATION_RULE = "UNKNOWN_AUTOMATION_RULE",
|
|
94
95
|
UNKNOWN_ELEMENT = "UNKNOWN_ELEMENT",
|
|
95
96
|
UNKNOWN_FORM = "UNKNOWN_FORM",
|
|
96
97
|
UNKNOWN_FORM_ATTRIBUTES = "UNKNOWN_FORM_ATTRIBUTES",
|
|
@@ -32,6 +32,7 @@ interface IDBPayloadDataMap {
|
|
|
32
32
|
[EventAction.APP_SAVE]: IApplication;
|
|
33
33
|
[EventAction.APP_DELETE]: IApplication;
|
|
34
34
|
[EventAction.AUTOMATION_RULE_CREATE]: IAutomationRule;
|
|
35
|
+
[EventAction.AUTOMATION_RULE_UPDATE]: IAutomationRule;
|
|
35
36
|
[EventAction.GLOBAL_SETTINGS_SAVE]: IGlobalSettings;
|
|
36
37
|
[EventAction.LIBRARY_SAVE]: ILibraryDbEvent;
|
|
37
38
|
[EventAction.LIBRARY_DELETE]: ILibraryDbEvent;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type INotification } from './notification';
|
|
2
|
+
import { type IRecord } from './record';
|
|
2
3
|
import { type ITask } from './tasksManager';
|
|
3
4
|
export declare enum TriggerNames {
|
|
4
5
|
APPLICATION_EVENT = "APPLICATION_EVENT",
|
|
@@ -7,6 +8,7 @@ export declare enum TriggerNames {
|
|
|
7
8
|
TASK = "TASK",
|
|
8
9
|
TREE_EVENT = "TREE_EVENT",
|
|
9
10
|
RECORD_UPDATE = "RECORD_UPDATE",
|
|
11
|
+
RECORD_NEW_COMMENT = "RECORD_NEW_COMMENT",
|
|
10
12
|
NOTIFICATION = "NOTIFICATION"
|
|
11
13
|
}
|
|
12
14
|
export interface IPubSubNotificationData {
|
|
@@ -16,3 +18,9 @@ export interface IPubSubNotificationData {
|
|
|
16
18
|
export interface IPubSubTaskData {
|
|
17
19
|
task: ITask;
|
|
18
20
|
}
|
|
21
|
+
export interface IPubSubRecordNewCommentData {
|
|
22
|
+
recordNewComment: {
|
|
23
|
+
record: IRecord;
|
|
24
|
+
comment: IRecord;
|
|
25
|
+
};
|
|
26
|
+
}
|
|
@@ -102,6 +102,7 @@ export interface IRecordUpdateEventFilters {
|
|
|
102
102
|
libraries?: string[];
|
|
103
103
|
records?: string[];
|
|
104
104
|
}
|
|
105
|
+
export type IRecordCommentEventFilters = IRecordUpdateEventFilters;
|
|
105
106
|
export interface IRecordFilterLight {
|
|
106
107
|
field?: string;
|
|
107
108
|
value?: string;
|
|
@@ -3,6 +3,7 @@ import { type IAttributeDomain } from '../../../domain/attribute/attributeDomain
|
|
|
3
3
|
import { type ILibraryDomain } from '../../../domain/library/libraryDomain';
|
|
4
4
|
import { type IPermissionDomain } from '../../../domain/permission/permissionDomain';
|
|
5
5
|
import { type IAttributeDependentValuesPermissionDomain } from '../../../domain/permission/attributeDependentValuesPermissionDomain';
|
|
6
|
+
import { type IfLibraryJoinLinkAttribute } from '../../../domain/attribute/helpers/ifLibraryJoinLinkAttribute';
|
|
6
7
|
import { type IRecordDomain } from '../../../domain/record/recordDomain';
|
|
7
8
|
import { type ITreeDomain } from '../../../domain/tree/treeDomain';
|
|
8
9
|
import { type IVersionProfileDomain } from '../../../domain/versionProfile/versionProfileDomain';
|
|
@@ -12,6 +13,7 @@ import { type ICoreApp } from '../coreApp';
|
|
|
12
13
|
export type ICoreAttributeApp = IGraphqlAppModule;
|
|
13
14
|
interface IDeps {
|
|
14
15
|
'core.domain.attribute': IAttributeDomain;
|
|
16
|
+
'core.domain.attribute.helpers.ifLibraryJoinLinkAttribute': IfLibraryJoinLinkAttribute;
|
|
15
17
|
'core.domain.library': ILibraryDomain;
|
|
16
18
|
'core.domain.record': IRecordDomain;
|
|
17
19
|
'core.domain.tree': ITreeDomain;
|
|
@@ -1,17 +1,22 @@
|
|
|
1
1
|
import { type IGraphqlAppModule } from '../graphql/graphqlApp';
|
|
2
2
|
import { type IAutomationDomain } from '../../domain/automation/automationDomain';
|
|
3
|
+
import { type IAutomationRule } from '../../_types/automation';
|
|
3
4
|
import { type IPaginationParams, type ISortParams } from '../../_types/list';
|
|
5
|
+
import { type IEventsManagerDomain } from '../../domain/eventsManager/eventsManagerDomain';
|
|
4
6
|
export type ICoreImportApp = IGraphqlAppModule;
|
|
5
|
-
interface
|
|
7
|
+
interface IAutomationAppDeps {
|
|
6
8
|
'core.domain.automation': IAutomationDomain;
|
|
9
|
+
'core.domain.eventsManager': IEventsManagerDomain;
|
|
7
10
|
}
|
|
8
11
|
export interface IGetAutomationRulesArgs {
|
|
9
12
|
filters?: ICoreEntityFilterOptions & {
|
|
10
|
-
|
|
11
|
-
|
|
13
|
+
active?: boolean;
|
|
14
|
+
synchronous?: boolean;
|
|
15
|
+
eventAction?: IAutomationRule['trigger']['eventAction'];
|
|
16
|
+
eventTopic?: IAutomationRule['trigger']['eventTopic'];
|
|
12
17
|
};
|
|
13
18
|
pagination?: IPaginationParams;
|
|
14
19
|
sort?: ISortParams;
|
|
15
20
|
}
|
|
16
|
-
export default function ({ 'core.domain.automation': automationDomain }:
|
|
21
|
+
export default function ({ 'core.domain.automation': automationDomain, 'core.domain.eventsManager': eventsManagerDomain, }: IAutomationAppDeps): ICoreImportApp;
|
|
17
22
|
export {};
|
|
@@ -2,7 +2,8 @@ import { type InitQueryContextFunc } from '../helpers/initQueryContext';
|
|
|
2
2
|
import { type IEventsManagerDomain } from '../../domain/eventsManager/eventsManagerDomain';
|
|
3
3
|
import { type IConfig } from '../../_types/config';
|
|
4
4
|
import { type IAppModule } from '../../_types/shared';
|
|
5
|
-
|
|
5
|
+
import { type IGraphqlAppModule } from '../graphql/graphqlApp';
|
|
6
|
+
export type IEventsManagerApp = IAppModule & IGraphqlAppModule;
|
|
6
7
|
interface IDeps {
|
|
7
8
|
'core.domain.eventsManager': IEventsManagerDomain;
|
|
8
9
|
'core.app.helpers.initQueryContext': InitQueryContextFunc;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { type IAutomationAction } from '../types';
|
|
3
|
+
declare const conditionActionParamsSchema: z.ZodObject<{
|
|
4
|
+
result: z.ZodBoolean;
|
|
5
|
+
}, z.core.$strip>;
|
|
6
|
+
export type ConditionActionParams = z.infer<typeof conditionActionParamsSchema>;
|
|
7
|
+
export default function (): IAutomationAction<ConditionActionParams>;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { type IAutomationAction } from '../types';
|
|
3
|
+
declare const errorActionParamsSchema: z.ZodObject<{
|
|
4
|
+
message: z.ZodString;
|
|
5
|
+
}, z.core.$strip>;
|
|
6
|
+
export type ErrorActionParams = z.infer<typeof errorActionParamsSchema>;
|
|
7
|
+
export default function (): IAutomationAction<ErrorActionParams>;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { type IAutomationAction } from '../types';
|
|
3
|
+
declare const logActionParamsSchema: z.ZodObject<{
|
|
4
|
+
message: z.ZodString;
|
|
5
|
+
level: z.ZodOptional<z.ZodEnum<{
|
|
6
|
+
info: "info";
|
|
7
|
+
error: "error";
|
|
8
|
+
debug: "debug";
|
|
9
|
+
silly: "silly";
|
|
10
|
+
verbose: "verbose";
|
|
11
|
+
warn: "warn";
|
|
12
|
+
}>>;
|
|
13
|
+
}, z.core.$strip>;
|
|
14
|
+
export type LogActionParams = z.infer<typeof logActionParamsSchema>;
|
|
15
|
+
export default function (): IAutomationAction<LogActionParams>;
|
|
16
|
+
export {};
|
|
@@ -1,13 +1,18 @@
|
|
|
1
|
-
import { type ICreateAutomationRule, type IAutomationRule } from '../../_types/automation';
|
|
1
|
+
import { type ICreateAutomationRule, type IAutomationRule, type IUpdateAutomationRule, type AutomationRulesEventTopic, type AutomationRuleEventAction } from '../../_types/automation';
|
|
2
2
|
import { type IList } from '../../_types/list';
|
|
3
3
|
import { type IQueryInfos } from '../../_types/queryInfos';
|
|
4
4
|
import { type IGetCoreEntitiesParams } from '../../_types/shared';
|
|
5
5
|
import { type IAutomationRuleRepo } from '../../infra/automation/automationRuleRepo';
|
|
6
6
|
import { type IAdminPermissionDomain } from '../permission/adminPermissionDomain';
|
|
7
7
|
import { type IEventsManagerDomain } from '../eventsManager/eventsManagerDomain';
|
|
8
|
+
import { type IConfig } from '../../_types/config';
|
|
9
|
+
import { type IPipelineExecutor } from './pipelineExecutor';
|
|
8
10
|
export interface IGetAutomationRulesParams extends IGetCoreEntitiesParams {
|
|
9
11
|
filters?: ICoreEntityFilterOptions & {
|
|
10
12
|
active?: boolean;
|
|
13
|
+
synchronous?: boolean;
|
|
14
|
+
eventAction?: AutomationRuleEventAction;
|
|
15
|
+
eventTopic?: AutomationRulesEventTopic;
|
|
11
16
|
};
|
|
12
17
|
}
|
|
13
18
|
export interface IAutomationDomain {
|
|
@@ -19,10 +24,20 @@ export interface IAutomationDomain {
|
|
|
19
24
|
rule: ICreateAutomationRule;
|
|
20
25
|
ctx: IQueryInfos;
|
|
21
26
|
}): Promise<IAutomationRule>;
|
|
27
|
+
updateAutomationRule({ rule, ctx }: {
|
|
28
|
+
rule: IUpdateAutomationRule;
|
|
29
|
+
ctx: IQueryInfos;
|
|
30
|
+
}): Promise<IAutomationRule>;
|
|
31
|
+
triggerRules(event: {
|
|
32
|
+
action: AutomationRuleEventAction;
|
|
33
|
+
topic?: AutomationRulesEventTopic;
|
|
34
|
+
}, synchronous: boolean, ctx: IQueryInfos): Promise<void>;
|
|
22
35
|
}
|
|
23
36
|
export interface IAutomationDomainDeps {
|
|
24
37
|
'core.domain.permission.admin': IAdminPermissionDomain;
|
|
25
38
|
'core.domain.eventsManager': IEventsManagerDomain;
|
|
39
|
+
'core.domain.automation.pipelineExecutor': IPipelineExecutor;
|
|
26
40
|
'core.infra.automation.rule': IAutomationRuleRepo;
|
|
41
|
+
config: IConfig;
|
|
27
42
|
}
|
|
28
|
-
export default function ({ 'core.domain.permission.admin': adminPermissionDomain, 'core.domain.eventsManager': eventsManagerDomain, 'core.infra.automation.rule': automationRuleRepo, }: IAutomationDomainDeps): IAutomationDomain;
|
|
43
|
+
export default function ({ 'core.domain.permission.admin': adminPermissionDomain, 'core.domain.eventsManager': eventsManagerDomain, 'core.domain.automation.pipelineExecutor': pipelineExecutor, 'core.infra.automation.rule': automationRuleRepo, config, }: IAutomationDomainDeps): IAutomationDomain;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type AutomationRuleEventAction, type AutomationRulesEventTopic, type IAutomationRule } from '../../_types/automation';
|
|
2
|
+
import { type IQueryInfos } from '../../_types/queryInfos';
|
|
3
|
+
export declare const TRIGGER_FAKER_RULES_FOR_DEV = false;
|
|
4
|
+
export declare const buildFakeRulesToTrigger: (event: {
|
|
5
|
+
action: AutomationRuleEventAction;
|
|
6
|
+
topic?: AutomationRulesEventTopic;
|
|
7
|
+
}, synchronous: boolean, ctx: IQueryInfos) => Promise<IAutomationRule[]>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type AwilixContainer } from 'awilix';
|
|
2
|
+
import { type AutomationRuleTrigger, type AutomationRulePipeline } from '../../_types/automation';
|
|
3
|
+
import { type IAutomationAction } from './types';
|
|
4
|
+
import { type IQueryInfos } from '../../_types/queryInfos';
|
|
5
|
+
export type AutomationPipelineToExecute = AutomationRulePipeline & {
|
|
6
|
+
ruleId: string;
|
|
7
|
+
trigger: AutomationRuleTrigger;
|
|
8
|
+
};
|
|
9
|
+
export interface IPipelineExecutor {
|
|
10
|
+
getAvailableActions(): IAutomationAction[];
|
|
11
|
+
executePipeline(pipelineExec: AutomationPipelineToExecute, ctx: IQueryInfos): Promise<boolean>;
|
|
12
|
+
}
|
|
13
|
+
export interface IPipelineExecutorDeps {
|
|
14
|
+
'core.depsManager': AwilixContainer;
|
|
15
|
+
}
|
|
16
|
+
export default function ({ 'core.depsManager': depsManager }: IPipelineExecutorDeps): IPipelineExecutor;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type ZodObject } from 'zod';
|
|
2
|
+
import { type AutomationRuleActions, type AutomationRuleTrigger } from '../../_types/automation';
|
|
3
|
+
import { type IQueryInfos } from '../../_types/queryInfos';
|
|
4
|
+
export declare enum ActionExecutionResultStatus {
|
|
5
|
+
CONTINUE = "continue",
|
|
6
|
+
STOP = "stop"
|
|
7
|
+
}
|
|
8
|
+
export type IActionExecutionResult = {
|
|
9
|
+
status: ActionExecutionResultStatus.CONTINUE;
|
|
10
|
+
} | {
|
|
11
|
+
status: ActionExecutionResultStatus.STOP;
|
|
12
|
+
reason?: string;
|
|
13
|
+
};
|
|
14
|
+
export type IAutomationPipelineExecutionState = {
|
|
15
|
+
readonly trigger: AutomationRuleTrigger;
|
|
16
|
+
};
|
|
17
|
+
export interface IAutomationAction<Params = unknown> {
|
|
18
|
+
readonly type: AutomationRuleActions | string;
|
|
19
|
+
readonly paramsSchema: ZodObject<any>;
|
|
20
|
+
validateParams?: (params: Params) => Promise<void>;
|
|
21
|
+
execute(params: Params, state: IAutomationPipelineExecutionState, ctx: IQueryInfos): Promise<IActionExecutionResult | void>;
|
|
22
|
+
}
|
|
@@ -6,6 +6,7 @@ import { type IValueDomain } from '../value/valueDomain';
|
|
|
6
6
|
import { type IUserDomain } from '../user/userDomain';
|
|
7
7
|
import { type i18n } from 'i18next';
|
|
8
8
|
import { type IConfig } from '../../_types/config';
|
|
9
|
+
import { type IEventsManagerDomain } from '../../domain/eventsManager/eventsManagerDomain';
|
|
9
10
|
export interface IDiscussionDomain {
|
|
10
11
|
postDiscussionComment(params: {
|
|
11
12
|
params?: IPostDiscussionCommentParams;
|
|
@@ -17,7 +18,8 @@ export interface IDiscussionDomainDeps {
|
|
|
17
18
|
'core.domain.record': IRecordDomain;
|
|
18
19
|
'core.domain.value': IValueDomain;
|
|
19
20
|
'core.domain.user': IUserDomain;
|
|
21
|
+
'core.domain.eventsManager': IEventsManagerDomain;
|
|
20
22
|
translator: i18n;
|
|
21
23
|
config: IConfig;
|
|
22
24
|
}
|
|
23
|
-
export default function ({ 'core.domain.notification': notificationDomain, 'core.domain.record': recordDomain, 'core.domain.value': valueDomain, 'core.domain.user': userDomain, translator, config, }: IDiscussionDomainDeps): IDiscussionDomain;
|
|
25
|
+
export default function ({ 'core.domain.notification': notificationDomain, 'core.domain.record': recordDomain, 'core.domain.value': valueDomain, 'core.domain.user': userDomain, 'core.domain.eventsManager': eventsManagerDomain, translator, config, }: IDiscussionDomainDeps): IDiscussionDomain;
|
|
@@ -4,6 +4,7 @@ import { type IRecordRepo } from '../../../infra/record/recordRepo';
|
|
|
4
4
|
import { type IQueryInfos } from '../../../_types/queryInfos';
|
|
5
5
|
import { type IRecord } from '../../../_types/record';
|
|
6
6
|
import { type ICreateRecordValueError } from '../_types';
|
|
7
|
+
import { type IAutomationDomain } from '../../automation/automationDomain';
|
|
7
8
|
export type IPreCreateRecordCallback = () => Promise<ICreateRecordValueError[]>;
|
|
8
9
|
export type CreateRecordHelper = (params: {
|
|
9
10
|
library: string;
|
|
@@ -14,6 +15,7 @@ interface IDeps {
|
|
|
14
15
|
'core.domain.eventsManager': IEventsManagerDomain;
|
|
15
16
|
'core.domain.permission.library': ILibraryPermissionDomain;
|
|
16
17
|
'core.infra.record': IRecordRepo;
|
|
18
|
+
'core.domain.automation': IAutomationDomain;
|
|
17
19
|
}
|
|
18
|
-
export default function ({ 'core.domain.eventsManager': eventsManager, 'core.domain.permission.library': libraryPermissionDomain, 'core.infra.record': recordRepo, }: IDeps): CreateRecordHelper;
|
|
20
|
+
export default function ({ 'core.domain.eventsManager': eventsManager, 'core.domain.permission.library': libraryPermissionDomain, 'core.infra.record': recordRepo, 'core.domain.automation': automationDomain, }: IDeps): CreateRecordHelper;
|
|
19
21
|
export {};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { type i18n } from 'i18next';
|
|
2
|
+
import { type IAttributeDomain } from '../../attribute/attributeDomain';
|
|
3
|
+
import { type IElementAncestorsHelper } from '../../tree/helpers/elementAncestors';
|
|
4
|
+
import { type GetCoreEntityByIdFunc } from '../../helpers/getCoreEntityById';
|
|
5
|
+
import { type IValidateHelper } from '../../helpers/validate';
|
|
6
|
+
import { type FindRecordsHelper } from './findRecords';
|
|
7
|
+
import { type ICachesService } from '../../../infra/cache/cacheService';
|
|
8
|
+
import { type IQueryInfos } from '../../../_types/queryInfos';
|
|
9
|
+
import { type IRecord, type IRecordIdentity } from '../../../_types/record';
|
|
10
|
+
import { type IUtils } from '../../../utils/utils';
|
|
11
|
+
import type * as Config from '../../../_types/config';
|
|
12
|
+
import { type GetRecordFieldValueHelper } from '../../value/helpers/getRecordFieldValue';
|
|
13
|
+
export type GetRecordIdentityHelper = (record: IRecord, ctx: IQueryInfos) => Promise<IRecordIdentity>;
|
|
14
|
+
interface IDeps {
|
|
15
|
+
config: Config.IConfig;
|
|
16
|
+
'core.domain.attribute': IAttributeDomain;
|
|
17
|
+
'core.domain.value.helpers.getRecordFieldValue': GetRecordFieldValueHelper;
|
|
18
|
+
'core.domain.helpers.validate': IValidateHelper;
|
|
19
|
+
'core.domain.helpers.getCoreEntityById': GetCoreEntityByIdFunc;
|
|
20
|
+
'core.domain.tree.helpers.elementAncestors': IElementAncestorsHelper;
|
|
21
|
+
'core.domain.record.helpers.findRecords': FindRecordsHelper;
|
|
22
|
+
'core.infra.cache.cacheService': ICachesService;
|
|
23
|
+
'core.utils': IUtils;
|
|
24
|
+
translator: i18n;
|
|
25
|
+
}
|
|
26
|
+
export default function ({ config, 'core.domain.attribute': attributeDomain, 'core.domain.value.helpers.getRecordFieldValue': getRecordFieldValueHelper, 'core.domain.helpers.validate': validateHelper, 'core.domain.helpers.getCoreEntityById': getCoreEntityById, 'core.domain.tree.helpers.elementAncestors': elementAncestorsHelper, 'core.domain.record.helpers.findRecords': findRecordsHelper, 'core.infra.cache.cacheService': cacheService, 'core.utils': utils, translator, }: IDeps): GetRecordIdentityHelper;
|
|
27
|
+
export {};
|
|
@@ -2,3 +2,4 @@ export { default as createRecord } from './createRecord';
|
|
|
2
2
|
export { default as deleteRecord } from './deleteRecord';
|
|
3
3
|
export { default as sendRecordUpdateEvent } from './sendRecordUpdateEvent';
|
|
4
4
|
export { default as findRecords } from './findRecords';
|
|
5
|
+
export { default as getRecordIdentity } from './getRecordIdentity';
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import { type IEventsManagerDomain } from '../eventsManager/eventsManagerDomain';
|
|
2
|
-
import { type GetCoreEntityByIdFunc } from '../helpers/getCoreEntityById';
|
|
3
|
-
import { type IValidateHelper } from '../helpers/validate';
|
|
4
2
|
import { type IValueDomain } from '../value/valueDomain';
|
|
5
|
-
import { type i18n } from 'i18next';
|
|
6
3
|
import { type IRecordRepo } from '../../infra/record/recordRepo';
|
|
7
4
|
import { type IUtils } from '../../utils/utils';
|
|
8
|
-
import type * as Config from '../../_types/config';
|
|
9
5
|
import { type IListWithCursor } from '../../_types/list';
|
|
10
6
|
import { type ISaveValue, type IValue, type IValuesOptions } from '../../_types/value';
|
|
11
7
|
import { type ICachesService } from '../../infra/cache/cacheService';
|
|
@@ -18,9 +14,9 @@ import { type IDuplicateRecordResult, type ICreateRecordResult, type ICreateReco
|
|
|
18
14
|
import { type IFormRepo } from '../../infra/form/formRepo';
|
|
19
15
|
import { type DeleteRecordHelper } from './helpers/deleteRecord';
|
|
20
16
|
import { type CreateRecordHelper } from './helpers/createRecord';
|
|
21
|
-
import { type IElementAncestorsHelper } from '../tree/helpers/elementAncestors';
|
|
22
17
|
import { type ILogger } from '@leav/logger';
|
|
23
18
|
import { type FindRecordsHelper } from './helpers/findRecords';
|
|
19
|
+
import { type GetRecordIdentityHelper } from './helpers/getRecordIdentity';
|
|
24
20
|
export declare const ATTRIBUTE_ACTIVE = "active";
|
|
25
21
|
export interface IDuplicateRecordRules {
|
|
26
22
|
attributesToDuplicate?: Array<{
|
|
@@ -118,23 +114,19 @@ export interface IRecordDomain {
|
|
|
118
114
|
}): Promise<IDuplicateRecordResult[]>;
|
|
119
115
|
}
|
|
120
116
|
export interface IRecordDomainDeps {
|
|
121
|
-
config: Config.IConfig;
|
|
122
117
|
'core.infra.record': IRecordRepo;
|
|
123
118
|
'core.domain.attribute': IAttributeDomain;
|
|
124
119
|
'core.domain.value': IValueDomain;
|
|
125
120
|
'core.domain.permission.record': IRecordPermissionDomain;
|
|
126
|
-
'core.domain.helpers.getCoreEntityById': GetCoreEntityByIdFunc;
|
|
127
|
-
'core.domain.helpers.validate': IValidateHelper;
|
|
128
121
|
'core.domain.record.helpers.createRecord': CreateRecordHelper;
|
|
129
122
|
'core.domain.record.helpers.deleteRecord': DeleteRecordHelper;
|
|
130
123
|
'core.domain.record.helpers.findRecords': FindRecordsHelper;
|
|
124
|
+
'core.domain.record.helpers.getRecordIdentity': GetRecordIdentityHelper;
|
|
131
125
|
'core.domain.record.helpers.sendRecordUpdateEvent': SendRecordUpdateEventHelper;
|
|
132
|
-
'core.domain.tree.helpers.elementAncestors': IElementAncestorsHelper;
|
|
133
126
|
'core.infra.form': IFormRepo;
|
|
134
127
|
'core.domain.eventsManager': IEventsManagerDomain;
|
|
135
128
|
'core.infra.cache.cacheService': ICachesService;
|
|
136
129
|
'core.utils.logger': ILogger;
|
|
137
130
|
'core.utils': IUtils;
|
|
138
|
-
translator: i18n;
|
|
139
131
|
}
|
|
140
|
-
export default function ({
|
|
132
|
+
export default function ({ 'core.infra.record': recordRepo, 'core.domain.attribute': attributeDomain, 'core.domain.value': valueDomain, 'core.domain.permission.record': recordPermissionDomain, 'core.domain.record.helpers.findRecords': findRecordsHelper, 'core.domain.record.helpers.getRecordIdentity': getRecordIdentityHelper, 'core.domain.record.helpers.createRecord': createRecordHelper, 'core.domain.record.helpers.deleteRecord': deleteRecordHelper, 'core.domain.record.helpers.sendRecordUpdateEvent': sendRecordUpdateEvent, 'core.infra.form': formRepo, 'core.domain.eventsManager': eventsManager, 'core.infra.cache.cacheService': cacheService, 'core.utils.logger': logger, 'core.utils': utils, }: IRecordDomainDeps): IRecordDomain;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type ILogger } from '@leav/logger';
|
|
2
|
+
import { type IAttributeDomain } from '../../attribute/attributeDomain';
|
|
3
|
+
import { type IUtils } from '../../../utils/utils';
|
|
4
|
+
import { type IAttribute } from '../../../_types/attribute';
|
|
5
|
+
import { type IQueryInfos } from '../../../_types/queryInfos';
|
|
6
|
+
import { type IValue } from '../../../_types/value';
|
|
7
|
+
export type FormatValueHelper = (params: {
|
|
8
|
+
attribute: IAttribute;
|
|
9
|
+
value: IValue;
|
|
10
|
+
ctx: IQueryInfos;
|
|
11
|
+
}) => Promise<IValue>;
|
|
12
|
+
export interface IFormatValueHelperDeps {
|
|
13
|
+
'core.domain.attribute': IAttributeDomain;
|
|
14
|
+
'core.utils': IUtils;
|
|
15
|
+
'core.utils.logger': ILogger;
|
|
16
|
+
}
|
|
17
|
+
export default function ({ 'core.domain.attribute': attributeDomain, 'core.utils': utils, 'core.utils.logger': logger, }: IFormatValueHelperDeps): FormatValueHelper;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { type ILogger } from '@leav/logger';
|
|
2
|
+
import { type IAttributeDomain } from '../../attribute/attributeDomain';
|
|
3
|
+
import { type IRecordAttributePermissionDomain } from '../../permission/recordAttributePermissionDomain';
|
|
4
|
+
import { type GetValuesHelper } from './getValues';
|
|
5
|
+
import { type IRecordRepo } from '../../../infra/record/recordRepo';
|
|
6
|
+
import { type IQueryInfos } from '../../../_types/queryInfos';
|
|
7
|
+
import { type IRecord } from '../../../_types/record';
|
|
8
|
+
import { type IValue, type IValuesOptions } from '../../../_types/value';
|
|
9
|
+
import { type FormatValueHelper } from './formatValue';
|
|
10
|
+
import { type RunActionsListHelper } from './runActionsList';
|
|
11
|
+
export type GetRecordFieldValueHelper = (params: {
|
|
12
|
+
library: string;
|
|
13
|
+
record: IRecord;
|
|
14
|
+
attributeId: string;
|
|
15
|
+
options?: IValuesOptions;
|
|
16
|
+
ctx: IQueryInfos;
|
|
17
|
+
}) => Promise<IValue[]>;
|
|
18
|
+
export interface IGetRecordFieldValueHelperDeps {
|
|
19
|
+
'core.domain.attribute': IAttributeDomain;
|
|
20
|
+
'core.domain.permission.recordAttribute': IRecordAttributePermissionDomain;
|
|
21
|
+
'core.domain.value.helpers.getValues': GetValuesHelper;
|
|
22
|
+
'core.domain.value.helpers.runActionsList': RunActionsListHelper;
|
|
23
|
+
'core.domain.value.helpers.formatValue': FormatValueHelper;
|
|
24
|
+
'core.infra.record': IRecordRepo;
|
|
25
|
+
'core.utils.logger': ILogger;
|
|
26
|
+
}
|
|
27
|
+
export default function ({ 'core.domain.attribute': attributeDomain, 'core.domain.permission.recordAttribute': recordAttributePermissionDomain, 'core.domain.value.helpers.getValues': getValuesHelper, 'core.domain.value.helpers.runActionsList': runActionsListHelper, 'core.domain.value.helpers.formatValue': formatValueHelper, 'core.infra.record': recordRepo, 'core.utils.logger': logger, }: IGetRecordFieldValueHelperDeps): GetRecordFieldValueHelper;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { type IAttributeDomain } from '../../attribute/attributeDomain';
|
|
2
|
+
import { type IValidateHelper } from '../../helpers/validate';
|
|
3
|
+
import { type IGetDefaultElementHelper } from '../../tree/helpers/getDefaultElement';
|
|
4
|
+
import { type IElementAncestorsHelper } from '../../tree/helpers/elementAncestors';
|
|
5
|
+
import { type IVersionProfileDomain } from '../../versionProfile/versionProfileDomain';
|
|
6
|
+
import { type IValueRepo } from '../../../infra/value/valueRepo';
|
|
7
|
+
import { type IQueryInfos } from '../../../_types/queryInfos';
|
|
8
|
+
import { type IValue, type IValuesOptions } from '../../../_types/value';
|
|
9
|
+
import { type RunActionsListHelper } from './runActionsList';
|
|
10
|
+
export type GetValuesHelper = (params: {
|
|
11
|
+
library: string;
|
|
12
|
+
recordId: string;
|
|
13
|
+
attribute: string;
|
|
14
|
+
options?: IValuesOptions;
|
|
15
|
+
ctx: IQueryInfos;
|
|
16
|
+
}) => Promise<IValue[]>;
|
|
17
|
+
export interface IGetValuesHelperDeps {
|
|
18
|
+
'core.domain.attribute': IAttributeDomain;
|
|
19
|
+
'core.domain.helpers.validate': IValidateHelper;
|
|
20
|
+
'core.domain.tree.helpers.elementAncestors': IElementAncestorsHelper;
|
|
21
|
+
'core.domain.tree.helpers.getDefaultElement': IGetDefaultElementHelper;
|
|
22
|
+
'core.domain.versionProfile': IVersionProfileDomain;
|
|
23
|
+
'core.domain.value.helpers.runActionsList': RunActionsListHelper;
|
|
24
|
+
'core.infra.value': IValueRepo;
|
|
25
|
+
}
|
|
26
|
+
export default function ({ 'core.domain.attribute': attributeDomain, 'core.domain.helpers.validate': validate, 'core.domain.tree.helpers.elementAncestors': elementAncestors, 'core.domain.tree.helpers.getDefaultElement': getDefaultElementHelper, 'core.domain.versionProfile': versionProfileDomain, 'core.domain.value.helpers.runActionsList': runActionsListHelper, 'core.infra.value': valueRepo, }: IGetValuesHelperDeps): GetValuesHelper;
|
|
@@ -1 +1,8 @@
|
|
|
1
1
|
export { default as formatLogValue } from './formatLogValue';
|
|
2
|
+
export { default as formatValue } from './formatValue';
|
|
3
|
+
export type { FormatValueHelper } from './formatValue';
|
|
4
|
+
export { default as getRecordFieldValue } from './getRecordFieldValue';
|
|
5
|
+
export { default as getValues } from './getValues';
|
|
6
|
+
export type { GetValuesHelper } from './getValues';
|
|
7
|
+
export { default as runActionsList } from './runActionsList';
|
|
8
|
+
export type { RunActionsListHelper } from './runActionsList';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type IActionsListDomain } from '../../actionsList/actionsListDomain';
|
|
2
|
+
import { type IUtils } from '../../../utils/utils';
|
|
3
|
+
import { type IValue } from '../../../_types/value';
|
|
4
|
+
import { type IRunActionListParams } from '../_types';
|
|
5
|
+
export type RunActionsListHelper = (params: IRunActionListParams) => Promise<IValue[]>;
|
|
6
|
+
export interface IRunActionsListHelperDeps {
|
|
7
|
+
'core.domain.actionsList': IActionsListDomain;
|
|
8
|
+
'core.utils': IUtils;
|
|
9
|
+
}
|
|
10
|
+
export default function ({ 'core.domain.actionsList': actionsListDomain, 'core.utils': utils, }: IRunActionsListHelperDeps): RunActionsListHelper;
|