This is an automated email from the ASF dual-hosted git repository.

riemer pushed a commit to branch improve-data-explorer-widgets
in repository https://gitbox.apache.org/repos/asf/streampipes.git


The following commit(s) were added to refs/heads/improve-data-explorer-widgets 
by this push:
     new 054a483fa Add revision to correlation charts
054a483fa is described below

commit 054a483fad1bfda7c6d24e98613ca642e8f478b3
Author: Dominik Riemer <[email protected]>
AuthorDate: Mon Aug 28 23:08:03 2023 +0200

    Add revision to correlation charts
---
 .../widgets/correlation-chart/correlation-chart-widget.component.html  | 2 ++
 .../widgets/correlation-chart/correlation-chart-widget.component.ts    | 3 +++
 2 files changed, 5 insertions(+)

diff --git 
a/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.html
 
b/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.html
index f4a9b8d5e..ad6a15e5d 100644
--- 
a/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.html
+++ 
b/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.html
@@ -43,6 +43,8 @@
         *ngIf="showData"
         [divId]="dataExplorerWidget._id"
         class="plotly-container"
+        [updateOnlyWithRevision]="true"
+        [revision]="revision"
         [data]="data"
         [layout]="graph.layout"
         [config]="graph.config"
diff --git 
a/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.ts
 
b/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.ts
index 2f8f6eccf..0da78416c 100644
--- 
a/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.ts
+++ 
b/ui/src/app/data-explorer/components/widgets/correlation-chart/correlation-chart-widget.component.ts
@@ -37,6 +37,7 @@ export class CorrelationChartWidgetComponent
     colNo = 2;
     fixedColNo = 2;
     rowNo = 2;
+    revision = 1;
 
     data = [];
 
@@ -221,6 +222,7 @@ export class CorrelationChartWidgetComponent
         this.graph.layout.autosize = false;
         (this.graph.layout as any).width = width;
         (this.graph.layout as any).height = height;
+        this.revision += 1;
     }
 
     beforeDataFetched() {}
@@ -229,6 +231,7 @@ export class CorrelationChartWidgetComponent
         this.prepareData(spQueryResult);
         this.updateAppearance();
         this.setShownComponents(false, true, false, false);
+        this.revision += 1;
     }
 
     handleUpdatedFields(

Reply via email to