开发者

Richfaces: dropDownMenu action

开发者 https://www.devze.com 2022-12-13 23:28 出处:网络
I understand, how to set action to rich:menuItem component, but can i somehow set action on rich:dropDownMenu? Parameter action cannot be set in rich:dropDownMenu component, only in dropDownMenus chil

I understand, how to set action to rich:menuItem component, but can i somehow set action on rich:dropDownMenu? Parameter action cannot be set in rich:dropDownMenu component, only in dropDownMenus child rich:menuItem. Maybe there开发者_StackOverflow中文版 is another approach?

Action setting to rich:menuItem:

<rich:menuItem submitMode="server" value="#{msg.someValue}" action="#{billdoc.list}">

I need to execute some action #{billdoc.someAction}, when user clicks on dropDownMenu.


If you are really sure you need this (it's rather strange), you can use <rich:dropDownMenu onexpand="myFunction()", and define myFunction as:

<a4j:jsFunction name="myFunction" action="#{billdoc.someAction}" />
0

精彩评论

暂无评论...
验证码 换一张
取 消