UI: Fix cycle dependency
This commit is contained in:
parent
5e3f1315f8
commit
7f747fcf1a
@ -22,8 +22,7 @@ import { EntityId } from '@shared/models/id/entity-id';
|
|||||||
import { NULL_UUID } from '@shared/models/id/has-uuid';
|
import { NULL_UUID } from '@shared/models/id/has-uuid';
|
||||||
import { BreadCrumbLabelFunction } from '@shared/components/breadcrumb';
|
import { BreadCrumbLabelFunction } from '@shared/components/breadcrumb';
|
||||||
import { EntityDetailsPageComponent } from '@home/components/entity/entity-details-page.component';
|
import { EntityDetailsPageComponent } from '@home/components/entity/entity-details-page.component';
|
||||||
import { baseDetailsPageByEntityType } from '@shared/models/constants';
|
import { EntityType, baseDetailsPageByEntityType } from '@shared/models/entity-type.models';
|
||||||
import { EntityType } from '@shared/models/entity-type.models';
|
|
||||||
|
|
||||||
const varsRegex = /\${([^}]*)}/g;
|
const varsRegex = /\${([^}]*)}/g;
|
||||||
|
|
||||||
|
|||||||
@ -16,7 +16,6 @@
|
|||||||
|
|
||||||
import { InjectionToken } from '@angular/core';
|
import { InjectionToken } from '@angular/core';
|
||||||
import { IModulesMap } from '@modules/common/modules-map.models';
|
import { IModulesMap } from '@modules/common/modules-map.models';
|
||||||
import { AliasEntityType, EntityType } from '@shared/models/entity-type.models';
|
|
||||||
|
|
||||||
export const Constants = {
|
export const Constants = {
|
||||||
serverErrorCode: {
|
serverErrorCode: {
|
||||||
@ -138,22 +137,6 @@ export const HelpLinks = {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export const baseDetailsPageByEntityType = new Map<EntityType, string>([
|
|
||||||
[EntityType.TENANT, '/tenants'],
|
|
||||||
[EntityType.TENANT_PROFILE, '/tenantProfiles'],
|
|
||||||
[EntityType.CUSTOMER, '/customers'],
|
|
||||||
[EntityType.USER, '/users'],
|
|
||||||
[EntityType.DASHBOARD, '/dashboards'],
|
|
||||||
[EntityType.ASSET, '/assets'],
|
|
||||||
[EntityType.DEVICE, '/devices'],
|
|
||||||
[EntityType.DEVICE_PROFILE, '/deviceProfiles'],
|
|
||||||
[EntityType.RULE_CHAIN, '/ruleChains'],
|
|
||||||
[EntityType.EDGE, '/edgeInstances'],
|
|
||||||
[EntityType.ENTITY_VIEW, '/entityViews'],
|
|
||||||
[EntityType.TB_RESOURCE, '/settings/resources-library'],
|
|
||||||
[EntityType.OTA_PACKAGE, '/otaUpdates']
|
|
||||||
]);
|
|
||||||
|
|
||||||
export interface ValueTypeData {
|
export interface ValueTypeData {
|
||||||
name: string;
|
name: string;
|
||||||
icon: string;
|
icon: string;
|
||||||
|
|||||||
@ -399,6 +399,22 @@ export const entityTypeResources = new Map<EntityType, EntityTypeResource<BaseDa
|
|||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
export const baseDetailsPageByEntityType = new Map<EntityType, string>([
|
||||||
|
[EntityType.TENANT, '/tenants'],
|
||||||
|
[EntityType.TENANT_PROFILE, '/tenantProfiles'],
|
||||||
|
[EntityType.CUSTOMER, '/customers'],
|
||||||
|
[EntityType.USER, '/users'],
|
||||||
|
[EntityType.DASHBOARD, '/dashboards'],
|
||||||
|
[EntityType.ASSET, '/assets'],
|
||||||
|
[EntityType.DEVICE, '/devices'],
|
||||||
|
[EntityType.DEVICE_PROFILE, '/deviceProfiles'],
|
||||||
|
[EntityType.RULE_CHAIN, '/ruleChains'],
|
||||||
|
[EntityType.EDGE, '/edgeInstances'],
|
||||||
|
[EntityType.ENTITY_VIEW, '/entityViews'],
|
||||||
|
[EntityType.TB_RESOURCE, '/settings/resources-library'],
|
||||||
|
[EntityType.OTA_PACKAGE, '/otaUpdates']
|
||||||
|
]);
|
||||||
|
|
||||||
export interface EntitySubtype {
|
export interface EntitySubtype {
|
||||||
tenantId: TenantId;
|
tenantId: TenantId;
|
||||||
entityType: EntityType;
|
entityType: EntityType;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user