From bd880489890399ebd4a638f221b431a7bf861d67 Mon Sep 17 00:00:00 2001 From: "francesco.mangiacrapa" Date: Tue, 13 Dec 2022 14:40:21 +0100 Subject: [PATCH] #24281 Fixed filtering selection label --- .classpath | 4 +-- .../com.gwtplugins.gdt.eclipse.core.prefs | 2 +- .settings/org.eclipse.wst.common.component | 29 ++++++++++------ CHANGELOG.md | 6 ++++ pom.xml | 2 +- .../client/ui/GeonaMainTabPanel.java | 25 +++++++------- .../ui/projects/ListOfProjectTablePanel.java | 34 ++++++++++++------- 7 files changed, 63 insertions(+), 39 deletions(-) diff --git a/.classpath b/.classpath index 733ce15..e799c8b 100644 --- a/.classpath +++ b/.classpath @@ -1,6 +1,6 @@ - + @@ -31,5 +31,5 @@ - + diff --git a/.settings/com.gwtplugins.gdt.eclipse.core.prefs b/.settings/com.gwtplugins.gdt.eclipse.core.prefs index f1cb019..a909db3 100644 --- a/.settings/com.gwtplugins.gdt.eclipse.core.prefs +++ b/.settings/com.gwtplugins.gdt.eclipse.core.prefs @@ -1,5 +1,5 @@ eclipse.preferences.version=1 jarsExcludedFromWebInfLib= -lastWarOutDir=/home/francescomangiacrapa/git/geoportal-data-entry-app/target/geoportal-data-entry-app-3.0.0 +lastWarOutDir=/home/francescomangiacrapa/git/geoportal-data-entry-app/target/geoportal-data-entry-app-3.0.1-SNAPSHOT warSrcDir=src/main/webapp warSrcDirIsOutput=false diff --git a/.settings/org.eclipse.wst.common.component b/.settings/org.eclipse.wst.common.component index 7917f92..9f12540 100644 --- a/.settings/org.eclipse.wst.common.component +++ b/.settings/org.eclipse.wst.common.component @@ -1,5 +1,5 @@ - + @@ -70,8 +70,10 @@ - - + + + + @@ -143,7 +145,8 @@ - + + @@ -215,7 +218,8 @@ - + + @@ -287,7 +291,8 @@ - + + @@ -311,7 +316,8 @@ - + + @@ -383,7 +389,8 @@ - + + @@ -455,7 +462,8 @@ - + + @@ -527,7 +535,8 @@ - + + diff --git a/CHANGELOG.md b/CHANGELOG.md index 9358e4d..3052277 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ 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). +## [v3.0.1-SNAPSHOT] - 2022-12-13 + +#### Fixes + +- [#24281] Fixed filtering selection label +- [#24049] Fixed "Show on Map" facility vs Chrome browser ## [v3.0.0] - 2022-11-09 diff --git a/pom.xml b/pom.xml index 27494e0..fb36d00 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ org.gcube.portlets.user geoportal-data-entry-app war - 3.0.0 + 3.0.1-SNAPSHOT GeoPortal Data Entry App The GeoPortal Data Entry App is an application to build the web forms for data entries needed to create projects/documents (based on UCD) in the D4Science Geoportal service diff --git a/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/GeonaMainTabPanel.java b/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/GeonaMainTabPanel.java index 4bc1a4a..7d7c58a 100644 --- a/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/GeonaMainTabPanel.java +++ b/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/GeonaMainTabPanel.java @@ -22,7 +22,6 @@ import org.gcube.application.geoportalcommon.shared.guipresentation.Header; import org.gcube.portlets.user.geoportaldataentry.client.ConstantsGeoPortalDataEntryApp; import org.gcube.portlets.user.geoportaldataentry.client.GeoPortalClientCaches.CacheSearchingFilterParametersFromConfig; import org.gcube.portlets.user.geoportaldataentry.client.events.CreateNewProjectEvent; -import org.gcube.portlets.user.geoportaldataentry.client.events.GetListOfRecordsEvent; import org.gcube.portlets.user.geoportaldataentry.client.events.OperationOnItemEvent; import org.gcube.portlets.user.geoportaldataentry.client.ui.form.GeonaDataEntryMainForm; import org.gcube.portlets.user.geoportaldataentry.client.ui.projects.ListOfProjectTablePanel; @@ -458,19 +457,21 @@ public class GeonaMainTabPanel extends Composite { if (dataListHandler != null) { - NavLink link = new NavLink(ucd.getName()); - link.addClickHandler(new ClickHandler() { - - @Override - public void onClick(ClickEvent event) { - - appManagerBus.fireEvent(new GetListOfRecordsEvent(false, ucd.getProfileID(), - getCurrentProjectsSearchingFilter(), true)); - } - }); +// NavLink link = new NavLink(ucd.getName()); +// link.addClickHandler(new ClickHandler() { +// +// @Override +// public void onClick(ClickEvent event) { +// +// appManagerBus.fireEvent(new GetListOfRecordsEvent(false, ucd.getProfileID(), +// getCurrentProjectsSearchingFilter(), true)); +// } +// }); ucdProjectTypesForListingDataView.add(ucd); - listOfProjectTablePanel.addProjectType(link); +// listOfProjectTablePanel.addProjectType(link); + + listOfProjectTablePanel.addProjectType(ucd); } diff --git a/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/projects/ListOfProjectTablePanel.java b/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/projects/ListOfProjectTablePanel.java index cd497bc..cfaf806 100644 --- a/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/projects/ListOfProjectTablePanel.java +++ b/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/ui/projects/ListOfProjectTablePanel.java @@ -203,15 +203,16 @@ public class ListOfProjectTablePanel extends Composite { alertSearchFor.setText(searchForFields.get(0).getDisplayName()); alertSortBy.setText(toLabelFilter((sortByFields.get(0)), SearchingFilter.ORDER.ASC)); - for (ItemFieldDV record_FIELD : searchForFields) { + for (final ItemFieldDV record_FIELD : searchForFields) { - NavLink nav = new NavLink(record_FIELD.getDisplayName()); - dropdownSearchFor.add(nav); + final NavLink navSearch = new NavLink(record_FIELD.getDisplayName()); + dropdownSearchFor.add(navSearch); - nav.addClickHandler(new ClickHandler() { + navSearch.addClickHandler(new ClickHandler() { @Override public void onClick(ClickEvent event) { + GWT.log("Search for: "+record_FIELD.getDisplayName()); alertSearchFor.setText(record_FIELD.getDisplayName()); if (searchField.getText().length() >= MIN_LENGHT_SERCHING_STRING) { @@ -318,8 +319,8 @@ public class ListOfProjectTablePanel extends Composite { public void execute() { //noProjectSelectionMessage.setVisible(true); - // SELECTION on the first item - if (ucdProjectTypesForListingDataView.size() > 0) { + // Selecting directly the unique UCD type. + if (ucdProjectTypesForListingDataView.size() == 1) { //noProjectSelectionMessage.setVisible(false); UseCaseDescriptorDV singleUCD = ucdProjectTypesForListingDataView.get(0); alertProjectType.setText(singleUCD.getName()); @@ -449,14 +450,21 @@ public class ListOfProjectTablePanel extends Composite { } - /** - * Adds the project type. - * - * @param link the link - */ - public void addProjectType(NavLink link) { - ddProjectType.add(link); + public void addProjectType(final UseCaseDescriptorDV ucd) { + + NavLink link = new NavLink(ucd.getName()); + link.addClickHandler(new ClickHandler() { + @Override + public void onClick(ClickEvent event) { + alertProjectType.setText(ucd.getName()); + appManagerBus.fireEvent(new GetListOfRecordsEvent(false, ucd.getProfileID(), + builtSearchingFilter(), true)); + } + }); + + ddProjectType.add(link); + } }