Code: Select all
<p:dataTable tableStyleClass="ui-table-columntoggle"
value="#{moduloBean.getValidRighe(dom.domandeList)}" var="linkedDom" rowIndexVar="linkedRowNum"
rendered="#{dom.tipoDomanda.tdmId.equals(14)}" >
<p:column>
<h:outputText value="#{localeBean.isItalian() ? linkedDom.domDescrIt : linkedDom.domDescrDe}" />
<p:selectOneRadio label="#{localeBean.isItalian() ? linkedDom.domDescrIt : linkedDom.domDescrDe}"
layout="custom" id="radioGrid"
required="#{moduloBean.isDomandaObbligatoria(dom)}"
value="#{moduloBean.risposte.get(linkedDom).singleValue}"
disabled="#{moduloBean.isDomandaDisabilitata(dom)}">
<p:ajax update="@form:list" listener="#{moduloBean.clearDisabledValues(dom)}" />
<f:selectItems value="#{moduloBean.getSelectItems(dom)}" />
</p:selectOneRadio>
</p:column>
<p:column headerText="#{moduloBean.getOpzDescr(dom, 0)}" rendered="#{moduloBean.getOpzDescr(dom, 0) != null}" style="text-align:center">
<p:radioButton for="radioGrid" itemIndex="0"/>
</p:column>
<p:column headerText="#{moduloBean.getOpzDescr(dom, 1)}" rendered="#{moduloBean.getOpzDescr(dom, 1) != null}" style="text-align:center">
<p:radioButton for="radioGrid" itemIndex="1"/>
</p:column>
</p:dataTable>
You can reproduce the problem using PF Showcase and the example shown on SelectOneRadio with custom layout
Code: Select all
<h3>Custom Layout</h3>
<p:outputPanel id="customPanel" style="margin-bottom:10px">
<p:selectOneRadio id="customRadio" value="#{radioView.color}" layout="custom">
<f:selectItem itemLabel="Red" itemValue="Red" />
<f:selectItem itemLabel="Green" itemValue="Green" />
<f:selectItem itemLabel="Blue" itemValue="Blue" />
</p:selectOneRadio>
<h:panelGrid columns="3" cellpadding="5">
<p:radioButton id="opt1" for="customRadio" itemIndex="0" />
<h:outputLabel for="opt1" value="Red" />
<p:spinner />
<p:radioButton id="opt2" for="customRadio" itemIndex="1" />
<h:outputLabel for="opt2" value="Green" />
<p:inputText />
<p:radioButton id="opt3" for="customRadio" itemIndex="2" />
<h:outputLabel for="opt3" value="Blue" />
<p:calendar />
</h:panelGrid>
</p:outputPanel>