$receipt_label $from_label $company.name  
 
 
{%set payment = payments|first %} {%if payment.transaction_reference %} {% endif %}
  $receipt_label #$number  
  Reference: {{ payment.transaction_reference }}  
 
 
$amount_paid_label
$amount
 
$date_label
$payment.date
 
$method_label
{% if payments is defined and payments is not empty %} {% set payment = payments|first %} {{ payment.method }} {% endif %}
 
 
  Summary  
 
 
 
  {% set totalPrice = 0 %} {% if payments is defined and payments is not empty %} {% for payment in payments %} {% for pivot in payment.paymentables|filter(pivot => pivot.is_credit == '0') %} {% set totalPrice = totalPrice + pivot.amount_raw %} {% endfor %} {% endfor %}
 
 
{{ pivot.date }}    
 
 
$invoice_label #{{ pivot.invoice }}
  {{ pivot.amount }}
 
 
 
 
 
$amount_paid_label   ${{ totalPrice|format_currency(currency_code) }} {% endif %}