tabbedPane selectionChangeListener not invoking method on tab selection
I am having some problems getting the method specified in selectionChangeListener invoked on tab change.
The loadingMode is default, ajaxLazy, which means it should be called the first time a tab is selected. The tabbedPane is wrapped in
The el expression looks like:
selectionChangeListener="#{pageController.tabSelected}"
The method signature of the method binding is开发者_如何学Go:
@Component("pageController") // Using spring for bean management
@Scope("request)"
public class PageController {
public void tabSelected(SelectionChangeEvent e)
}
It is not throwing any exceptions so it is not even trying to resolve the method binding.
Any ideas?
Try this:
<o:tabbedPane loadingMode="server" rendered="true" selectionChangeListener="#{yourBeanName.listenerMethod}">
...
</o:tabbedPane>
As you can see I`m using server as loading mode. That way the listener method will be invoked each time a tab is clicked. If you use client as loading mode, the tab click event will not be picked up by the server.
For more info you can view the documentation for tabbedPane
精彩评论