2013-03-04 21 views
1

我正面臨一種情況,我必須使用組件包裝器,或者與primefaces中的「outputPanel」做同樣的事情。你知道任何 ?corePanel中的outputPanel的等效組件jsf

+0

你需要什麼'outputPanel'的特定功能? – partlov 2013-03-04 15:44:04

+0

@partlov我需要從其內部的命令鏈接發起的ajax動作重新渲染DataTable – 2013-03-04 15:53:01

回答

4

既然你問了一個等效的組件包裝,我會建議使用列值爲1的panelGrid。

<h:panelGrid id="grid" columns="1"> 
</h:panelGrid> 
+0

thx它工作:) – 2013-03-04 15:50:51

1

我需要從一個命令鏈接解僱裏面

只是引用數據表本身的AJAX動作重新解析數據表。

<h:form id="form"> 
    <h:dataTable id="table" ...> 
     <h:column> 
      <h:commandLink ...> 
       <f:ajax ... render=":form:table" /> 
      </h:commandLink> 
     </h:column> 
    </h:dataTable> 
</h:form> 

或者,如果你真的堅持某種不明原因,普通的JSF相當於<p:outputPanel>只是<h:panelGroup>

<h:form id="form"> 
    <h:panelGroup id="group"> 
     <h:dataTable ...> 
      <h:column> 
       <h:commandLink ...> 
        <f:ajax ... render=":form:group" /> 
       </h:commandLink> 
      </h:column> 
     </h:dataTable> 
    </h:panelGroup> 
</h:form>