我正在使用一個a4j:repeat
控制來遍歷一個Map<Object, List<MyType>>
列表。 XHTML頁面顯示h:outputText
和rich:select
控件。從豐富的獲取選定的值:選擇內部o a4j:重複
我循環遍歷一個Map<String, List<Items>>
實例,以顯示主 - 細節表。在h:outputText
中,我顯示了主要描述,rich:select
顯示了詳細信息。
的代碼如下:
customer.xhtml
<a4j:repeat value="#{masterManagedBean.listMasterItems.entrySet().toArray()}"
var="itemsVar">
<h:outputText value="#{itemsVar.key}" />
<rich:select enableManualInput="true">
<f:selectItems value="#{itemsVar.value}" id="itemsMenu"
var="itemsVarSelect"
itemLabel="#{itemsVarSelect.descriptionItems}"
itemValue="#{itemsVarSelect.idItems}" />
</rich:select>
</a4j:repeat>
這個片段可以完美運行。但是,我不知道如何獲得由中繼器生成的每個rich:select
的選定值。請指導我解決這個問題。
請提供您的xhtml和託管bean的示例(http://sscce.org)。你想要詳細記錄什麼,目前的確切問題是什麼(例外,錯誤信息)... –
@ L-Ray我在下面發佈了一個片段。在此先感謝 – HumanoLegal
據我所知,列表'是不同的每個對象,對不對? –