mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-10-08 13:20:57 +00:00
fix for bug Bug 2153 - "Show All Events" button on newhome doesn't work
This commit is contained in:
1 parent
043160e8f6
commit
7256a31351
2 files changed
+13
-1
No files matched your search
+10
@@ -5,8 +5,11 @@ import java.util.List;
|
||||
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.dom.client.DivElement;
|
||||
import com.google.gwt.event.dom.client.ClickEvent;
|
||||
import com.google.gwt.uibinder.client.UiBinder;
|
||||
import com.google.gwt.uibinder.client.UiField;
|
||||
import com.google.gwt.uibinder.client.UiHandler;
|
||||
import com.google.gwt.user.client.ui.Anchor;
|
||||
import com.google.gwt.user.client.ui.Composite;
|
||||
import com.google.gwt.user.client.ui.Widget;
|
||||
import com.sap.sailing.gwt.home.client.app.PlaceNavigator;
|
||||
@@ -22,6 +25,7 @@ public class MainEvents extends Composite {
|
||||
private List<EventBaseDTO> recentEvents;
|
||||
|
||||
@UiField DivElement recentEventsDiv;
|
||||
@UiField Anchor showAllEventsAnchor;
|
||||
|
||||
private final PlaceNavigator navigator;
|
||||
|
||||
@@ -56,4 +60,10 @@ public class MainEvents extends Composite {
|
||||
event.setEvent(eventBase);
|
||||
recentEventsDiv.appendChild(event.getElement());
|
||||
}
|
||||
|
||||
@UiHandler("showAllEventsAnchor")
|
||||
public void showAllEvents(ClickEvent e) {
|
||||
navigator.goToEvents();;
|
||||
}
|
||||
|
||||
}
|
||||
+3
-1
@@ -19,7 +19,9 @@
|
||||
<!-- the recent events will be inserted here -->
|
||||
</div>
|
||||
<div class="{res.mainCss.grid} {res.mainCss.mainsection_navigation}">
|
||||
<div class="{res.mediaCss.small12} {res.mediaCss.columns}"><a href="#" class="{res.mainCss.button}"><ui:text from='{i18n.mainEventShowAll}'/></a></div>
|
||||
<div class="{res.mediaCss.small12} {res.mediaCss.columns}">
|
||||
<g:Anchor ui:field="showAllEventsAnchor" href="javascript:;" styleName="{res.mainCss.button}"><ui:text from='{i18n.mainEventShowAll}'/></g:Anchor>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</g:HTMLPanel>
|
||||
|
||||
Reference in new issue
Block a user