diff --git a/.project b/.project
index 9bca262..00f51be 100644
--- a/.project
+++ b/.project
@@ -20,11 +20,6 @@
-
- org.eclipse.m2e.core.maven2Builder
-
-
-
com.google.gdt.eclipse.core.webAppProjectValidator
@@ -35,6 +30,11 @@
+
+ org.eclipse.m2e.core.maven2Builder
+
+
+
org.eclipse.jem.workbench.JavaEMFNature
diff --git a/src/main/java/org/gcube/portal/clientcontext/client/GCubeClientContext.java b/src/main/java/org/gcube/portal/clientcontext/client/GCubeClientContext.java
index efef99f..cc33e19 100644
--- a/src/main/java/org/gcube/portal/clientcontext/client/GCubeClientContext.java
+++ b/src/main/java/org/gcube/portal/clientcontext/client/GCubeClientContext.java
@@ -13,6 +13,24 @@ public class GCubeClientContext implements EntryPoint {
public void onModuleLoad() {}
+ public static native String getCurrentContextId() /*-{
+ var groupId;
+ if ($wnd.Liferay != null) {
+ groupId = $wnd.Liferay.ThemeDisplay.getScopeGroupId();
+ console.log("context id is = " + groupId);
+ }
+ return groupId;
+ }-*/;
+
+ public static native String getCurrentUserId() /*-{
+ var userId;
+ if ($wnd.Liferay != null) {
+ userId = $wnd.Liferay.ThemeDisplay.getScopeGroupId();
+ console.log("current userid is = " + userId);
+ }
+ return userId;
+ }-*/;
+
public static native void injectContext() /*-{
if ($wnd.Liferay != null) {
var userId;