I have the following ArrayList
class Report{ private String manufacturer; private String color; private List<Double> revenue; }
How can I map it to datatable. I tried using p: columns, it does not work. I have code on the XHTML page
<p:dataTable value="#{tableBean.reportList}" var="report" id="table"> <p:column headerText="Manufacturer">#{report.manufacturer}</p:column> <p:column headerText="Color">#{report.color}</p:column> </p:dataTable >
I also tried p: columns and ui: repeat. But I canβt achieve the desired result. result.
<p:columns var="amount" value="#{report.revenue}">#{amount}</p:columns> <ui:repeat var="amount" value="#{report.revenue}"> <p:column headerText="Revenue">#{amount}</p:column> </ui:repeat>
I need the output in the form of a table with the name of the manufacturer, color and all revenues
source share