@c8y/ngx-components
Version:
Angular modules for Cumulocity IoT applications
79 lines (75 loc) • 2.77 kB
JavaScript
import { gettext, ViewContext, NavigatorNode } from '@c8y/ngx-components';
import { AlarmsModule, getChildrenForViewContext, AlarmsComponent, ALARMS_PATH, getViewContextRoutes } from '@c8y/ngx-components/alarms';
function alarmsDeviceManagementRouteAndNodeConfig() {
return AlarmsModule.config({
rootNavigatorNode: new NavigatorNode({
label: gettext('Alarms'),
icon: 'bell',
priority: 3000,
path: `/${ALARMS_PATH}`,
featureId: 'alarms',
parent: 'Overviews',
routerLinkExact: false
}),
route: [
{
path: ALARMS_PATH,
component: AlarmsComponent,
data: { title: true },
children: getChildrenForViewContext(ViewContext.Alarms)
},
{
context: ViewContext.Group,
path: ALARMS_PATH,
priority: 800,
icon: 'bell',
label: gettext('Alarms'),
component: AlarmsComponent,
featureId: 'alarms',
children: getChildrenForViewContext(ViewContext.GroupAlarms)
},
{
context: ViewContext.Device,
path: ALARMS_PATH,
priority: 800,
icon: 'bell',
label: gettext('Alarms'),
component: AlarmsComponent,
featureId: 'alarms',
children: getChildrenForViewContext(ViewContext.DeviceAlarms)
},
{
context: ViewContext.Service,
path: ALARMS_PATH,
priority: 800,
icon: 'bell',
label: gettext('Alarms'),
component: AlarmsComponent,
featureId: 'alarms',
children: getChildrenForViewContext(ViewContext.ServiceAlarms)
},
{
context: ViewContext.Simulators,
path: ALARMS_PATH,
priority: -2,
icon: 'bell',
label: gettext('Alarms'),
component: AlarmsComponent,
featureId: 'alarms',
children: getChildrenForViewContext(ViewContext.SimulatorsAlarms)
},
...getViewContextRoutes([
ViewContext.Alarms,
ViewContext.GroupAlarms,
ViewContext.DeviceAlarms,
ViewContext.ServiceAlarms,
ViewContext.SimulatorsAlarms
])
]
});
}
/**
* Generated bundle index. Do not edit.
*/
export { alarmsDeviceManagementRouteAndNodeConfig };
//# sourceMappingURL=c8y-ngx-components-alarms-devicemanagement.mjs.map