Details
Description
Annotation @EventListener doesn't emmit javascript neccesary to trigger a method on the server if specified in a component (like Border).
This doesn't get called becouse there is no javascript to make a dojo ajax call.
-
-
- Border.java ###
@EventListener(elements = "tab1", events = "onclick")
public void tab1Clicked() { logger.info("tab1 clicked"); }
- Border.java ###
-
-
-
- Border.html ###
<div id="myTabContainer">
<div id="tab1">
<div id="treeArea">
<div jwcid="tree" id="tree" style="overflow: auto; width: auto; height: auto;">
<a jwcid="nodeLink" href="folder.png">
<img jwcid="icon" align="absbottom"/>
<span jwcid="nodeLabel">Node 1</span>
</a>
</div>
</div>
</div>
<div id="tab2">
<h3>This is tab 2.</h3>
</div>
</div>
- Border.html ###
-
If a listener method is moved to an enclosing page (like Home), then it works - but it is not very nice to have the method anywhere but in a component.