(()=>{function o(o,n,t,e){var r={anyRole:["ROLE_DATA_BROKER_READ","ROLE_DATA_BROKER_ADMIN"]};function c(o){return o.isAvailable({key:"c8y-feature-broker"})}o.addNavigation({name:e("Data connectors"),parent:{name:e("Data broker"),icon:"c8y-data-broker"},icon:"c8y-connector-out",priority:1e3,path:t.CONNECTOR_BASE_URL,showIfPermissions:r,showIf:["$q","c8yTenant","c8yApplication",function(o,n,t){return o.all({topTenant:n.isCurrentUserTopTenant(),featureAvailable:c(t)}).then(function(o){return!o.topTenant&&o.featureAvailable})}]}),n.when(t.CONNECTOR_BASE_URL,{template:"<c8y-data-broker-connectors-list />",name:e("Connectors"),icon:"c8y-connector-out",priority:2e3}),n.when("".concat(t.CONNECTOR_BASE_URL,"/:connectorId"),{template:'<c8y-data-broker-connector-alarms id="vm.connectorId"/>',controller:["$routeParams",function(o){this.connectorId=o.connectorId}],controllerAs:"vm",name:e("Alarms"),icon:"warning",priority:1e3,showIf:["$routeParams",function(o){return"new"!==o.connectorId}]}),n.when("".concat(t.CONNECTOR_BASE_URL,"/:connectorId"),{template:'<c8y-data-broker-connector-editor id="vm.connectorId" />',controller:["$routeParams",function(o){this.connectorId=o.connectorId}],controllerAs:"vm",name:e("Settings"),priority:2e3,icon:"cog"}),n.when("".concat(t.CONNECTOR_BASE_URL,"/:connectorId/duplicate"),{template:'<c8y-data-broker-connector-editor duplicate-id="vm.connectorId" />',controller:["$routeParams",function(o){this.connectorId=o.connectorId}],controllerAs:"vm"}),o.addNavigation({name:e("Data subscriptions"),parent:e("Data broker"),icon:"c8y-connector-in",priority:1e3,path:t.SUBSCRIPTION_BASE_URL,showIfPermissions:r,showIf:["c8yApplication",c]}),n.when(t.SUBSCRIPTION_BASE_URL,{template:"<c8y-data-broker-subscriptions></c8y-data-broker-subscriptions>"})}o.$inject=["c8yNavigatorProvider","c8yViewsProvider","dataBrokerConstants","gettext"],angular.module("c8y.dataBroker").config(o)})();