added condition checkbox in JSON download link dialog
This commit is contained in:
parent
79a2ad59f2
commit
40afc348e1
@ -111,7 +111,10 @@
|
|||||||
<rb-form-checkbox class="space-right" name="download-spectra" [(ngModel)]="downloadSpectra">
|
<rb-form-checkbox class="space-right" name="download-spectra" [(ngModel)]="downloadSpectra">
|
||||||
add spectra
|
add spectra
|
||||||
</rb-form-checkbox>
|
</rb-form-checkbox>
|
||||||
<rb-form-checkbox name="download-flatten" [(ngModel)]="downloadFlatten">
|
<rb-form-checkbox class="space-right" name="download-conditions" [(ngModel)]="downloadCondition">
|
||||||
|
add conditions
|
||||||
|
</rb-form-checkbox>
|
||||||
|
<rb-form-checkbox class="space-right" name="download-flatten" [(ngModel)]="downloadFlatten">
|
||||||
flatten object
|
flatten object
|
||||||
</rb-form-checkbox>
|
</rb-form-checkbox>
|
||||||
<rb-icon-button icon="clipboard" mode="secondary" (click)="clipboard()">Copy to clipboard</rb-icon-button>
|
<rb-icon-button icon="clipboard" mode="secondary" (click)="clipboard()">Copy to clipboard</rb-icon-button>
|
||||||
|
@ -34,7 +34,8 @@ export class SamplesComponent implements OnInit {
|
|||||||
@ViewChild('pageSizeSelection') pageSizeSelection: ElementRef<HTMLElement>;
|
@ViewChild('pageSizeSelection') pageSizeSelection: ElementRef<HTMLElement>;
|
||||||
@ViewChild('linkarea') linkarea: ElementRef<HTMLTextAreaElement>;
|
@ViewChild('linkarea') linkarea: ElementRef<HTMLTextAreaElement>;
|
||||||
|
|
||||||
downloadSpectra = false;
|
downloadSpectra = false; // TODO: streamline these options after csv option handling is clear
|
||||||
|
downloadCondition = false;
|
||||||
downloadFlatten = true;
|
downloadFlatten = true;
|
||||||
samples: SampleModel[] = [];
|
samples: SampleModel[] = [];
|
||||||
totalSamples = 0; // total number of samples
|
totalSamples = 0; // total number of samples
|
||||||
@ -236,6 +237,9 @@ export class SamplesComponent implements OnInit {
|
|||||||
if (this.downloadSpectra) {
|
if (this.downloadSpectra) {
|
||||||
query.push('fields[]=measurements.spectrum.dpt');
|
query.push('fields[]=measurements.spectrum.dpt');
|
||||||
}
|
}
|
||||||
|
if (this.downloadCondition) {
|
||||||
|
query.push('fields[]=condition');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return (options.host && isDevMode() ? window.location.host : '') +
|
return (options.host && isDevMode() ? window.location.host : '') +
|
||||||
(options.export ? this.api.hostName : '') +
|
(options.export ? this.api.hostName : '') +
|
||||||
|
Loading…
Reference in New Issue
Block a user