UI: Fixed display columns without sources
This commit is contained in:
parent
dd900dafba
commit
9fceba291c
@ -388,9 +388,11 @@ export class TimeseriesTableWidgetComponent extends PageComponent implements OnI
|
||||
this.sources.push(source);
|
||||
}
|
||||
}
|
||||
if (this.sources.length) {
|
||||
this.prepareDisplayedColumn();
|
||||
this.sources[this.sourceIndex].displayedColumns =
|
||||
this.displayedColumns[this.sourceIndex].filter(value => value.display).map(value => value.def);
|
||||
}
|
||||
this.updateActiveEntityInfo();
|
||||
}
|
||||
|
||||
@ -398,6 +400,7 @@ export class TimeseriesTableWidgetComponent extends PageComponent implements OnI
|
||||
if ($event) {
|
||||
$event.stopPropagation();
|
||||
}
|
||||
if (this.sources.length) {
|
||||
const target = $event.target || $event.currentTarget;
|
||||
const config = new OverlayConfig();
|
||||
config.backdropClass = 'cdk-overlay-transparent-backdrop';
|
||||
@ -441,6 +444,7 @@ export class TimeseriesTableWidgetComponent extends PageComponent implements OnI
|
||||
this.viewContainerRef, injector));
|
||||
this.ctx.detectChanges();
|
||||
}
|
||||
}
|
||||
|
||||
private prepareDisplayedColumn() {
|
||||
if (!this.displayedColumns[this.sourceIndex]) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user