Commit 15473c040a6f53f65e7892976d44f473263d07f3
1 parent
854307fd
Hide Manage credentials for edge_customer_user
Showing
3 changed files
with
3 additions
and
3 deletions
@@ -38,7 +38,7 @@ | @@ -38,7 +38,7 @@ | ||
38 | [disabled]="(isLoading$ | async)" | 38 | [disabled]="(isLoading$ | async)" |
39 | (click)="onEntityAction($event, 'manageCredentials')" | 39 | (click)="onEntityAction($event, 'manageCredentials')" |
40 | [fxShow]="!isEdit"> | 40 | [fxShow]="!isEdit"> |
41 | - {{ (deviceScope === 'customer_user' ? 'device.view-credentials' : 'device.manage-credentials') | translate }} | 41 | + {{ ((deviceScope === 'customer_user' || deviceScope === 'edge_customer_user') ? 'device.view-credentials' : 'device.manage-credentials') | translate }} |
42 | </button> | 42 | </button> |
43 | <button mat-raised-button color="primary" | 43 | <button mat-raised-button color="primary" |
44 | [disabled]="(isLoading$ | async)" | 44 | [disabled]="(isLoading$ | async)" |
@@ -48,7 +48,7 @@ export class DeviceComponent extends EntityComponent<DeviceInfo> { | @@ -48,7 +48,7 @@ export class DeviceComponent extends EntityComponent<DeviceInfo> { | ||
48 | 48 | ||
49 | deviceCredentials$: Subject<DeviceCredentials>; | 49 | deviceCredentials$: Subject<DeviceCredentials>; |
50 | 50 | ||
51 | - deviceScope: 'tenant' | 'customer' | 'customer_user' | 'edge'; | 51 | + deviceScope: 'tenant' | 'customer' | 'customer_user' | 'edge' | 'edge_customer_user'; |
52 | 52 | ||
53 | otaUpdateType = OtaUpdateType; | 53 | otaUpdateType = OtaUpdateType; |
54 | 54 |
@@ -528,7 +528,7 @@ export class DevicesTableConfigResolver implements Resolve<EntityTableConfig<Dev | @@ -528,7 +528,7 @@ export class DevicesTableConfigResolver implements Resolve<EntityTableConfig<Dev | ||
528 | panelClass: ['tb-dialog', 'tb-fullscreen-dialog'], | 528 | panelClass: ['tb-dialog', 'tb-fullscreen-dialog'], |
529 | data: { | 529 | data: { |
530 | deviceId: device.id.id, | 530 | deviceId: device.id.id, |
531 | - isReadOnly: this.config.componentsData.deviceScope === 'customer_user' | 531 | + isReadOnly: this.config.componentsData.deviceScope === 'customer_user' || this.config.componentsData.deviceScope === 'edge_customer_user' |
532 | } | 532 | } |
533 | }).afterClosed().subscribe(deviceCredentials => { | 533 | }).afterClosed().subscribe(deviceCredentials => { |
534 | if (isDefinedAndNotNull(deviceCredentials)) { | 534 | if (isDefinedAndNotNull(deviceCredentials)) { |