2012-03-06 71 views
0

我試圖通過JSP include包含ADF上下文菜單,但菜單拒絕顯示。下面是試圖包含菜單的片段:不能包含與jsp中的ContextMenu:包含在ADF中

<af:table value="#{mockupPersonController.people}" 
    var="person" id="personDataTable" 
    rowSelection="single" inlineStyle="width: 100%; height: 95%"> 
    <f:facet name="contextMenu"> 
     <af:popup id="tableContextMenu"> 
     <af:menu> 
      <jsp:include page="/contextMenu.jsp" flush="true"/> 
     </af:menu> 
     </af:popup> 
    </f:facet> 
      .... 

這裏是contextMenu.jsp的一部分。我們的想法是用來顯示基於會話的上下文菜單的各個部分作用域「WHEREAMI」的價值:

<af:commandMenuItem text="Review Person" 
actionListener="#{personStatusBean.launchPopup}" /> 
<af:separator /> 
<af:switcher facetName="#{sessionScope.whereami}" 
    defaultFacet="default"> 
<f:facet name="default"> 
    <af:commandMenuItem text="Main Menu" /> 
</f:facet> 
<f:facet name="location1"> 
    <af:commandMenuItem text="Do Something" /> 
    <af:commandMenuItem text="Do Something Else" /> 
</f:facet> 

誰能幫助?

回答

1

聲明菜單是這樣的一種方式,另一種方式是使用pagefragment,包括它在一個任務流中,然後你作爲一個區域進入頁面。