@c8y/ngx-components 1017.0.261 → 1017.0.263
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/plugins/plugins.service.d.ts +9 -0
- package/ecosystem/shared/ecosystem.service.d.ts +1 -1
- package/esm2020/core/common/permissions.service.mjs +2 -4
- package/esm2020/core/plugins/plugins.service.mjs +37 -2
- package/esm2020/ecosystem/shared/ecosystem.service.mjs +7 -9
- package/esm2020/sub-assets/add-group/add-group.component.mjs +3 -4
- package/esm2020/sub-assets/sub-assets.component.mjs +2 -5
- package/fesm2015/c8y-ngx-components-ecosystem-shared.mjs +6 -8
- package/fesm2015/c8y-ngx-components-ecosystem-shared.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components-sub-assets.mjs +3 -7
- package/fesm2015/c8y-ngx-components-sub-assets.mjs.map +1 -1
- package/fesm2015/c8y-ngx-components.mjs +36 -4
- package/fesm2015/c8y-ngx-components.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-ecosystem-shared.mjs +6 -8
- package/fesm2020/c8y-ngx-components-ecosystem-shared.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components-sub-assets.mjs +3 -7
- package/fesm2020/c8y-ngx-components-sub-assets.mjs.map +1 -1
- package/fesm2020/c8y-ngx-components.mjs +36 -4
- package/fesm2020/c8y-ngx-components.mjs.map +1 -1
- package/package.json +2 -2
|
@@ -467,9 +467,8 @@ class AddGroupComponent {
|
|
|
467
467
|
this.subscription = this.onCancel.subscribe(() => this.resetStepper());
|
|
468
468
|
this.canCreateGroup =
|
|
469
469
|
this.subAssetsService.canCreateGroup() ||
|
|
470
|
-
(await this.permissionsService.canEdit([
|
|
471
|
-
|
|
472
|
-
skipRolesCheck: true
|
|
470
|
+
(await this.permissionsService.canEdit(['ROLE_INVENTORY_ADMIN', 'ROLE_INVENTORY_CREATE'], {
|
|
471
|
+
id: this.currentGroupId
|
|
473
472
|
}));
|
|
474
473
|
this.canAssignDevice = await this.subAssetsService.canAssignDevice({
|
|
475
474
|
id: this.currentGroupId
|
|
@@ -1608,10 +1607,7 @@ class SubAssetsComponent {
|
|
|
1608
1607
|
this.group = { ...contextData };
|
|
1609
1608
|
this.title = this.group.name;
|
|
1610
1609
|
this.currentGroupId = this.group.id;
|
|
1611
|
-
this.shouldDisableAddGroup = !(await this.permissionsService.canEdit([], this.group
|
|
1612
|
-
skipOwnerCheck: true,
|
|
1613
|
-
skipRolesCheck: true
|
|
1614
|
-
}));
|
|
1610
|
+
this.shouldDisableAddGroup = !(await this.permissionsService.canEdit(['ROLE_INVENTORY_ADMIN', 'ROLE_INVENTORY_CREATE'], this.group));
|
|
1615
1611
|
this.shouldDisableAssignDevices = !(await this.subAssetsService.canAssignDevice(this.group));
|
|
1616
1612
|
this.customProperties = await this.subAssetsService.getCustomProperties(this.group);
|
|
1617
1613
|
this.shouldShowAssetsProperties = this.customProperties.length > 0;
|