Skip to content

Commit

Permalink
Fix #1188 Add presets for the whole task
Browse files Browse the repository at this point in the history
Importer provides the possibility to update the whole tranform chain updating the "transformChain" entry in the task.

Allowing this in the task, we can configure presets like this to allow correct transforms preset:

```
{
        "state": "READY",
        "data": {
            "format": "GeoTIFF"
        },
        "changes": {
            "task": {
                "transformChain": {
                    "type": "raster",
                "transforms": [{
                     "type": "GdalWarpTransform",
                     "options": [ "-t_srs", "EPSG:4326", "-co", "TILED=YES", "-co", "BLOCKXSIZE=512", "-co", "BLOCKYSIZE=512"]
                 }, {
                     "type": "GdalAddoTransform",
                     "options": [ "-r", "average"],
                     "levels" : [2, 4, 8, 16, 32, 64, 128]
                 }]
             }
            }
        }

    }
```
  • Loading branch information
offtherailz committed Oct 21, 2016
1 parent 9e3ad2a commit c28b1ec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web/client/api/geoserver/Importer.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ var Api = {
updateTask: function( geoserverBaseUrl, importId, taskId, element, body, options) {
let url = geoserverBaseUrl + "imports/" + importId + "/tasks/" + taskId;
// element can be target, layer, transforms...
if (element) {
if (element && element !== "task") {
url += "/" + element;
}
return axios.put(url, body, options);
Expand Down

0 comments on commit c28b1ec

Please sign in to comment.