0 votes

After successful integration of my Shopify Store with Wallee, I would like to offer customers the opportunity to download the invoice per order directly to their customer account via a link. According to Wallee settings this function is activated, but without success. What do I have to do to integrate the link into the current Shopify theme?

asked by Timo GEUGGIS (120 points)

1 Answer

0 votes

In order to display the invoice for download you have two options.

Integrate it on the order status page:

To integrate the payment information on Shopify’s order status page, the following snippet needs to be included in the Additional scripts. This can be configured in the Checkout settings of your Shopify store in the section Order processing.

{% for nAttribute in order.attributes %}
	{% if nAttribute[0] == 'paymentInformationScript' %}
		<script src="{{ nAttribute[1] }}&position=order-status"></script>
	{% endif %}
{% endfor %}

Display on the Order Page in Customer Account

To integrate the payment information on the order page in the customers account, the following two snippets need to be added to corresponding templates.

In order to do this, navigate in your Shopify stores’s backend to the theme section of the Online Store sales channel and open the code editor for the current theme by clicking on Actions → Edit code.

Open the template customers/order.liquid in the Templates folder and insert the following snippet at the position you wish the information to be displayed.

{% for nAttribute in order.attributes %}
	{% if nAttribute[0] == 'paymentInformationScript' %}
		<script src="{{ nAttribute[1] }}&position=customer-order"></script>
		<h3>{{ 'customer.order.payment_information' | t }}</h3>
		<div id="paymentInformationContainer"></div>
	{% endif %}
{% endfor %}

For the texts to be translated, add the following code to the section customer → order in the .json files in the Locales folder and translate the texts to the respective language.

"payment_information": "Payment Information"
answered by Sascha KRüSI (3.9k points)