From 1aeb03c0a2dbf71bcb08aa6ed09e67e298ee2c2e Mon Sep 17 00:00:00 2001 From: Vladyslav_Prykhodko Date: Thu, 25 Mar 2021 13:12:26 +0200 Subject: [PATCH] UI: Fixed updated device profiles table after added new profiles --- .../device-profiles-table-config.resolver.ts | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/ui-ngx/src/app/modules/home/pages/device-profile/device-profiles-table-config.resolver.ts b/ui-ngx/src/app/modules/home/pages/device-profile/device-profiles-table-config.resolver.ts index 3a6862b422..49a256dd55 100644 --- a/ui-ngx/src/app/modules/home/pages/device-profile/device-profiles-table-config.resolver.ts +++ b/ui-ngx/src/app/modules/home/pages/device-profile/device-profiles-table-config.resolver.ts @@ -36,7 +36,6 @@ import { import { DeviceProfileService } from '@core/http/device-profile.service'; import { DeviceProfileComponent } from '@home/components/profile/device-profile.component'; import { DeviceProfileTabsComponent } from './device-profile-tabs.component'; -import { Observable } from 'rxjs'; import { MatDialog } from '@angular/material/dialog'; import { AddDeviceProfileDialogComponent, @@ -138,8 +137,8 @@ export class DeviceProfilesTableConfigResolver implements Resolve { - return this.dialog.open(AddDeviceProfileDialogComponent, { disableClose: true, panelClass: ['tb-dialog', 'tb-fullscreen-dialog'], @@ -147,7 +146,13 @@ export class DeviceProfilesTableConfigResolver implements Resolve { + if (res) { + this.config.table.updateData(); + } + } + ); } setDefaultDeviceProfile($event: Event, deviceProfile: DeviceProfile) {