【发布时间】:2012-12-11 02:44:23
【问题描述】:
我想在用户选择特定单选按钮时切换隐藏面板。 使用最新版本的 primefaces。
例如:
<p:panel id="panel1" visible="false" widgetVar="firePanel" closable="true" toggleable="true">
hello
</p:panel>
<p:selectOneRadio value="#{formBean.selectedOptions}" layout="pageDirection">
<f:selectItem itemLabel="Option 1" itemValue="opt1" />
<f:selectItem itemLabel="Option 2" itemValue="opt2" />
<f:selectItem itemLabel="Option 3" itemValue="opt"/>
</p:selectOneRadio>
我想实现这样的目标,但是在单击 RadioButton3 时,不使用命令按钮
<p:commandButton id="but" value="Show" onclick="firePanel.show();"/>
这可能吗? 谢谢!
【问题讨论】:
标签: jsf primefaces