All things Shopify and commerce
We need an invoice when sending orders out of EU. The Invoice needs to show price, HS code and Country of Origin for each product.
Im currently using the Print Order app to generate the invoice. And I'm now trying to add the HS code and Country of Origin to the invoice.
After a lot of hassle, the HS code is now shown by adding this line:
{{ line_item.variant.metafields.harmonized_system_code.value }}
I did however read that metafields are not recommended to use, as this is deprecated, but nothing else have worked.
And I still haven't found any solution as to how to show the Country of Origin.
It seems like a fairly straight task, but it has not been possible for me to find any documentation on this field or how to access it.
I really hope someone can help me, ideally on how to access this field, or on how to generate an invoice with this (really common) info.
I'm having exactly the same issue. All I need is a print out for each order showing the item, the SKU, weight, value, HS code and country or origin. Astonishingly, it appears Shopify can't accomplish this really basic task. I spent most of yesterday chatting with support and we are nowhere nearer a solution. I am completely amazed that Shopify cannot resolve this.
I'm also looking for the same solution but I couldn't find it yet. Why does Shopify ask to fill the "Country of Origin" if they can't have an option to show it?
DISAPPOINTED!!!
It is ridiculous that Shopify does not enable this function as standard. If you need this functionality it appears you have no alternative but to pay a developer a solution. I am becoming more and more frustrated with Shopify and the fact that you have to stick your hand in your pocket everytime you want a basic function such as showing the HS code on shipping paperwork or defining shipping rules based on weight. These functions should be standard.
SOLVED!
I have finally created a solution to this issue. No more spending a lot of money on this now.
Reach out to me at hello@iamrohitsoni.com
Thanks!
Could someone share an answer for this? I'm also unable to output the Variant country of origin.
We're having the same issue & I agree - this is now a requirement for any business sending goods overseas and Shopify really should have a solution for it.
Could you help us with this? We want to show country of origin & hs code. We also want variables of this. You can call us on 9716072875. I am Kawal.
Yes, same problem here. Shipping out of the UK and unable to get Country of Origin to appear on Order Printer paperwork. I've sorted the HS code (although Shopify only supports a 6 digit code, not the 8 or 10 we use here). Layout issue can be solved in Order Printer after a bit of digging, but can I find the Country Code? Not a chance! Support have been unable to help and have pointed me in the direction of a developer, but I only want to know how to extract that COO so I can finish the code in the template!! How difficult can it be.
We've now solved this with the help of a developer. They were also unable to just enter the Country of Origin onto the order printer template and ended up having to add a tag to each product showing the name of the country. It works, but how crazy. We have to use a tag creator app to enter all the tags quickly as buld edit doesn't allow you to do that job quickly.
I actually am a shopify partner / developer / expert and I can't find this information either. If I find something I will update.
For the HST code I did end up using:
{{ line_item.variant.metafields.harmonized_system_code.value }}
I'm still looking for Country of Origin. I'm using the "Order Printer" app.
@NessaSnipe
Do you mind please sharing how to add this {{ line_item.variant.metafields.harmonized_system_code.value }} (which line to use in the printer app) as it does not show up.
Many thanks
For anyone struggling with invoice print including HS code, I managed to include this code
<table class="table-tabular" style="margin: 0 0 1.5em 0;">
<thead>
<tr>
<th>Quantity</th>
<th>Item</th>
<th>HSN Code</th>
{% if show_line_item_taxes %}
<th>Taxes</th>
{% endif %}
<th>Price</th>
</tr>
</thead>
<tbody>
{% for line_item in line_items %}
<tr>
<td>{{ line_item.quantity }} x</td>
<td>{{ line_item.title }}</td><td>{{ line_item.variant.metafields.harmonized_system_code.value }}</td>
{% if show_line_item_taxes %}
<td>
Hope it works for others too
I just downloaded Invoice Wizard app which has both HSN Code + Country of Origin fields.
Did this solve the problem? How is it working?
hello your code work for me . But one problem arise with me HS code is one step shifted on my table . please have a look . Can you help me with this? i used
<td>{{ line_item.variant.metafields.harmonized_system_code.value }}</td> code
I now use https://apps.shopify.com/partners/wizard-labs.
Hey @Hemant_Chauhan
Try to use this code, it worked for me!
<p style="float: right; text-align: right; margin: 0;">
{{ "now" | date: "%m/%d/%y" }}<br />
Invoice for {{ 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 }}
</div>
<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>Quantity</th>
<th>HSN CODE</th>
<th>Item</th>
{% if show_line_item_taxes %}
<th>Taxes</th>
{% endif %}
<th>Price</th>
</tr>
</thead>
<tbody>
{% for line_item in line_items %}
<tr>
<td>{{ line_item.quantity }} x</td>
<td>{{ line_item.variant.metafields.harmonized_system_code.value }}</td>
<td><b>{{ line_item.title }}</b></td>
{% if show_line_item_taxes %}
<td>
{% for tax_line in line_item.tax_lines %}
{{ tax_line.price | money }} {{ tax_line.title }}<br/>
{% endfor %}
</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 %}
</tbody>
</table>
{% if transactions.size > 1 %}
<h3 style="margin: 0 0 1em 0;">Transaction 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;">Payment Details</h3>
<table class="table-tabular" style="margin: 0 0 1.5em 0;">
<tr>
<td>Subtotal price:</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>Total tax:</td>
<td>{{ tax_price | money }}</td>
</tr>
{% if shipping_address %}
<tr>
<td>Shipping:</td>
<td>{{ shipping_price | money }}</td>
</tr>
{% endif %}
<tr>
<td><strong>Total price:</strong></td>
<td><strong>{{ total_price | money }}</strong></td>
</tr>
{% if total_paid != total_price %}
<tr>
<td><strong>Total paid:</strong></td>
<td><strong>{{ total_paid | money }}</strong></td>
</tr>
<tr>
<td><strong>Outstanding Amount:</strong></td>
<td><strong>{{ total_price | minus: total_paid | money }}</strong></td>
</tr>
{% endif %}
</table>
{% if note %}
<h3 style="margin: 0 0 1em 0;">Note</h3>
<p>{{ note }}</p>
{% endif %}
{% if shipping_address %}
<h3 style="margin: 0 0 1em 0;">Shipping Details</h3>
<div style="margin: 0 0 1em 0; padding: 1em; border: 1px solid black;">
<strong>{{ shipping_address.name }}</strong><br/>
{{ shipping_address | format_address }}
</div>
{% endif %}
<p>If you have any questions, please send an email to <u>{{ shop.email }}</u></p>
As a complete newbie to coding - please could you let me know where I would insert this in the template? Thank you!
Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024Hey Community! It’s time to share some appreciation and celebrate what we have accomplis...
By JasonH Nov 14, 2024