My guess is you would use this code in your PDF Template because it look like a HTML code:
<br pagebreak="true">
AP: printing quotes - generating tcpdf pagebreaks for long itemlists
Collapse
X
-
Hello, i dont really get how this should be implemented. Could you please provide me with a new description on how to do this?
Thank you!Leave a comment:
-
Thanks, it worked. I recap as maybe it can be usefull to others...
- I added to QuoteItem entity definition a field like this:
Code:"lastOfPage": { "type": "bool", "notStorable": true, "default": false, "disabled": true }
Code:<!-- {{#if lastOfPage}} --> </tbody></table> <br pagebreak="true"> <table class="table table-bordered" cellpadding="2" border="0.5pt"> <tbody> <tr> <th>.. </th> </tr> <!-- {{/if}} -->
Leave a comment:
-
I saw that in loadAdditionalFieldsForPdf() there's a loop where is associated the itemList data list for htmlizer rendering of quote items. I could customize it and add a new unstorable field there, to Quote Item, for example, lastOfPage to set to 1 every 10 elements; so within the quote template, within the main itemList loop {{#if lastOfPage}} close table, pagebreak, new table {{/If}}. I'll let you know if this works...
MicheleLeave a comment:
-
Hello,
for this create a bool notStorable field in Quote entityDefs (like breakPdfPage). In custom Quote service set this field in method loadAdditionalFieldsForPdf, and now you can use in on the templateLeave a comment:
-
AP: printing quotes - generating tcpdf pagebreaks for long itemlists
Hi,
We need to print quotes landscape because we have lots of fields to print for every item. This way we risk to generate more than one page PDF and get the total amount table box we have at the end cutted in two parts as it spans over two different pages.
So I'm wondering if there's a way to conditionally put a <br pagebreak="true"/> that forces tcpdf to go on another page, something that counts itemNum for example ... something like <!-- {{#if itemNum moreThan 10}} -->
thanks a lot,
MicheleTags: None
Leave a comment: