Commit 20ba01dd authored by Matthieu Benoist's avatar Matthieu Benoist
Browse files

Add a copy link button component to the download tab

parent f9028634
......@@ -54,8 +54,13 @@
<span class="sr-only">Options</span>
</button>
<app-download-button [url]="queryableUrl" [fileName]="fileName">
</app-download-button>
<app-link-copy-icon [linkUrl]="queryableUrl" [displayLink]="false" >
<div class="resource-download-icon">
<app-download-button [url]="queryableUrl" [fileName]="fileName">
</app-download-button>
</div>
</app-link-copy-icon>
</div>
</div>
......
......@@ -133,7 +133,6 @@ export class ResourceDownloadItemComponent implements OnInit {
get queryableUrl() {
let queryableUrl = '';
if (this.isQueryable) {
queryableUrl = this.resource.metadataLink.url;
let layer = '';
let outputFormat = '';
......@@ -161,9 +160,11 @@ export class ResourceDownloadItemComponent implements OnInit {
}
} else if (this.resource.type === linkFormats.ws) {
if (this.format.name === 'JSON') {
queryableUrl += `/${this.resource.metadataLink.name}/all.json`;
queryableUrl += `/${this.resource.metadataLink.name}/all.json?maxFeatures=-1`;
} else {
queryableUrl += `/${this.resource.metadataLink.name}.shp?srsname=EPSG:3946`;
const projectionAndBbox = this.getProjectionAndBbox(this.format);
queryableUrl += `/${this.resource.metadataLink.name}.shp?${projectionAndBbox.projection}`;
}
} else if (this.resource.type === linkFormats.kml) {
queryableUrl += `?${this.resource.parametersUrl}` +
......
Markdown is supported
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