-
Notifications
You must be signed in to change notification settings - Fork 9
/
order.html
executable file
·52 lines (41 loc) · 1.54 KB
/
order.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{% extends 'snipcart/email/_layout' %}
{% set isDevMode = craft.app.getConfig().general.devMode %}
{% set imageUrl = isDevMode ? '@verbb/snipcart/resources/dist/img/order-complete-devmode.png' : '@verbb/snipcart/resources/dist/img/order-complete.png' %}
{% set primaryDetails = {
'Order Number': order.invoiceNumber,
'Order Email': order.email,
} %}
{% if providerOrders.shipStation.orderId is defined %}
{% set primaryDetails = primaryDetails | merge({
'ShipStation #': providerOrders.shipStation.orderId,
}) %}
{% endif %}
{% block hero %}
{% include 'snipcart/email/_parts/hero' with {
imageSrc: craft.app.assetManager.getPublishedUrl(imageUrl, true)
} only %}
{% endblock hero %}
{% block content %}
{% include 'snipcart/email/_parts/heading' with {
heading: '{name} just placed an order.' | t('snipcart', { name: order.billingAddressName }),
} only %}
{% include 'snipcart/email/_parts/primary-details' with {
primaryDetails: primaryDetails,
} only %}
{% include 'snipcart/email/_parts/items' with {
order: order,
} only %}
{% include 'snipcart/email/_parts/custom-fields' with {
customFields: order.customFields,
} only %}
{% include 'snipcart/email/_parts/addresses' with {
order: order,
} only %}
{% include 'snipcart/email/_parts/payments' with {
order: order,
} only %}
<p style="margin-top: 40px;" class="muted mono">
{{- order.ipAddress }}<br>
{{- order.userAgent -}}
</p>
{% endblock content %}