【发布时间】:2015-12-19 18:36:16
【问题描述】:
我正在使用带有标签的 primefaces tabview 来分离数据。当我使用 ui:include src 在包含 src 代码中的选项卡代码上包含一个带有保存按钮的数据表时,我得到一个不包含在选项卡中的保存按钮
这是标签代码
<p:tab title="Event Costs" disabled="#{eventCreateEditModel.projectEvent.projectEventId==0}">
<p:panelGrid id="costsPanelGrid">
<ui:include src="eventCreateEditCosts.xhtml"/>
<p:row>
<p:column colspan="2"> <p:commandButton value="Save" actionListener="#{eventCreateEditModel.update}" update="@form"/></p:column>
</p:row>
</p:panelGrid>
</p:tab>
这是数据表代码
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:p="http://primefaces.org/ui">
<p:panel header="Audits List" update="@form" closable="false" >
<p:panelGrid columns="3">
<p:dataTable value="#{eventCreateEditCostModel.costEntities}" var="eventCost"
rowKey="#{eventCost.eventCostId}"
sortMode="multiple"
resizableColumns="true"
widgetVar="eventCostTable"
rows="10">
<f:facet name="header">
Event Audit Listing
</f:facet>
<p:column headerText="ID">
<h:outputText value="#{eventCost.eventCostId}" />
</p:column>
</p:dataTable>
</p:panelGrid>
</p:panel>
保存按钮不包含在选项卡内,而是显示在选项卡外。
有人见过这种问题吗?是否有另一种包含来源的方式?
【问题讨论】:
标签: jsf primefaces tabs