How can I update my code to display the correct tax percentage?

How can I update my code to display the correct tax percentage?

StudioVliering
New Member
20 0 0

Hi Shopify Guru's,

 

Can you please help me update this code. What I need is it to show the TAX percentage, a calculating of the tax that is correct. But I'm struggle to make it work:

 

<p style="float: right; text-align: right; margin: 0;">
{{ "now" | date: "%d/%m/%y" }}<br />
Factuur voor bestelling {{ order_name }}
</p>

<div style="float: left; margin: 0 0 1.5em 0;" >
<strong style="font-size: 2em;">{{ shop_name }}</strong><br /><br />
{{ shop.address }}<br/>
{{ shop.city }} {{ shop.province_code }} {{ shop.zip | upcase }}<br/>
{{ shop.country }}
<p>KVK nummer 71969713</p>
<p>BTW-nummer NL858922137B01</p>
</div>
{% if note %}
<h3 style="margin: 0 0 1em 0;">PO Nummer of boodschap:</h3>
<p>{{ note }}</p>
{% endif %}
<hr />

<h3 style="margin: 0 0 1em 0;">Item Details</h3>

<table class="table-tabular" style="margin: 0 0 1.5em 0;">
<thead>
<tr>
<th>Aantallen</th>
<th>Product</th>
{% if show_line_item_taxes %}
<th>BTW</th>
{% endif %}
<th>Prijs</th>
</tr>
</thead>
<tbody>
{% for line_item in line_items %}
{% assign line_item_tax = 0 %}
{% for tax_line in line_item.tax_lines %}
{% assign line_item_tax = line_item_tax | plus: tax_line.price %}
{% endfor %}
<tr>
<td>{{ line_item.quantity }} x</td>
<td><b>{{ line_item.title }}</b></td>
{% if show_line_item_taxes %}
<td>{{ line_item_tax | money }}</td>
{% endif %}
<td>
{% if line_item.original_price != line_item.price %}
<s>{{ line_item.original_price | money }}</s>
{% endif %}
{{ line_item.price | money }}
</td>
</tr>
{% endfor %}
{% if shipping_line %}
{% assign shipping_tax = 121 %}
{% for tax_line in shipping_line.tax_lines %}
{% assign shipping_tax = shipping_tax | plus: tax_line.price %}
{% endfor %}
<tr>
<td></td>
<td>Shipping</td>
{% if show_line_item_taxes %}
<td>{{ shipping_tax | money }}</td>
{% endif %}
<td>{{ shipping_price | money }}</td>
</tr>
{% endif %}
</tbody>
</table>

{% if transactions.size > 1 %}
<h3 style="margin: 0 0 1em 0;">Betaling Details</h3>
<table class="table-tabular" style="margin: 0 0 1.5em 0;">
<thead>
<tr>
<th>Type</th>
<th>Amount</th>
<th>Kind</th>
<th>Status</th>
</tr>
</thead>
<tbody>
{% for transaction in transactions %}
<tr>
<td>{{ transaction.gateway | payment_method }}</td>
<td>{{ transaction.amount | money }}</td>
<td>{{ transaction.kind }}</td>
<td>{{ transaction.status }}</td>
</tr>
{% endfor %}
</tbody>
</table
{% endif %}

<h3 style="margin: 0 0 1em 0;">Betaling Details</h3>

<table class="table-tabular" style="margin: 0 0 1.5em 0;">
<tr>
<td>Bedrag producten:</td>
<td>{{ subtotal_price | money }}</td>
</tr>
{% for discount in discounts %}
<tr>
<td>Includes discount "{{ discount.code }}"</td>
<td>{{ discount.savings | money }}</td>
</tr>
{% endfor %}
<tr>
<td>BTW Producten:</td>
<td>{{ total_tax | money }}</td>
</tr>
{% if shipping_address %}
<tr>
<td>Verzendkosten:</td>
<td>{{ shipping_price | money }}</td>
</tr>
{% endif %}
<tr>
<td>BTW Verzendkosten:</td>
<td>{{ shipping_tax | money }}</td>
</tr>
{% if shipping_address %}
{% endif %}
{% if shipping_address %}
{% endif %}
<tr>
<td>Totaal bedrag:</td>
<td>{{ subtotal_price | money }}</td>
</tr>
<tr>
<td><strong>Totaal incl. BTW:</strong></td>
<td><strong>{{ total_price | money }}</strong></td>
</tr>

<p>Bij vragen over de factuur graag mailen naar administratie@dekoekfabriek.com</p>

Replies 0 (0)