@acorex-platform/module-business-core-client 0.0.18 → 0.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/acorex-platform-module-business-core-client-contracts.mjs +25 -1337
- package/fesm2022/acorex-platform-module-business-core-client-contracts.mjs.map +1 -1
- package/fesm2022/acorex-platform-module-business-core-client.mjs +33 -89
- package/fesm2022/acorex-platform-module-business-core-client.mjs.map +1 -1
- package/package.json +1 -1
- package/types/acorex-platform-module-business-core-client-contracts.d.ts +26 -25
- package/types/acorex-platform-module-business-core-client.d.ts +7 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-platform-module-business-core-client.mjs","sources":["../../../../libs/modules/business-core/client/src/lib/manifest.ts","../../../../libs/modules/business-core/client/src/lib/business-core.module.ts","../../../../libs/modules/business-core/client/src/lib/entity.provider.ts","../../../../libs/modules/business-core/client/src/lib/menu.provider.ts","../../../../libs/modules/business-core/client/src/lib/permission-definition.provider.ts","../../../../libs/modules/business-core/client/src/acorex-platform-module-business-core-client.ts"],"sourcesContent":["//#region ---- Imports ----\n\nimport { AXPModuleManifest } from '@acorex-platform/framework-client/core';\nimport { RootConfig } from '@acorex-platform/module-business-core-client/contracts';\n\n//#endregion\n\n//#region ---- Manifest Definition ----\n\n/**\n * Business Core Module Manifest.\n * Defines module metadata and dependencies.\n */\nexport const BusinessCoreManifest: 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\n // Module dependencies (optional)\n};\n\n//#endregion\n\n","//#region ---- Imports ----\n\nimport { NgModule } from '@angular/core';\nimport { AXP_MODULE_MANIFEST_PROVIDER, provideLazyProvider } from '@acorex-platform/framework-client/core';\nimport { AXP_ENTITY_DEFINITION_LOADER } from '@acorex-platform/framework-client/layout/entity';\nimport { BusinessCoreManifest } from './manifest';\nimport { AXP_MENU_PROVIDER } from '@acorex-platform/framework-client/common';\nimport { AXP_PERMISSION_DEFINITION_PROVIDER } from '@acorex-platform/framework-client/auth';\n\n//#endregion\n\n//#region ---- Module ----\n\n@NgModule({\n imports: [],\n providers: [\n\n // Module Manifest Provider\n {\n provide: AXP_MODULE_MANIFEST_PROVIDER,\n useValue: BusinessCoreManifest,\n multi: true,\n },\n // Provider references (now using tokens)\n provideLazyProvider(\n AXP_PERMISSION_DEFINITION_PROVIDER,\n () => import('./permission-definition.provider').then(m => m.AXMBusinessCorePermissionDefinitionProvider)\n ),\n provideLazyProvider(\n AXP_MENU_PROVIDER,\n () => import('./menu.provider').then(m => m.AXMBusinessCoreMenuProvider)\n ),\n provideLazyProvider(\n AXP_ENTITY_DEFINITION_LOADER,\n () => import('./entity.provider').then(m => m.AXMBusinessCoreEntityProvider)\n ),\n ],\n})\nexport class AXMBusinessCoreModule { }\n\n//#endregion\n\n","//#region ---- Imports ----\n\n\n\nimport { AXPEntity } from '@acorex-platform/framework-shared/entity';\nimport { AXPEntityDefinitionLoader } from '@acorex-platform/framework-client/layout/entity';\nimport { RootConfig } from '@acorex-platform/module-business-core-client/contracts';\n\n//#endregion\n\n//#region ---- Entity Provider ----\n\nexport class AXMBusinessCoreEntityProvider implements AXPEntityDefinitionLoader {\n async get(moduleName: string, entityName: string): Promise<AXPEntity | null> {\n if (moduleName !== RootConfig.module.name) {\n return null;\n }\n\n switch (entityName) {\n case RootConfig.entities.manufacturer.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).manufacturerFactory();\n\n case RootConfig.entities.industry.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).industryFactory();\n\n case RootConfig.entities.businessType.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).businessTypeFactory();\n\n case RootConfig.entities.businessStatus.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).businessStatusFactory();\n\n case RootConfig.entities.partyType.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).partyTypeFactory();\n\n case RootConfig.entities.partySegment.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).partySegmentFactory();\n\n case RootConfig.entities.lifecycleStage.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).lifecycleStageFactory();\n\n case RootConfig.entities.party.name:\n return (await import('@acorex-platform/module-business-core-client/contracts')).partyFactory();\n\n }\n\n return null;\n }\n\n async list(): Promise<{ name: string; module: string }[]> {\n const m = RootConfig.module.name;\n return Promise.resolve(\n Object.values(RootConfig.entities).map((e) => ({ name: e.name, module: m }))\n );\n }\n}\n\n//#endregion\n\n","//#region ---- Imports ----\n\nimport { AXPMenuProvider, AXPMenuProviderContext } from '@acorex-platform/framework-client/common';\nimport { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';\nimport { inject } from '@angular/core';\nimport { RootConfig } from '@acorex-platform/module-business-core-client/contracts';\nimport { AXMBusinessCoreMenuKeys } from '@acorex-platform/module-business-core-client/contracts';\nimport { AXPCommonMenuKeys } from '@acorex-platform/module-common-client/contracts';\nimport { AXMBusinessCorePermissionKeys } from '@acorex-platform/module-business-core-client/contracts';\n\n//#endregion\n\n//#region ---- Menu Provider ----\n\nexport class AXMBusinessCoreMenuProvider implements AXPMenuProvider {\n private readonly entityService = inject(AXPEntityService);\n\n async provide(context: AXPMenuProviderContext): Promise<void> {\n const module = RootConfig.module;\n\n context.find(AXPCommonMenuKeys.Configuration).addItems([\n {\n name: AXMBusinessCoreMenuKeys.Root,\n priority: 8500,\n text: \"@business-core:module.menus.root.title\",\n icon: module.icon,\n policy: {\n features: [RootConfig.module.name],\n },\n children: [\n {\n name: AXMBusinessCoreMenuKeys.Manufacturers,\n text: RootConfig.entities.manufacturer.titlePlural,\n icon: RootConfig.entities.manufacturer.icon,\n priority: 1,\n path: this.entityService.withEntity(module.name, RootConfig.entities.manufacturer.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.Manufacturer.Management],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.Divider1,\n text: '',\n type: 'break',\n priority: 2,\n },\n {\n name: AXMBusinessCoreMenuKeys.Industries,\n text: RootConfig.entities.industry.titlePlural,\n icon: RootConfig.entities.industry.icon,\n priority: 3,\n path: this.entityService.withEntity(module.name, RootConfig.entities.industry.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.Industry.Management],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.BusinessTypes,\n text: RootConfig.entities.businessType.titlePlural,\n icon: RootConfig.entities.businessType.icon,\n priority: 4,\n path: this.entityService.withEntity(module.name, RootConfig.entities.businessType.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.BusinessType.Management],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.BusinessStatuses,\n text: RootConfig.entities.businessStatus.titlePlural,\n icon: RootConfig.entities.businessStatus.icon,\n priority: 5,\n path: this.entityService.withEntity(module.name, RootConfig.entities.businessStatus.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.BusinessStatus.Management],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.Divider2,\n text: '',\n type: 'break',\n priority: 6,\n },\n {\n name: AXMBusinessCoreMenuKeys.PartyTypes,\n text: RootConfig.entities.partyType.titlePlural,\n icon: RootConfig.entities.partyType.icon,\n priority: 7,\n path: this.entityService.withEntity(module.name, RootConfig.entities.partyType.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.PartyType.Management],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.PartySegments,\n text: RootConfig.entities.partySegment.titlePlural,\n icon: RootConfig.entities.partySegment.icon,\n priority: 8,\n path: this.entityService.withEntity(module.name, RootConfig.entities.partySegment.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.PartySegment.Management],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.LifecycleStages,\n text: RootConfig.entities.lifecycleStage.titlePlural,\n icon: RootConfig.entities.lifecycleStage.icon,\n priority: 9,\n path: this.entityService.withEntity(module.name, RootConfig.entities.lifecycleStage.name).createPath(),\n policy: {\n permissions: [AXMBusinessCorePermissionKeys.BusinessCore.LifecycleStage.Management],\n },\n },\n ],\n },\n ]);\n }\n}\n\n//#endregion\n\n","//#region ---- Imports ----\n\nimport { AXTranslationService } from '@acorex/core/translation';\nimport { AXPPermissionDefinitionProvider, AXPPermissionDefinitionProviderContext } from '@acorex-platform/framework-client/auth';\nimport { inject } from '@angular/core';\nimport { AXMBusinessCorePermissionKeys } from '@acorex-platform/module-business-core-client/contracts';\nimport { RootConfig } from '@acorex-platform/module-business-core-client/contracts';\n\n//#endregion\n\n//#region ---- Permission Definition Provider ----\n\nexport class AXMBusinessCorePermissionDefinitionProvider implements AXPPermissionDefinitionProvider {\n private readonly translationService = inject(AXTranslationService);\n\n async define(context: AXPPermissionDefinitionProviderContext): Promise<void> {\n const keys = AXMBusinessCorePermissionKeys.BusinessCore;\n const moduleTitle = await this.translationService.translateAsync('@business-core:module.title');\n\n const manufacturerTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:manufacturers.permissions.manufacturer.${action}.title`);\n\n const industryTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:industries.permissions.industry.${action}.title`);\n\n const businessTypeTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:business-types.permissions.business-type.${action}.title`);\n\n const businessStatusTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:business-statuses.permissions.business-status.${action}.title`);\n\n const partyTypeTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:party-types.permissions.party-type.${action}.title`);\n\n const partySegmentTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:party-segments.permissions.party-segment.${action}.title`);\n\n const lifecycleStageTrans = (action: string) =>\n this.translationService.translateAsync(`@business-core:lifecycle-stages.permissions.lifecycle-stage.${action}.title`);\n\n context\n .addGroup(RootConfig.module.name, moduleTitle)\n\n .addPermission(keys.Manufacturer.Management, await manufacturerTrans('manage'))\n .endPermission()\n\n .addPermission(keys.Industry.Management, await industryTrans('manage'))\n .endPermission()\n\n .addPermission(keys.BusinessType.Management, await businessTypeTrans('manage'))\n .endPermission()\n\n .addPermission(keys.BusinessStatus.Management, await businessStatusTrans('manage'))\n .endPermission()\n\n .addPermission(keys.PartyType.Management, await partyTypeTrans('manage'))\n .endPermission()\n\n .addPermission(keys.PartySegment.Management, await partySegmentTrans('manage'))\n .endPermission()\n\n .addPermission(keys.LifecycleStage.Management, await lifecycleStageTrans('manage'))\n .endPermission()\n\n .endGroup();\n }\n}\n\n//#endregion\n\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AAAA;AAKA;AAEA;AAEA;;;AAGG;AACI,MAAM,oBAAoB,GAAsB;AACnD,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;;CAG/B;AAED;;ACvBA;AASA;AAEA;MA2Ba,qBAAqB,CAAA;8GAArB,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAArB,qBAAqB,EAAA,CAAA,CAAA;AAArB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,qBAAqB,EAAA,SAAA,EAvBnB;;AAGP,YAAA;AACI,gBAAA,OAAO,EAAE,4BAA4B;AACrC,gBAAA,QAAQ,EAAE,oBAAoB;AAC9B,gBAAA,KAAK,EAAE,I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QAAQ,CAAC;AAC7E,aAAA,aAAa;AAEb,aAAA,aAAa,CAAC,IAAI,CAAC,cAAc,CAAC,UAAU,EAAE,MAAM,mBAAmB,CAAC,QAAQ,CAAC;AACjF,aAAA,aAAa;AAEb,aAAA,aAAa,CAAC,IAAI,CAAC,SAAS,CAAC,UAAU,EAAE,MAAM,cAAc,CAAC,QAAQ,CAAC;AACvE,aAAA,aAAa;AAEb,aAAA,aAAa,CAAC,IAAI,CAAC,YAAY,CAAC,UAAU,EAAE,MAAM,iBAAiB,CAAC,QAAQ,CAAC;AAC7E,aAAA,aAAa;AAEb,aAAA,aAAa,CAAC,IAAI,CAAC,cAAc,CAAC,UAAU,EAAE,MAAM,mBAAmB,CAAC,QAAQ,CAAC;AACjF,aAAA,aAAa;AAEb,aAAA,QAAQ,EAAE;IACnB;AACH;AAED;;;;;;;ACpEA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"acorex-platform-module-business-core-client.mjs","sources":["../../../../libs/modules/business-core/client/src/lib/manifest.ts","../../../../libs/modules/business-core/client/src/lib/business-core.module.ts","../../../../libs/modules/business-core/client/src/lib/menu.provider.ts","../../../../libs/modules/business-core/client/src/lib/permission-definition.provider.ts","../../../../libs/modules/business-core/client/src/acorex-platform-module-business-core-client.ts"],"sourcesContent":["//#region ---- Imports ----\n\nimport { AXPModuleManifest } from '@acorex-platform/framework-client/core';\nimport { RootConfig } from '@acorex-platform/module-business-core-client/contracts';\n\n//#endregion\n\n//#region ---- Manifest Definition ----\n\n/**\n * Business Core Module Manifest.\n * Defines module metadata and dependencies.\n */\nexport const BusinessCoreManifest: 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\n type: 'domain',\n domain: 'finance-commerce',\n // Module dependencies (optional)\n};\n\n//#endregion\n\n","//#region ---- Imports ----\n\nimport { NgModule } from '@angular/core';\nimport { AXP_MODULE_MANIFEST_PROVIDER, provideLazyProvider } from '@acorex-platform/framework-client/core';\nimport { BusinessCoreManifest } from './manifest';\nimport { AXP_MENU_PROVIDER } from '@acorex-platform/framework-client/common';\nimport { AXP_PERMISSION_DEFINITION_PROVIDER } from '@acorex-platform/framework-client/auth';\n\n//#endregion\n\n//#region ---- Module ----\n\n@NgModule({\n imports: [],\n providers: [\n\n // Module Manifest Provider\n {\n provide: AXP_MODULE_MANIFEST_PROVIDER,\n useValue: BusinessCoreManifest,\n multi: true,\n },\n // Provider references (now using tokens)\n provideLazyProvider(\n AXP_PERMISSION_DEFINITION_PROVIDER,\n () => import('./permission-definition.provider').then(m => m.AXMBusinessCorePermissionDefinitionProvider)\n ),\n provideLazyProvider(\n AXP_MENU_PROVIDER,\n () => import('./menu.provider').then(m => m.AXMBusinessCoreMenuProvider)\n ),\n \n ],\n})\nexport class AXMBusinessCoreModule { }\n\n//#endregion\n\n","//#region ---- Imports ----\n\nimport { AXPMenuProvider, AXPMenuProviderContext } from '@acorex-platform/framework-client/common';\nimport { AXPEntityService } from '@acorex-platform/framework-client/layout/entity';\nimport {\n RootConfig,\n AXPSalesCustomersPermissionKeys\n} from '@acorex-platform/module-business-core-client/contracts';\nimport { AXMBusinessCoreMenuKeys } from '@acorex-platform/module-business-core-client/contracts';\nimport {\n AXPCommonMenuKeys\n} from '@acorex-platform/module-common-client/contracts';\nimport { inject } from '@angular/core';\n\n//#endregion\n\n//#region ---- Menu Provider ----\n\nexport class AXMBusinessCoreMenuProvider implements AXPMenuProvider {\n private readonly entityService = inject(AXPEntityService);\n\n async provide(context: AXPMenuProviderContext): Promise<void> {\n const module = RootConfig.module;\n const keys = AXPSalesCustomersPermissionKeys;\n\n context.find(AXPCommonMenuKeys.Configuration).addItems([\n {\n name: AXMBusinessCoreMenuKeys.Root,\n priority: 8500,\n text: \"@business-core:module.menus.root.title\",\n icon: module.icon,\n policy: {\n features: [RootConfig.module.name],\n },\n children: [\n {\n name: AXMBusinessCoreMenuKeys.Manufacturers,\n text: RootConfig.entities.manufacturer.titlePlural,\n icon: RootConfig.entities.manufacturer.icon,\n priority: 1,\n path: this.entityService.withEntity(module.name, RootConfig.entities.manufacturer.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.Divider1,\n text: '',\n type: 'break',\n priority: 2,\n },\n {\n name: AXMBusinessCoreMenuKeys.Industries,\n text: RootConfig.entities.industry.titlePlural,\n icon: RootConfig.entities.industry.icon,\n priority: 3,\n path: this.entityService.withEntity(module.name, RootConfig.entities.industry.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.BusinessTypes,\n text: RootConfig.entities.businessType.titlePlural,\n icon: RootConfig.entities.businessType.icon,\n priority: 4,\n path: this.entityService.withEntity(module.name, RootConfig.entities.businessType.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.BusinessStatuses,\n text: RootConfig.entities.businessStatus.titlePlural,\n icon: RootConfig.entities.businessStatus.icon,\n priority: 5,\n path: this.entityService.withEntity(module.name, RootConfig.entities.businessStatus.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.Divider2,\n text: '',\n type: 'break',\n priority: 6,\n },\n {\n name: AXMBusinessCoreMenuKeys.PartyTypes,\n text: RootConfig.entities.partyType.titlePlural,\n icon: RootConfig.entities.partyType.icon,\n priority: 7,\n path: this.entityService.withEntity(module.name, RootConfig.entities.partyType.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.PartySegments,\n text: RootConfig.entities.partySegment.titlePlural,\n icon: RootConfig.entities.partySegment.icon,\n priority: 8,\n path: this.entityService.withEntity(module.name, RootConfig.entities.partySegment.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n {\n name: AXMBusinessCoreMenuKeys.LifecycleStages,\n text: RootConfig.entities.lifecycleStage.titlePlural,\n icon: RootConfig.entities.lifecycleStage.icon,\n priority: 9,\n path: this.entityService.withEntity(module.name, RootConfig.entities.lifecycleStage.name).createPath(),\n policy: {\n permissions: [keys.Setup],\n },\n },\n ],\n },\n ]);\n }\n}\n\n//#endregion\n","//#region ---- Imports ----\n\nimport {\n AXPPermissionDefinitionProvider,\n AXPPermissionDefinitionProviderContext,\n} from '@acorex-platform/framework-client/auth';\nimport { AXPCommonPermissionGroupKeys } from '@acorex-platform/module-common-client/contracts';\nimport { Injectable } from '@angular/core';\n\n//#endregion\n\n//#region ---- Permission Definition Provider ----\n\n/**\n * Ensures Sales & Customers root + Customers section exist for business-core\n * (Setup owned by customer-management).\n */\n@Injectable()\nexport class AXMBusinessCorePermissionDefinitionProvider implements AXPPermissionDefinitionProvider {\n async define(context: AXPPermissionDefinitionProviderContext): Promise<void> {\n const groups = AXPCommonPermissionGroupKeys;\n const G = '@common:permission-groups';\n\n context.addGroup(\n groups.SalesCustomers.Root,\n `${G}.sales-and-customers.title`,\n `${G}.sales-and-customers.description`,\n { order: 50 },\n );\n context\n .addGroup(\n groups.SalesCustomers.Customers,\n `${G}.sales-and-customers-customers.title`,\n `${G}.sales-and-customers-customers.description`,\n { parent: groups.SalesCustomers.Root, order: 10 },\n )\n .endGroup();\n }\n}\n\n//#endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAAA;AAKA;AAEA;AAEA;;;AAGG;AACI,MAAM,oBAAoB,GAAsB;AACnD,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;AAE9B,IAAA,IAAI,EAAE,QAAQ;AACd,IAAA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CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,EAAE;AAElD,aAAA,QAAQ,EAAE;IACf;8GAnBW,2CAA2C,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;kHAA3C,2CAA2C,EAAA,CAAA,CAAA;;2FAA3C,2CAA2C,EAAA,UAAA,EAAA,CAAA;kBADvD;;;;;;;;ACjBD;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AXPEntity, AXPEntityModel } from '@acorex-platform/framework-shared/entity';
|
|
2
1
|
import { AXPMultiLanguageString, AXPCategoryListItem } from '@acorex-platform/framework-shared/core';
|
|
2
|
+
import { AXPEntityModel } from '@acorex-platform/framework-shared/entity';
|
|
3
3
|
|
|
4
4
|
declare const AXMBusinessCoreMenuKeys: {
|
|
5
5
|
readonly Root: "business-core";
|
|
@@ -14,28 +14,45 @@ declare const AXMBusinessCoreMenuKeys: {
|
|
|
14
14
|
readonly LifecycleStages: "business-core.lifecycle-stages";
|
|
15
15
|
};
|
|
16
16
|
|
|
17
|
+
/**
|
|
18
|
+
* Sales & Customers capabilities used by this module.
|
|
19
|
+
* Domain capability keys for this module. Root groups live in `AXPCommonPermissionGroupKeys` (common contracts).
|
|
20
|
+
*/
|
|
21
|
+
declare const AXPSalesCustomersPermissionKeys: {
|
|
22
|
+
readonly Access: "SalesCustomers:Permission:Access";
|
|
23
|
+
readonly MaintainCustomers: "SalesCustomers:Permission:MaintainCustomers";
|
|
24
|
+
readonly MaintainSales: "SalesCustomers:Permission:MaintainSales";
|
|
25
|
+
readonly MaintainProducts: "SalesCustomers:Permission:MaintainProducts";
|
|
26
|
+
readonly MaintainOrders: "SalesCustomers:Permission:MaintainOrders";
|
|
27
|
+
readonly MaintainSubscriptions: "SalesCustomers:Permission:MaintainSubscriptions";
|
|
28
|
+
readonly Setup: "SalesCustomers:Permission:Setup";
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* @deprecated Prefer {@link AXPSalesCustomersPermissionKeys}.
|
|
32
|
+
* Legacy nested shape kept so existing imports compile during migration.
|
|
33
|
+
*/
|
|
17
34
|
declare const AXMBusinessCorePermissionKeys: {
|
|
18
35
|
readonly BusinessCore: {
|
|
19
36
|
readonly Manufacturer: {
|
|
20
|
-
readonly Management: "
|
|
37
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
21
38
|
};
|
|
22
39
|
readonly Industry: {
|
|
23
|
-
readonly Management: "
|
|
40
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
24
41
|
};
|
|
25
42
|
readonly BusinessType: {
|
|
26
|
-
readonly Management: "
|
|
43
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
27
44
|
};
|
|
28
45
|
readonly BusinessStatus: {
|
|
29
|
-
readonly Management: "
|
|
46
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
30
47
|
};
|
|
31
48
|
readonly PartyType: {
|
|
32
|
-
readonly Management: "
|
|
49
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
33
50
|
};
|
|
34
51
|
readonly PartySegment: {
|
|
35
|
-
readonly Management: "
|
|
52
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
36
53
|
};
|
|
37
54
|
readonly LifecycleStage: {
|
|
38
|
-
readonly Management: "
|
|
55
|
+
readonly Management: "SalesCustomers:Permission:Setup";
|
|
39
56
|
};
|
|
40
57
|
};
|
|
41
58
|
};
|
|
@@ -102,8 +119,6 @@ declare const RootConfig: {
|
|
|
102
119
|
};
|
|
103
120
|
};
|
|
104
121
|
|
|
105
|
-
declare function businessStatusFactory(): Promise<AXPEntity>;
|
|
106
|
-
|
|
107
122
|
interface AXMBusinessCoreBusinessStatusEntityModel extends AXPEntityModel<string> {
|
|
108
123
|
code: string;
|
|
109
124
|
title: AXPMultiLanguageString;
|
|
@@ -111,8 +126,6 @@ interface AXMBusinessCoreBusinessStatusEntityModel extends AXPEntityModel<string
|
|
|
111
126
|
isDisabled?: boolean;
|
|
112
127
|
}
|
|
113
128
|
|
|
114
|
-
declare function businessTypeFactory(): Promise<AXPEntity>;
|
|
115
|
-
|
|
116
129
|
interface AXMBusinessCoreBusinessTypeEntityModel extends AXPEntityModel<string> {
|
|
117
130
|
code: string;
|
|
118
131
|
title: AXPMultiLanguageString;
|
|
@@ -120,8 +133,6 @@ interface AXMBusinessCoreBusinessTypeEntityModel extends AXPEntityModel<string>
|
|
|
120
133
|
isDisabled?: boolean;
|
|
121
134
|
}
|
|
122
135
|
|
|
123
|
-
declare function industryFactory(): Promise<AXPEntity>;
|
|
124
|
-
|
|
125
136
|
interface AXMBusinessCoreIndustryEntityModel extends AXPEntityModel<string> {
|
|
126
137
|
code: string;
|
|
127
138
|
title: AXPMultiLanguageString;
|
|
@@ -129,16 +140,12 @@ interface AXMBusinessCoreIndustryEntityModel extends AXPEntityModel<string> {
|
|
|
129
140
|
isDisabled?: boolean;
|
|
130
141
|
}
|
|
131
142
|
|
|
132
|
-
declare function lifecycleStageFactory(): Promise<AXPEntity>;
|
|
133
|
-
|
|
134
143
|
interface AXMBusinessCoreLifecycleStageEntityModel extends AXPEntityModel<string> {
|
|
135
144
|
title: AXPMultiLanguageString;
|
|
136
145
|
description?: AXPMultiLanguageString | null;
|
|
137
146
|
order?: number;
|
|
138
147
|
}
|
|
139
148
|
|
|
140
|
-
declare function manufacturerFactory(): Promise<AXPEntity | null>;
|
|
141
|
-
|
|
142
149
|
interface AXMBusinessCoreManufacturerEntityModel extends AXPEntityModel<string> {
|
|
143
150
|
code: string;
|
|
144
151
|
title: AXPMultiLanguageString;
|
|
@@ -153,8 +160,6 @@ interface AXMBusinessCoreManufacturerEntityModel extends AXPEntityModel<string>
|
|
|
153
160
|
categories?: AXPCategoryListItem[];
|
|
154
161
|
}
|
|
155
162
|
|
|
156
|
-
declare function partyFactory(): Promise<AXPEntity>;
|
|
157
|
-
|
|
158
163
|
interface AXMBusinessCorePartyEntityModel extends AXPEntityModel<string> {
|
|
159
164
|
code: string;
|
|
160
165
|
title: AXPMultiLanguageString;
|
|
@@ -172,8 +177,6 @@ interface AXMBusinessCorePartyEntityModel extends AXPEntityModel<string> {
|
|
|
172
177
|
}>;
|
|
173
178
|
}
|
|
174
179
|
|
|
175
|
-
declare function partySegmentFactory(): Promise<AXPEntity>;
|
|
176
|
-
|
|
177
180
|
interface AXMBusinessCorePartySegmentEntityModel extends AXPEntityModel<string> {
|
|
178
181
|
title: AXPMultiLanguageString;
|
|
179
182
|
description?: AXPMultiLanguageString | null;
|
|
@@ -181,8 +184,6 @@ interface AXMBusinessCorePartySegmentEntityModel extends AXPEntityModel<string>
|
|
|
181
184
|
isArchived?: boolean;
|
|
182
185
|
}
|
|
183
186
|
|
|
184
|
-
declare function partyTypeFactory(): Promise<AXPEntity>;
|
|
185
|
-
|
|
186
187
|
interface AXMBusinessCorePartyTypeEntityModel extends AXPEntityModel<string> {
|
|
187
188
|
code: string;
|
|
188
189
|
title: AXPMultiLanguageString;
|
|
@@ -190,5 +191,5 @@ interface AXMBusinessCorePartyTypeEntityModel extends AXPEntityModel<string> {
|
|
|
190
191
|
isDisabled?: boolean;
|
|
191
192
|
}
|
|
192
193
|
|
|
193
|
-
export { AXMBusinessCoreMenuKeys, AXMBusinessCorePermissionKeys,
|
|
194
|
+
export { AXMBusinessCoreMenuKeys, AXMBusinessCorePermissionKeys, AXPSalesCustomersPermissionKeys, RootConfig };
|
|
194
195
|
export type { AXMBusinessCoreBusinessStatusEntityModel, AXMBusinessCoreBusinessTypeEntityModel, AXMBusinessCoreIndustryEntityModel, AXMBusinessCoreLifecycleStageEntityModel, AXMBusinessCoreManufacturerEntityModel, AXMBusinessCorePartyEntityModel, AXMBusinessCorePartySegmentEntityModel, AXMBusinessCorePartyTypeEntityModel };
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { AXPEntity } from '@acorex-platform/framework-shared/entity';
|
|
3
|
-
import { AXPEntityDefinitionLoader } from '@acorex-platform/framework-client/layout/entity';
|
|
4
2
|
import { AXPMenuProvider, AXPMenuProviderContext } from '@acorex-platform/framework-client/common';
|
|
5
3
|
import { AXPPermissionDefinitionProvider, AXPPermissionDefinitionProviderContext } from '@acorex-platform/framework-client/auth';
|
|
6
4
|
|
|
@@ -10,22 +8,19 @@ declare class AXMBusinessCoreModule {
|
|
|
10
8
|
static ɵinj: i0.ɵɵInjectorDeclaration<AXMBusinessCoreModule>;
|
|
11
9
|
}
|
|
12
10
|
|
|
13
|
-
declare class AXMBusinessCoreEntityProvider implements AXPEntityDefinitionLoader {
|
|
14
|
-
get(moduleName: string, entityName: string): Promise<AXPEntity | null>;
|
|
15
|
-
list(): Promise<{
|
|
16
|
-
name: string;
|
|
17
|
-
module: string;
|
|
18
|
-
}[]>;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
11
|
declare class AXMBusinessCoreMenuProvider implements AXPMenuProvider {
|
|
22
12
|
private readonly entityService;
|
|
23
13
|
provide(context: AXPMenuProviderContext): Promise<void>;
|
|
24
14
|
}
|
|
25
15
|
|
|
16
|
+
/**
|
|
17
|
+
* Ensures Sales & Customers root + Customers section exist for business-core
|
|
18
|
+
* (Setup owned by customer-management).
|
|
19
|
+
*/
|
|
26
20
|
declare class AXMBusinessCorePermissionDefinitionProvider implements AXPPermissionDefinitionProvider {
|
|
27
|
-
private readonly translationService;
|
|
28
21
|
define(context: AXPPermissionDefinitionProviderContext): Promise<void>;
|
|
22
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AXMBusinessCorePermissionDefinitionProvider, never>;
|
|
23
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AXMBusinessCorePermissionDefinitionProvider>;
|
|
29
24
|
}
|
|
30
25
|
|
|
31
|
-
export {
|
|
26
|
+
export { AXMBusinessCoreMenuProvider, AXMBusinessCoreModule, AXMBusinessCorePermissionDefinitionProvider };
|