@c8y/ngx-components 1018.0.194 → 1018.0.196
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/core/common/global-config.service.d.ts +1 -1
- package/core/common/permissions.service.d.ts +67 -0
- package/core/common/tenant-ui.service.d.ts +1 -1
- package/esm2020/assets-navigator/asset-node.service.mjs +5 -4
- package/esm2020/auth-configuration/auth-configuration.guard.mjs +5 -2
- package/esm2020/auth-configuration/factories/navigation.factory.mjs +3 -3
- package/esm2020/cockpit-config/cockpit-config.guard.mjs +2 -2
- package/esm2020/cockpit-config/cockpit-config.service.mjs +2 -2
- package/esm2020/context-dashboard/add-dashboard.factory.mjs +6 -3
- package/esm2020/context-dashboard/context-dashboard.service.mjs +3 -3
- package/esm2020/context-dashboard/dashboard-detail.component.mjs +2 -2
- package/esm2020/context-dashboard/report-dashboard/report-dashboard-list.component.mjs +3 -3
- package/esm2020/core/common/global-config.service.mjs +3 -2
- package/esm2020/core/common/permissions.service.mjs +68 -1
- package/esm2020/core/common/tenant-ui.service.mjs +3 -2
- package/esm2020/core/common/user-preferences/user-preferences.service.mjs +6 -2
- package/esm2020/ecosystem/application-properties/application-properties.component.mjs +2 -2
- package/esm2020/ecosystem/ecosystem-navigation.factory.mjs +3 -3
- package/esm2020/ecosystem/packages/package-list/packages-list.component.mjs +2 -2
- package/esm2020/ecosystem/packages/package-versions/package-versions-list/package-versions-list.component.mjs +2 -2
- package/esm2020/files-repository/files-repository.guard.mjs +5 -3
- package/esm2020/protocol-lwm2m/components/bootstrap-parameters/lwm2m-bootstrap-parameters.component.mjs +2 -2
- package/esm2020/register-device/register-device-navigation.factory.mjs +3 -3
- package/esm2020/reports/export-schedules.component.mjs +3 -3
- package/esm2020/repository/configuration/device-tab/configuration-preview.component.mjs +4 -4
- package/esm2020/sms-gateway/sms-gateway.guard.mjs +2 -2
- package/esm2020/sms-gateway/sms-gateway.module.mjs +6 -6
- package/esm2020/sub-assets/add-group/add-group.component.mjs +2 -2
- package/esm2020/sub-assets/groups.component.mjs +2 -2
- package/esm2020/sub-assets/sub-assets.component.mjs +2 -2
- package/esm2020/sub-assets/sub-assets.service.mjs +16 -10
- package/esm2020/tenants/tenant-list/tenant-list.component.mjs +12 -7
- package/esm2020/upgrade/ng1/downgraded.services.mjs +3 -2
- package/esm2020/upgrade/ng1/index.mjs +4 -3
- package/fesm2015/c8y-ngx-components-assets-navigator.mjs +4 -3
- package/fesm2015/c8y-ngx-components-assets-navigator.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-auth-configuration.mjs +7 -4
- package/fesm2015/c8y-ngx-components-auth-configuration.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-cockpit-config.mjs +3 -3
- package/fesm2015/c8y-ngx-components-cockpit-config.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-context-dashboard.mjs +11 -8
- package/fesm2015/c8y-ngx-components-context-dashboard.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-ecosystem.mjs +6 -6
- package/fesm2015/c8y-ngx-components-ecosystem.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-files-repository.mjs +5 -3
- package/fesm2015/c8y-ngx-components-files-repository.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-protocol-lwm2m-components-bootstrap-parameters.mjs +2 -2
- package/fesm2015/c8y-ngx-components-protocol-lwm2m-components-bootstrap-parameters.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-register-device.mjs +3 -3
- package/fesm2015/c8y-ngx-components-register-device.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-reports.mjs +2 -2
- package/fesm2015/c8y-ngx-components-reports.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-repository-configuration.mjs +3 -3
- package/fesm2015/c8y-ngx-components-repository-configuration.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-sms-gateway.mjs +6 -6
- package/fesm2015/c8y-ngx-components-sms-gateway.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-sub-assets.mjs +19 -13
- package/fesm2015/c8y-ngx-components-sub-assets.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-tenants.mjs +11 -6
- package/fesm2015/c8y-ngx-components-tenants.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-upgrade.mjs +4 -2
- package/fesm2015/c8y-ngx-components-upgrade.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components.mjs +74 -3
- package/fesm2015/c8y-ngx-components.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-assets-navigator.mjs +4 -3
- package/fesm2020/c8y-ngx-components-assets-navigator.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-auth-configuration.mjs +7 -4
- package/fesm2020/c8y-ngx-components-auth-configuration.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-cockpit-config.mjs +3 -3
- package/fesm2020/c8y-ngx-components-cockpit-config.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-context-dashboard.mjs +11 -8
- package/fesm2020/c8y-ngx-components-context-dashboard.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-ecosystem.mjs +6 -6
- package/fesm2020/c8y-ngx-components-ecosystem.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-files-repository.mjs +5 -3
- package/fesm2020/c8y-ngx-components-files-repository.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-protocol-lwm2m-components-bootstrap-parameters.mjs +2 -2
- package/fesm2020/c8y-ngx-components-protocol-lwm2m-components-bootstrap-parameters.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-register-device.mjs +3 -3
- package/fesm2020/c8y-ngx-components-register-device.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-reports.mjs +2 -2
- package/fesm2020/c8y-ngx-components-reports.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-repository-configuration.mjs +3 -3
- package/fesm2020/c8y-ngx-components-repository-configuration.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-sms-gateway.mjs +6 -6
- package/fesm2020/c8y-ngx-components-sms-gateway.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-sub-assets.mjs +19 -13
- package/fesm2020/c8y-ngx-components-sub-assets.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-tenants.mjs +11 -6
- package/fesm2020/c8y-ngx-components-tenants.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-upgrade.mjs +4 -2
- package/fesm2020/c8y-ngx-components-upgrade.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components.mjs +74 -3
- package/fesm2020/c8y-ngx-components.mjs.map +1 -1
- package/package.json +1 -1
- package/tenants/tenant-list/tenant-list.component.d.ts +4 -2
- package/upgrade/ng1/downgraded.services.d.ts +1 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Component, Input, Injectable, EventEmitter, NgModule, Output } from '@angular/core';
|
|
3
3
|
import * as i1 from '@c8y/ngx-components';
|
|
4
|
-
import { gettext, CoreModule, hookRoute, memoize, Status, NavigatorNode, hookTab, hookNavigator } from '@c8y/ngx-components';
|
|
4
|
+
import { Permissions, gettext, CoreModule, hookRoute, memoize, Status, NavigatorNode, hookTab, hookNavigator } from '@c8y/ngx-components';
|
|
5
5
|
import * as i1$1 from '@c8y/client';
|
|
6
6
|
import { TenantLoginOptionType, UserManagementSource, GrantType, TfaStrategy } from '@c8y/client';
|
|
7
7
|
import * as i3 from '@angular/forms';
|
|
@@ -106,7 +106,10 @@ class AuthConfigurationGuard {
|
|
|
106
106
|
this.permissions = permissions;
|
|
107
107
|
}
|
|
108
108
|
canActivate() {
|
|
109
|
-
return this.permissions.hasAnyRole([
|
|
109
|
+
return this.permissions.hasAnyRole([
|
|
110
|
+
Permissions.ROLE_TENANT_ADMIN,
|
|
111
|
+
Permissions.ROLE_TENANT_MANAGEMENT_ADMIN
|
|
112
|
+
]);
|
|
110
113
|
}
|
|
111
114
|
}
|
|
112
115
|
AuthConfigurationGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.6", ngImport: i0, type: AuthConfigurationGuard, deps: [{ token: i1.Permissions }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
@@ -2270,8 +2273,8 @@ class NavigationFactory {
|
|
|
2270
2273
|
get() {
|
|
2271
2274
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2272
2275
|
const userHasPermission = this.permissions.hasAnyRole([
|
|
2273
|
-
|
|
2274
|
-
|
|
2276
|
+
Permissions.ROLE_TENANT_ADMIN,
|
|
2277
|
+
Permissions.ROLE_TENANT_MANAGEMENT_ADMIN
|
|
2275
2278
|
]);
|
|
2276
2279
|
if (this.navs.length === 0 && userHasPermission) {
|
|
2277
2280
|
this.navs.push(new NavigatorNode({
|