diff --git a/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTD.java b/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTD.java index c9eccb1..036cf31 100644 --- a/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTD.java +++ b/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTD.java @@ -9,6 +9,7 @@ import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTIsLockedExcep import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTSessionExpiredException; import org.gcube.portlets.user.td.gwtservice.shared.map.MapCreationSession; import org.gcube.portlets.user.td.gwtservice.shared.tr.ColumnData; +import org.gcube.portlets.user.td.gwtservice.shared.user.UserInfo; import org.gcube.portlets.user.td.widgetcommonevent.client.event.SessionExpiredEvent; import org.gcube.portlets.user.td.widgetcommonevent.client.type.SessionExpiredType; import org.gcube.portlets.user.td.widgetcommonevent.shared.TRId; @@ -36,12 +37,12 @@ public class MapWidgetTD extends WizardWindow { * @param title * @param eventBus */ - public MapWidgetTD(TRId trId, String userName, String title, EventBus eventBus) { + public MapWidgetTD(TRId trId, UserInfo userInfo, String title, EventBus eventBus) { super(title,eventBus); mapCreationSession= new MapCreationSession(); mapCreationSession.setTrId(trId); - mapCreationSession.setUsername(userName); + mapCreationSession.setUsername(userInfo.getUsername()); retrieveColumns(); } diff --git a/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTDEntry.java b/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTDEntry.java index 7a8db3d..51f2bdb 100644 --- a/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTDEntry.java +++ b/src/main/java/org/gcube/portlets/user/td/mapwidget/client/MapWidgetTDEntry.java @@ -1,5 +1,6 @@ package org.gcube.portlets.user.td.mapwidget.client; +import org.gcube.portlets.user.td.gwtservice.shared.user.UserInfo; import org.gcube.portlets.user.td.widgetcommonevent.shared.TRId; import com.allen_sauer.gwt.log.client.Log; @@ -11,10 +12,11 @@ public class MapWidgetTDEntry implements EntryPoint { public void onModuleLoad() { TRId trId=new TRId("10","20"); - String userName="test.user"; + UserInfo userInfo=new UserInfo(); + userInfo.setUsername("test.user"); SimpleEventBus eventBus=new SimpleEventBus(); - MapWidgetTD mapCreationWizard= new MapWidgetTD(trId, userName,"Map Creation",eventBus); + MapWidgetTD mapCreationWizard= new MapWidgetTD(trId, userInfo,"Map Creation",eventBus); Log.info(mapCreationWizard.getId()); } }