提问者:小点点

当rendered="true "时,Primefaces折叠选项卡为空


我对表单和数据表有一个完美的操作手风琴,直到我决定根据get参数隐藏一些选项卡。例如/editarContrato.jsf?id=19

现在渲染的选项卡显示为空。我现在正确地计算了boolen,并且标签头在应该显示的时候显示,而不是内容。

谢谢!

<p:accordionPanel multiple="true" dynamic="true" cache="false"
id="mainAccordion">
<p:tab title="#{msg['label.contrato']}" id="mainTab">
    <h:form styleClass="form-horizontal" id="form">

    </h:form>
</p:tab>
<p:tab title="Plan de Pagos" rendered="#{not empty param.id}">
    <h:form styleClass="form-horizontal" id="formPago">
        <p:dataTable id="dataPagos" value="#{pagoMB.dataPagos}" var="pago"
            editable="true" ajax="true" royKey="#{pago.id}" scrollable="true"
            scrollWidth="100%" rows="10" paginator="true"
            paginatorTemplate="{CurrentPageReport}  {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
            rowsPerPageTemplate="5,10,15" style="table-layout: auto">
            <f:facet name="header">Plan de Pagos
                </f:facet>
        </p:dataTable>
    </h:form>
</p:tab>

共1个答案

匿名用户

尝试:

<p:tab title="Plan de Pagos" rendered="#{not empty param['id']}">

Param是值的映射,不能以这种方式解析id。