dashboard #1

Merged
andi merged 118 commits from dashboard into master 2024-09-29 06:47:35 +00:00
4 changed files with 26 additions and 3 deletions
Showing only changes of commit b6045eda22 - Show all commits

View File

@@ -12,8 +12,6 @@
<div id="filters"> <div id="filters">
<div id="filterpanel"> <div id="filterpanel">
<mat-form-field class="pdb-form-full-width"> <mat-form-field class="pdb-form-full-width">
<mat-label>Type:</mat-label> <mat-label>Type:</mat-label>
<mat-select multiple [(ngModel)]="selectedPlotType" (ngModelChange)="changePlotType($event)"> <mat-select multiple [(ngModel)]="selectedPlotType" (ngModelChange)="changePlotType($event)">
@@ -66,6 +64,13 @@
<div id="plot-button-bar"> <div id="plot-button-bar">
<a
mat-icon-button
[routerLink]="['/vis']"
[queryParams]="{config: serializedConfig()}"
target="_blank"
aria-label="open new window with the same search"
title="open new window with the same search"><img src="assets/img/link.svg" aria-hidden="true"/></a>
<button <button
*ngIf="!enableGallery && !plotJobActive" *ngIf="!enableGallery && !plotJobActive"
[disabled]="plotJobActive" [disabled]="plotJobActive"

View File

@@ -67,5 +67,7 @@
} }
#plot-button-bar { #plot-button-bar {
text-align: right; display: flex;
justify-content: space-between;
} }

View File

@@ -63,6 +63,12 @@ export class VisualizationPageComponent implements OnInit, AfterViewInit {
plotJobActive = false; plotJobActive = false;
constructor(private plotService: PlotService, private snackBar: MatSnackBar) { constructor(private plotService: PlotService, private snackBar: MatSnackBar) {
const params = new URLSearchParams(window.location.search);
if (!this.defaultConfig && params.get("config")) {
const config = JSON.parse(params.get("config")!);
this.defaultConfig = config;
}
} }
showError(message:string) { showError(message:string) {
@@ -248,4 +254,13 @@ toggleGallery(event: Event){
); );
return request; return request;
} }
serializedConfig(): string {
try{
const config = this.createPlotConfig();
return JSON.stringify(config);
}catch (e) {
return "";
}
}
} }

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24"><path d="M0 0h24v24H0z" fill="none"/><path d="M19 19H5V5h7V3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2v-7h-2v7zM14 3v2h3.59l-9.83 9.83 1.41 1.41L19 6.41V10h2V3h-7z"/></svg>

After

Width:  |  Height:  |  Size: 268 B