Skip to content

Commit

Permalink
[Fixes #1156] Remove duplicated data download plugin (#1162) (#1165)
Browse files Browse the repository at this point in the history
  • Loading branch information
allyoucanmap committed Aug 23, 2022
1 parent 7e5b6b6 commit 4c486ba
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 137 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,25 +112,6 @@ export const FullScreenActionButton = connect(createSelector([
);
});

export const DataDownloadActionButton = connect(
() => ({}),
{ onClick: setControlProperty.bind(null, 'layerdownload', 'enabled', true, true) }
)(({
onClick,
variant,
size
}) => {
return (
<Button
variant={variant}
size={size}
onClick={() => onClick()}
>
<Message msgId="gnhome.dataset" />
</Button>
);
});

export const LayerDownloadActionButton = connect(
() => ({}),
{ onClick: setControlProperty.bind(null, 'layerdownload', 'enabled', true, true) }
Expand All @@ -145,7 +126,7 @@ export const LayerDownloadActionButton = connect(
size={size}
onClick={() => onClick()}
>
<Message msgId="gnviewer.export" />
<Message msgId="gnhome.dataset" />
</Button>
);
});
Expand Down
13 changes: 0 additions & 13 deletions geonode_mapstore_client/client/js/plugins/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import {
CatalogActionButton,
MeasureActionButton,
LayerDownloadActionButton,
DataDownloadActionButton,
AnnotationsActionButton,
FullScreenActionButton,
FilterLayerActionButton
Expand Down Expand Up @@ -117,18 +116,6 @@ export const plugins = {
}
}
),
DataDownloadPlugin: toLazyPlugin(
'LayerDownload',
() => import(/* webpackChunkName: 'plugins/data-download' */ '@mapstore/framework/plugins/LayerDownload'),
{
containers: {
ActionNavbar: {
name: 'DataDownload',
Component: DataDownloadActionButton
}
}
}
),
SwipePlugin: toLazyPlugin(
'Swipe',
() => import(/* webpackChunkName: 'plugins/swipe' */ '@mapstore/framework/plugins/Swipe')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -935,7 +935,7 @@
"items": [
{
"type": "plugin",
"name": "DataDownload"
"name": "LayerDownload"
},
{
"type": "plugin",
Expand Down Expand Up @@ -1281,109 +1281,6 @@
{
"name": "AddLayer"
},
{
"name": "DataDownload",
"cfg": {
"formats": [
{
"name": "application/json",
"label": "GeoJSON",
"type": "vector",
"validServices": [
"wps"
]
},
{
"name": "application/arcgrid",
"label": "ArcGrid",
"type": "raster",
"validServices": [
"wps"
]
},
{
"name": "image/tiff",
"label": "TIFF",
"type": "raster",
"validServices": [
"wps"
]
},
{
"name": "image/png",
"label": "PNG",
"type": "raster",
"validServices": [
"wps"
]
},
{
"name": "image/jpeg",
"label": "JPEG",
"type": "raster",
"validServices": [
"wps"
]
},
{
"name": "application/wfs-collection-1.0",
"label": "GML (FeatureCollection)",
"type": "vector",
"validServices": [
"wps"
]
},
{
"name": "application/wfs-collection-1.1",
"label": "GML (WFS 1.1.0 FeatureCollection)",
"type": "vector",
"validServices": [
"wps"
]
},
{
"name": "application/zip",
"label": "Shapefile",
"type": "vector",
"validServices": [
"wps"
]
},
{
"name": "text/csv",
"label": "CSV",
"type": "vector",
"validServices": [
"wps"
]
},
{
"name": "application/geopackage+sqlite3",
"label": "GeoPackage",
"type": "vector",
"validServices": [
"wps"
]
},
{
"name": "application/geopackage+sqlite3",
"label": "GeoPackage",
"type": "raster",
"validServices": [
"wps"
]
},
{
"name": "application/vnd.google-earth.kml+xml",
"label": "KML",
"type": "vector",
"validServices": [
"wps"
]
}
]
}
},
{
"name": "FilterLayer"
},
Expand Down

0 comments on commit 4c486ba

Please sign in to comment.