Skip to content

Commit

Permalink
Update Widget.js
Browse files Browse the repository at this point in the history
Fixed export bug
  • Loading branch information
ldwr011 committed Jun 29, 2020
1 parent d0b4fee commit 0a1b06a
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions Widget.js
Original file line number Diff line number Diff line change
Expand Up @@ -1147,17 +1147,17 @@ define([

_onExportPopupOK: function () {
let exportConfig = this.ExportPopupContent.getConfig();

if (exportConfig.filetype === "csv") {
this._exportToCsv(exportConfig.filename, exportConfig.layers);
}
else if (exportConfig.filetype === "geojson") {
this._exportToGeoJSON(exportConfig.filename, exportConfig.layers);
}
/*else if (exportConfig.filetype === "shp") {
this._exportToShapefile(exportConfig.filename, exportConfig.layers);
}*/
if (layers.length > 0) {
if (exportConfig.layers.length > 0) {
if (exportConfig.filetype === "csv") {
this._exportToCsv(exportConfig.filename, exportConfig.layers);
}
else if (exportConfig.filetype === "geojson") {
this._exportToGeoJSON(exportConfig.filename, exportConfig.layers);
}
/*else if (exportConfig.filetype === "shp") {
this._exportToShapefile(exportConfig.filename, exportConfig.layers);
}*/
this.ExportPopup.close();
}
else {
Expand Down

0 comments on commit 0a1b06a

Please sign in to comment.