Compare commits
No commits in common. "master" and "feature_25598" have entirely different histories.
master
...
feature_25
|
@ -1,6 +1,6 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<classpath>
|
<classpath>
|
||||||
<classpathentry kind="src" output="target/geoportal-data-viewer-app-3.7.0/WEB-INF/classes" path="src/main/java">
|
<classpathentry kind="src" output="target/geoportal-data-viewer-app-3.6.0/WEB-INF/classes" path="src/main/java">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="optional" value="true"/>
|
<attribute name="optional" value="true"/>
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
|
@ -30,10 +30,5 @@
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry excluding="**" kind="src" output="target/geoportal-data-viewer-app-3.7.0/WEB-INF/classes" path="src/main/resources">
|
<classpathentry kind="output" path="target/geoportal-data-viewer-app-3.6.0/WEB-INF/classes"/>
|
||||||
<attributes>
|
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
|
||||||
</attributes>
|
|
||||||
</classpathentry>
|
|
||||||
<classpathentry kind="output" path="target/geoportal-data-viewer-app-3.7.0/WEB-INF/classes"/>
|
|
||||||
</classpath>
|
</classpath>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
eclipse.preferences.version=1
|
eclipse.preferences.version=1
|
||||||
lastWarOutDir=/home/francescomangiacrapa/git/geoportal-data-viewer-app/target/geoportal-data-viewer-app-3.7.0
|
lastWarOutDir=/home/francescomangiacrapa/git/geoportal-data-viewer-app/target/geoportal-data-viewer-app-3.6.0
|
||||||
warSrcDir=src/main/webapp
|
warSrcDir=src/main/webapp
|
||||||
warSrcDirIsOutput=false
|
warSrcDirIsOutput=false
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
|
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -96,108 +96,8 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<wb-module deploy-name="geoportal-data-viewer-app-3.6.0">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<wb-module deploy-name="geoportal-data-viewer-app-3.7.0">
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -295,57 +195,7 @@
|
||||||
|
|
||||||
|
|
||||||
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
|
<wb-resource deploy-path="/" source-path="/target/m2e-wtp/web-resources"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -443,57 +293,7 @@
|
||||||
|
|
||||||
|
|
||||||
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -591,57 +391,7 @@
|
||||||
|
|
||||||
|
|
||||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/target/generated-sources/gwt"/>
|
<wb-resource deploy-path="/WEB-INF/classes" source-path="/target/generated-sources/gwt"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -739,97 +489,10 @@
|
||||||
|
|
||||||
|
|
||||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
||||||
|
<dependent-module archiveName="geoportal-data-common-2.3.0-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/geoportal-data-common/geoportal-data-common">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
|
|
||||||
<dependent-module archiveName="geoportal-client-1.2.2.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/geoportal-client/geoportal-client">
|
|
||||||
<dependency-type>uses</dependency-type>
|
<dependency-type>uses</dependency-type>
|
||||||
</dependent-module>
|
</dependent-module>
|
||||||
<dependent-module archiveName="geoportal-common-1.1.1.jar" deploy-path="/WEB-INF/lib" handle="module:/resource/geoportal-common/geoportal-common">
|
|
||||||
<dependency-type>uses</dependency-type>
|
|
||||||
</dependent-module>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -927,57 +590,7 @@
|
||||||
|
|
||||||
|
|
||||||
<property name="java-output-path" value="/geoportal-data-viewer-app/target/geoportal-data-viewer-app-0.0.1-SNAPSHOT/WEB-INF/classes"/>
|
<property name="java-output-path" value="/geoportal-data-viewer-app/target/geoportal-data-viewer-app-0.0.1-SNAPSHOT/WEB-INF/classes"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1075,57 +688,7 @@
|
||||||
|
|
||||||
|
|
||||||
<property name="context-root" value="geoportal-data-viewer-app"/>
|
<property name="context-root" value="geoportal-data-viewer-app"/>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1223,57 +786,7 @@
|
||||||
|
|
||||||
|
|
||||||
</wb-module>
|
</wb-module>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -4,13 +4,7 @@
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
## [v3.7.0]
|
## [v3.6.0-SNAPSHOT]
|
||||||
|
|
||||||
- Provided the "Export as PDF" facility [#26026]
|
|
||||||
- Integrated the GeoportalExporter as service [#27321]
|
|
||||||
- Passed to the new KC-client [#27398]
|
|
||||||
|
|
||||||
## [v3.6.0]
|
|
||||||
|
|
||||||
- GUI optimization [#25461]
|
- GUI optimization [#25461]
|
||||||
- Using the latest libraries version: gwt-ol.v8.4.1 (with openlayers.v6.6.1) and gwt.v2.10
|
- Using the latest libraries version: gwt-ol.v8.4.1 (with openlayers.v6.6.1) and gwt.v2.10
|
||||||
|
|
|
@ -9,9 +9,9 @@ The "Geoportal data-viewer" technology allows users to access and search for spa
|
||||||
|
|
||||||
**Uses**
|
**Uses**
|
||||||
|
|
||||||
* GWT v.2.10.0. [GWT](http://www.gwtproject.org) is licensed under [Apache License 2.0](http://www.gwtproject.org/terms.html)
|
* GWT v.2.9.0. [GWT](http://www.gwtproject.org) is licensed under [Apache License 2.0](http://www.gwtproject.org/terms.html)
|
||||||
* GWT-Bootstrap v.2.3.2.0. [GWT-Bootstrap](https://github.com/gwtbootstrap) is licensed under [Apache License 2.0](http://www.apache.org/licenses/LICENSE-2.0)
|
* GWT-Bootstrap v.2.3.2.0. [GWT-Bootstrap](https://github.com/gwtbootstrap) is licensed under [Apache License 2.0](http://www.apache.org/licenses/LICENSE-2.0)
|
||||||
* GWT-OpenLayers 3+ v.8.5.0-gwt2_9. [GWT-OL3](https://github.com/TDesjardins/gwt-ol)
|
* GWT-OpenLayers 3+ v.8.1.0-gwt2_9. [GWT-OL3](https://github.com/TDesjardins/gwt-ol)
|
||||||
* OpenLayers v.6.x [OpenLayers](https://openlayers.org/) is licensed under [BSD 2-Clause "Simplified"](https://github.com/openlayers/openlayers/blob/main/LICENSE.md)
|
* OpenLayers v.6.x [OpenLayers](https://openlayers.org/) is licensed under [BSD 2-Clause "Simplified"](https://github.com/openlayers/openlayers/blob/main/LICENSE.md)
|
||||||
* NanoGallery v2.X [NanoGallery2](https://github.com/nanostudio-org/nanogallery2) is licensed under [GNU General Public License "gplv3"](https://www.gnu.org/licenses/gpl-3.0.html)
|
* NanoGallery v2.X [NanoGallery2](https://github.com/nanostudio-org/nanogallery2) is licensed under [GNU General Public License "gplv3"](https://www.gnu.org/licenses/gpl-3.0.html)
|
||||||
* Vis-Timeline v7.x [VisTimeline](https://github.com/visjs/vis-timeline) is licensed under [Apache License 2.0](http://www.apache.org/licenses/LICENSE-2.0) and MIT
|
* Vis-Timeline v7.x [VisTimeline](https://github.com/visjs/vis-timeline) is licensed under [Apache License 2.0](http://www.apache.org/licenses/LICENSE-2.0) and MIT
|
||||||
|
@ -54,7 +54,7 @@ See the [Releases](https://code-repo.d4science.org/gCubeSystem/geoportal-data-vi
|
||||||
|
|
||||||
## Authors
|
## Authors
|
||||||
|
|
||||||
* **Francesco Mangiacrapa** ([ORCID](https://orcid.org/0000-0002-6528-664X)) Computer Scientist at [ISTI-CNR Infrascience Group](http://infrascience.isti.cnr.it)
|
* **Francesco Mangiacrapa** ([ORCID](https://orcid.org/0000-0002-6528-664X)) Computer Scientist at [ISTI-CNR Infrascience Group](http://nemis.isti.cnr.it/groups/infrascience)
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
|
|
43
pom.xml
43
pom.xml
|
@ -14,7 +14,7 @@
|
||||||
<groupId>org.gcube.portlets.user</groupId>
|
<groupId>org.gcube.portlets.user</groupId>
|
||||||
<artifactId>geoportal-data-viewer-app</artifactId>
|
<artifactId>geoportal-data-viewer-app</artifactId>
|
||||||
<packaging>war</packaging>
|
<packaging>war</packaging>
|
||||||
<version>3.7.0</version>
|
<version>3.6.0-SNAPSHOT</version>
|
||||||
<name>GeoPortal Data Viewer App</name>
|
<name>GeoPortal Data Viewer App</name>
|
||||||
<description>The GeoPortal Data Viewer App is an application to access, discovery and navigate the Geoportal projects/documents by a Web-Map Interface</description>
|
<description>The GeoPortal Data Viewer App is an application to access, discovery and navigate the Geoportal projects/documents by a Web-Map Interface</description>
|
||||||
|
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
<gwt.version>2.10.0</gwt.version>
|
<gwt.version>2.10.0</gwt.version>
|
||||||
<gwt.compiler.style>PRETTY</gwt.compiler.style>
|
<gwt.compiler.style>PRETTY</gwt.compiler.style>
|
||||||
<gson.version>2.6.2</gson.version>
|
<gson.version>2.6.2</gson.version>
|
||||||
<gwt.ol.version>8.5.0</gwt.ol.version>
|
<gwt.ol.version>8.4.1</gwt.ol.version>
|
||||||
<webappDirectory>${project.build.directory}/${project.build.finalName}</webappDirectory>
|
<webappDirectory>${project.build.directory}/${project.build.finalName}</webappDirectory>
|
||||||
<!-- GWT 2.9 support 8, 9 and 11 -->
|
<!-- GWT 2.9 support 8, 9 and 11 -->
|
||||||
<maven.compiler.source>1.8</maven.compiler.source>
|
<maven.compiler.source>1.8</maven.compiler.source>
|
||||||
|
@ -56,40 +56,13 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.distribution</groupId>
|
<groupId>org.gcube.distribution</groupId>
|
||||||
<artifactId>maven-portal-bom</artifactId>
|
<artifactId>maven-portal-bom</artifactId>
|
||||||
<version>${gcube-portal-bom-version}</version>
|
<version>3.7.0</version>
|
||||||
<type>pom</type>
|
<type>pom</type>
|
||||||
<scope>import</scope>
|
<scope>import</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
</dependencyManagement>
|
</dependencyManagement>
|
||||||
|
|
||||||
<profiles>
|
|
||||||
<!-- PROD profile -->
|
|
||||||
<profile>
|
|
||||||
<id>geoportal-data-viewer-app-release-profile</id>
|
|
||||||
<activation>
|
|
||||||
<property>
|
|
||||||
<name>Release</name>
|
|
||||||
</property>
|
|
||||||
</activation>
|
|
||||||
<properties>
|
|
||||||
<gcube-portal-bom-version>4.0.0</gcube-portal-bom-version>
|
|
||||||
</properties>
|
|
||||||
</profile>
|
|
||||||
<!-- DEV profile -->
|
|
||||||
<profile>
|
|
||||||
<id>geoportal-data-viewer-app-snapshot-profile</id>
|
|
||||||
<activation>
|
|
||||||
<property>
|
|
||||||
<name>!Release</name>
|
|
||||||
</property>
|
|
||||||
</activation>
|
|
||||||
<properties>
|
|
||||||
<gcube-portal-bom-version>4.0.0-SNAPSHOT</gcube-portal-bom-version>
|
|
||||||
</properties>
|
|
||||||
</profile>
|
|
||||||
</profiles>
|
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -174,13 +147,13 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.application</groupId>
|
<groupId>org.gcube.application</groupId>
|
||||||
<artifactId>geoportal-data-mapper</artifactId>
|
<artifactId>geoportal-data-mapper</artifactId>
|
||||||
<version>[1.0.1, 2.0.0-SNAPSHOT)</version>
|
<version>[1.0.0-SNAPSHOT, 2.0.0-SNAPSHOT)</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.application</groupId>
|
<groupId>org.gcube.application</groupId>
|
||||||
<artifactId>geoportal-data-common</artifactId>
|
<artifactId>geoportal-data-common</artifactId>
|
||||||
<version>[2.0.0, 3.0.0-SNAPSHOT)</version>
|
<version>[2.0.0-SNAPSHOT, 3.0.0-SNAPSHOT)</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -202,26 +175,30 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.gcube.common</groupId>
|
<groupId>org.gcube.common</groupId>
|
||||||
<artifactId>keycloak-client</artifactId>
|
<artifactId>keycloak-client</artifactId>
|
||||||
<version>[2.0.0, 3.0.0-SNAPSHOT)</version>
|
<version>[1.0.0-SNAPSHOT, 2.0.0-SNAPSHOT)</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.liferay.portal</groupId>
|
<groupId>com.liferay.portal</groupId>
|
||||||
<artifactId>portal-service</artifactId>
|
<artifactId>portal-service</artifactId>
|
||||||
|
<!-- <version>6.2.5</version> -->
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>javax.portlet</groupId>
|
<groupId>javax.portlet</groupId>
|
||||||
<artifactId>portlet-api</artifactId>
|
<artifactId>portlet-api</artifactId>
|
||||||
|
<!-- <version>2.0</version> -->
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.slf4j</groupId>
|
<groupId>org.slf4j</groupId>
|
||||||
<artifactId>slf4j-log4j12</artifactId>
|
<artifactId>slf4j-log4j12</artifactId>
|
||||||
|
<!-- <version>1.6.4</version> -->
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.slf4j</groupId>
|
<groupId>org.slf4j</groupId>
|
||||||
<artifactId>slf4j-api</artifactId>
|
<artifactId>slf4j-api</artifactId>
|
||||||
|
<!-- <version>1.6.4</version> -->
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
|
@ -17,17 +17,11 @@
|
||||||
|
|
||||||
<inherits name="com.google.gwt.json.JSON" />
|
<inherits name="com.google.gwt.json.JSON" />
|
||||||
|
|
||||||
<inherits
|
|
||||||
name='org.gcube.portal.clientcontext.GCubeClientContext' />
|
|
||||||
|
|
||||||
<!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/> -->
|
<!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/> -->
|
||||||
<!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/> -->
|
<!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/> -->
|
||||||
|
|
||||||
<!-- Other module inherits -->
|
<!-- Other module inherits -->
|
||||||
|
|
||||||
<servlet path="/geoportalexporterservice"
|
|
||||||
class="org.gcube.portlets.user.geoportaldataviewer.server.GeoportalExporterActionServlet" />
|
|
||||||
|
|
||||||
<!-- Specify the app entry point class. -->
|
<!-- Specify the app entry point class. -->
|
||||||
<entry-point
|
<entry-point
|
||||||
class='org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewer' />
|
class='org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewer' />
|
||||||
|
|
|
@ -64,7 +64,7 @@ import org.gcube.portlets.user.geoportaldataviewer.client.gis.ExtentWrapped;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.MapUtils;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.MapUtils;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayerMap;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayerMap;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayerMap.CQL_FACILITY_ORIGIN;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayerMap.CQL_FACILITY_ORIGIN;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalImages;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAImages;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.GeonaDataViewMainPanel;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.GeonaDataViewMainPanel;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.relation.TimelineManagerStatus;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.relation.TimelineManagerStatus;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.util.OLGeoJSONUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.util.OLGeoJSONUtil;
|
||||||
|
@ -150,7 +150,7 @@ public class GeoportalDataViewer implements EntryPoint {
|
||||||
int attempt = 0;
|
int attempt = 0;
|
||||||
|
|
||||||
private LoaderIcon loaderApp = new LoaderIcon("Loading application... please wait",
|
private LoaderIcon loaderApp = new LoaderIcon("Loading application... please wait",
|
||||||
new com.google.gwt.user.client.ui.Image(GeoportalImages.ICONS.spinnerEarth()));
|
new com.google.gwt.user.client.ui.Image(GNAImages.ICONS.spinnerEarth()));
|
||||||
|
|
||||||
private HTML attributionDiv = new HTML();
|
private HTML attributionDiv = new HTML();
|
||||||
|
|
||||||
|
@ -543,7 +543,7 @@ public class GeoportalDataViewer implements EntryPoint {
|
||||||
Modal errorModal = new Modal(true, true);
|
Modal errorModal = new Modal(true, true);
|
||||||
errorModal.setCloseVisible(true);
|
errorModal.setCloseVisible(true);
|
||||||
errorModal.setTitle("Oops...");
|
errorModal.setTitle("Oops...");
|
||||||
Image geoportalError = new Image(GeoportalImages.ICONS.warningError());
|
Image geoportalError = new Image(GNAImages.ICONS.warningError());
|
||||||
FlowPanel errorPanelMsg = new FlowPanel();
|
FlowPanel errorPanelMsg = new FlowPanel();
|
||||||
errorPanelMsg.getElement().addClassName("general_warning");
|
errorPanelMsg.getElement().addClassName("general_warning");
|
||||||
errorPanelMsg.add(geoportalError);
|
errorPanelMsg.add(geoportalError);
|
||||||
|
@ -1072,7 +1072,7 @@ public class GeoportalDataViewer implements EntryPoint {
|
||||||
* @return the general error panel
|
* @return the general error panel
|
||||||
*/
|
*/
|
||||||
private FlowPanel getGeneralErrorPanel() {
|
private FlowPanel getGeneralErrorPanel() {
|
||||||
Image geoportalError = new Image(GeoportalImages.ICONS.geoportaServiceError());
|
Image geoportalError = new Image(GNAImages.ICONS.geoportaServiceError());
|
||||||
FlowPanel errorPanelMsg = new FlowPanel();
|
FlowPanel errorPanelMsg = new FlowPanel();
|
||||||
errorPanelMsg.getElement().addClassName("general_error");
|
errorPanelMsg.getElement().addClassName("general_error");
|
||||||
errorPanelMsg.add(geoportalError);
|
errorPanelMsg.add(geoportalError);
|
||||||
|
|
|
@ -3,7 +3,6 @@ package org.gcube.portlets.user.geoportaldataviewer.client;
|
||||||
import org.gcube.application.geoportalcommon.ConvertToDataViewModel;
|
import org.gcube.application.geoportalcommon.ConvertToDataViewModel;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayersMapParameters;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayersMapParameters;
|
||||||
|
|
||||||
import com.google.gwt.core.client.GWT;
|
|
||||||
import com.google.gwt.dom.client.Element;
|
import com.google.gwt.dom.client.Element;
|
||||||
import com.google.gwt.i18n.client.DateTimeFormat;
|
import com.google.gwt.i18n.client.DateTimeFormat;
|
||||||
|
|
||||||
|
@ -15,16 +14,7 @@ import com.google.gwt.i18n.client.DateTimeFormat;
|
||||||
* Nov 24, 2020
|
* Nov 24, 2020
|
||||||
*/
|
*/
|
||||||
public class GeoportalDataViewerConstants {
|
public class GeoportalDataViewerConstants {
|
||||||
|
|
||||||
//Geoportal_Exporter_ACTION_SERVLET
|
|
||||||
public static final String UCD_ID_PARAMETER = "ucdID";
|
|
||||||
public static final String PROIECT_ID_PARAMETER = "projectID";
|
|
||||||
public static final String CONTEXT_ID_PARAMETER = "c_id";
|
|
||||||
public static final String USER_ID_PARAMETER = "u_id";
|
|
||||||
public static final String USERNAME_PARAMETER = "usn";
|
|
||||||
public static final String GEOPORTAL_EXPORT_ACTION_SERVLET = GWT.getModuleBaseURL()
|
|
||||||
+ "geoportalexporterservice";
|
|
||||||
|
|
||||||
public static final int TABLET_WIDTH = 1601;
|
public static final int TABLET_WIDTH = 1601;
|
||||||
|
|
||||||
public static final String MAP_DIV = "map";
|
public static final String MAP_DIV = "map";
|
||||||
|
@ -50,9 +40,12 @@ public class GeoportalDataViewerConstants {
|
||||||
public static final String PROJECT_ID_KEY_FEATURE = "projectid";
|
public static final String PROJECT_ID_KEY_FEATURE = "projectid";
|
||||||
|
|
||||||
public static enum GisToolbarFacilities {
|
public static enum GisToolbarFacilities {
|
||||||
COLLECTION("Collection", "Open the collections"), MAP("Map", "Select the base Map"),
|
COLLECTION("Collection", "Open the collections"),
|
||||||
OVERLAY("Overlay", "Add overlay layers"), SEARCH("Search", "Search in the collections"),
|
MAP("Map", "Select the base Map"),
|
||||||
FILTER("Filter", "Apply spatial filtering"), LAYERS("Layers", "Layers added to Map"),
|
OVERLAY("Overlay", "Add overlay layers"),
|
||||||
|
SEARCH("Search", "Search in the collections"),
|
||||||
|
FILTER("Filter", "Apply spatial filtering"),
|
||||||
|
LAYERS("Layers", "Layers added to Map"),
|
||||||
PRESET_LOCATION("Preset Location", "Center the Map to Location");
|
PRESET_LOCATION("Preset Location", "Center the Map to Location");
|
||||||
|
|
||||||
String name;
|
String name;
|
||||||
|
|
|
@ -14,7 +14,7 @@ import org.gcube.application.geoportalcommon.shared.geoportal.materialization.GC
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.ucd.GEOPORTAL_DATA_HANDLER;
|
import org.gcube.application.geoportalcommon.shared.geoportal.ucd.GEOPORTAL_DATA_HANDLER;
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.view.ProjectView;
|
import org.gcube.application.geoportalcommon.shared.geoportal.view.ProjectView;
|
||||||
import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoportalSpatialQueryResult;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoNaSpatialQueryResult;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ItemFieldsResponse;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ItemFieldsResponse;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ResultSetPaginatedDataIDs;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ResultSetPaginatedDataIDs;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ViewerConfiguration;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ViewerConfiguration;
|
||||||
|
@ -57,8 +57,8 @@ public interface GeoportalDataViewerService extends RemoteService {
|
||||||
* @return the data result
|
* @return the data result
|
||||||
* @throws Exception the exception
|
* @throws Exception the exception
|
||||||
*/
|
*/
|
||||||
List<GeoportalSpatialQueryResult> getDataResult(List<LayerObject> layerObjects, String mapSrsName,
|
List<GeoNaSpatialQueryResult> getDataResult(List<LayerObject> layerObjects, String mapSrsName, BoundsMap mapBBOX,
|
||||||
BoundsMap mapBBOX, int maxWFSFeature, double zoomLevel) throws Exception;
|
int maxWFSFeature, double zoomLevel) throws Exception;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the my login.
|
* Gets the my login.
|
||||||
|
@ -104,7 +104,7 @@ public interface GeoportalDataViewerService extends RemoteService {
|
||||||
* @param zoomLevel the zoom level
|
* @param zoomLevel the zoom level
|
||||||
* @return the WFS features
|
* @return the WFS features
|
||||||
*/
|
*/
|
||||||
List<GeoportalSpatialQueryResult> getWFSFeatures(List<LayerObject> layerObjects, String mapSrsName,
|
List<GeoNaSpatialQueryResult> getWFSFeatures(List<LayerObject> layerObjects, String mapSrsName,
|
||||||
BoundsMap selectBBOX, int maxWFSFeature, double zoomLevel);
|
BoundsMap selectBBOX, int maxWFSFeature, double zoomLevel);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -229,6 +229,4 @@ public interface GeoportalDataViewerService extends RemoteService {
|
||||||
|
|
||||||
Integer getCountFor(String profileID, String phase, String status);
|
Integer getCountFor(String profileID, String phase, String status);
|
||||||
|
|
||||||
Boolean checkExportAsPDFConfig();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,7 @@ import org.gcube.application.geoportalcommon.shared.geoportal.materialization.GC
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.ucd.GEOPORTAL_DATA_HANDLER;
|
import org.gcube.application.geoportalcommon.shared.geoportal.ucd.GEOPORTAL_DATA_HANDLER;
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.view.ProjectView;
|
import org.gcube.application.geoportalcommon.shared.geoportal.view.ProjectView;
|
||||||
import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoportalSpatialQueryResult;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoNaSpatialQueryResult;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ItemFieldsResponse;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ItemFieldsResponse;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ResultSetPaginatedDataIDs;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ResultSetPaginatedDataIDs;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ViewerConfiguration;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ViewerConfiguration;
|
||||||
|
@ -48,7 +48,7 @@ public interface GeoportalDataViewerServiceAsync {
|
||||||
void parseWmsRequest(String wmsRequest, String layerName, AsyncCallback<GeoInformationForWMSRequest> callback);
|
void parseWmsRequest(String wmsRequest, String layerName, AsyncCallback<GeoInformationForWMSRequest> callback);
|
||||||
|
|
||||||
void getDataResult(List<LayerObject> layerObjects, String mapSrsName, BoundsMap mapBBOX, int maxWFSFeature,
|
void getDataResult(List<LayerObject> layerObjects, String mapSrsName, BoundsMap mapBBOX, int maxWFSFeature,
|
||||||
double zoomLevel, AsyncCallback<List<GeoportalSpatialQueryResult>> callback);
|
double zoomLevel, AsyncCallback<List<GeoNaSpatialQueryResult>> callback);
|
||||||
|
|
||||||
void getMyLogin(AsyncCallback<String> callback);
|
void getMyLogin(AsyncCallback<String> callback);
|
||||||
|
|
||||||
|
@ -60,7 +60,7 @@ public interface GeoportalDataViewerServiceAsync {
|
||||||
AsyncCallback<List<GCubeSDIViewerLayerDV>> asyncCallback);
|
AsyncCallback<List<GCubeSDIViewerLayerDV>> asyncCallback);
|
||||||
|
|
||||||
void getWFSFeatures(List<LayerObject> layerObjects, String mapSrsName, BoundsMap selectBBOX, int maxWFSFeature,
|
void getWFSFeatures(List<LayerObject> layerObjects, String mapSrsName, BoundsMap selectBBOX, int maxWFSFeature,
|
||||||
double zoomLevel, AsyncCallback<List<GeoportalSpatialQueryResult>> callback);
|
double zoomLevel, AsyncCallback<List<GeoNaSpatialQueryResult>> callback);
|
||||||
|
|
||||||
void getListBaseLayers(AsyncCallback<List<BaseMapLayer>> callback);
|
void getListBaseLayers(AsyncCallback<List<BaseMapLayer>> callback);
|
||||||
|
|
||||||
|
@ -93,6 +93,4 @@ public interface GeoportalDataViewerServiceAsync {
|
||||||
|
|
||||||
void getCountFor(String profileID, String phase, String status, AsyncCallback<Integer> callback);
|
void getCountFor(String profileID, String phase, String status, AsyncCallback<Integer> callback);
|
||||||
|
|
||||||
void checkExportAsPDFConfig(AsyncCallback<Boolean> callback);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,7 +40,7 @@ import org.gcube.portlets.user.geoportaldataviewer.client.ui.ModalWindow;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.ProjectUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.ProjectUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.util.StringUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.util.StringUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.util.URLUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.util.URLUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoportalSpatialQueryResult;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoNaSpatialQueryResult;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.GeoQuery;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.GeoQuery;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.LayerItem;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.LayerItem;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.LayerObject;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.LayerObject;
|
||||||
|
@ -190,7 +190,7 @@ public class LayerManager {
|
||||||
|
|
||||||
GeoportalDataViewerServiceAsync.Util.getInstance().getDataResult(listLO, olMap.getProjectionCode(),
|
GeoportalDataViewerServiceAsync.Util.getInstance().getDataResult(listLO, olMap.getProjectionCode(),
|
||||||
mapBBOX, GeoportalDataViewerConstants.MAX_WFS_FEATURES, olMap.getCurrentZoomLevel(),
|
mapBBOX, GeoportalDataViewerConstants.MAX_WFS_FEATURES, olMap.getCurrentZoomLevel(),
|
||||||
new AsyncCallback<List<GeoportalSpatialQueryResult>>() {
|
new AsyncCallback<List<GeoNaSpatialQueryResult>>() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
|
@ -199,7 +199,7 @@ public class LayerManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(List<GeoportalSpatialQueryResult> listGeonaDataObjects) {
|
public void onSuccess(List<GeoNaSpatialQueryResult> listGeonaDataObjects) {
|
||||||
|
|
||||||
if (listGeonaDataObjects == null)
|
if (listGeonaDataObjects == null)
|
||||||
return;
|
return;
|
||||||
|
@ -221,7 +221,7 @@ public class LayerManager {
|
||||||
List<FeatureRow> theFeatures = null;
|
List<FeatureRow> theFeatures = null;
|
||||||
|
|
||||||
// TODO SWTCH FOR EARCH ITEM TYPE
|
// TODO SWTCH FOR EARCH ITEM TYPE
|
||||||
for (final GeoportalSpatialQueryResult geoNaDataObject : listGeonaDataObjects) {
|
for (final GeoNaSpatialQueryResult geoNaDataObject : listGeonaDataObjects) {
|
||||||
GWT.log("GeoNaDataObject: " + geoNaDataObject);
|
GWT.log("GeoNaDataObject: " + geoNaDataObject);
|
||||||
List<FeatureRow> features = geoNaDataObject.getFeatures();
|
List<FeatureRow> features = geoNaDataObject.getFeatures();
|
||||||
LayerItem layerItem = geoNaDataObject.getSourceLayerObject().getLayerItem();
|
LayerItem layerItem = geoNaDataObject.getSourceLayerObject().getLayerItem();
|
||||||
|
@ -709,7 +709,7 @@ public class LayerManager {
|
||||||
* @param listGeoNaDataObject the list geo na data object
|
* @param listGeoNaDataObject the list geo na data object
|
||||||
* @param queryClick the query click
|
* @param queryClick the query click
|
||||||
*/
|
*/
|
||||||
public void showPopupInfoForLayer(List<GeoportalSpatialQueryResult> listGeoNaDataObject, ExtentWrapped queryClick) {
|
public void showPopupInfoForLayer(List<GeoNaSpatialQueryResult> listGeoNaDataObject, ExtentWrapped queryClick) {
|
||||||
GWT.log("showPopupInfoForLayer called for " + listGeoNaDataObject);
|
GWT.log("showPopupInfoForLayer called for " + listGeoNaDataObject);
|
||||||
|
|
||||||
ScrollPanel scrollPanel = new ScrollPanel();
|
ScrollPanel scrollPanel = new ScrollPanel();
|
||||||
|
@ -767,7 +767,7 @@ public class LayerManager {
|
||||||
// }
|
// }
|
||||||
|
|
||||||
String prevProjectId = "";
|
String prevProjectId = "";
|
||||||
for (GeoportalSpatialQueryResult geoNaSpatialQueryResult : listGeoNaDataObject) {
|
for (GeoNaSpatialQueryResult geoNaSpatialQueryResult : listGeoNaDataObject) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
Set<String> indexLayers = mapIndexLayerObjects.keySet();
|
Set<String> indexLayers = mapIndexLayerObjects.keySet();
|
||||||
|
@ -1123,7 +1123,7 @@ public class LayerManager {
|
||||||
* @param feature the feature
|
* @param feature the feature
|
||||||
* @param onFailureCenterTo the on failure center to
|
* @param onFailureCenterTo the on failure center to
|
||||||
*/
|
*/
|
||||||
public void showPopupInfoForCentroidLayer(GeoportalSpatialQueryResult geoNaDataObject, FeatureRow feature,
|
public void showPopupInfoForCentroidLayer(GeoNaSpatialQueryResult geoNaDataObject, FeatureRow feature,
|
||||||
Coordinate onFailureCenterTo) {
|
Coordinate onFailureCenterTo) {
|
||||||
GWT.log("showPopupInfoForCentroidLayer showing feature: " + feature);
|
GWT.log("showPopupInfoForCentroidLayer showing feature: " + feature);
|
||||||
GWT.log("showPopupInfoForCentroidLayer showing layerObject: " + geoNaDataObject.getSourceLayerObject());
|
GWT.log("showPopupInfoForCentroidLayer showing layerObject: " + geoNaDataObject.getSourceLayerObject());
|
||||||
|
|
|
@ -8,7 +8,7 @@ import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewer;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewer;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants.MAP_PROJECTION;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants.MAP_PROJECTION;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalImages;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAImages;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.BaseMapLayer;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.BaseMapLayer;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.GeoQuery;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.GeoQuery;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.GeoQuery.TYPE;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.GeoQuery.TYPE;
|
||||||
|
@ -87,7 +87,7 @@ public class LightOpenLayerMap {
|
||||||
|
|
||||||
private ol.layer.Vector geometryLayer;
|
private ol.layer.Vector geometryLayer;
|
||||||
|
|
||||||
private String markerURL = GeoportalImages.ICONS.mapMarkerIcon().getURL();
|
private String markerURL = GNAImages.ICONS.mapMarkerIcon().getURL();
|
||||||
|
|
||||||
private LayerOrder layerOrder = new LayerOrder();
|
private LayerOrder layerOrder = new LayerOrder();
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import com.github.gwtbootstrap.client.ui.constants.BaseIconType;
|
||||||
import com.google.gwt.core.client.GWT;
|
import com.google.gwt.core.client.GWT;
|
||||||
import com.google.gwt.resources.client.ClientBundle;
|
import com.google.gwt.resources.client.ClientBundle;
|
||||||
|
|
||||||
public interface GeoportalIcons extends ClientBundle {
|
public interface GNAIcons extends ClientBundle {
|
||||||
|
|
||||||
/** My custom base icon collection */
|
/** My custom base icon collection */
|
||||||
public enum CustomIconType implements BaseIconType {
|
public enum CustomIconType implements BaseIconType {
|
||||||
|
@ -15,7 +15,7 @@ public interface GeoportalIcons extends ClientBundle {
|
||||||
|
|
||||||
/** Inject the icon's css once at first usage */
|
/** Inject the icon's css once at first usage */
|
||||||
static {
|
static {
|
||||||
GeoportalImages icons = GWT.create(GeoportalImages.class);
|
GNAImages icons = GWT.create(GNAImages.class);
|
||||||
icons.css().ensureInjected();
|
icons.css().ensureInjected();
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,13 +5,13 @@ import com.google.gwt.resources.client.ClientBundle;
|
||||||
import com.google.gwt.resources.client.CssResource;
|
import com.google.gwt.resources.client.CssResource;
|
||||||
import com.google.gwt.resources.client.ImageResource;
|
import com.google.gwt.resources.client.ImageResource;
|
||||||
|
|
||||||
public interface GeoportalImages extends ClientBundle {
|
public interface GNAImages extends ClientBundle {
|
||||||
|
|
||||||
/** Get access to the css resource during gwt compilation */
|
/** Get access to the css resource during gwt compilation */
|
||||||
@Source("baseIcons.css")
|
@Source("baseIcons.css")
|
||||||
CssResource css();
|
CssResource css();
|
||||||
|
|
||||||
public static final GeoportalImages ICONS = GWT.create(GeoportalImages.class);
|
public static final GNAImages ICONS = GWT.create(GNAImages.class);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Our sample image icon. Makes the image resource for the gwt-compiler's css
|
* Our sample image icon. Makes the image resource for the gwt-compiler's css
|
|
@ -22,8 +22,8 @@ import org.gcube.portlets.user.geoportaldataviewer.client.events.ChangeMapLayerE
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.MapExtentToEvent;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.MapExtentToEvent;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.collections.OpenCollectionEvent;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.collections.OpenCollectionEvent;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayerMap;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.OpenLayerMap;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalIcons;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAIcons;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalImages;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAImages;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.search.SearchFacilityUI;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.search.SearchFacilityUI;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.crossfiltering.CrossFilteringLayerPanel;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.crossfiltering.CrossFilteringLayerPanel;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.customoverlays.OverlayCustomLayerPanel;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.customoverlays.OverlayCustomLayerPanel;
|
||||||
|
@ -193,19 +193,19 @@ public class GeonaDataViewMainPanel extends Composite {
|
||||||
dataBoxSelection.setIcon(IconType.BOOKMARK);
|
dataBoxSelection.setIcon(IconType.BOOKMARK);
|
||||||
removeQuery.setIcon(IconType.REMOVE);
|
removeQuery.setIcon(IconType.REMOVE);
|
||||||
|
|
||||||
Image italyImg = new Image(GeoportalImages.ICONS.italyIcon());
|
Image italyImg = new Image(GNAImages.ICONS.italyIcon());
|
||||||
italyImg.getElement().getStyle().setPaddingLeft(20, Unit.PX);
|
italyImg.getElement().getStyle().setPaddingLeft(20, Unit.PX);
|
||||||
extentToItaly.getElement().appendChild(italyImg.getElement());
|
extentToItaly.getElement().appendChild(italyImg.getElement());
|
||||||
extentToItaly.setWidth("140px");
|
extentToItaly.setWidth("140px");
|
||||||
|
|
||||||
Image worldImg = new Image(GeoportalImages.ICONS.worldIcon());
|
Image worldImg = new Image(GNAImages.ICONS.worldIcon());
|
||||||
worldImg.getElement().getStyle().setPaddingLeft(20, Unit.PX);
|
worldImg.getElement().getStyle().setPaddingLeft(20, Unit.PX);
|
||||||
extentToEarth.getElement().appendChild(worldImg.getElement());
|
extentToEarth.getElement().appendChild(worldImg.getElement());
|
||||||
extentToEarth.setWidth("140px");
|
extentToEarth.setWidth("140px");
|
||||||
|
|
||||||
// linkMap.setCustomIconStyle(GeoportalIcons.CustomIconType.MAP.get());
|
// linkMap.setCustomIconStyle(GNAIcons.CustomIconType.MAP.get());
|
||||||
linkPresetLocation.setCustomIconStyle(GeoportalIcons.CustomIconType.PRESET_LOCATION.get());
|
linkPresetLocation.setCustomIconStyle(GNAIcons.CustomIconType.PRESET_LOCATION.get());
|
||||||
linkLayers.setCustomIconStyle(GeoportalIcons.CustomIconType.LAYERS.get());
|
linkLayers.setCustomIconStyle(GNAIcons.CustomIconType.LAYERS.get());
|
||||||
|
|
||||||
openCollectionDropDown.setIcon(IconType.COMPASS);
|
openCollectionDropDown.setIcon(IconType.COMPASS);
|
||||||
|
|
||||||
|
|
|
@ -4,11 +4,9 @@ import java.util.List;
|
||||||
|
|
||||||
import org.gcube.application.geoportalcommon.shared.GeoportalItemReferences;
|
import org.gcube.application.geoportalcommon.shared.GeoportalItemReferences;
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.geojson.GeoJSON;
|
import org.gcube.application.geoportalcommon.shared.geoportal.geojson.GeoJSON;
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.project.ProjectDV;
|
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.project.RelationshipDV;
|
import org.gcube.application.geoportalcommon.shared.geoportal.project.RelationshipDV;
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.view.ProjectView;
|
import org.gcube.application.geoportalcommon.shared.geoportal.view.ProjectView;
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.view.SectionView;
|
import org.gcube.application.geoportalcommon.shared.geoportal.view.SectionView;
|
||||||
import org.gcube.portal.clientcontext.client.GCubeClientContext;
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants.MAP_PROJECTION;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants.MAP_PROJECTION;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerServiceAsync;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerServiceAsync;
|
||||||
|
@ -27,7 +25,6 @@ import com.github.gwtbootstrap.client.ui.Button;
|
||||||
import com.github.gwtbootstrap.client.ui.constants.ButtonType;
|
import com.github.gwtbootstrap.client.ui.constants.ButtonType;
|
||||||
import com.github.gwtbootstrap.client.ui.constants.IconType;
|
import com.github.gwtbootstrap.client.ui.constants.IconType;
|
||||||
import com.google.gwt.core.client.GWT;
|
import com.google.gwt.core.client.GWT;
|
||||||
import com.google.gwt.dom.client.FormElement;
|
|
||||||
import com.google.gwt.dom.client.UListElement;
|
import com.google.gwt.dom.client.UListElement;
|
||||||
import com.google.gwt.event.dom.client.ClickEvent;
|
import com.google.gwt.event.dom.client.ClickEvent;
|
||||||
import com.google.gwt.event.dom.client.ClickHandler;
|
import com.google.gwt.event.dom.client.ClickHandler;
|
||||||
|
@ -38,16 +35,8 @@ import com.google.gwt.user.client.Random;
|
||||||
import com.google.gwt.user.client.Window;
|
import com.google.gwt.user.client.Window;
|
||||||
import com.google.gwt.user.client.rpc.AsyncCallback;
|
import com.google.gwt.user.client.rpc.AsyncCallback;
|
||||||
import com.google.gwt.user.client.ui.Composite;
|
import com.google.gwt.user.client.ui.Composite;
|
||||||
import com.google.gwt.user.client.ui.FormPanel;
|
|
||||||
import com.google.gwt.user.client.ui.FormPanel.SubmitCompleteEvent;
|
|
||||||
import com.google.gwt.user.client.ui.FormPanel.SubmitCompleteHandler;
|
|
||||||
import com.google.gwt.user.client.ui.FormPanel.SubmitEvent;
|
|
||||||
import com.google.gwt.user.client.ui.FormPanel.SubmitHandler;
|
|
||||||
import com.google.gwt.user.client.ui.HTML;
|
import com.google.gwt.user.client.ui.HTML;
|
||||||
import com.google.gwt.user.client.ui.HTMLPanel;
|
import com.google.gwt.user.client.ui.HTMLPanel;
|
||||||
import com.google.gwt.user.client.ui.Hidden;
|
|
||||||
import com.google.gwt.user.client.ui.RootPanel;
|
|
||||||
import com.google.gwt.user.client.ui.VerticalPanel;
|
|
||||||
import com.google.gwt.user.client.ui.Widget;
|
import com.google.gwt.user.client.ui.Widget;
|
||||||
|
|
||||||
import ol.Coordinate;
|
import ol.Coordinate;
|
||||||
|
@ -94,9 +83,6 @@ public class ProjectViewer extends Composite {
|
||||||
@UiField
|
@UiField
|
||||||
Button expandButton;
|
Button expandButton;
|
||||||
|
|
||||||
@UiField
|
|
||||||
Button exportButton;
|
|
||||||
|
|
||||||
@UiField
|
@UiField
|
||||||
Button relationshipsButton;
|
Button relationshipsButton;
|
||||||
|
|
||||||
|
@ -150,22 +136,6 @@ public class ProjectViewer extends Composite {
|
||||||
this.geoportalItemReferences = geoportalItemRefs;
|
this.geoportalItemReferences = geoportalItemRefs;
|
||||||
this.applicationBus = applicationBus;
|
this.applicationBus = applicationBus;
|
||||||
|
|
||||||
GeoportalDataViewerServiceAsync.Util.getInstance().checkExportAsPDFConfig(new AsyncCallback<Boolean>() {
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onFailure(Throwable caught) {
|
|
||||||
// TODO Auto-generated method stub
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onSuccess(Boolean result) {
|
|
||||||
GWT.log("Export as PDF visible: " + result);
|
|
||||||
exportButton.setVisible(result);
|
|
||||||
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
final String theTitle = projectView.getTheProjectDV().getProfileName() != null
|
final String theTitle = projectView.getTheProjectDV().getProfileName() != null
|
||||||
? projectView.getTheProjectDV().getProfileName()
|
? projectView.getTheProjectDV().getProfileName()
|
||||||
: "Project ID: " + projectView.getTheProjectDV().getId();
|
: "Project ID: " + projectView.getTheProjectDV().getId();
|
||||||
|
@ -213,79 +183,6 @@ public class ProjectViewer extends Composite {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
exportButton.setType(ButtonType.LINK);
|
|
||||||
exportButton.setIcon(IconType.FILE);
|
|
||||||
exportButton.setTitle("Export as PDF");
|
|
||||||
exportButton.setVisible(false);
|
|
||||||
|
|
||||||
exportButton.addClickHandler(new ClickHandler() {
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onClick(ClickEvent event) {
|
|
||||||
String theProjectName = "";
|
|
||||||
try {
|
|
||||||
theProjectName = (String) projectView.getTheProjectDV().getTheDocument().getFirstEntryOfMap()
|
|
||||||
.getValue();
|
|
||||||
theProjectName = theProjectName != null ? theProjectName
|
|
||||||
: "Project ID: " + projectView.getTheProjectDV().getId();
|
|
||||||
} catch (Exception e) {
|
|
||||||
// TODO: handle exception
|
|
||||||
}
|
|
||||||
|
|
||||||
// Reading contextId and userId from GCubeClientContext
|
|
||||||
String currentContextId = GCubeClientContext.getCurrentContextId();
|
|
||||||
String currentUserId = GCubeClientContext.getCurrentUserId();
|
|
||||||
|
|
||||||
ProjectDV thePDV = projectView.getTheProjectDV();
|
|
||||||
|
|
||||||
final String targetWindow = "target_window_" + Random.nextInt() + "_" + Random.nextInt();
|
|
||||||
|
|
||||||
final FormPanel form = new FormPanel();
|
|
||||||
final FormElement fe = form.getElement().cast();
|
|
||||||
//NewBrowserWindow theNewTabWindow = NewBrowserWindow.open("", "", null);
|
|
||||||
RootPanel.get().add(form);
|
|
||||||
VerticalPanel panel = new VerticalPanel();
|
|
||||||
form.setWidget(panel);
|
|
||||||
form.setAction(GeoportalDataViewerConstants.GEOPORTAL_EXPORT_ACTION_SERVLET);
|
|
||||||
form.setEncoding(FormPanel.ENCODING_URLENCODED);
|
|
||||||
form.setMethod(FormPanel.METHOD_POST);
|
|
||||||
panel.add(new Hidden(GeoportalDataViewerConstants.UCD_ID_PARAMETER, thePDV.getProfileID()));
|
|
||||||
panel.add(new Hidden(GeoportalDataViewerConstants.PROIECT_ID_PARAMETER, thePDV.getId()));
|
|
||||||
panel.add(new Hidden(GeoportalDataViewerConstants.CONTEXT_ID_PARAMETER, currentContextId));
|
|
||||||
panel.add(new Hidden(GeoportalDataViewerConstants.USER_ID_PARAMETER, currentUserId));
|
|
||||||
|
|
||||||
if(myLogin!=null) {
|
|
||||||
panel.add(new Hidden(GeoportalDataViewerConstants.USERNAME_PARAMETER, myLogin));
|
|
||||||
}
|
|
||||||
|
|
||||||
// final Modal contactinServiceModal = new Modal(true, true);
|
|
||||||
// contactinServiceModal.setCloseVisible(false);
|
|
||||||
// contactinServiceModal.setTitle("Export");
|
|
||||||
// FlowPanel panelMsg = new FlowPanel();
|
|
||||||
// panelMsg.add(new HTML("Contacting the service..."));
|
|
||||||
// contactinServiceModal.add(panelMsg);
|
|
||||||
// contactinServiceModal.show();
|
|
||||||
|
|
||||||
// Add an event handler to the form.
|
|
||||||
form.addSubmitHandler(new SubmitHandler() {
|
|
||||||
public void onSubmit(SubmitEvent event) {
|
|
||||||
GWT.log("onSubmit done");
|
|
||||||
fe.setTarget(targetWindow);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
form.addSubmitCompleteHandler(new SubmitCompleteHandler() {
|
|
||||||
public void onSubmitComplete(SubmitCompleteEvent event) {
|
|
||||||
GWT.log("onSubmitComplete done");
|
|
||||||
//contactinServiceModal.hide();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
form.submit();
|
|
||||||
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
relationshipsButton.setType(ButtonType.LINK);
|
relationshipsButton.setType(ButtonType.LINK);
|
||||||
relationshipsButton.setIcon(IconType.LINK);
|
relationshipsButton.setIcon(IconType.LINK);
|
||||||
relationshipsButton.setTitle("Show Relationships of this Project");
|
relationshipsButton.setTitle("Show Relationships of this Project");
|
||||||
|
@ -343,6 +240,14 @@ public class ProjectViewer extends Composite {
|
||||||
public void onClick(ClickEvent event) {
|
public void onClick(ClickEvent event) {
|
||||||
boolean visible = toc_list_container.isVisible();
|
boolean visible = toc_list_container.isVisible();
|
||||||
setTocContentVisible(!visible);
|
setTocContentVisible(!visible);
|
||||||
|
|
||||||
|
// if (visible) {
|
||||||
|
// toc_list_container.setVisible(false);
|
||||||
|
// reduceToc.setIcon(IconType.PLUS_SIGN_ALT);
|
||||||
|
// } else {
|
||||||
|
// toc_list_container.setVisible(true);
|
||||||
|
// reduceToc.setIcon(IconType.MINUS_SIGN_ALT);
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -44,10 +44,9 @@
|
||||||
<g:HorizontalPanel
|
<g:HorizontalPanel
|
||||||
addStyleNames="functionalities-style">
|
addStyleNames="functionalities-style">
|
||||||
<b:Button ui:field="shareButton">Share</b:Button>
|
<b:Button ui:field="shareButton">Share</b:Button>
|
||||||
<b:Button ui:field="exportButton">Export</b:Button>
|
|
||||||
<b:Button ui:field="expandButton">Expand</b:Button>
|
<b:Button ui:field="expandButton">Expand</b:Button>
|
||||||
<b:Button ui:field="relationshipsButton">Relationships</b:Button>
|
<b:Button ui:field="relationshipsButton">Relationships</b:Button>
|
||||||
<b:Button ui:field="addLayersToMap">Add Layers</b:Button>
|
<b:Button ui:field="addLayersToMap">Add Layers to Map</b:Button>
|
||||||
</g:HorizontalPanel>
|
</g:HorizontalPanel>
|
||||||
<g:HTMLPanel ui:field="centroidPanel"></g:HTMLPanel>
|
<g:HTMLPanel ui:field="centroidPanel"></g:HTMLPanel>
|
||||||
<g:HTMLPanel ui:field="tableOfContentPanel"
|
<g:HTMLPanel ui:field="tableOfContentPanel"
|
||||||
|
|
|
@ -7,7 +7,7 @@ import org.gcube.application.geoportalcommon.shared.geoportal.project.ProjectDV;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerServiceAsync;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerServiceAsync;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.ShowDetailsEvent;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.ShowDetailsEvent;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.ShowDetailsEvent.EVENT_SOURCE;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.ShowDetailsEvent.EVENT_SOURCE;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalImages;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAImages;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.ProjectUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.ProjectUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.util.LoaderIcon;
|
import org.gcube.portlets.user.geoportaldataviewer.client.util.LoaderIcon;
|
||||||
|
|
||||||
|
@ -45,7 +45,7 @@ public class TimelineRelationPanel extends Composite {
|
||||||
Anchor timelinePopupCloser;
|
Anchor timelinePopupCloser;
|
||||||
|
|
||||||
private LoaderIcon loaderData = new LoaderIcon("Loading data... please wait",
|
private LoaderIcon loaderData = new LoaderIcon("Loading data... please wait",
|
||||||
new Image(GeoportalImages.ICONS.spinnerClock()));
|
new Image(GNAImages.ICONS.spinnerClock()));
|
||||||
|
|
||||||
private TimelineRelationPanel instance = this;
|
private TimelineRelationPanel instance = this;
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerSer
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.DoActionOnDetailLayersEvent;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.DoActionOnDetailLayersEvent;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.DoActionOnDetailLayersEvent.DO_LAYER_ACTION;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.DoActionOnDetailLayersEvent.DO_LAYER_ACTION;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.events.DoActionOnDetailLayersEvent.SwapLayer;
|
import org.gcube.portlets.user.geoportaldataviewer.client.events.DoActionOnDetailLayersEvent.SwapLayer;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalImages;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAImages;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.ProjectUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.cms.project.ProjectUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.util.LoaderIcon;
|
import org.gcube.portlets.user.geoportaldataviewer.client.util.LoaderIcon;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.util.StringUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.client.util.StringUtil;
|
||||||
|
@ -50,11 +50,11 @@ public class DragDropLayer extends FlowPanel {
|
||||||
private static DragDropLayer draggingTarget = null;
|
private static DragDropLayer draggingTarget = null;
|
||||||
final boolean droppable;
|
final boolean droppable;
|
||||||
private Label labelLayerName;
|
private Label labelLayerName;
|
||||||
private Image imgLayerVisible = new Image(GeoportalImages.ICONS.layerVisible());
|
private Image imgLayerVisible = new Image(GNAImages.ICONS.layerVisible());
|
||||||
private Image imgLayerInvisible = new Image(GeoportalImages.ICONS.layerInvisible());
|
private Image imgLayerInvisible = new Image(GNAImages.ICONS.layerInvisible());
|
||||||
|
|
||||||
private Image imgLocate = new Image(GeoportalImages.ICONS.locate());
|
private Image imgLocate = new Image(GNAImages.ICONS.locate());
|
||||||
private Image imgLocateNone = new Image(GeoportalImages.ICONS.locateNone());
|
private Image imgLocateNone = new Image(GNAImages.ICONS.locateNone());
|
||||||
private boolean locateEnabled = false;
|
private boolean locateEnabled = false;
|
||||||
private HTML buttonLocate = new HTML();
|
private HTML buttonLocate = new HTML();
|
||||||
|
|
||||||
|
|
|
@ -146,13 +146,13 @@ public class DialogShareableLink extends Composite {
|
||||||
/**
|
/**
|
||||||
* Instantiates a new dialog shareable link.
|
* Instantiates a new dialog shareable link.
|
||||||
*
|
*
|
||||||
* @param itemRef the item ref
|
* @param item the item
|
||||||
* @param version the version
|
* @param version the version
|
||||||
*/
|
*/
|
||||||
public DialogShareableLink(GeoportalItemReferences itemRef, String version) {
|
public DialogShareableLink(GeoportalItemReferences item, String version) {
|
||||||
initWidget(uiBinder.createAndBindUi(this));
|
initWidget(uiBinder.createAndBindUi(this));
|
||||||
|
|
||||||
this.geonItemRef = itemRef;
|
this.geonItemRef = item;
|
||||||
this.fileVersion = version;
|
this.fileVersion = version;
|
||||||
this.actionAlert.setAnimation(true);
|
this.actionAlert.setAnimation(true);
|
||||||
|
|
||||||
|
@ -186,7 +186,7 @@ public class DialogShareableLink extends Composite {
|
||||||
showLoadingIcon(true);
|
showLoadingIcon(true);
|
||||||
|
|
||||||
// alertFilePublicLink.setVisible(true);
|
// alertFilePublicLink.setVisible(true);
|
||||||
loadAndShowPublicLinksForItem(itemRef);
|
loadAndShowPublicLinksForItem(item);
|
||||||
// getElement().setClassName("gwt-DialogBoxNew");
|
// getElement().setClassName("gwt-DialogBoxNew");
|
||||||
modalBox.setTitle("Share Link...");
|
modalBox.setTitle("Share Link...");
|
||||||
ModalFooter modalFooter = new ModalFooter();
|
ModalFooter modalFooter = new ModalFooter();
|
||||||
|
|
|
@ -9,7 +9,7 @@ import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerCon
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.ExtentWrapped;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.ExtentWrapped;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.LightOpenLayerMap;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.LightOpenLayerMap;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.gis.MapUtils;
|
import org.gcube.portlets.user.geoportaldataviewer.client.gis.MapUtils;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalIcons;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAIcons;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.map.ExtentMapUtil.Location;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.map.ExtentMapUtil.Location;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.ui.map.ExtentMapUtil.PLACE;
|
import org.gcube.portlets.user.geoportaldataviewer.client.ui.map.ExtentMapUtil.PLACE;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.BaseMapLayer;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.BaseMapLayer;
|
||||||
|
@ -86,7 +86,7 @@ public class MapView extends Composite {
|
||||||
theMapPanel.setWidth(internalMapWidth);
|
theMapPanel.setWidth(internalMapWidth);
|
||||||
theMapPanel.setHeight(internalMapHeight);
|
theMapPanel.setHeight(internalMapHeight);
|
||||||
|
|
||||||
linkMap.setCustomIconStyle(GeoportalIcons.CustomIconType.MAP.get());
|
linkMap.setCustomIconStyle(GNAIcons.CustomIconType.MAP.get());
|
||||||
|
|
||||||
Scheduler.get().scheduleDeferred(new ScheduledCommand() {
|
Scheduler.get().scheduleDeferred(new ScheduledCommand() {
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
*/
|
*/
|
||||||
package org.gcube.portlets.user.geoportaldataviewer.client.util;
|
package org.gcube.portlets.user.geoportaldataviewer.client.util;
|
||||||
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GeoportalImages;
|
import org.gcube.portlets.user.geoportaldataviewer.client.resources.GNAImages;
|
||||||
|
|
||||||
import com.google.gwt.user.client.ui.HTML;
|
import com.google.gwt.user.client.ui.HTML;
|
||||||
import com.google.gwt.user.client.ui.HorizontalPanel;
|
import com.google.gwt.user.client.ui.HorizontalPanel;
|
||||||
|
@ -18,7 +18,7 @@ import com.google.gwt.user.client.ui.Image;
|
||||||
public class LoaderIcon extends HorizontalPanel{
|
public class LoaderIcon extends HorizontalPanel{
|
||||||
|
|
||||||
|
|
||||||
private Image imgLoading = new Image(GeoportalImages.ICONS.loading());
|
private Image imgLoading = new Image(GNAImages.ICONS.loading());
|
||||||
private HTML txtLoading = new HTML("");
|
private HTML txtLoading = new HTML("");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -69,7 +69,6 @@ import org.gcube.application.geoportalcommon.util.StringUtil;
|
||||||
import org.gcube.application.geoportalcommon.util.URLParserUtil;
|
import org.gcube.application.geoportalcommon.util.URLParserUtil;
|
||||||
import org.gcube.application.geoportaldatamapper.GcubeProfilesPerUCDIdCache;
|
import org.gcube.application.geoportaldatamapper.GcubeProfilesPerUCDIdCache;
|
||||||
import org.gcube.application.geoportaldatamapper.Geoportal_JSON_Mapper;
|
import org.gcube.application.geoportaldatamapper.Geoportal_JSON_Mapper;
|
||||||
import org.gcube.application.geoportaldatamapper.exporter.Geoportal_PDF_Exporter;
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerService;
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerService;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.gis.FeatureParser;
|
import org.gcube.portlets.user.geoportaldataviewer.server.gis.FeatureParser;
|
||||||
|
@ -81,7 +80,7 @@ import org.gcube.portlets.user.geoportaldataviewer.server.util.HTTPRequestUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.util.SessionUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.server.util.SessionUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.util.TemporalComparatorUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.server.util.TemporalComparatorUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.GCubeCollection;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.GCubeCollection;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoportalSpatialQueryResult;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoNaSpatialQueryResult;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ItemFieldsResponse;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ItemFieldsResponse;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ResultSetPaginatedDataIDs;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ResultSetPaginatedDataIDs;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.ViewerConfiguration;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.ViewerConfiguration;
|
||||||
|
@ -414,14 +413,14 @@ public class GeoportalDataViewerServiceImpl extends RemoteServiceServlet impleme
|
||||||
* @return the WFS features
|
* @return the WFS features
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<GeoportalSpatialQueryResult> getWFSFeatures(List<LayerObject> layerObjects, String mapSrsName,
|
public List<GeoNaSpatialQueryResult> getWFSFeatures(List<LayerObject> layerObjects, String mapSrsName,
|
||||||
BoundsMap selectBBOX, int maxWFSFeature, double zoomLevel) {
|
BoundsMap selectBBOX, int maxWFSFeature, double zoomLevel) {
|
||||||
LOG.info("getWFSFeatures called");
|
LOG.info("getWFSFeatures called");
|
||||||
|
|
||||||
List<GeoportalSpatialQueryResult> listDAO = new ArrayList<GeoportalSpatialQueryResult>(layerObjects.size());
|
List<GeoNaSpatialQueryResult> listDAO = new ArrayList<GeoNaSpatialQueryResult>(layerObjects.size());
|
||||||
|
|
||||||
for (LayerObject layerObject : layerObjects) {
|
for (LayerObject layerObject : layerObjects) {
|
||||||
GeoportalSpatialQueryResult geoDAO = new GeoportalSpatialQueryResult();
|
GeoNaSpatialQueryResult geoDAO = new GeoNaSpatialQueryResult();
|
||||||
List<FeatureRow> features = FeatureParser.getWFSFeatures(layerObject.getLayerItem(), mapSrsName, selectBBOX,
|
List<FeatureRow> features = FeatureParser.getWFSFeatures(layerObject.getLayerItem(), mapSrsName, selectBBOX,
|
||||||
maxWFSFeature);
|
maxWFSFeature);
|
||||||
LOG.debug("For layer name: " + layerObject.getLayerItem().getName() + " got features: " + features);
|
LOG.debug("For layer name: " + layerObject.getLayerItem().getName() + " got features: " + features);
|
||||||
|
@ -618,6 +617,56 @@ public class GeoportalDataViewerServiceImpl extends RemoteServiceServlet impleme
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// public Map<String, List<GroupedLayersDV>> getAvaiableCrossFilteringLayers() {
|
||||||
|
//
|
||||||
|
// Map<String, List<GroupedLayersDV>> mapProfileIDOvelayLayers = new LinkedHashMap<>();
|
||||||
|
//
|
||||||
|
// // Reading UCDs Collections from the session
|
||||||
|
// Map<String, UseCaseDescriptor> ucdCollections = SessionUtil.getAvailableCollections(getThreadLocalRequest());
|
||||||
|
//
|
||||||
|
// for (String profileId : ucdCollections.keySet()) {
|
||||||
|
//
|
||||||
|
// UseCaseDescriptor u = ucdCollections.get(profileId);
|
||||||
|
//
|
||||||
|
// // Loading geoportal_grouped_overlay_layers if exists
|
||||||
|
// GEOPORTAL_DATA_HANDLER theHandler = GEOPORTAL_DATA_HANDLER.geoportal_grouped_cross_filtering;
|
||||||
|
// List<HandlerDeclaration> handlers = u.getHandlersByType(theHandler.getType());
|
||||||
|
//
|
||||||
|
// if (handlers != null && handlers.size() > 0) {
|
||||||
|
// // Loading Handler gcube_profiles
|
||||||
|
// HandlerDeclaration handler = handlers.get(0);
|
||||||
|
// List<GroupedLayersDV> listGroupedCustomLayers = null;
|
||||||
|
// try {
|
||||||
|
//
|
||||||
|
// HandlerDeclarationDV handlerDV = ConvertToDataValueObjectModel.toHandlerDeclarationDV(handler, u,
|
||||||
|
// GEOPORTAL_CONFIGURATION_TYPE.grouped_overlay_layers);
|
||||||
|
//
|
||||||
|
// if (handler != null) {
|
||||||
|
// ConfigurationDV<?> config = handlerDV.getConfiguration();
|
||||||
|
// switch (config.getConfigurationType()) {
|
||||||
|
// case grouped_overlay_layers:
|
||||||
|
// listGroupedCustomLayers = (List<GroupedLayersDV>) config.getConfiguration();
|
||||||
|
// break;
|
||||||
|
// default:
|
||||||
|
// break;
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// } catch (Exception e) {
|
||||||
|
// LOG.error("Error on loading {} config for ucd Id {}. Returning null",
|
||||||
|
// GEOPORTAL_CONFIGURATION_TYPE.grouped_overlay_layers, u.getId());
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// mapProfileIDOvelayLayers.put(profileId, listGroupedCustomLayers);
|
||||||
|
// } else {
|
||||||
|
// LOG.warn("No handler " + theHandler + "found into UCD " + u.getId() + ", continue...");
|
||||||
|
// mapProfileIDOvelayLayers.put(profileId, null);
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// return mapProfileIDOvelayLayers;
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the layer index.
|
* Gets the layer index.
|
||||||
*
|
*
|
||||||
|
@ -1199,7 +1248,7 @@ public class GeoportalDataViewerServiceImpl extends RemoteServiceServlet impleme
|
||||||
* @throws Exception the exception
|
* @throws Exception the exception
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<GeoportalSpatialQueryResult> getDataResult(List<LayerObject> layerObjects, String mapSrsName,
|
public List<GeoNaSpatialQueryResult> getDataResult(List<LayerObject> layerObjects, String mapSrsName,
|
||||||
BoundsMap selectBBOX, int maxWFSFeature, double zoomLevel) throws Exception {
|
BoundsMap selectBBOX, int maxWFSFeature, double zoomLevel) throws Exception {
|
||||||
LOG.info("getDataResult called");
|
LOG.info("getDataResult called");
|
||||||
|
|
||||||
|
@ -1214,13 +1263,13 @@ public class GeoportalDataViewerServiceImpl extends RemoteServiceServlet impleme
|
||||||
+ ", zoomLevel: " + zoomLevel);
|
+ ", zoomLevel: " + zoomLevel);
|
||||||
}
|
}
|
||||||
|
|
||||||
List<GeoportalSpatialQueryResult> listDAO = new ArrayList<GeoportalSpatialQueryResult>(layerObjects.size());
|
List<GeoNaSpatialQueryResult> listDAO = new ArrayList<GeoNaSpatialQueryResult>(layerObjects.size());
|
||||||
|
|
||||||
try {
|
try {
|
||||||
new GeoportalServiceIdentityProxy(this.getThreadLocalRequest());
|
new GeoportalServiceIdentityProxy(this.getThreadLocalRequest());
|
||||||
|
|
||||||
for (LayerObject layerObject : layerObjects) {
|
for (LayerObject layerObject : layerObjects) {
|
||||||
GeoportalSpatialQueryResult geoDAO = new GeoportalSpatialQueryResult();
|
GeoNaSpatialQueryResult geoDAO = new GeoNaSpatialQueryResult();
|
||||||
List<FeatureRow> features = FeatureParser.getWFSFeatures(layerObject.getLayerItem(), mapSrsName,
|
List<FeatureRow> features = FeatureParser.getWFSFeatures(layerObject.getLayerItem(), mapSrsName,
|
||||||
selectBBOX, maxWFSFeature);
|
selectBBOX, maxWFSFeature);
|
||||||
LOG.debug("For layer name: " + layerObject.getLayerItem().getName() + " got features: " + features);
|
LOG.debug("For layer name: " + layerObject.getLayerItem().getName() + " got features: " + features);
|
||||||
|
@ -1829,24 +1878,4 @@ public class GeoportalDataViewerServiceImpl extends RemoteServiceServlet impleme
|
||||||
return integer;
|
return integer;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Boolean checkExportAsPDFConfig() {
|
|
||||||
LOG.debug("checkExportAsPDFConfig called");
|
|
||||||
Boolean configChecked = null;
|
|
||||||
try {
|
|
||||||
new GeoportalServiceIdentityProxy(this.getThreadLocalRequest());
|
|
||||||
configChecked = SessionUtil.getCheckConfigForPFDExporter(this.getThreadLocalRequest());
|
|
||||||
if(configChecked==null) {
|
|
||||||
Geoportal_PDF_Exporter gpdfe = new Geoportal_PDF_Exporter();
|
|
||||||
configChecked = gpdfe.checkConfig();
|
|
||||||
SessionUtil.setCheckConfigForPFDExporter(this.getThreadLocalRequest(), configChecked);
|
|
||||||
}
|
|
||||||
|
|
||||||
LOG.info("Does the 'Export As PDF' config exists? " + configChecked);
|
|
||||||
} catch (Exception e) {
|
|
||||||
LOG.error("Error occurred in checkExportAsPDFConfig", e);
|
|
||||||
}
|
|
||||||
return configChecked;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,257 +0,0 @@
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
package org.gcube.portlets.user.geoportaldataviewer.server;
|
|
||||||
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.io.InputStream;
|
|
||||||
import java.net.HttpURLConnection;
|
|
||||||
import java.net.URL;
|
|
||||||
import java.util.Enumeration;
|
|
||||||
|
|
||||||
import javax.servlet.ServletException;
|
|
||||||
import javax.servlet.http.HttpServlet;
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
|
||||||
import javax.servlet.http.HttpServletResponse;
|
|
||||||
|
|
||||||
import org.apache.commons.io.IOUtils;
|
|
||||||
import org.apache.http.client.methods.HttpGet;
|
|
||||||
import org.gcube.common.portal.PortalContext;
|
|
||||||
import org.gcube.common.scope.api.ScopeProvider;
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants;
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.mongoservice.GeoportalServiceIdentityProxy;
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.util.SessionUtil;
|
|
||||||
import org.gcube.portlets.user.uriresolvermanager.geoportal.GeoportalExporterAPI;
|
|
||||||
import org.slf4j.Logger;
|
|
||||||
import org.slf4j.LoggerFactory;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The Class GeoportalExporterActionServlet.
|
|
||||||
*
|
|
||||||
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
|
|
||||||
*
|
|
||||||
* Apr 23, 2024
|
|
||||||
*/
|
|
||||||
public class GeoportalExporterActionServlet extends HttpServlet {
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
private static final long serialVersionUID = 6037090280489238565L;
|
|
||||||
protected static Logger logger = LoggerFactory.getLogger(GeoportalExporterActionServlet.class);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* {@inheritDoc}
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
public void init() throws ServletException {
|
|
||||||
super.init();
|
|
||||||
logger.trace(GeoportalExporterActionServlet.class.getSimpleName() + " ready.");
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
|
|
||||||
logger.info("doPost Called");
|
|
||||||
serveRequest(req, resp);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Do get.
|
|
||||||
*
|
|
||||||
* @param req the req
|
|
||||||
* @param resp the resp
|
|
||||||
* @throws IOException Signals that an I/O exception has occurred.
|
|
||||||
* @throws ServletException the servlet exception
|
|
||||||
*/
|
|
||||||
public void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException, ServletException {
|
|
||||||
logger.info("doGet Called");
|
|
||||||
sendError(resp,
|
|
||||||
"The request cannot be served (via http GET). Please retry by using the Export facility provided by Data-Viewer UI");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Serve request.
|
|
||||||
*
|
|
||||||
* @param req the req
|
|
||||||
* @param resp the resp
|
|
||||||
* @throws IOException Signals that an I/O exception has occurred.
|
|
||||||
*/
|
|
||||||
public void serveRequest(HttpServletRequest req, HttpServletResponse resp) throws IOException {
|
|
||||||
// setSecretManager();
|
|
||||||
String projectID = req.getParameter(GeoportalDataViewerConstants.PROIECT_ID_PARAMETER);
|
|
||||||
String ucdID = req.getParameter(GeoportalDataViewerConstants.UCD_ID_PARAMETER);
|
|
||||||
String contextID = req.getParameter(GeoportalDataViewerConstants.CONTEXT_ID_PARAMETER);
|
|
||||||
String userID = req.getParameter(GeoportalDataViewerConstants.USER_ID_PARAMETER);
|
|
||||||
String username = req.getParameter(GeoportalDataViewerConstants.USERNAME_PARAMETER);
|
|
||||||
// logger.info("serveRequest called with [projectID: " + projectID + ", ucdID: " + ucdID + ", contextID: " + contextID+"]");
|
|
||||||
logger.info("serveRequest called with [projectID: " + projectID + ", ucdID: " + ucdID + ", contextID: "
|
|
||||||
+ contextID + ", userID: " + userID + ", username: " + username + "]");
|
|
||||||
|
|
||||||
if (contextID == null || contextID.isEmpty())
|
|
||||||
sendError(resp, "Bad Request. No context found!");
|
|
||||||
|
|
||||||
PortalContext pContext = PortalContext.getConfiguration();
|
|
||||||
String scope = pContext.getCurrentScope(contextID);
|
|
||||||
logger.info("The scope is {}", scope);
|
|
||||||
|
|
||||||
try {
|
|
||||||
// Setting header required to {@PortalContext}
|
|
||||||
MutableHttpServletRequest mutableRequest = new MutableHttpServletRequest(req);
|
|
||||||
mutableRequest.putHeader(PortalContext.VRE_ID_ATTR_NAME, contextID);
|
|
||||||
// DEV MODE
|
|
||||||
if (!SessionUtil.isIntoPortal()) {
|
|
||||||
logger.info("DEBUG MODE, putting header " + PortalContext.USER_ID_ATTR_NAME);
|
|
||||||
mutableRequest.putHeader(PortalContext.USER_ID_ATTR_NAME, userID);
|
|
||||||
}
|
|
||||||
|
|
||||||
// IF USERNAME exists, add the userID to request. So performing the request to
|
|
||||||
// exporter service on behalf of the user.
|
|
||||||
if (username != null) {
|
|
||||||
logger.info("Username found, putting header " + PortalContext.USER_ID_ATTR_NAME);
|
|
||||||
mutableRequest.putHeader(PortalContext.USER_ID_ATTR_NAME, userID);
|
|
||||||
}
|
|
||||||
|
|
||||||
ScopeProvider.instance.set(scope);
|
|
||||||
GeoportalServiceIdentityProxy identity = new GeoportalServiceIdentityProxy(mutableRequest);
|
|
||||||
String theToken = identity.getToken();
|
|
||||||
String theIdentity = identity.getIdentity();
|
|
||||||
logger.info("The identity is {}", theIdentity);
|
|
||||||
|
|
||||||
GeoportalExporterAPI geoportalExporterAPI = new GeoportalExporterAPI();
|
|
||||||
URL urlRequest = geoportalExporterAPI.exportProject("pdf", ucdID, projectID, false);
|
|
||||||
String urlToRedirect = urlRequest.toString();
|
|
||||||
logger.info("Performing request to {} with identity description {}", urlToRedirect,
|
|
||||||
identity.getDescription());
|
|
||||||
logger.info("Token is {}", theToken.substring(0, 20) + "_MASKED_TOKEN");
|
|
||||||
|
|
||||||
InputStream is = performHttpRequestToSGService(urlToRedirect, theIdentity, theToken);
|
|
||||||
resp.setContentType("text/html; charset=utf-8");
|
|
||||||
IOUtils.copy(is, resp.getOutputStream());
|
|
||||||
resp.flushBuffer();
|
|
||||||
|
|
||||||
} catch (Exception e) {
|
|
||||||
logger.error("Error occurred when exporting the Project with id: " + projectID, e);
|
|
||||||
sendError(resp, "Error occurred when exporting the Project. Error is: " + e.getMessage());
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Perform http request to SG service.
|
|
||||||
*
|
|
||||||
* @param urlToService the url to service
|
|
||||||
* @param identity the identity
|
|
||||||
* @param token the token
|
|
||||||
* @return the input stream
|
|
||||||
* @throws IOException Signals that an I/O exception has occurred.
|
|
||||||
*/
|
|
||||||
public static InputStream performHttpRequestToSGService(String urlToService, String identity, String token)
|
|
||||||
throws IOException {
|
|
||||||
logger.debug("performHttpRequestToSGService called");
|
|
||||||
try {
|
|
||||||
|
|
||||||
URL url = new URL(urlToService);
|
|
||||||
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
|
|
||||||
// timeout at 60sec
|
|
||||||
conn.setConnectTimeout(6000);
|
|
||||||
conn.setDoOutput(true);
|
|
||||||
|
|
||||||
if (token.length() > 50) {
|
|
||||||
// is JWT TOKEN
|
|
||||||
conn.setRequestProperty("Authorization", "Bearer " + token);
|
|
||||||
} else {
|
|
||||||
// is legacy Token
|
|
||||||
conn.setRequestProperty("gcube-token", token);
|
|
||||||
}
|
|
||||||
|
|
||||||
conn.setRequestProperty("Content-Type", "text/html");
|
|
||||||
conn.setRequestMethod("GET");
|
|
||||||
logger.debug("performHttpRequestToSGService done, returning");
|
|
||||||
return conn.getInputStream();
|
|
||||||
} catch (IOException e) {
|
|
||||||
logger.error("Error on performing request to url " + urlToService, e);
|
|
||||||
throw e;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the headers to target.
|
|
||||||
*
|
|
||||||
* @param httpSource the http source
|
|
||||||
* @param response the response
|
|
||||||
* @return the http servlet response
|
|
||||||
*/
|
|
||||||
public static HttpServletResponse setHeadersToTarget(HttpServletRequest httpSource, HttpServletResponse response) {
|
|
||||||
|
|
||||||
Enumeration<String> headersNames = httpSource.getHeaderNames();
|
|
||||||
while (headersNames.hasMoreElements()) {
|
|
||||||
String headerName = (String) headersNames.nextElement();
|
|
||||||
Enumeration<String> values = httpSource.getHeaders(headerName);
|
|
||||||
while (values.hasMoreElements()) {
|
|
||||||
String value = values.nextElement();
|
|
||||||
logger.info("Copying header {} with value {}", headerName, value);
|
|
||||||
response.addHeader(headerName, value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return response;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the headers to target.
|
|
||||||
*
|
|
||||||
* @param httpSource the http source
|
|
||||||
* @param httpTarget the http target
|
|
||||||
* @return the http get
|
|
||||||
*/
|
|
||||||
public static HttpGet setHeadersToTarget(HttpServletRequest httpSource, HttpGet httpTarget) {
|
|
||||||
|
|
||||||
Enumeration<String> headersNames = httpSource.getHeaderNames();
|
|
||||||
while (headersNames.hasMoreElements()) {
|
|
||||||
String headerName = (String) headersNames.nextElement();
|
|
||||||
Enumeration<String> values = httpSource.getHeaders(headerName);
|
|
||||||
while (values.hasMoreElements()) {
|
|
||||||
String value = values.nextElement();
|
|
||||||
logger.info("Copying header {} with value {}", headerName, value);
|
|
||||||
httpTarget.addHeader(headerName, value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return httpTarget;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Sets the headers to response.
|
|
||||||
*
|
|
||||||
* @param httpSource the http source
|
|
||||||
* @param httpTarget the http target
|
|
||||||
* @return the http get
|
|
||||||
*/
|
|
||||||
public static HttpGet setHeadersToResponse(HttpServletRequest httpSource, HttpGet httpTarget) {
|
|
||||||
|
|
||||||
Enumeration<String> headersNames = httpSource.getHeaderNames();
|
|
||||||
while (headersNames.hasMoreElements()) {
|
|
||||||
String headerName = (String) headersNames.nextElement();
|
|
||||||
Enumeration<String> values = httpSource.getHeaders(headerName);
|
|
||||||
while (values.hasMoreElements()) {
|
|
||||||
String value = values.nextElement();
|
|
||||||
logger.info("Copying header {} with value {}", headerName, value);
|
|
||||||
httpTarget.addHeader(headerName, value);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return httpTarget;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Send response.
|
|
||||||
*
|
|
||||||
* @param response the response
|
|
||||||
* @param message the message
|
|
||||||
* @throws IOException Signals that an I/O exception has occurred.
|
|
||||||
*/
|
|
||||||
protected void sendError(HttpServletResponse response, String message) throws IOException {
|
|
||||||
response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
|
|
||||||
response.setContentType("text/html");
|
|
||||||
response.getWriter().write("<html><head><title>Error</title></head><body>" + message + "</body></html>");
|
|
||||||
response.flushBuffer();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,53 +0,0 @@
|
||||||
package org.gcube.portlets.user.geoportaldataviewer.server;
|
|
||||||
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.Enumeration;
|
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.HashSet;
|
|
||||||
import java.util.Map;
|
|
||||||
import java.util.Set;
|
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
|
||||||
import javax.servlet.http.HttpServletRequestWrapper;
|
|
||||||
|
|
||||||
final class MutableHttpServletRequest extends HttpServletRequestWrapper {
|
|
||||||
// holds custom header and value mapping
|
|
||||||
private final Map<String, String> customHeaders;
|
|
||||||
|
|
||||||
public MutableHttpServletRequest(HttpServletRequest request){
|
|
||||||
super(request);
|
|
||||||
this.customHeaders = new HashMap<String, String>();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void putHeader(String name, String value){
|
|
||||||
this.customHeaders.put(name, value);
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getHeader(String name) {
|
|
||||||
// check the custom headers first
|
|
||||||
String headerValue = customHeaders.get(name);
|
|
||||||
|
|
||||||
if (headerValue != null){
|
|
||||||
return headerValue;
|
|
||||||
}
|
|
||||||
// else return from into the original wrapped object
|
|
||||||
return ((HttpServletRequest) getRequest()).getHeader(name);
|
|
||||||
}
|
|
||||||
|
|
||||||
public Enumeration<String> getHeaderNames() {
|
|
||||||
// create a set of the custom header names
|
|
||||||
Set<String> set = new HashSet<String>(customHeaders.keySet());
|
|
||||||
|
|
||||||
// now add the headers from the wrapped request object
|
|
||||||
@SuppressWarnings("unchecked")
|
|
||||||
Enumeration<String> e = ((HttpServletRequest) getRequest()).getHeaderNames();
|
|
||||||
while (e.hasMoreElements()) {
|
|
||||||
// add the names of the request headers into the list
|
|
||||||
String n = e.nextElement();
|
|
||||||
set.add(n);
|
|
||||||
}
|
|
||||||
|
|
||||||
// create an enumeration from the set and return
|
|
||||||
return Collections.enumeration(set);
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -22,9 +22,9 @@ public class GeoportalServiceIdentityProxy {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(GeoportalServiceIdentityProxy.class);
|
private static final Logger LOG = LoggerFactory.getLogger(GeoportalServiceIdentityProxy.class);
|
||||||
|
|
||||||
private GcubeIdentity gCubeIdentity;
|
private GcubeIdentity gCubeIdentity;
|
||||||
|
|
||||||
private boolean isUser = false;
|
private boolean isUser = false;
|
||||||
|
|
||||||
private boolean isIAMClient = false;
|
private boolean isIAMClient = false;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -57,24 +57,12 @@ public class GeoportalServiceIdentityProxy {
|
||||||
|
|
||||||
gCubeIdentity.setIdentity(request);
|
gCubeIdentity.setIdentity(request);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isUser() {
|
public boolean isUser() {
|
||||||
return isUser;
|
return isUser;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isIAMClient() {
|
public boolean isIAMClient() {
|
||||||
return isIAMClient;
|
return isIAMClient;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getDescription() {
|
|
||||||
return gCubeIdentity.getIdentityDescription();
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getToken() {
|
|
||||||
return gCubeIdentity.getToken();
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getIdentity() {
|
|
||||||
return gCubeIdentity.getIdentity();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,15 +2,16 @@ package org.gcube.portlets.user.geoportaldataviewer.server.mongoservice.accessid
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Interface GcubeIdentity.
|
* The Interface GcubeIdentity.
|
||||||
*
|
*
|
||||||
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
|
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
|
||||||
*
|
*
|
||||||
* Sep 23, 2021
|
* Sep 23, 2021
|
||||||
*/
|
*/
|
||||||
public interface GcubeIdentity {
|
public interface GcubeIdentity {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the identity.
|
* Sets the identity.
|
||||||
*
|
*
|
||||||
|
@ -18,32 +19,10 @@ public interface GcubeIdentity {
|
||||||
* @throws Exception the exception
|
* @throws Exception the exception
|
||||||
*/
|
*/
|
||||||
public void setIdentity(HttpServletRequest httpRequest) throws Exception;
|
public void setIdentity(HttpServletRequest httpRequest) throws Exception;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reset identity.
|
* Reset identity.
|
||||||
*/
|
*/
|
||||||
public void resetIdentity();
|
public void resetIdentity();
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets the identity description.
|
|
||||||
*
|
|
||||||
* @return the identity description
|
|
||||||
*/
|
|
||||||
public String getIdentityDescription();
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets the identity.
|
|
||||||
*
|
|
||||||
* @return the identity
|
|
||||||
*/
|
|
||||||
public String getIdentity();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets the token.
|
|
||||||
*
|
|
||||||
* @return the token
|
|
||||||
*/
|
|
||||||
public String getToken();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,23 +16,18 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(IAMClientIdentity.class);
|
private static final Logger LOG = LoggerFactory.getLogger(IAMClientIdentity.class);
|
||||||
|
|
||||||
private String previousUMAToken = null;
|
private String previousUMAToken = null;
|
||||||
|
|
||||||
private String currentUMAToken = null;
|
|
||||||
|
|
||||||
private String clientId = null;
|
|
||||||
|
|
||||||
private static final String IAM_CLIENT_CREDENTIALS = "IAM_CLIENT_CREDENTIALS";
|
private static final String IAM_CLIENT_CREDENTIALS = "IAM_CLIENT_CREDENTIALS";
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setIdentity(HttpServletRequest httpRequest) throws Exception {
|
public void setIdentity(HttpServletRequest httpRequest) throws Exception {
|
||||||
LOG.info("setIdentity called");
|
LOG.info("setIdentity called");
|
||||||
String currentScope = SessionUtil.getCurrentContext(httpRequest, true);
|
String currentScope = SessionUtil.getCurrentContext(httpRequest, true);
|
||||||
LOG.info("the scope is {}", currentScope);
|
IAMClientCredentials credentials = sessionGetIAMClientCredentials(httpRequest);
|
||||||
IAMClientCredentials credentials = sessionGetIAMClientCredentials(httpRequest);
|
|
||||||
try {
|
try {
|
||||||
if (credentials == null) {
|
if(credentials==null) {
|
||||||
credentials = IAMClientCredentialsReader.getCredentials();
|
credentials = IAMClientCredentialsReader.getCredentials();
|
||||||
sessionSetIAMClientCredentials(httpRequest, credentials);
|
sessionSetIAMClientCredentials(httpRequest,credentials);
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
LOG.error("Error on discovering IAM Client credentials", e);
|
LOG.error("Error on discovering IAM Client credentials", e);
|
||||||
|
@ -40,16 +35,16 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
}
|
}
|
||||||
|
|
||||||
LOG.trace("Read credentials: " + credentials);
|
LOG.trace("Read credentials: " + credentials);
|
||||||
clientId = credentials.getClientId();
|
String umaAcessToken = null;
|
||||||
|
String clientId = credentials.getClientId();
|
||||||
String clientSecret = credentials.getClientSecret();
|
String clientSecret = credentials.getClientSecret();
|
||||||
try {
|
try {
|
||||||
|
|
||||||
LOG.info("Querying KeycloakClientFactory to get UMA token..");
|
LOG.info("Querying KeycloakClientFactory to get UMA token..");
|
||||||
TokenResponse tr = KeycloakClientFactory.newInstance().queryUMAToken(currentScope, clientId, clientSecret, currentScope,
|
TokenResponse tr = KeycloakClientFactory.newInstance().queryUMAToken(clientId, clientSecret, currentScope,
|
||||||
null);
|
null);
|
||||||
|
umaAcessToken = tr.getAccessToken();
|
||||||
currentUMAToken = tr.getAccessToken();
|
if (umaAcessToken != null && !umaAcessToken.isEmpty()) {
|
||||||
if (currentUMAToken != null && !currentUMAToken.isEmpty()) {
|
|
||||||
LOG.info("UMA Access Token read correctly");
|
LOG.info("UMA Access Token read correctly");
|
||||||
} else {
|
} else {
|
||||||
LOG.error("UMA Access Token NOT RETRIEVED!!!");
|
LOG.error("UMA Access Token NOT RETRIEVED!!!");
|
||||||
|
@ -61,8 +56,6 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
LOG.debug("JWT token: " + currentUMAToken.substring(0, 20) + "_MASKED_TOKEN_");
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
// Here the previousUMAToken should be null
|
// Here the previousUMAToken should be null
|
||||||
previousUMAToken = AccessTokenProvider.instance.get();
|
previousUMAToken = AccessTokenProvider.instance.get();
|
||||||
|
@ -71,9 +64,10 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
// silent
|
// silent
|
||||||
}
|
}
|
||||||
|
|
||||||
|
LOG.debug("JWT token: " + umaAcessToken.substring(0, 20) + "_MASKED_TOKEN_");
|
||||||
LOG.info("Setting clientId '" + clientId + "' identity by JWT token in the "
|
LOG.info("Setting clientId '" + clientId + "' identity by JWT token in the "
|
||||||
+ AccessTokenProvider.class.getSimpleName());
|
+ AccessTokenProvider.class.getSimpleName());
|
||||||
AccessTokenProvider.instance.set(currentUMAToken);
|
AccessTokenProvider.instance.set(umaAcessToken);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
LOG.error(e.getMessage(), e);
|
LOG.error(e.getMessage(), e);
|
||||||
throw new Exception(e.getMessage());
|
throw new Exception(e.getMessage());
|
||||||
|
@ -81,11 +75,6 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getToken() {
|
|
||||||
return currentUMAToken;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void resetIdentity() {
|
public void resetIdentity() {
|
||||||
LOG.info("resetIdentity called");
|
LOG.info("resetIdentity called");
|
||||||
|
@ -93,7 +82,7 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
LOG.info("resetIdentity to previous AccessToken");
|
LOG.info("resetIdentity to previous AccessToken");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the IAM client credentials.
|
* Gets the IAM client credentials.
|
||||||
*
|
*
|
||||||
|
@ -114,7 +103,7 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
* Sets the IAM client credentials.
|
* Sets the IAM client credentials.
|
||||||
*
|
*
|
||||||
* @param httpRequest the http request
|
* @param httpRequest the http request
|
||||||
* @param iamCC the iam CC
|
* @param iamCC the iam CC
|
||||||
*/
|
*/
|
||||||
public static void sessionSetIAMClientCredentials(HttpServletRequest httpRequest, IAMClientCredentials iamCC) {
|
public static void sessionSetIAMClientCredentials(HttpServletRequest httpRequest, IAMClientCredentials iamCC) {
|
||||||
HttpSession session = httpRequest.getSession();
|
HttpSession session = httpRequest.getSession();
|
||||||
|
@ -125,15 +114,4 @@ public class IAMClientIdentity implements GcubeIdentity {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getIdentityDescription() {
|
|
||||||
return "ClientId: " + clientId;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getIdentity() {
|
|
||||||
return clientId;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,6 @@ package org.gcube.portlets.user.geoportaldataviewer.server.mongoservice.accessid
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.util.SessionUtil;
|
import org.gcube.portlets.user.geoportaldataviewer.server.util.SessionUtil;
|
||||||
import org.gcube.vomanagement.usermanagement.model.GCubeUser;
|
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
|
@ -11,19 +10,13 @@ public class UserIdentity implements GcubeIdentity {
|
||||||
|
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(UserIdentity.class);
|
private static final Logger LOG = LoggerFactory.getLogger(UserIdentity.class);
|
||||||
|
|
||||||
private HttpServletRequest httpRequest;
|
|
||||||
|
|
||||||
private GCubeUser user;
|
|
||||||
|
|
||||||
public UserIdentity() {
|
public UserIdentity() {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setIdentity(HttpServletRequest httpRequest) throws Exception {
|
public void setIdentity(HttpServletRequest httpRequest) throws Exception {
|
||||||
LOG.info("setIdentity called");
|
LOG.info("setIdentity called");
|
||||||
this.httpRequest = httpRequest;
|
SessionUtil.getCurrentToken(httpRequest, true);
|
||||||
SessionUtil.getCurrentToken(this.httpRequest, true);
|
|
||||||
user = SessionUtil.getCurrentUser(this.httpRequest);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -32,20 +25,4 @@ public class UserIdentity implements GcubeIdentity {
|
||||||
LOG.info("resetIdentity called, doing nothing");
|
LOG.info("resetIdentity called, doing nothing");
|
||||||
// doing nothing
|
// doing nothing
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getToken() {
|
|
||||||
return SessionUtil.getCurrentToken(this.httpRequest, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getIdentityDescription() {
|
|
||||||
return user != null ? "user: " + user.getUsername() : "null";
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public String getIdentity() {
|
|
||||||
return user.getUsername();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -55,8 +55,6 @@ public class SessionUtil {
|
||||||
|
|
||||||
private static final String UCD_COLLECTIONS_SESSION = "THE_UCD_COLLECTIONS";
|
private static final String UCD_COLLECTIONS_SESSION = "THE_UCD_COLLECTIONS";
|
||||||
|
|
||||||
private static final String CHECKED_CONFIG_FOR_PDF_EXPORTER = "CHECKED_CONFIG_FOR_PDF_EXPORTER";
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Checks if is into portal.
|
* Checks if is into portal.
|
||||||
*
|
*
|
||||||
|
@ -347,14 +345,4 @@ public class SessionUtil {
|
||||||
return (Map<String, UseCaseDescriptor>) session.getAttribute(UCD_COLLECTIONS_SESSION);
|
return (Map<String, UseCaseDescriptor>) session.getAttribute(UCD_COLLECTIONS_SESSION);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Boolean getCheckConfigForPFDExporter(HttpServletRequest httpServletRequest) {
|
|
||||||
HttpSession session = httpServletRequest.getSession();
|
|
||||||
return (Boolean) session.getAttribute(CHECKED_CONFIG_FOR_PDF_EXPORTER);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void setCheckConfigForPFDExporter(HttpServletRequest httpServletRequest, Boolean configChecked) {
|
|
||||||
HttpSession session = httpServletRequest.getSession();
|
|
||||||
session.setAttribute(CHECKED_CONFIG_FOR_PDF_EXPORTER, configChecked);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@ package org.gcube.portlets.user.geoportaldataviewer.server.util;
|
||||||
import java.util.Comparator;
|
import java.util.Comparator;
|
||||||
|
|
||||||
import org.gcube.application.geoportalcommon.shared.geoportal.project.ProjectDV;
|
import org.gcube.application.geoportalcommon.shared.geoportal.project.ProjectDV;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoportalSpatialQueryResult;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.GeoNaSpatialQueryResult;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Class TemporalComparatorUtil.
|
* The Class TemporalComparatorUtil.
|
||||||
|
@ -12,7 +12,7 @@ import org.gcube.portlets.user.geoportaldataviewer.shared.GeoportalSpatialQueryR
|
||||||
*
|
*
|
||||||
* Nov 18, 2022
|
* Nov 18, 2022
|
||||||
*/
|
*/
|
||||||
public class TemporalComparatorUtil implements Comparator<GeoportalSpatialQueryResult> {
|
public class TemporalComparatorUtil implements Comparator<GeoNaSpatialQueryResult> {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Compare.
|
* Compare.
|
||||||
|
@ -22,7 +22,7 @@ public class TemporalComparatorUtil implements Comparator<GeoportalSpatialQueryR
|
||||||
* @return the int
|
* @return the int
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public int compare(GeoportalSpatialQueryResult a, GeoportalSpatialQueryResult b) {
|
public int compare(GeoNaSpatialQueryResult a, GeoNaSpatialQueryResult b) {
|
||||||
if (a == null || a.getSourceLayerObject() == null || a.getSourceLayerObject().getProjectDV() == null) {
|
if (a == null || a.getSourceLayerObject() == null || a.getSourceLayerObject().getProjectDV() == null) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,13 +9,13 @@ import org.gcube.portlets.user.geoportaldataviewer.shared.gis.LayerObject;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.wfs.FeatureRow;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.wfs.FeatureRow;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Class GeoportalSpatialQueryResult.
|
* The Class GeoNaSpatialQueryResult.
|
||||||
*
|
*
|
||||||
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
|
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
|
||||||
*
|
*
|
||||||
* Jul 30, 2021
|
* Jul 30, 2021
|
||||||
*/
|
*/
|
||||||
public class GeoportalSpatialQueryResult implements Serializable {
|
public class GeoNaSpatialQueryResult implements Serializable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -23,14 +23,14 @@ public class GeoportalSpatialQueryResult implements Serializable {
|
||||||
private static final long serialVersionUID = 3513120677727206958L;
|
private static final long serialVersionUID = 3513120677727206958L;
|
||||||
private List<FeatureRow> features;
|
private List<FeatureRow> features;
|
||||||
private LayerObject sourceLayerObject;
|
private LayerObject sourceLayerObject;
|
||||||
// Map with couple (mongoId project, list of uploaded GeoportalImages for the
|
// Map with couple (mongoId concessione, list of uploaded GNAImages for the
|
||||||
// project)
|
// concessione)
|
||||||
private Map<String, List<PayloadDV>> mapImages = null;
|
private Map<String, List<PayloadDV>> mapImages = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Instantiates a new geo na data object.
|
* Instantiates a new geo na data object.
|
||||||
*/
|
*/
|
||||||
public GeoportalSpatialQueryResult() {
|
public GeoNaSpatialQueryResult() {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -91,7 +91,7 @@ public class GeoportalSpatialQueryResult implements Serializable {
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
StringBuilder builder = new StringBuilder();
|
StringBuilder builder = new StringBuilder();
|
||||||
builder.append("GeoportalSpatialQueryResult [features=");
|
builder.append("GeoNaSpatialQueryResult [features=");
|
||||||
builder.append(features);
|
builder.append(features);
|
||||||
builder.append(", sourceLayerObject=");
|
builder.append(", sourceLayerObject=");
|
||||||
builder.append(sourceLayerObject);
|
builder.append(sourceLayerObject);
|
|
@ -0,0 +1,16 @@
|
||||||
|
package org.gcube.portlets.user.geoportaldataviewer.shared.gis;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Data
|
||||||
|
public class DisplayCategory implements Serializable {
|
||||||
|
|
||||||
|
|
||||||
|
String title;
|
||||||
|
String description;
|
||||||
|
|
||||||
|
}
|
|
@ -2,13 +2,18 @@ package org.gcube.portlets.user.geoportaldataviewer.shared.gis;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
import org.gcube.application.geoportalcommon.shared.gis.BoundsMap;
|
||||||
|
import org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewerConstants.LayerType;
|
||||||
|
import org.gcube.portlets.user.geoportaldataviewer.client.util.URLUtil;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.wms.Property;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.wms.Property;
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.wms.ZAxis;
|
import org.gcube.portlets.user.geoportaldataviewer.shared.gis.wms.ZAxis;
|
||||||
|
|
||||||
|
import com.google.gwt.core.client.GWT;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The Class LayerItem.
|
* The Class LayerItem.
|
||||||
*
|
*
|
||||||
|
@ -948,4 +953,90 @@ public class LayerItem implements Serializable, Cloneable {
|
||||||
return builder.toString();
|
return builder.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* To layer item.
|
||||||
|
*
|
||||||
|
* @param layerType the layer type
|
||||||
|
* @param layerTitle the layer title
|
||||||
|
* @param layerName the layer name
|
||||||
|
* @param layerURL the layer URL
|
||||||
|
* @param mapServerHost the map server host
|
||||||
|
* @param isExternal the is external
|
||||||
|
* @param isBase the is base
|
||||||
|
* @param displayInLayerSwitcher the display in layer switcher
|
||||||
|
* @param styles the styles
|
||||||
|
* @param wmsLink the wms link
|
||||||
|
* @param onTop the on top
|
||||||
|
* @param wmsNotStandardParams the wms not standard params
|
||||||
|
* @param isNcWms the is nc wms
|
||||||
|
* @param UUID the uuid
|
||||||
|
* @param zAxis the z axis
|
||||||
|
* @param minResolution the min resolution
|
||||||
|
* @param maxResolution the max resolution
|
||||||
|
* @return the layer item
|
||||||
|
*/
|
||||||
|
|
||||||
|
// TODO Constructor from IndexLayerDV, GCUBESDILAeryDV or direct info
|
||||||
|
private LayerItem toLayerItem(LayerType layerType, String layerTitle, String layerName, String layerURL,
|
||||||
|
String mapServerHost, boolean isExternal, boolean isBase, boolean displayInLayerSwitcher,
|
||||||
|
ArrayList<String> styles, String wmsLink, boolean onTop, HashMap<String, String> wmsNotStandardParams,
|
||||||
|
boolean isNcWms, String UUID, ZAxis zAxis, Double minResolution, Double maxResolution) {
|
||||||
|
|
||||||
|
// GWT.log("Add addLayerByWms 1");
|
||||||
|
LayerItem layerItem = new LayerItem();
|
||||||
|
layerItem.setBaseLayer(isBase);
|
||||||
|
layerItem.setTitle(layerTitle);
|
||||||
|
layerItem.setName(layerName);
|
||||||
|
layerItem.setUrl(layerURL);
|
||||||
|
layerItem.setMapServerHost(mapServerHost);
|
||||||
|
// l.setExternal(isExternal);
|
||||||
|
layerItem.setOpacity(1d);
|
||||||
|
layerItem.setBuffer(2);
|
||||||
|
layerItem.setWmsLink(wmsLink);
|
||||||
|
layerItem.setWmsNotStandardParams(wmsNotStandardParams);
|
||||||
|
layerItem.setNcWms(isNcWms);
|
||||||
|
layerItem.setUUID(UUID);
|
||||||
|
layerItem.setZAxis(zAxis);
|
||||||
|
layerItem.setMinResolution(minResolution);
|
||||||
|
layerItem.setMaxResolution(maxResolution);
|
||||||
|
|
||||||
|
switch (layerType) {
|
||||||
|
|
||||||
|
// TODO IMPLEMENT THIS CASE
|
||||||
|
case RASTER_BASELAYER:
|
||||||
|
|
||||||
|
// l.setHasLegend(false);
|
||||||
|
layerItem.setBaseLayer(true);
|
||||||
|
layerItem.setTrasparent(false);
|
||||||
|
layerItem.setClickData(false);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case FEATURE_TYPE:
|
||||||
|
|
||||||
|
// CASE FEATURE TYPE
|
||||||
|
layerItem.setBaseLayer(false);
|
||||||
|
layerItem.setClickData(true);
|
||||||
|
layerItem.setTrasparent(true);
|
||||||
|
break;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
GWT.log("styles " + styles);
|
||||||
|
|
||||||
|
if (styles != null && styles.size() > 0) {
|
||||||
|
layerItem.setHasLegend(true);
|
||||||
|
layerItem.setDefaultStyle(styles.get(0));
|
||||||
|
layerItem.setStyle(styles.get(0));
|
||||||
|
layerItem.setStyles(styles);
|
||||||
|
} else {
|
||||||
|
String style = URLUtil.getValueOfParameter("styles", wmsLink);
|
||||||
|
if (style != null) { // CASE OF STYLE ="";
|
||||||
|
// TENTATIVE TO GET LEGEND
|
||||||
|
layerItem.setHasLegend(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
GWT.log("Built layer: " + layerItem);
|
||||||
|
return layerItem;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,13 @@
|
||||||
|
package org.gcube.portlets.user.geoportaldataviewer.shared.gis;
|
||||||
|
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
public class OverlayWMSLayer {
|
||||||
|
|
||||||
|
private String title;
|
||||||
|
private String name;
|
||||||
|
private String wmsServiceBaseURL;
|
||||||
|
private boolean display;
|
||||||
|
private Map<String, String> mapProperties;
|
||||||
|
|
||||||
|
}
|
|
@ -17,17 +17,11 @@
|
||||||
|
|
||||||
<inherits name="com.google.gwt.json.JSON" />
|
<inherits name="com.google.gwt.json.JSON" />
|
||||||
|
|
||||||
<inherits
|
|
||||||
name='org.gcube.portal.clientcontext.GCubeClientContext' />
|
|
||||||
|
|
||||||
<!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/> -->
|
<!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/> -->
|
||||||
<!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/> -->
|
<!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/> -->
|
||||||
|
|
||||||
<!-- Other module inherits -->
|
<!-- Other module inherits -->
|
||||||
|
|
||||||
<servlet path="/geoportalexporterservice"
|
|
||||||
class="org.gcube.portlets.user.geoportaldataviewer.server.GeoportalExporterActionServlet" />
|
|
||||||
|
|
||||||
<!-- Specify the app entry point class. -->
|
<!-- Specify the app entry point class. -->
|
||||||
<entry-point
|
<entry-point
|
||||||
class='org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewer' />
|
class='org.gcube.portlets.user.geoportaldataviewer.client.GeoportalDataViewer' />
|
||||||
|
|
|
@ -15,17 +15,7 @@
|
||||||
<servlet-name>geoportalDataViewerServlet</servlet-name>
|
<servlet-name>geoportalDataViewerServlet</servlet-name>
|
||||||
<servlet-class>org.gcube.portlets.user.geoportaldataviewer.server.GeoportalDataViewerServiceImpl</servlet-class>
|
<servlet-class>org.gcube.portlets.user.geoportaldataviewer.server.GeoportalDataViewerServiceImpl</servlet-class>
|
||||||
</servlet>
|
</servlet>
|
||||||
|
|
||||||
<!-- <servlet> -->
|
|
||||||
<!-- <servlet-name>geoportalWaitingServerActionServlet</servlet-name> -->
|
|
||||||
<!-- <servlet-class>org.gcube.portlets.user.geoportaldataviewer.server.WatingServerActionServlet</servlet-class> -->
|
|
||||||
<!-- </servlet> -->
|
|
||||||
|
|
||||||
<servlet>
|
|
||||||
<servlet-name>geoportalExporterServerActionServlet</servlet-name>
|
|
||||||
<servlet-class>org.gcube.portlets.user.geoportaldataviewer.server.GeoportalExporterActionServlet</servlet-class>
|
|
||||||
</servlet>
|
|
||||||
|
|
||||||
<servlet>
|
<servlet>
|
||||||
<servlet-name>mpformbuilderServlet</servlet-name>
|
<servlet-name>mpformbuilderServlet</servlet-name>
|
||||||
<servlet-class>org.gcube.portlets.widgets.mpformbuilder.server.MetadataProfileFormBuilderServiceImpl</servlet-class>
|
<servlet-class>org.gcube.portlets.widgets.mpformbuilder.server.MetadataProfileFormBuilderServiceImpl</servlet-class>
|
||||||
|
@ -41,15 +31,5 @@
|
||||||
<servlet-name>geoportalDataViewerServlet</servlet-name>
|
<servlet-name>geoportalDataViewerServlet</servlet-name>
|
||||||
<url-pattern>/GeoportalDataViewer/geoportaldataviewerservice</url-pattern>
|
<url-pattern>/GeoportalDataViewer/geoportaldataviewerservice</url-pattern>
|
||||||
</servlet-mapping>
|
</servlet-mapping>
|
||||||
|
|
||||||
<!-- <servlet-mapping> -->
|
|
||||||
<!-- <servlet-name>geoportalWaitingServerActionServlet</servlet-name> -->
|
|
||||||
<!-- <url-pattern>/GeoportalDataViewer/geoportaldataviewerwaitingservice</url-pattern> -->
|
|
||||||
<!-- </servlet-mapping> -->
|
|
||||||
|
|
||||||
<servlet-mapping>
|
|
||||||
<servlet-name>geoportalExporterServerActionServlet</servlet-name>
|
|
||||||
<url-pattern>/GeoportalDataViewer/geoportalexporterservice</url-pattern>
|
|
||||||
</servlet-mapping>
|
|
||||||
|
|
||||||
</web-app>
|
</web-app>
|
||||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 55 KiB |
Binary file not shown.
Before Width: | Height: | Size: 2.5 KiB |
|
@ -1,42 +0,0 @@
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
package org.gcube.portlets.user.geoportaldataviewer;
|
|
||||||
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.io.InputStream;
|
|
||||||
|
|
||||||
import org.apache.commons.io.IOUtils;
|
|
||||||
import org.gcube.portlets.user.geoportaldataviewer.server.GeoportalExporterActionServlet;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The Class GeoportalExporterActionServletTest.
|
|
||||||
*
|
|
||||||
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
|
|
||||||
*
|
|
||||||
* Apr 24, 2024
|
|
||||||
*/
|
|
||||||
public class GeoportalExporterActionServletTest {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* The main method.
|
|
||||||
*
|
|
||||||
* @param args the arguments
|
|
||||||
*/
|
|
||||||
public static void main(String[] args) {
|
|
||||||
String url = "https://data.dev.d4science.org/geoportal/export/pdf/profiledConcessioni/661d2c6f8804530afb90b132";
|
|
||||||
String identity = "francesco.mangiacrapa";
|
|
||||||
String token = "";
|
|
||||||
System.out.println("Start");
|
|
||||||
InputStream response;
|
|
||||||
try {
|
|
||||||
response = GeoportalExporterActionServlet.performHttpRequestToSGService(url, identity, token);
|
|
||||||
System.out.println(IOUtils.toString(response));
|
|
||||||
} catch (IOException e) {
|
|
||||||
// TODO Auto-generated catch block
|
|
||||||
e.printStackTrace();
|
|
||||||
}
|
|
||||||
System.out.println("End");
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
Loading…
Reference in New Issue