@c8y/ngx-components 1018.0.115 → 1018.0.119

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.
Files changed (24) hide show
  1. package/esm2020/core/common/permissions.service.mjs +2 -4
  2. package/esm2020/core/realtime/measurement-realtime.service.mjs +4 -2
  3. package/esm2020/device-profile/device-profile.component.mjs +4 -2
  4. package/esm2020/sub-assets/add-group/add-group.component.mjs +3 -4
  5. package/esm2020/sub-assets/sub-assets.component.mjs +2 -5
  6. package/esm2020/widgets/implementations/kpi/kpi-widget-view/kpi-widget-view.component.mjs +2 -2
  7. package/fesm2015/c8y-ngx-components-device-profile.mjs +3 -1
  8. package/fesm2015/c8y-ngx-components-device-profile.mjs.map +1 -1
  9. package/fesm2015/c8y-ngx-components-sub-assets.mjs +3 -7
  10. package/fesm2015/c8y-ngx-components-sub-assets.mjs.map +1 -1
  11. package/fesm2015/c8y-ngx-components-widgets-implementations-kpi.mjs +1 -1
  12. package/fesm2015/c8y-ngx-components-widgets-implementations-kpi.mjs.map +1 -1
  13. package/fesm2015/c8y-ngx-components.mjs +4 -4
  14. package/fesm2015/c8y-ngx-components.mjs.map +1 -1
  15. package/fesm2020/c8y-ngx-components-device-profile.mjs +3 -1
  16. package/fesm2020/c8y-ngx-components-device-profile.mjs.map +1 -1
  17. package/fesm2020/c8y-ngx-components-sub-assets.mjs +3 -7
  18. package/fesm2020/c8y-ngx-components-sub-assets.mjs.map +1 -1
  19. package/fesm2020/c8y-ngx-components-widgets-implementations-kpi.mjs +1 -1
  20. package/fesm2020/c8y-ngx-components-widgets-implementations-kpi.mjs.map +1 -1
  21. package/fesm2020/c8y-ngx-components.mjs +4 -4
  22. package/fesm2020/c8y-ngx-components.mjs.map +1 -1
  23. package/package.json +1 -1
  24. package/widgets/implementations/kpi/kpi-widget-view/kpi-widget-view.component.d.ts +2 -2
@@ -518,9 +518,8 @@ class AddGroupComponent {
518
518
  this.subscription = this.onCancel.subscribe(() => this.resetStepper());
519
519
  this.canCreateGroup =
520
520
  this.subAssetsService.canCreateGroup() ||
521
- (await this.permissionsService.canEdit([], { id: this.currentGroupId }, {
522
- skipOwnerCheck: true,
523
- skipRolesCheck: true
521
+ (await this.permissionsService.canEdit(['ROLE_INVENTORY_ADMIN', 'ROLE_INVENTORY_CREATE'], {
522
+ id: this.currentGroupId
524
523
  }));
525
524
  this.canAssignDevice = await this.subAssetsService.canAssignDevice({
526
525
  id: this.currentGroupId
@@ -1745,10 +1744,7 @@ class SubAssetsComponent {
1745
1744
  this.group = { ...contextData };
1746
1745
  this.title = this.group.name;
1747
1746
  this.currentGroupId = this.group.id;
1748
- this.shouldDisableAddGroup = !(await this.permissionsService.canEdit([], this.group, {
1749
- skipOwnerCheck: true,
1750
- skipRolesCheck: true
1751
- }));
1747
+ this.shouldDisableAddGroup = !(await this.permissionsService.canEdit(['ROLE_INVENTORY_ADMIN', 'ROLE_INVENTORY_CREATE'], this.group));
1752
1748
  this.shouldDisableAssignDevices = !(await this.subAssetsService.canAssignDevice(this.group));
1753
1749
  this.customProperties = await this.subAssetsService.getCustomProperties(this.group);
1754
1750
  this.shouldShowAssetsProperties =