I want to print multiple p:pieChart that generate inside a p:repeat so I do not know how many charts there are.I just want to get a PDF with all the charts basically. I have tried using this:
<p:printer target="@([id$=divWhereAllTheChartsAre]) " />
But the charts appear blank. I also saw this in the official documentation:
<script type="text/javascript">
//<![CDATA[
function exportChart() {
//export image
$('#output').empty().append(PF('chart').exportAsImage());
//show the dialog
PF('dlg').show();
}
//]]>
</script>
But I cannot get the component by its PF widgetVar because there are more than one. Is there any other way to export the charts?
I am working with the primefaces7.0.jar, thanks.