Commit 2d2ac1fd authored by François Agneray's avatar François Agneray
Browse files

Fixed bug: InstanceName dans url display

parent 84f0a9af
......@@ -11,6 +11,7 @@ import { Criterion } from '../../store/model';
})
export class UrlDisplayComponent {
@Input() apiPath: string;
@Input() instanceName: string;
@Input() datasetName: string;
@Input() criteriaList: Criterion[];
@Input() outputList: number[];
......@@ -18,7 +19,7 @@ export class UrlDisplayComponent {
constructor(private toastr: ToastrService) { }
getUrl() {
let query = this.apiPath + '/data/' + this.datasetName + '?a=' + this.outputList.join(';');
let query = this.apiPath + '/' + this.instanceName + '/data/' + this.datasetName + '?a=' + this.outputList.join(';');
if (this.criteriaList.length > 0) {
query += '&c=' + this.criteriaList.map(criterion => criterion.getCriterionStr()).join(';');
}
......
......@@ -6,6 +6,7 @@
<div class="col-12 col-md-8">
<app-url-display
[apiPath]="apiPath"
[instanceName]="instanceName"
[datasetName]="datasetName | async"
[criteriaList]="criteriaList | async"
[outputList]="outputList | async">
......
......@@ -29,6 +29,7 @@ export class ResultComponent implements OnInit {
public attributeSearchMetaIsLoading: Observable<boolean>;
public attributeSearchMetaIsLoaded: Observable<boolean>;
public apiPath: string = environment.apiUrl + '/search';
public instanceName: string = environment.instanceName;
public datasetName: Observable<string>;
public currentStep: Observable<string>;
public datasetList: Observable<Dataset[]>;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment