Solved

email templates edits & translations: order confirmation, new order notification (multi language)

Ober
Excursionist
26 1 11

The ML Shopify I am managing has main language DE and second language IT with the Debutify theme. I'm struggling both with text string translations (locale.json), inshop translations (articles etc.), theme sections translations as well as email templates translations like those for order confirmation. The logic of Shopify core, Theme ML support, ML Apps and custom edits regarding MultiLanguage is not logical and very difficult to track and maintain. 

For the new order notification I changed the topic to change the beginning, include total price and city:

 

Shopify-Bestellung {{ name }} {{ total_price }} - {% if customer.name %} {{ customer.name }},{% endif %} {{ address.city }} {% if has_high_risks? %} (Betrugsrisiko){% endif %}

 

In the into section about the customer and time I edited to have custom time (see strftime) and include customer email and phone (see email-variables)

 

                                        {% assign current_date = date | date: "%d. %b ." %}
                                        {% assign current_time = date | date: "%H:%M" %}
                                        {% if customer.name %}
                                            {{ customer.name }} hat die Bestellung {{ name }} am {{ current_date }} um {{ current_time | strip }} aufgegeben. 
                                            <br>{{email}}, Tel. {{billing_address.phone}}, {{shipping_address.phone}}

 

 

While the customer notifications in the second language IT seems to work as long as you do not edit any code, it is very difficult to understand which notifications have been customized (I could not see any Admin-GUI indication).

So as one of the main suggestions for onlineshops is to customize the order confirmation to give the client a more personal message, I did that in DE and only later found out that also IT clients now receive this message (code) and automatic notification translation is not working in that case. Bummer. 

I consulted many sites and found some insight on weglot Translate your Shopify email notificationslangify Translating Notifications. The code to use in any customized email templates seems to be like this

 

{% case attributes.lang %} {% when 'it' %} ITALIAN CODE {% else %} GERMAN CODE {% endcase %}

 

 

I have the following questions:

  • Can anybody confirm this code works?
  • Is there a way to see if an email template was customized (not anymore being the one from the theme)?
  • If I change the Theme main language or the theme altogether what happens to the email templates?
Accepted Solution (1)
Ober
Excursionist
26 1 11

This is an accepted solution.

Some necessary progress for ML. Under myshopify.com/admin/settings/notifications now the secondary languages can be edited. 

View solution in original post

Replies 3 (3)

Ober
Excursionist
26 1 11

The first code is to correct regarding two variables: 

 

 

Shopify-Bestellung {{ name }}: {{ total_price | money }} - {% if customer.name %} {{ customer.name }},{% endif %} {{ shipping_address.city }} {% if has_high_risks? %} (Betrugsrisiko){% endif %}

 

 

  The 

{% case attributes.lang %}

code seems to work as far as I could test it for DE - not sure how to test the second language IT without doing an actual order in that language.  

Ober
Excursionist
26 1 11

This is an accepted solution.

Some necessary progress for ML. Under myshopify.com/admin/settings/notifications now the secondary languages can be edited. 

EstebanSady
Visitor
2 0 0

I don't see this option to edit the secondary language templates.