diff --git a/pom.xml b/pom.xml index 169f9d7..0affa1c 100644 --- a/pom.xml +++ b/pom.xml @@ -54,6 +54,7 @@ aslcore provided + org.gcube.dvos usermanagement-core @@ -68,6 +69,13 @@ org.gcube.common.portal portal-manager + [2.0.0-SNAPSHOT, 3.0.0-SNAPSHOT) + provided + + + org.gcube.portal + custom-portal-handler + [2.0.0-SNAPSHOT, 3.0.0-SNAPSHOT) provided diff --git a/src/main/java/org/gcube/portlets/user/gcubewidgets/client/ClientScopeHelper.java b/src/main/java/org/gcube/portlets/user/gcubewidgets/client/ClientScopeHelper.java index 248bdcb..09e905e 100644 --- a/src/main/java/org/gcube/portlets/user/gcubewidgets/client/ClientScopeHelper.java +++ b/src/main/java/org/gcube/portlets/user/gcubewidgets/client/ClientScopeHelper.java @@ -1,9 +1,11 @@ package org.gcube.portlets.user.gcubewidgets.client; + import org.gcube.portlets.user.gcubewidgets.client.rpc.ScopeService; import org.gcube.portlets.user.gcubewidgets.client.rpc.ScopeServiceAsync; import com.google.gwt.core.client.GWT; +import com.google.gwt.user.client.Window.Location; public class ClientScopeHelper { public static ScopeServiceAsync getService() { @@ -25,4 +27,5 @@ public class ClientScopeHelper { } return null; } + } diff --git a/src/main/java/org/gcube/portlets/user/gcubewidgets/server/ScopeServiceImpl.java b/src/main/java/org/gcube/portlets/user/gcubewidgets/server/ScopeServiceImpl.java index 42374df..2c63bd1 100644 --- a/src/main/java/org/gcube/portlets/user/gcubewidgets/server/ScopeServiceImpl.java +++ b/src/main/java/org/gcube/portlets/user/gcubewidgets/server/ScopeServiceImpl.java @@ -7,6 +7,7 @@ import javax.servlet.http.HttpSession; import org.gcube.application.framework.core.session.ASLSession; import org.gcube.application.framework.core.session.SessionManager; import org.gcube.common.portal.PortalContext; +import org.gcube.portal.custom.scopemanager.scopehelper.ScopeHelper; import org.gcube.portlets.user.gcubewidgets.client.rpc.ScopeService; import org.gcube.vomanagement.usermanagement.GroupManager; import org.gcube.vomanagement.usermanagement.impl.LiferayGroupManager; @@ -81,7 +82,7 @@ public class ScopeServiceImpl extends RemoteServiceServlet implements ScopeServi private ASLSession getASLSession() { HttpSession httpSession = this.getThreadLocalRequest().getSession(); String sessionID = httpSession.getId(); - String user = (String) httpSession.getAttribute("username"); + String user = (String) httpSession.getAttribute(ScopeHelper.USERNAME_ATTRIBUTE); if (user == null) { _log.warn("NO USER FOUND, exiting"); return null;