Within an Advanced PDF/HTML Template, I am trying ...
# general
b
Within an Advanced PDF/HTML Template, I am trying to get a sum of a field to include in the totals below the lines. Searching for options on Freemarker/BFO hasn't been too successful. My list is currently in a table and then I am pulling total fields after it. One of my columns in the lines is a quantity and I want to display a total quantity along with the total amount.
a
You should ask this in the #C466X49JB channel for a better chance at a good answer
Try something like this:
Copy code
<#assign sum = 0>
<#list rows as row>
  <!-- row stuff here -->
  <#assign sum += row.quantity>
</#list>
<p>{{sum}}</p>
b
Thanks @adavies! I didn't know about that channel