fetch possible values for gallery view

This commit is contained in:
2019-11-14 18:45:32 +01:00
parent 10a7710940
commit 57c5cca688
6 changed files with 38 additions and 8 deletions

View File

@@ -80,7 +80,7 @@
*ngIf="enableGallery"
mat-button
matTooltip="Create Gallery"
(click)="plot()"
(click)="gallery()"
[disabled]="this.splitBy == null">
<img src="assets/img/four-squares-line.svg" class="icon-inline" aria-hidden="true" title="Create Gallery (only active if 'Split' is set)" />
Gallery

View File

@@ -90,6 +90,18 @@ export class VisualizationPageComponent implements OnInit {
dateRangeAsString() : string {
return (<HTMLInputElement>document.getElementById("search-date-range")).value;
}
gallery(){
const that = this;
this.plotService.splitQuery(this.query.query, this.splitBy.name).subscribe(function(valuesForSplitBy){
console.log("valuesForSplitBy: " + JSON.stringify(valuesForSplitBy));
that.plotView.errorMessage = '';
},
error => {
that.plotView.imageUrl = '';
that.plotView.errorMessage = error.error.message;
});
}
plot(){
const that = this;