Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Improve default admin email templates (#10734)

Mirek Mencel42f9464ca69f
diff --git a/saleor/account/tests/test_notifications.py b/saleor/account/tests/test_notifications.py
index 33a7ef6213..9daa73c582 100644
--- a/saleor/account/tests/test_notifications.py
+++ b/saleor/account/tests/test_notifications.py
@@ -5,6 +5,7 @@ import pytest
from freezegun import freeze_time
from ...core.notify_events import NotifyEventType, UserNotifyEvent
+from ...core.tests.utils import get_site_context_payload
from ...core.utils.url import prepare_url
from ...graphql.core.utils import to_global_id_or_none
from ...plugins.manager import get_plugins_manager
@@ -52,9 +53,8 @@ def test_send_email_request_change(
"redirect_url": f"{redirect_url}?token={token}",
"old_email": customer_user.email,
"new_email": new_email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -77,9 +77,8 @@ def test_send_email_changed_notification(
expected_payload = {
"user": get_default_user_payload(customer_user),
"recipient_email": old_email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -114,9 +113,8 @@ def test_send_password_reset_notification(
"recipient_email": customer_user.email,
"token": token,
"reset_url": reset_url,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
expected_event = (
NotifyEventType.ACCOUNT_STAFF_RESET_PASSWORD
diff --git a/saleor/checkout/tests/test_checkout_complete.py b/saleor/checkout/tests/test_checkout_complete.py
index 3f5409460b..d8bfd38849 100644
--- a/saleor/checkout/tests/test_checkout_complete.py
+++ b/saleor/checkout/tests/test_checkout_complete.py
@@ -10,6 +10,7 @@ from ...account.models import CustomerEvent
from ...core.exceptions import InsufficientStock
from ...core.notify_events import NotifyEventType
from ...core.taxes import zero_money, zero_taxed_money
+from ...core.tests.utils import get_site_context_payload
from ...discount.models import VoucherCustomer
from ...giftcard import GiftCardEvents
from ...giftcard.models import GiftCard, GiftCardEvent
@@ -40,6 +41,7 @@ def test_create_order_captured_payment_creates_expected_events(
shipping_method,
payment_txn_captured,
channel_USD,
+ site_settings,
):
checkout = checkout_with_item
checkout_user = customer_user
@@ -126,8 +128,7 @@ def test_create_order_captured_payment_creates_expected_events(
expected_order_payload = {
"order": get_default_order_payload(order, checkout.redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
expected_payment_payload = {
@@ -141,8 +142,7 @@ def test_create_order_captured_payment_creates_expected_events(
"captured_amount": payment_txn_captured.captured_amount,
"currency": payment_txn_captured.currency,
},
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
# Ensure the correct order confirmed event was created
# should be order confirmed event
@@ -189,6 +189,7 @@ def test_create_order_captured_payment_creates_expected_events_anonymous_user(
shipping_method,
payment_txn_captured,
channel_USD,
+ site_settings,
):
checkout = checkout_with_item
checkout_user = None
@@ -276,8 +277,7 @@ def test_create_order_captured_payment_creates_expected_events_anonymous_user(
expected_order_payload = {
"order": get_default_order_payload(order, checkout.redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
expected_payment_payload = {
@@ -291,8 +291,7 @@ def test_create_order_captured_payment_creates_expected_events_anonymous_user(
"captured_amount": payment_txn_captured.captured_amount,
"currency": payment_txn_captured.currency,
},
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
# Ensure the correct order confirmed event was created
@@ -335,6 +334,7 @@ def test_create_order_preauth_payment_creates_expected_events(
shipping_method,
payment_txn_preauth,
channel_USD,
+ site_settings,
):
checkout = checkout_with_item
checkout_user = customer_user
@@ -408,8 +408,7 @@ def test_create_order_preauth_payment_creates_expected_events(
expected_payload = {
"order": get_default_order_payload(order, checkout.redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
# Ensure the correct order confirmed event was created
@@ -447,6 +446,7 @@ def test_create_order_preauth_payment_creates_expected_events_anonymous_user(
shipping_method,
payment_txn_preauth,
channel_USD,
+ site_settings,
):
checkout = checkout_with_item
checkout_user = None
@@ -521,8 +521,7 @@ def test_create_order_preauth_payment_creates_expected_events_anonymous_user(
expected_payload = {
"order": get_default_order_payload(order, checkout.redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
# Ensure the correct order confirmed event was created
# should be order confirmed event
@@ -1190,7 +1189,12 @@ def test_create_order_use_translations(
@mock.patch("saleor.plugins.manager.PluginsManager.notify")
def test_complete_checkout_0_total_captured_payment_creates_expected_events(
- mock_notify, checkout_with_item_total_0, customer_user, channel_USD, app
+ mock_notify,
+ checkout_with_item_total_0,
+ customer_user,
+ channel_USD,
+ app,
+ site_settings,
):
checkout = checkout_with_item_total_0
checkout_user = customer_user
@@ -1254,8 +1258,7 @@ def test_complete_checkout_0_total_captured_payment_creates_expected_events(
expected_order_payload = {
"order": get_default_order_payload(order, checkout.redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
# Ensure the correct order confirmed event was created
diff --git a/saleor/core/notification/utils.py b/saleor/core/notification/utils.py
index 75a151f552..b99d4e518c 100644
--- a/saleor/core/notification/utils.py
+++ b/saleor/core/notification/utils.py
@@ -1,4 +1,9 @@
from django.contrib.sites.models import Site
+from django.contrib.staticfiles.storage import staticfiles_storage
+
+from ..utils import build_absolute_uri
+
+LOGO_URL = "images/saleor-logo-sign.png"
def get_site_context():
@@ -6,5 +11,6 @@ def get_site_context():
site_context = {
"domain": site.domain,
"site_name": site.name,
+ "logo_url": build_absolute_uri(staticfiles_storage.url(LOGO_URL)),
}
return site_context
diff --git a/saleor/core/tests/utils.py b/saleor/core/tests/utils.py
new file mode 100644
index 0000000000..d50be124c0
--- /dev/null
+++ b/saleor/core/tests/utils.py
@@ -0,0 +1,12 @@
+from django.conf import settings
+
+from ..notification.utils import LOGO_URL
+
+
+def get_site_context_payload(site):
+ domain = site.domain
+ return {
+ "site_name": site.name,
+ "domain": domain,
+ "logo_url": f"http://{domain}{settings.STATIC_URL}{LOGO_URL}",
+ }
diff --git a/saleor/giftcard/tests/test_notifications.py b/saleor/giftcard/tests/test_notifications.py
index e6f1b7bbdf..c5c17d07d2 100644
--- a/saleor/giftcard/tests/test_notifications.py
+++ b/saleor/giftcard/tests/test_notifications.py
@@ -2,6 +2,7 @@ from unittest import mock
from ...account.notifications import get_default_user_payload
from ...core.notify_events import NotifyEventType
+from ...core.tests.utils import get_site_context_payload
from ...graphql.core.utils import to_global_id_or_none
from ...plugins.manager import get_plugins_manager
from ..notifications import get_default_gift_card_payload, send_gift_card_notification
@@ -19,7 +20,7 @@ def test_get_default_gift_card_payload(gift_card):
@mock.patch("saleor.plugins.manager.PluginsManager.notify")
def test_send_gift_card_notification(
- mocked_notify, staff_user, customer_user, gift_card, channel_USD
+ mocked_notify, staff_user, customer_user, gift_card, channel_USD, site_settings
):
manager = get_plugins_manager()
resending = False
@@ -46,8 +47,7 @@ def test_send_gift_card_notification(
"requester_app_id": None,
"recipient_email": customer_user.email,
"resending": resending,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
diff --git a/saleor/graphql/account/tests/test_account.py b/saleor/graphql/account/tests/test_account.py
index 6885e5a649..fa7107960c 100644
--- a/saleor/graphql/account/tests/test_account.py
+++ b/saleor/graphql/account/tests/test_account.py
@@ -31,6 +31,7 @@ from ....checkout import AddressType
from ....core.jwt import create_token
from ....core.notify_events import NotifyEventType
from ....core.permissions import AccountPermissions, OrderPermissions
+from ....core.tests.utils import get_site_context_payload
from ....core.tokens import account_delete_token_generator
from ....core.utils.json_serializer import CustomJsonEncoder
from ....core.utils.url import prepare_url
@@ -1344,6 +1345,7 @@ def test_customer_register(
api_client,
channel_PLN,
order,
+ site_settings,
):
mocked_generator.return_value = "token"
@@ -1375,9 +1377,8 @@ def test_customer_register(
"token": "token",
"confirm_url": confirm_url,
"recipient_email": new_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
assert new_user.metadata == {"meta": "data"}
assert new_user.language_code == "pl"
@@ -1482,6 +1483,7 @@ def test_customer_create(
address,
permission_manage_users,
channel_PLN,
+ site_settings,
):
mocked_generator.return_value = "token"
@@ -1539,9 +1541,8 @@ def test_customer_create(
"token": "token",
"password_set_url": password_set_url,
"recipient_email": new_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ACCOUNT_SET_CUSTOMER_PASSWORD,
@@ -1563,6 +1564,7 @@ def test_customer_create_send_password_with_url(
staff_api_client,
permission_manage_users,
channel_PLN,
+ site_settings,
):
mocked_generator.return_value = "token"
@@ -1589,9 +1591,8 @@ def test_customer_create_send_password_with_url(
"password_set_url": password_set_url,
"token": "token",
"recipient_email": new_customer.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ACCOUNT_SET_CUSTOMER_PASSWORD,
@@ -2176,7 +2177,7 @@ ACCOUNT_REQUEST_DELETION_MUTATION = """
@patch("saleor.account.notifications.account_delete_token_generator.make_token")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_request_deletion(
- mocked_notify, mocked_token, user_api_client, channel_PLN
+ mocked_notify, mocked_token, user_api_client, channel_PLN, site_settings
):
mocked_token.return_value = "token"
user = user_api_client.user
@@ -2195,9 +2196,8 @@ def test_account_request_deletion(
"delete_url": delete_url,
"token": "token",
"recipient_email": user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -2210,7 +2210,7 @@ def test_account_request_deletion(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_request_deletion_token_validation(
- mocked_notify, user_api_client, channel_PLN
+ mocked_notify, user_api_client, channel_PLN, site_settings
):
user = user_api_client.user
token = account_delete_token_generator.make_token(user)
@@ -2229,9 +2229,8 @@ def test_account_request_deletion_token_validation(
"delete_url": delete_url,
"token": token,
"recipient_email": user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -2271,7 +2270,7 @@ def test_account_request_deletion_storefront_hosts_not_allowed(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_request_deletion_all_storefront_hosts_allowed(
- mocked_notify, user_api_client, settings, channel_PLN
+ mocked_notify, user_api_client, settings, channel_PLN, site_settings
):
user = user_api_client.user
user.last_login = timezone.now()
@@ -2295,9 +2294,8 @@ def test_account_request_deletion_all_storefront_hosts_allowed(
"delete_url": delete_url,
"token": token,
"recipient_email": user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -2310,7 +2308,7 @@ def test_account_request_deletion_all_storefront_hosts_allowed(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_request_deletion_subdomain(
- mocked_notify, user_api_client, settings, channel_PLN
+ mocked_notify, user_api_client, settings, channel_PLN, site_settings
):
user = user_api_client.user
token = account_delete_token_generator.make_token(user)
@@ -2330,9 +2328,8 @@ def test_account_request_deletion_subdomain(
"delete_url": delete_url,
"token": token,
"recipient_email": user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -2656,6 +2653,7 @@ def test_staff_create(
permission_manage_staff,
permission_manage_users,
channel_PLN,
+ site_settings,
):
group = permission_group_manage_users
group.permissions.add(permission_manage_products)
@@ -2702,9 +2700,8 @@ def test_staff_create(
"password_set_url": password_set_url,
"token": token,
"recipient_email": staff_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": None,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -2867,6 +2864,7 @@ def test_staff_create_out_of_scope_group(
permission_manage_users,
permission_group_manage_users,
channel_PLN,
+ site_settings,
):
"""Ensure user can't create staff with groups which are out of user scope.
Ensure superuser pass restrictions.
@@ -2947,9 +2945,8 @@ def test_staff_create_out_of_scope_group(
"password_set_url": password_set_url,
"token": token,
"recipient_email": staff_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": None,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -2962,10 +2959,7 @@ def test_staff_create_out_of_scope_group(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_staff_create_send_password_with_url(
- mocked_notify,
- staff_api_client,
- media_root,
- permission_manage_staff,
+ mocked_notify, staff_api_client, media_root, permission_manage_staff, site_settings
):
redirect_url = "https://www.example.com"
@@ -2989,9 +2983,8 @@ def test_staff_create_send_password_with_url(
"password_set_url": password_set_url,
"token": token,
"recipient_email": staff_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": None,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -4806,7 +4799,12 @@ CONFIRM_ACCOUNT_MUTATION = """
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_reset_password(
- mocked_notify, user_api_client, customer_user, channel_PLN, channel_USD
+ mocked_notify,
+ user_api_client,
+ customer_user,
+ channel_PLN,
+ channel_USD,
+ site_settings,
):
redirect_url = "https://www.example.com"
variables = {
@@ -4826,9 +4824,8 @@ def test_account_reset_password(
"reset_url": reset_url,
"token": token,
"recipient_email": customer_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -4920,7 +4917,7 @@ def test_account_confirmation_invalid_token(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_request_password_reset_email_for_staff(
- mocked_notify, staff_api_client, channel_USD
+ mocked_notify, staff_api_client, channel_USD, site_settings
):
redirect_url = "https://www.example.com"
variables = {"email": staff_api_client.user.email, "redirectUrl": redirect_url}
@@ -4936,9 +4933,8 @@ def test_request_password_reset_email_for_staff(
"reset_url": reset_url,
"token": token,
"recipient_email": staff_api_client.user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": None,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -5007,7 +5003,13 @@ def test_account_reset_password_storefront_hosts_not_allowed(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_reset_password_all_storefront_hosts_allowed(
- mocked_notify, user_api_client, customer_user, settings, channel_PLN, channel_USD
+ mocked_notify,
+ user_api_client,
+ customer_user,
+ settings,
+ channel_PLN,
+ channel_USD,
+ site_settings,
):
settings.ALLOWED_CLIENT_HOSTS = ["*"]
redirect_url = "https://www.test.com"
@@ -5029,9 +5031,8 @@ def test_account_reset_password_all_storefront_hosts_allowed(
"reset_url": reset_url,
"token": token,
"recipient_email": customer_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -5044,7 +5045,7 @@ def test_account_reset_password_all_storefront_hosts_allowed(
@freeze_time("2018-05-31 12:00:01")
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_account_reset_password_subdomain(
- mocked_notify, user_api_client, customer_user, settings, channel_PLN
+ mocked_notify, user_api_client, customer_user, settings, channel_PLN, site_settings
):
settings.ALLOWED_CLIENT_HOSTS = [".example.com"]
redirect_url = "https://sub.example.com"
@@ -5066,9 +5067,8 @@ def test_account_reset_password_subdomain(
"reset_url": reset_url,
"token": token,
"recipient_email": customer_user.email,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"channel_slug": channel_PLN.slug,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
diff --git a/saleor/graphql/invoice/tests/test_send_invoice_notification.py b/saleor/graphql/invoice/tests/test_send_invoice_notification.py
index 44db4c1cee..5681a0ac7b 100644
--- a/saleor/graphql/invoice/tests/test_send_invoice_notification.py
+++ b/saleor/graphql/invoice/tests/test_send_invoice_notification.py
@@ -4,6 +4,7 @@ import graphene
from ....core import JobStatus
from ....core.notify_events import NotifyEventType
+from ....core.tests.utils import get_site_context_payload
from ....graphql.tests.utils import get_graphql_content
from ....invoice.models import Invoice
from ....invoice.notifications import get_invoice_payload
@@ -26,7 +27,7 @@ INVOICE_SEND_EMAIL_MUTATION = """
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_invoice_send_notification_by_user(
- mock_notify, staff_api_client, permission_manage_orders, order
+ mock_notify, staff_api_client, permission_manage_orders, order, site_settings
):
number = "01/12/2020/TEST"
url = "http://www.example.com"
@@ -43,8 +44,7 @@ def test_invoice_send_notification_by_user(
"requester_app_id": None,
"invoice": get_invoice_payload(invoice),
"recipient_email": invoice.order.get_customer_email(),
- "domain": "mirumee.com",
- "site_name": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mock_notify.assert_called_once_with(
@@ -57,7 +57,7 @@ def test_invoice_send_notification_by_user(
@patch("saleor.plugins.manager.PluginsManager.notify")
def test_invoice_send_notification_by_app(
- mock_notify, app_api_client, permission_manage_orders, order
+ mock_notify, app_api_client, permission_manage_orders, order, site_settings
):
number = "01/12/2020/TEST"
url = "http://www.example.com"
@@ -74,8 +74,7 @@ def test_invoice_send_notification_by_app(
"requester_app_id": to_global_id_or_none(app_api_client.app),
"invoice": get_invoice_payload(invoice),
"recipient_email": invoice.order.get_customer_email(),
- "domain": "mirumee.com",
- "site_name": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mock_notify.assert_called_once_with(
diff --git a/saleor/graphql/order/tests/test_order.py b/saleor/graphql/order/tests/test_order.py
index f1bfc52572..afcd995465 100644
--- a/saleor/graphql/order/tests/test_order.py
+++ b/saleor/graphql/order/tests/test_order.py
@@ -24,6 +24,7 @@ from ....core.notify_events import NotifyEventType
from ....core.postgres import FlatConcatSearchVector
from ....core.prices import quantize_price
from ....core.taxes import TaxError, zero_money, zero_taxed_money
+from ....core.tests.utils import get_site_context_payload
from ....discount.models import OrderDiscount, VoucherChannelListing
from ....giftcard import GiftCardEvents
from ....giftcard.events import gift_cards_bought_event, gift_cards_used_in_order_event
@@ -1597,8 +1598,7 @@ def test_order_confirm(
"recipient_email": order_unconfirmed.user.email,
"requester_user_id": to_global_id_or_none(staff_api_client.user),
"requester_app_id": None,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_CONFIRMED,
@@ -1620,6 +1620,7 @@ def test_order_confirm_without_sku(
order_unconfirmed,
permission_manage_orders,
payment_txn_preauth,
+ site_settings,
):
order_unconfirmed.lines.update(product_sku=None)
ProductVariant.objects.update(sku=None)
@@ -1659,8 +1660,7 @@ def test_order_confirm_without_sku(
"recipient_email": order_unconfirmed.user.email,
"requester_user_id": to_global_id_or_none(staff_api_client.user),
"requester_app_id": None,
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_CONFIRMED,
@@ -6644,8 +6644,7 @@ def test_order_capture(
"captured_amount": payment.captured_amount,
"currency": payment.currency,
},
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
diff --git a/saleor/order/tests/test_notifications.py b/saleor/order/tests/test_notifications.py
index 67f0d00b29..26a55e3dbb 100644
--- a/saleor/order/tests/test_notifications.py
+++ b/saleor/order/tests/test_notifications.py
@@ -9,6 +9,7 @@ from prices import Money, fixed_discount
from ...core.notify_events import NotifyEventType
from ...core.prices import quantize_price
+from ...core.tests.utils import get_site_context_payload
from ...discount import DiscountValueType
from ...graphql.core.utils import to_global_id_or_none
from ...graphql.order.utils import OrderLineData
@@ -30,7 +31,7 @@ from ..notifications import (
from ..utils import add_variant_to_order
-def test_get_custom_order_payload(order):
+def test_get_custom_order_payload(order, site_settings):
expected_payload = get_custom_order_payload(order)
assert expected_payload == {
"order": {
@@ -90,8 +91,7 @@ def test_get_custom_order_payload(order):
"discount_amount": 0,
},
"recipient_email": "[email protected]",
- "domain": "mirumee.com",
- "site_name": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
@@ -273,10 +273,7 @@ def test_get_default_order_payload(order_line):
}
-def test_get_default_fulfillment_payload(
- fulfillment,
- digital_content,
-):
+def test_get_default_fulfillment_payload(fulfillment, digital_content, site_settings):
order = fulfillment.order
fulfillment.tracking_number = "http://tracking.url.com/123"
fulfillment.save(update_fields=["tracking_number"])
@@ -304,8 +301,7 @@ def test_get_default_fulfillment_payload(
"physical_lines": [get_default_fulfillment_line_payload(physical_line)],
"digital_lines": [get_default_fulfillment_line_payload(digital_line)],
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
@@ -325,8 +321,7 @@ def test_send_email_payment_confirmation(mocked_notify, site_settings, payment_d
"captured_amount": payment_dummy.captured_amount,
"currency": payment_dummy.currency,
},
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
notifications.send_payment_confirmation(order_info, manager)
mocked_notify.assert_called_once_with(
@@ -347,8 +342,7 @@ def test_send_email_order_confirmation(mocked_notify, order, site_settings):
expected_payload = {
"order": get_default_order_payload(order, redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_CONFIRMATION,
@@ -370,8 +364,7 @@ def test_send_email_order_confirmation_for_cc(
expected_payload = {
"order": get_default_order_payload(order_with_lines_for_cc, redirect_url),
"recipient_email": order_with_lines_for_cc.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_CONFIRMATION,
@@ -425,8 +418,7 @@ def test_send_confirmation_emails_without_addresses_for_payment(
"captured_amount": payment_dummy.captured_amount,
"currency": payment_dummy.currency,
},
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_PAYMENT_CONFIRMATION,
@@ -474,8 +466,7 @@ def test_send_confirmation_emails_without_addresses_for_order(
expected_payload = {
"order": get_default_order_payload(order, redirect_url),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -573,10 +564,9 @@ def test_send_email_order_canceled_by_user(
expected_payload = {
"order": get_default_order_payload(order),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"requester_user_id": to_global_id_or_none(staff_user),
"requester_app_id": None,
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_CANCELED,
@@ -597,10 +587,9 @@ def test_send_email_order_canceled_by_app(mocked_notify, order, site_settings, a
expected_payload = {
"order": get_default_order_payload(order),
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
"requester_user_id": None,
"requester_app_id": to_global_id_or_none(app),
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
NotifyEventType.ORDER_CANCELED,
@@ -630,8 +619,7 @@ def test_send_email_order_refunded_by_user(
"amount": amount,
"currency": order.currency,
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
@@ -660,8 +648,7 @@ def test_send_email_order_refunded_by_app(mocked_notify, order, site_settings, a
"amount": amount,
"currency": order.currency,
"recipient_email": order.get_customer_email(),
- "site_name": "mirumee.com",
- "domain": "mirumee.com",
+ **get_site_context_payload(site_settings.site),
}
mocked_notify.assert_called_once_with(
diff --git a/saleor/plugins/admin_email/constants.py b/saleor/plugins/admin_email/constants.py
index 96d7b74d4a..b22a60d7d9 100644
--- a/saleor/plugins/admin_email/constants.py
+++ b/saleor/plugins/admin_email/constants.py
@@ -35,10 +35,10 @@ STAFF_PASSWORD_RESET_SUBJECT_FIELD = "staff_password_reset_subject"
STAFF_ORDER_CONFIRMATION_DEFAULT_SUBJECT = "Order {{ order.number }} details"
-SET_STAFF_PASSWORD_DEFAULT_SUBJECT = "Set password e-mail"
-CSV_EXPORT_SUCCESS_DEFAULT_SUBJECT = "Export {{ data_type }} data"
-CSV_EXPORT_FAILED_DEFAULT_SUBJECT = "Export {{ data_type }} data"
-STAFF_PASSWORD_RESET_DEFAULT_SUBJECT = "Staff password reset"
+SET_STAFF_PASSWORD_DEFAULT_SUBJECT = "Set Your Dashboard Password"
+CSV_EXPORT_SUCCESS_DEFAULT_SUBJECT = "Your exported {{ data_type }} data is ready"
+CSV_EXPORT_FAILED_DEFAULT_SUBJECT = "Exporting {{ data_type }} data failed"
+STAFF_PASSWORD_RESET_DEFAULT_SUBJECT = "Reset Your Dashboard Password"
PLUGIN_ID = "mirumee.notifications.admin_email"
diff --git a/saleor/plugins/admin_email/default_email_templates/export_failed.html b/saleor/plugins/admin_email/default_email_templates/export_failed.html
index 79d319e633..6a004aef52 100644
--- a/saleor/plugins/admin_email/default_email_templates/export_failed.html
+++ b/saleor/plugins/admin_email/default_email_templates/export_failed.html
@@ -1,43 +1,36 @@
-
- <!doctype html>
- <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
- <head>
- <title>
-
- </title>
- <!--[if !mso]><!-- -->
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <!--<![endif]-->
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <style type="text/css">
- #outlook a { padding:0; }
- body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
- table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
- img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
- p { display:block;margin:13px 0; }
- </style>
- <!--[if mso]>
- <xml>
- <o:OfficeDocumentSettings>
- <o:AllowPNG/>
- <o:PixelsPerInch>96</o:PixelsPerInch>
- </o:OfficeDocumentSettings>
- </xml>
- <![endif]-->
- <!--[if lte mso 11]>
- <style type="text/css">
- .mj-outlook-group-fix { width:100% !important; }
- </style>
- <![endif]-->
-
- <!--[if !mso]><!-->
- <link href="https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700" rel="stylesheet" type="text/css">
- <style type="text/css">
- @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700);
- </style>
- <!--<![endif]-->
-
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
+ <head>
+ <title>
+
+ </title>
+ <!--[if !mso]><!-->
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <!--<![endif]-->
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <style type="text/css">
+ #outlook a { padding:0; }
+ body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
+ table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
+ img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
+ p { display:block;margin:13px 0; }
+ </style>
+ <!--[if mso]>
+ <noscript>
+ <xml>
+ <o:OfficeDocumentSettings>
+ <o:AllowPNG/>
+ <o:PixelsPerInch>96</o:PixelsPerInch>
+ </o:OfficeDocumentSettings>
+ </xml>
+ </noscript>
+ <![endif]-->
+ <!--[if lte mso 11]>
+ <style type="text/css">
+ .mj-outlook-group-fix { width:100% !important; }
+ </style>
+ <![endif]-->
<style type="text/css">
@@ -45,141 +38,154 @@
.mj-column-per-100 { width:100% !important; max-width: 100%; }
}
</style>
+ <style media="screen and (min-width:480px)">
+ .moz-text-html .mj-column-per-100 { width:100% !important; max-width: 100%; }
+ </style>
- <style type="text/css">
-
-
- </style>
- <style type="text/css">address {
- font-style: inherit;
- font-family: Ubuntu, Helvetica, Arial;
- }</style>
+ <style type="text/css">
- </head>
- <body>
- <div style>
+ @media only screen and (max-width:480px) {
+ table.mj-full-width-mobile { width: 100% !important; }
+ td.mj-full-width-mobile { width: auto !important; }
+ }
+ </style>
+ <style type="text/css">
- <!--[if mso | IE]>
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ </style>
+ </head>
+ <body style="word-spacing:normal;background-color:#fafafa;">
- <div style="margin:0px auto;max-width:600px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <div
+ style="background-color:#fafafa;"
+ >
- <tr>
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div style="margin:0px auto;max-width:600px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ style="border:0;direction:ltr;font-size:0px;padding:50px 30px;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" bgcolor="white" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:16px;line-height:1;text-align:left;color:#000000;">Hi!</div>
- </td>
- </tr>
+ <div style="background:white;background-color:white;margin:0px auto;max-width:540px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:white;background-color:white;width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ style="border:1px solid secondaryColor;direction:ltr;font-size:0px;padding:1rem 0.5rem;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:538px;" ><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">Sorry, we couldn't finish exporting {{data_type}}, some unexpected errors occurred.
- Please try again.</div>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
- </td>
- </tr>
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- </table>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- </div>
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;"
+ >
+ <tbody>
+ <tr>
+ <td style="width:28px;">
+
+ <img
+ height="auto" src="{{ logo_url }}" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:14px;" width="28"
+ />
- <!--[if mso | IE]>
</td>
+ </tr>
+ </tbody>
+ </table>
- </tr>
+ </td>
+ </tr>
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- </div>
+ <p
+ style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:100%;"
+ >
+ </p>
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:488px;" role="presentation" width="488px" ><tr><td style="height:0;line-height:0;"> &nbsp;
+</td></tr></table><![endif]-->
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ </td>
+ </tr>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;padding-top:16px;word-break:break-word;"
+ >
- <div style="margin:0px auto;max-width:600px;">
+ <div
+ style="font-family:Helvetica, Arial;font-size:1.4rem;font-weight:bold;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Hello,</div>
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ </td>
+ </tr>
- <tr>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Sorry, we couldn't finish exporting {{data_type}} due to unexpected errors. Please try again.</div>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ </td>
+ </tr>
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Our appolgies and thank you.</div>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">This is an automatically generated e-mail, please do not reply.</div>
-
- </td>
- </tr>
+ </td>
+ </tr>
+ </tbody>
</table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -188,58 +194,48 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
-
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="background:#F2F2F2;background-color:#F2F2F2;margin:0px auto;max-width:600px;">
+ <div style="margin:0px auto;max-width:540px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:#F2F2F2;background-color:#F2F2F2;width:100%;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
<tbody>
<tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
-
- <tr>
+ <td
+ style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:540px;" ><![endif]-->
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
-
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <tr>
- <td align="center" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:center;color:#000000;">Sincerely, {{ site_name }}</div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:10px;line-height:1.2rem;text-align:center;color:#7f7b93;"
+ >This is an automatically generated e-mail, please do not reply. <br />Certain messages, like this one, are essectial to service operations.</div>
- </td>
- </tr>
+ </td>
+ </tr>
+ </tbody>
</table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -248,62 +244,7 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
-
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="no-display-outlook" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
-
-
- <div class="no-display" style="display: none; margin: 0px auto; max-width: 600px;">
-
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
-
- <tr>
-
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
-
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
-
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
-
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">{{#if order}}
- <script type="application/ld+json">
- {{{{raw}}}}{{schema_markup}}{{{{/raw}}}}
- </script>
- {{/if}}</div>
-
- </td>
- </tr>
-
- </table>
-
- </div>
-
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -312,14 +253,10 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</div>
- </body>
- </html>
+ </body>
+</html>
diff --git a/saleor/plugins/admin_email/default_email_templates/export_success.html b/saleor/plugins/admin_email/default_email_templates/export_success.html
index 208061192f..c4dae489c0 100644
--- a/saleor/plugins/admin_email/default_email_templates/export_success.html
+++ b/saleor/plugins/admin_email/default_email_templates/export_success.html
@@ -1,43 +1,36 @@
-
- <!doctype html>
- <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
- <head>
- <title>
-
- </title>
- <!--[if !mso]><!-- -->
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <!--<![endif]-->
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <style type="text/css">
- #outlook a { padding:0; }
- body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
- table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
- img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
- p { display:block;margin:13px 0; }
- </style>
- <!--[if mso]>
- <xml>
- <o:OfficeDocumentSettings>
- <o:AllowPNG/>
- <o:PixelsPerInch>96</o:PixelsPerInch>
- </o:OfficeDocumentSettings>
- </xml>
- <![endif]-->
- <!--[if lte mso 11]>
- <style type="text/css">
- .mj-outlook-group-fix { width:100% !important; }
- </style>
- <![endif]-->
-
- <!--[if !mso]><!-->
- <link href="https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700" rel="stylesheet" type="text/css">
- <style type="text/css">
- @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700);
- </style>
- <!--<![endif]-->
-
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
+ <head>
+ <title>
+
+ </title>
+ <!--[if !mso]><!-->
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <!--<![endif]-->
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <style type="text/css">
+ #outlook a { padding:0; }
+ body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
+ table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
+ img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
+ p { display:block;margin:13px 0; }
+ </style>
+ <!--[if mso]>
+ <noscript>
+ <xml>
+ <o:OfficeDocumentSettings>
+ <o:AllowPNG/>
+ <o:PixelsPerInch>96</o:PixelsPerInch>
+ </o:OfficeDocumentSettings>
+ </xml>
+ </noscript>
+ <![endif]-->
+ <!--[if lte mso 11]>
+ <style type="text/css">
+ .mj-outlook-group-fix { width:100% !important; }
+ </style>
+ <![endif]-->
<style type="text/css">
@@ -45,200 +38,192 @@
.mj-column-per-100 { width:100% !important; max-width: 100%; }
}
</style>
+ <style media="screen and (min-width:480px)">
+ .moz-text-html .mj-column-per-100 { width:100% !important; max-width: 100%; }
+ </style>
- <style type="text/css">
-
-
- </style>
- <style type="text/css">address {
- font-style: inherit;
- font-family: Ubuntu, Helvetica, Arial;
- }</style>
+ <style type="text/css">
- </head>
- <body>
- <div style>
+ @media only screen and (max-width:480px) {
+ table.mj-full-width-mobile { width: 100% !important; }
+ td.mj-full-width-mobile { width: auto !important; }
+ }
+ </style>
+ <style type="text/css">
- <!--[if mso | IE]>
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ </style>
+ </head>
+ <body style="word-spacing:normal;background-color:#fafafa;">
- <div style="margin:0px auto;max-width:600px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <div
+ style="background-color:#fafafa;"
+ >
- <tr>
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div style="margin:0px auto;max-width:600px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ style="border:0;direction:ltr;font-size:0px;padding:50px 30px;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" bgcolor="white" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:16px;line-height:1;text-align:left;color:#000000;">Hi!</div>
- </td>
- </tr>
+ <div style="background:white;background-color:white;margin:0px auto;max-width:540px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:white;background-color:white;width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">Your file with {{data_type}} data is ready to download: <a href="{{csv_link}}">{{csv_link}}</a></div>
+ <td
+ style="border:1px solid secondaryColor;direction:ltr;font-size:0px;padding:1rem 0.5rem;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:538px;" ><![endif]-->
- </td>
- </tr>
-
- </table>
-
- </div>
-
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
-
- </div>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
<table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;"
>
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <tbody>
+ <tr>
+ <td style="width:28px;">
+ <img
+ height="auto" src="{{ logo_url }}" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:14px;" width="28"
+ />
- <div style="margin:0px auto;max-width:600px;">
+ </td>
+ </tr>
+ </tbody>
+ </table>
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ </td>
+ </tr>
- <tr>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <p
+ style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:100%;"
+ >
+ </p>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:488px;" role="presentation" width="488px" ><tr><td style="height:0;line-height:0;"> &nbsp;
+</td></tr></table><![endif]-->
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ </td>
+ </tr>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">This is an automatically generated e-mail, please do not reply.</div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;padding-top:16px;word-break:break-word;"
+ >
- </td>
- </tr>
+ <div
+ style="font-family:Helvetica, Arial;font-size:1.4rem;font-weight:bold;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Hello,</div>
- </table>
+ </td>
+ </tr>
- </div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <!--[if mso | IE]>
- </td>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >We're happy to let you know that your file with {{data_type}} data is ready to download.</div>
- </tr>
+ </td>
+ </tr>
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- </div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >To download your {{data_type}} data, simply click the button below.</div>
+ </td>
+ </tr>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
+ <tr>
+ <td
+ align="center" vertical-align="middle" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
<table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:separate;line-height:100%;"
>
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
-
-
- <div style="background:#F2F2F2;background-color:#F2F2F2;margin:0px auto;max-width:600px;">
-
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:#F2F2F2;background-color:#F2F2F2;width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
-
- <tr>
-
+ <tbody>
+ <tr>
<td
- class="" style="vertical-align:top;width:600px;"
+ align="center" bgcolor="#056dff" role="presentation" style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#056dff;" valign="middle"
>
- <![endif]-->
-
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <a
+ href="{{csv_link}}" style="display:inline-block;background:#056dff;color:white;font-family:Helvetica, Arial;font-size:14px;font-weight:normal;line-height:1.5rem;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;" target="_blank"
+ >
+ Download data
+ </a>
+ </td>
+ </tr>
+ </tbody>
+ </table>
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ </td>
+ </tr>
- <tr>
- <td align="center" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:center;color:#000000;">Sincerely, {{ site_name }}</div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Have a great day and thank you!</div>
- </td>
- </tr>
+ </td>
+ </tr>
+ </tbody>
</table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -247,62 +232,57 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
-
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="no-display-outlook" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="no-display" style="display: none; margin: 0px auto; max-width: 600px;">
+ <div style="margin:0px auto;max-width:540px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
<tbody>
<tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <td
+ style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:540px;" ><![endif]-->
- <tr>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div
+ style="font-family:Helvetica, Arial;font-size:10px;line-height:1.2rem;text-align:center;color:#7f7b93;"
+ >This is an automatically generated e-mail, please do not reply. <br />Certain messages, like this one, are essectial to service operations.</div>
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ </td>
+ </tr>
+
+ </tbody>
+ </table>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">{{#if order}}
- <script type="application/ld+json">
- {{{{raw}}}}{{schema_markup}}{{{{/raw}}}}
- </script>
- {{/if}}</div>
+ </div>
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
-
- </table>
+ </tbody>
+ </table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -311,14 +291,10 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</div>
- </body>
- </html>
+ </body>
+</html>
diff --git a/saleor/plugins/admin_email/default_email_templates/password_reset.html b/saleor/plugins/admin_email/default_email_templates/password_reset.html
index 07187977a8..74dbd8ea7d 100644
--- a/saleor/plugins/admin_email/default_email_templates/password_reset.html
+++ b/saleor/plugins/admin_email/default_email_templates/password_reset.html
@@ -1,43 +1,36 @@
-
- <!doctype html>
- <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
- <head>
- <title>
-
- </title>
- <!--[if !mso]><!-- -->
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <!--<![endif]-->
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <style type="text/css">
- #outlook a { padding:0; }
- body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
- table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
- img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
- p { display:block;margin:13px 0; }
- </style>
- <!--[if mso]>
- <xml>
- <o:OfficeDocumentSettings>
- <o:AllowPNG/>
- <o:PixelsPerInch>96</o:PixelsPerInch>
- </o:OfficeDocumentSettings>
- </xml>
- <![endif]-->
- <!--[if lte mso 11]>
- <style type="text/css">
- .mj-outlook-group-fix { width:100% !important; }
- </style>
- <![endif]-->
-
- <!--[if !mso]><!-->
- <link href="https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700" rel="stylesheet" type="text/css">
- <style type="text/css">
- @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700);
- </style>
- <!--<![endif]-->
-
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
+ <head>
+ <title>
+
+ </title>
+ <!--[if !mso]><!-->
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <!--<![endif]-->
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <style type="text/css">
+ #outlook a { padding:0; }
+ body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
+ table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
+ img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
+ p { display:block;margin:13px 0; }
+ </style>
+ <!--[if mso]>
+ <noscript>
+ <xml>
+ <o:OfficeDocumentSettings>
+ <o:AllowPNG/>
+ <o:PixelsPerInch>96</o:PixelsPerInch>
+ </o:OfficeDocumentSettings>
+ </xml>
+ </noscript>
+ <![endif]-->
+ <!--[if lte mso 11]>
+ <style type="text/css">
+ .mj-outlook-group-fix { width:100% !important; }
+ </style>
+ <![endif]-->
<style type="text/css">
@@ -45,211 +38,216 @@
.mj-column-per-100 { width:100% !important; max-width: 100%; }
}
</style>
+ <style media="screen and (min-width:480px)">
+ .moz-text-html .mj-column-per-100 { width:100% !important; max-width: 100%; }
+ </style>
- <style type="text/css">
-
-
- </style>
- <style type="text/css">address {
- font-style: inherit;
- font-family: Ubuntu, Helvetica, Arial;
- }</style>
-
- </head>
- <body>
-
-
- <div style>
+ <style type="text/css">
- <!--[if mso | IE]>
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ @media only screen and (max-width:480px) {
+ table.mj-full-width-mobile { width: 100% !important; }
+ td.mj-full-width-mobile { width: auto !important; }
+ }
- <div style="margin:0px auto;max-width:600px;">
+ </style>
+ <style type="text/css">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ </style>
- <tr>
+ </head>
+ <body style="word-spacing:normal;background-color:#fafafa;">
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <div
+ style="background-color:#fafafa;"
+ >
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:16px;line-height:1;text-align:left;color:#000000;">Hi!</div>
- </td>
- </tr>
+ <div style="margin:0px auto;max-width:600px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ style="border:0;direction:ltr;font-size:0px;padding:50px 30px;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" bgcolor="white" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">You're receiving this e-mail because you or someone else has requested a password for your staff account at {{site_name}}.<br>
- It can be safely ignored if you did not request a password reset. Click the link below to reset your password.</div>
- </td>
- </tr>
+ <div style="background:white;background-color:white;margin:0px auto;max-width:540px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:white;background-color:white;width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;"><a href="{{reset_url}}">
- {{reset_url}}
- </a></div>
-
- </td>
- </tr>
-
- </table>
-
- </div>
-
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ <td
+ style="border:1px solid secondaryColor;direction:ltr;font-size:0px;padding:1rem 0.5rem;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:538px;" ><![endif]-->
- </div>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
<table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;"
>
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <tbody>
+ <tr>
+ <td style="width:28px;">
+ <img
+ height="auto" src="{{ logo_url }}" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:14px;" width="28"
+ />
- <div style="margin:0px auto;max-width:600px;">
+ </td>
+ </tr>
+ </tbody>
+ </table>
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ </td>
+ </tr>
- <tr>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <p
+ style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:100%;"
+ >
+ </p>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:488px;" role="presentation" width="488px" ><tr><td style="height:0;line-height:0;"> &nbsp;
+</td></tr></table><![endif]-->
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ </td>
+ </tr>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">This is an automatically generated e-mail, please do not reply.</div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;padding-top:16px;word-break:break-word;"
+ >
- </td>
- </tr>
+ <div
+ style="font-family:Helvetica, Arial;font-size:1.4rem;font-weight:bold;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Hello there!</div>
- </table>
+ </td>
+ </tr>
- </div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <!--[if mso | IE]>
- </td>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >We received your dashboard password reset request.</div>
- </tr>
+ </td>
+ </tr>
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- </div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >To reset your password, simply click the “Reset my password” button below.</div>
+ </td>
+ </tr>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
+ <tr>
+ <td
+ align="center" vertical-align="middle" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
<table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:separate;line-height:100%;"
>
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <tbody>
+ <tr>
+ <td
+ align="center" bgcolor="#056dff" role="presentation" style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#056dff;" valign="middle"
+ >
+ <a
+ href="{{reset_url}}" style="display:inline-block;background:#056dff;color:white;font-family:Helvetica, Arial;font-size:14px;font-weight:normal;line-height:1.5rem;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;" target="_blank"
+ >
+ Reset my password
+ </a>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
- <div style="background:#F2F2F2;background-color:#F2F2F2;margin:0px auto;max-width:600px;">
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:#F2F2F2;background-color:#F2F2F2;width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >This link expires in 24 hours. If you miss the window, please reset your password again.</div>
- <tr>
+ </td>
+ </tr>
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Didn&apos;t request a reset? Ignore this message (or reply to let us know).</div>
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ </td>
+ </tr>
- <tr>
- <td align="center" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:center;color:#000000;">Sincerely, {{ site_name }}</div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Thank you!</div>
- </td>
- </tr>
+ </td>
+ </tr>
+ </tbody>
</table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -258,62 +256,57 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
-
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="no-display-outlook" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="no-display" style="display: none; margin: 0px auto; max-width: 600px;">
+ <div style="margin:0px auto;max-width:540px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
<tbody>
<tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <td
+ style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:540px;" ><![endif]-->
- <tr>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div
+ style="font-family:Helvetica, Arial;font-size:10px;line-height:1.2rem;text-align:center;color:#7f7b93;"
+ >This is an automatically generated e-mail, please do not reply. <br />Certain messages, like this one, are essectial to service operations.</div>
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ </td>
+ </tr>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">{{#if order}}
- <script type="application/ld+json">
- {{{{raw}}}}{{schema_markup}}{{{{/raw}}}}
- </script>
- {{/if}}</div>
+ </tbody>
+ </table>
+ </div>
+
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
-
- </table>
+ </tbody>
+ </table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -322,14 +315,10 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</div>
- </body>
- </html>
+ </body>
+</html>
diff --git a/saleor/plugins/admin_email/default_email_templates/set_password.html b/saleor/plugins/admin_email/default_email_templates/set_password.html
index 00c1054c83..c3a6b92720 100644
--- a/saleor/plugins/admin_email/default_email_templates/set_password.html
+++ b/saleor/plugins/admin_email/default_email_templates/set_password.html
@@ -1,43 +1,36 @@
-
- <!doctype html>
- <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
- <head>
- <title>
-
- </title>
- <!--[if !mso]><!-- -->
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <!--<![endif]-->
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <style type="text/css">
- #outlook a { padding:0; }
- body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
- table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
- img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
- p { display:block;margin:13px 0; }
- </style>
- <!--[if mso]>
- <xml>
- <o:OfficeDocumentSettings>
- <o:AllowPNG/>
- <o:PixelsPerInch>96</o:PixelsPerInch>
- </o:OfficeDocumentSettings>
- </xml>
- <![endif]-->
- <!--[if lte mso 11]>
- <style type="text/css">
- .mj-outlook-group-fix { width:100% !important; }
- </style>
- <![endif]-->
-
- <!--[if !mso]><!-->
- <link href="https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700" rel="stylesheet" type="text/css">
- <style type="text/css">
- @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700);
- </style>
- <!--<![endif]-->
-
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
+ <head>
+ <title>
+
+ </title>
+ <!--[if !mso]><!-->
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <!--<![endif]-->
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <style type="text/css">
+ #outlook a { padding:0; }
+ body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
+ table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
+ img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
+ p { display:block;margin:13px 0; }
+ </style>
+ <!--[if mso]>
+ <noscript>
+ <xml>
+ <o:OfficeDocumentSettings>
+ <o:AllowPNG/>
+ <o:PixelsPerInch>96</o:PixelsPerInch>
+ </o:OfficeDocumentSettings>
+ </xml>
+ </noscript>
+ <![endif]-->
+ <!--[if lte mso 11]>
+ <style type="text/css">
+ .mj-outlook-group-fix { width:100% !important; }
+ </style>
+ <![endif]-->
<style type="text/css">
@@ -45,211 +38,192 @@
.mj-column-per-100 { width:100% !important; max-width: 100%; }
}
</style>
+ <style media="screen and (min-width:480px)">
+ .moz-text-html .mj-column-per-100 { width:100% !important; max-width: 100%; }
+ </style>
- <style type="text/css">
-
-
- </style>
- <style type="text/css">address {
- font-style: inherit;
- font-family: Ubuntu, Helvetica, Arial;
- }</style>
+ <style type="text/css">
- </head>
- <body>
- <div style>
+ @media only screen and (max-width:480px) {
+ table.mj-full-width-mobile { width: 100% !important; }
+ td.mj-full-width-mobile { width: auto !important; }
+ }
+ </style>
+ <style type="text/css">
- <!--[if mso | IE]>
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ </style>
+ </head>
+ <body style="word-spacing:normal;background-color:#fafafa;">
- <div style="margin:0px auto;max-width:600px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <div
+ style="background-color:#fafafa;"
+ >
- <tr>
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div style="margin:0px auto;max-width:600px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ style="border:0;direction:ltr;font-size:0px;padding:50px 30px;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" bgcolor="white" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:16px;line-height:1;text-align:left;color:#000000;">Hi!</div>
- </td>
- </tr>
-
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">You're receiving this e-mail because you have to set password for your staff member account at {{site_name}}.<br>
- Click the link below to set up your password.</div>
-
- </td>
- </tr>
+ <div style="background:white;background-color:white;margin:0px auto;max-width:540px;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:white;background-color:white;width:100%;"
+ >
+ <tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;"><a href="{{ password_set_url}}">
- {{password_set_url}}
- </a></div>
-
- </td>
- </tr>
-
- </table>
-
- </div>
-
- <!--[if mso | IE]>
- </td>
+ <td
+ style="border:1px solid secondaryColor;direction:ltr;font-size:0px;padding:1rem 0.5rem;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:538px;" ><![endif]-->
- </tr>
-
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
-
- </div>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
<table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;"
>
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <tbody>
+ <tr>
+ <td style="width:28px;">
+ <img
+ height="auto" src="{{ logo_url }}" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:14px;" width="28"
+ />
- <div style="margin:0px auto;max-width:600px;">
+ </td>
+ </tr>
+ </tbody>
+ </table>
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ </td>
+ </tr>
- <tr>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <p
+ style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:100%;"
+ >
+ </p>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:488px;" role="presentation" width="488px" ><tr><td style="height:0;line-height:0;"> &nbsp;
+</td></tr></table><![endif]-->
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ </td>
+ </tr>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">This is an automatically generated e-mail, please do not reply.</div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;padding-top:16px;word-break:break-word;"
+ >
- </td>
- </tr>
+ <div
+ style="font-family:Helvetica, Arial;font-size:1.4rem;font-weight:bold;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Hello there!</div>
- </table>
+ </td>
+ </tr>
- </div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <!--[if mso | IE]>
- </td>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >You received this e-mail because you have to set password for your dashboard user account.</div>
- </tr>
+ </td>
+ </tr>
- </table>
- <![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- </div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >To set up your password, simply click the “Set my password” button below.</div>
+ </td>
+ </tr>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
+ <tr>
+ <td
+ align="center" vertical-align="middle" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
<table
- align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600"
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:separate;line-height:100%;"
>
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
-
-
- <div style="background:#F2F2F2;background-color:#F2F2F2;margin:0px auto;max-width:600px;">
-
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:#F2F2F2;background-color:#F2F2F2;width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
-
- <tr>
-
+ <tbody>
+ <tr>
<td
- class="" style="vertical-align:top;width:600px;"
+ align="center" bgcolor="#056dff" role="presentation" style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#056dff;" valign="middle"
>
- <![endif]-->
+ <a
+ href="{{password_set_url}}" style="display:inline-block;background:#056dff;color:white;font-family:Helvetica, Arial;font-size:14px;font-weight:normal;line-height:1.5rem;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;" target="_blank"
+ >
+ Set my password
+ </a>
+ </td>
+ </tr>
+ </tbody>
+ </table>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ </td>
+ </tr>
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <tr>
- <td align="center" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Thank you!</div>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:center;color:#000000;">Sincerely, {{ site_name }}</div>
-
- </td>
- </tr>
+ </td>
+ </tr>
+ </tbody>
</table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
-
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -258,62 +232,57 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
-
- <table
- align="center" border="0" cellpadding="0" cellspacing="0" class="no-display-outlook" style="width:600px;" width="600"
- >
- <tr>
- <td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;">
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="no-display" style="display: none; margin: 0px auto; max-width: 600px;">
+ <div style="margin:0px auto;max-width:540px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
<tbody>
<tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]>
- <table role="presentation" border="0" cellpadding="0" cellspacing="0">
+ <td
+ style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:540px;" ><![endif]-->
- <tr>
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
- <td
- class="" style="vertical-align:top;width:600px;"
- >
- <![endif]-->
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
+ <tbody>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div
+ style="font-family:Helvetica, Arial;font-size:10px;line-height:1.2rem;text-align:center;color:#7f7b93;"
+ >This is an automatically generated e-mail, please do not reply. <br />Certain messages, like this one, are essectial to service operations.</div>
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ </td>
+ </tr>
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">{{#if order}}
- <script type="application/ld+json">
- {{{{raw}}}}{{schema_markup}}{{{{/raw}}}}
- </script>
- {{/if}}</div>
+ </tbody>
+ </table>
+ </div>
+
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</td>
</tr>
-
- </table>
+ </tbody>
+ </table>
</div>
- <!--[if mso | IE]>
- </td>
-
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -322,14 +291,10 @@
</div>
- <!--[if mso | IE]>
- </td>
- </tr>
- </table>
- <![endif]-->
+ <!--[if mso | IE]></td></tr></table><![endif]-->
</div>
- </body>
- </html>
+ </body>
+</html>
diff --git a/saleor/plugins/admin_email/default_email_templates/staff_confirm_order.html b/saleor/plugins/admin_email/default_email_templates/staff_confirm_order.html
index 26a9784e0e..2667e72f0b 100644
--- a/saleor/plugins/admin_email/default_email_templates/staff_confirm_order.html
+++ b/saleor/plugins/admin_email/default_email_templates/staff_confirm_order.html
@@ -1,43 +1,36 @@
-
- <!doctype html>
- <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
- <head>
- <title>
-
- </title>
- <!--[if !mso]><!-->
- <meta http-equiv="X-UA-Compatible" content="IE=edge">
- <!--<![endif]-->
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <style type="text/css">
- #outlook a { padding:0; }
- body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
- table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
- img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
- p { display:block;margin:13px 0; }
- </style>
- <!--[if mso]>
- <xml>
- <o:OfficeDocumentSettings>
- <o:AllowPNG/>
- <o:PixelsPerInch>96</o:PixelsPerInch>
- </o:OfficeDocumentSettings>
- </xml>
- <![endif]-->
- <!--[if lte mso 11]>
- <style type="text/css">
- .mj-outlook-group-fix { width:100% !important; }
- </style>
- <![endif]-->
-
- <!--[if !mso]><!-->
- <link href="https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700" rel="stylesheet" type="text/css">
- <style type="text/css">
- @import url(https://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700);
- </style>
- <!--<![endif]-->
-
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
+ <head>
+ <title>
+
+ </title>
+ <!--[if !mso]><!-->
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <!--<![endif]-->
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <style type="text/css">
+ #outlook a { padding:0; }
+ body { margin:0;padding:0;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%; }
+ table, td { border-collapse:collapse;mso-table-lspace:0pt;mso-table-rspace:0pt; }
+ img { border:0;height:auto;line-height:100%; outline:none;text-decoration:none;-ms-interpolation-mode:bicubic; }
+ p { display:block;margin:13px 0; }
+ </style>
+ <!--[if mso]>
+ <noscript>
+ <xml>
+ <o:OfficeDocumentSettings>
+ <o:AllowPNG/>
+ <o:PixelsPerInch>96</o:PixelsPerInch>
+ </o:OfficeDocumentSettings>
+ </xml>
+ </noscript>
+ <![endif]-->
+ <!--[if lte mso 11]>
+ <style type="text/css">
+ .mj-outlook-group-fix { width:100% !important; }
+ </style>
+ <![endif]-->
<style type="text/css">
@@ -45,269 +38,336 @@
.mj-column-per-100 { width:100% !important; max-width: 100%; }
}
</style>
+ <style media="screen and (min-width:480px)">
+ .moz-text-html .mj-column-per-100 { width:100% !important; max-width: 100%; }
+ </style>
- <style type="text/css">
+ <style type="text/css">
- </style>
- <style type="text/css">address {
- font-style: inherit;
- font-family: Ubuntu, Helvetica, Arial;
- }</style>
- </head>
- <body style="word-spacing:normal;">
+ @media only screen and (max-width:480px) {
+ table.mj-full-width-mobile { width: 100% !important; }
+ td.mj-full-width-mobile { width: auto !important; }
+ }
+ </style>
+ <style type="text/css">
- <div style>
+ </style>
+ </head>
+ <body style="word-spacing:normal;background-color:#fafafa;">
- <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
+ <div
+ style="background-color:#fafafa;"
+ >
- <div style="margin:0px auto;max-width:600px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
+
+
+ <div style="margin:0px auto;max-width:600px;">
+
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
<tbody>
<tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
+ <td
+ style="border:0;direction:ltr;font-size:0px;padding:50px 30px;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" bgcolor="white" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <div style="background:white;background-color:white;margin:0px auto;max-width:540px;">
+
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:white;background-color:white;width:100%;"
+ >
+ <tbody>
+ <tr>
+ <td
+ style="border:1px solid secondaryColor;direction:ltr;font-size:0px;padding:1rem 0.5rem;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:538px;" ><![endif]-->
+
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
+
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
<tbody>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:16px;line-height:1;text-align:left;color:#000000;">Hi!</div>
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:collapse;border-spacing:0px;"
+ >
+ <tbody>
+ <tr>
+ <td style="width:28px;">
+
+ <img
+ height="auto" src="{{ logo_url }}" style="border:0;display:block;outline:none;text-decoration:none;height:auto;width:100%;font-size:14px;" width="28"
+ />
+
+ </td>
+ </tr>
+ </tbody>
+ </table>
</td>
</tr>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
+
+ <p
+ style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:100%;"
+ >
+ </p>
+
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:solid 4px #056dff;font-size:1px;margin:0px auto;width:488px;" role="presentation" width="488px" ><tr><td style="height:0;line-height:0;"> &nbsp;
+</td></tr></table><![endif]-->
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">Someone placed a new order in your store. To see order details please visit:
- <a href="{{order.order_details_url}}">{{order.order_details_url}}</a></div>
</td>
</tr>
- </tbody>
- </table>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;padding-top:16px;word-break:break-word;"
+ >
- </div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:1.4rem;font-weight:bold;line-height:1.5rem;text-align:left;color:#28234a;"
+ >New order just came in! 🎉</div>
- <!--[if mso | IE]></td></tr></table><![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ </td>
+ </tr>
- </div>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;padding-bottom:10px;word-break:break-word;"
+ >
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Someone placed a new order in your store.</div>
- <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
+ </td>
+ </tr>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="margin:0px auto;max-width:600px;">
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >To see order details please click the button "See order" below.</div>
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
+ </td>
+ </tr>
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <tr>
+ <td
+ align="center" vertical-align="middle" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="border-collapse:separate;line-height:100%;"
+ >
<tbody>
-
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <table cellpadding="0" cellspacing="0" width="100%" border="0" style="color:#000000;font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:22px;table-layout:auto;width:100%;border:none;">
- <tfoot>
- <tr>
- <td colspan="3" style="padding: 5px; text-align: right;" align="right">Subtotal</td>
- <td style="padding: 5px; text-align: right;" align="right">
- {{price order.subtotal_net_amount order.subtotal_gross_amount order.currency display_gross=order.display_gross_prices}}
- </td>
- </tr>
- <tr>
- <td colspan="3" style="padding: 5px; text-align: right;" align="right">
- Shipping
- </td>
- <td style="padding: 5px; text-align: right;" align="right">
- {{price order.shipping_price_net_amount order.shipping_price_gross_amount order.currency display_gross=order.display_gross_prices}}
- </td>
- </tr>
- <tr>
- <td colspan="3" style="padding: 5px; text-align: right;" align="right">
- {{#if order.display_gross_prices}}
- Taxes (included)
- {{else}}
- Taxes
- {{/if}}
- </td>
- <td style="padding: 5px; text-align: right;" align="right">
- {{price order.tax_amount order.tax_amount order.currency display_gross=order.display_gross_prices}}
- </td>
- </tr>
- {{#if order.voucher_discount}}
<tr>
- <td colspan="3" style="padding: 5px; text-align: right;" align="right">
- Discount
- </td>
- <td style="padding: 5px; text-align: right;" align="right">
- {{price order.voucher_discount.amount_value order.voucher_discount.amount_value order.currency display_gross=order.display_gross_prices}}
+ <td
+ align="center" bgcolor="#056dff" role="presentation" style="border:none;border-radius:3px;cursor:auto;mso-padding-alt:10px 25px;background:#056dff;" valign="middle"
+ >
+ <a
+ href="{{order.order_details_url}}" style="display:inline-block;background:#056dff;color:white;font-family:Helvetica, Arial;font-size:14px;font-weight:normal;line-height:1.5rem;margin:0;text-decoration:none;text-transform:none;padding:10px 25px;mso-padding-alt:0px;border-radius:3px;" target="_blank"
+ >
+ See order
+ </a>
</td>
</tr>
- {{/if}}
- <tr>
- <td colspan="3" style="padding: 5px; text-align: right;" align="right">
- <strong>
- Total
- </strong>
- </td>
- <td style="padding: 5px; text-align: right;" align="right">
- <strong>
- {{price order.total_net_amount order.total_gross_amount order.currency display_gross=order.display_gross_prices}}
- </strong>
- </td>
- </tr>
- </tfoot>
- <thead class="table-header-row" style="border-bottom: 2px solid #000;">
- <tr>
- <th style="padding: 5px;">Item</th>
- <th style="padding: 5px;">Quantity</th>
- <th style="padding: 5px;">Per unit</th>
- <th style="padding: 5px;">Subtotal</th>
- </tr>
- </thead>
- <tbody>
- {{#each order.lines}}
- <tr class="table-item-row" style="border-bottom: 1px solid #D3D1D0;">
- {{#if variant_name}}
- <td style="padding: 5px;">{{product_name}} ({{variant_name}})</td>
- {{else}}
- <td style="padding: 5px;">{{product_name}}</td>
- {{/if}}
- <td style="padding: 5px; text-align: right;" align="right">{{quantity}}</td>
- <td style="padding: 5px; text-align: right;" align="right">
- {{price unit_price_net_amount unit_price_gross_amount ../order.currency display_gross=../order.display_gross_prices}}
- </td>
- <td style="padding: 5px; text-align: right;" align="right">
- {{price total_net_amount total_gross_amount ../order.currency display_gross=../order.display_gross_prices}}
- </td>
- </tr>
- {{/each}}
- </tbody>
+ </tbody>
</table>
</td>
</tr>
-
- </tbody>
- </table>
-
- </div>
-
- <!--[if mso | IE]></td></tr></table><![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
-
- </div>
-
-
- <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
-
-
- <div style="margin:0px auto;max-width:600px;">
-
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
-
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
-
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tbody>
-
+ <!-- <mj-text mj-class="h2">The details of the order</mj-text> -->
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
+
+ <table
+ cellpadding="0" cellspacing="0" width="100%" border="0" style="color:#28234a;font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;table-layout:auto;width:100%;border:none;"
+ >
+ <thead class="table-header-row" style="border-bottom: 2px solid #28234a">
+ <tr>
+ <th style="padding: 5px;">Item</th>
+ <th style="padding: 5px;">Qty</th>
+ <th style="padding: 5px;">Per unit</th>
+ <th style="padding: 5px;">Subtotal</th>
+ </tr>
+ </thead>
- <table cellpadding="0" cellspacing="0" width="100%" border="0" style="color:#000000;font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:22px;table-layout:auto;width:100%;border:none;">
- <thead class="table-header-row" style="border-bottom: 2px solid #000;">
- <tr>
- <th style="padding: 5px;">Billing address</th>
- <th style="padding: 5px;">Shipping address</th>
- </tr>
- </thead>
- <tbody>
- <tr>
- <td class="address" style="padding: 5px;">
- {{#if order.billing_address}}
- {{format_address order.billing_address}}
- {{else}}
- No billing address
- {{/if}}
- </td>
- <td css-class="address" style="padding: 5px;">
- {{#if order.shipping_address}}
- {{format_address order.shipping_address}}
+ {{#each order.lines}}
+ <tr class="table-item-row" style="border-bottom: 1px solid #28234a;">
+ {{#if variant_name}}
+ <td style="padding: 5px;">{{product_name}} ({{variant_name}})</td>
{{else}}
- No shipping required
+ <td style="padding: 5px;">{{product_name}}</td>
{{/if}}
- </td>
- </tr>
- </tbody>
+ <td style="padding: 5px; text-align: right;" align="right">{{quantity}}</td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ {{price unit_price_net_amount unit_price_gross_amount ../order.currency display_gross=../order.display_gross_prices}}
+ </td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ {{price total_net_amount total_gross_amount ../order.currency display_gross=../order.display_gross_prices}}
+ </td>
+ </tr>
+ {{/each}}
+ <tfoot>
+ <tr>
+ <td colspan="3" style="padding: 5px; text-align: right;" align="right">Subtotal</td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ {{price order.subtotal_net_amount order.subtotal_gross_amount order.currency display_gross=order.display_gross_prices}}
+ </td>
+ </tr>
+ <tr>
+ <td colspan="3" style="padding: 5px; text-align: right;" align="right">
+ Shipping
+ </td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ {{price order.shipping_price_net_amount order.shipping_price_gross_amount order.currency display_gross=order.display_gross_prices}}
+ </td>
+ </tr>
+ <tr>
+ <td colspan="3" style="padding: 5px; text-align: right;" align="right">
+ {{#if order.display_gross_prices}}
+ Taxes (included)
+ {{else}}
+ Taxes
+ {{/if}}
+ </td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ {{price order.tax_amount order.tax_amount order.currency display_gross=order.display_gross_prices}}
+ </td>
+ </tr>
+ {{#if order.voucher_discount}}
+ <tr>
+ <td colspan="3" style="padding: 5px; text-align: right;" align="right">
+ Discount
+ </td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ {{price order.voucher_discount.amount_value order.voucher_discount.amount_value order.currency display_gross=order.display_gross_prices}}
+ </td>
+ </tr>
+ {{/if}}
+ <tr>
+ <td colspan="3" style="padding: 5px; text-align: right;" align="right">
+ <strong>
+ Total
+ </strong>
+ </td>
+ <td style="padding: 5px; text-align: right;" align="right">
+ <strong>
+ {{price order.total_net_amount order.total_gross_amount order.currency display_gross=order.display_gross_prices}}
+ </strong>
+ </td>
+ </tr>
+ </tfoot>
</table>
</td>
</tr>
- </tbody>
- </table>
-
- </div>
+ <tr>
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <!--[if mso | IE]></td></tr></table><![endif]-->
- </td>
- </tr>
- </tbody>
- </table>
+ <p
+ style="border-top:dashed 1px #D3D1D0;font-size:1px;margin:0px auto;width:100%;"
+ >
+ </p>
- </div>
+ <!--[if mso | IE]><table align="center" border="0" cellpadding="0" cellspacing="0" style="border-top:dashed 1px #D3D1D0;font-size:1px;margin:0px auto;width:488px;" role="presentation" width="488px" ><tr><td style="height:0;line-height:0;"> &nbsp;
+</td></tr></table><![endif]-->
- <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
+ </td>
+ </tr>
+ <tr>
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
+
+ <table
+ cellpadding="0" cellspacing="0" width="100%" border="0" style="color:#28234a;font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;table-layout:auto;width:100%;border:none;"
+ >
+ <thead class="table-header-row" style="border-bottom: 2px solid #28234a;">
+ <tr>
+ <th style="padding: 5px;">Billing address</th>
+ <th style="padding: 5px;">Shipping address</th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td class="address" style="padding: 5px;">
+ {{#if order.billing_address}}
+ {{format_address order.billing_address}}
+ {{else}}
+ No billing address
+ {{/if}}
+ </td>
+ <td css-class="address" style="padding: 5px;">
+ {{#if order.shipping_address}}
+ {{format_address order.shipping_address}}
+ {{else}}
+ No shipping required
+ {{/if}}
+ </td>
+ </tr>
+ </tbody>
+ </table>
- <div style="margin:0px auto;max-width:600px;">
+ </td>
+ </tr>
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
+ <tr>
+ <td
+ style="font-size:0px;word-break:break-word;"
+ >
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
+ <div
+ style="height:20px;line-height:20px;"
+ >&#8202;</div>
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tbody>
+ </td>
+ </tr>
<tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ align="left" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">This is an automatically generated e-mail, please do not reply.</div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:14px;line-height:1.5rem;text-align:left;color:#28234a;"
+ >Have a great day!</div>
</td>
</tr>
@@ -326,26 +386,38 @@
</div>
- <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr><tr><td class="" width="600px" ><table align="center" border="0" cellpadding="0" cellspacing="0" class="" role="presentation" style="width:540px;" width="540" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
- <div style="background:#F2F2F2;background-color:#F2F2F2;margin:0px auto;max-width:600px;">
+ <div style="margin:0px auto;max-width:540px;">
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background:#F2F2F2;background-color:#F2F2F2;width:100%;">
+ <table
+ align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;"
+ >
<tbody>
<tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
-
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
-
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
+ <td
+ style="direction:ltr;font-size:0px;padding:20px 0;text-align:center;"
+ >
+ <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:540px;" ><![endif]-->
+
+ <div
+ class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;"
+ >
+
+ <table
+ border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%"
+ >
<tbody>
<tr>
- <td align="center" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
+ <td
+ align="center" style="font-size:0px;padding:10px 25px;word-break:break-word;"
+ >
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:center;color:#000000;">Sincerely, {{ site_name }}</div>
+ <div
+ style="font-family:Helvetica, Arial;font-size:10px;line-height:1.2rem;text-align:center;color:#7f7b93;"
+ >This is an automatically generated e-mail, please do not reply. <br />Certain messages, like this one, are essectial to service operations.</div>
</td>
</tr>
@@ -364,40 +436,7 @@
</div>
- <!--[if mso | IE]></td></tr></table><table align="center" border="0" cellpadding="0" cellspacing="0" class="no-display-outlook" style="width:600px;" width="600" ><tr><td style="line-height:0px;font-size:0px;mso-line-height-rule:exactly;"><![endif]-->
-
-
- <div class="no-display" style="display: none; margin: 0px auto; max-width: 600px;">
-
- <table align="center" border="0" cellpadding="0" cellspacing="0" role="presentation" style="width:100%;">
- <tbody>
- <tr>
- <td style="direction: ltr; font-size: 0px; padding: 20px 0; text-align: center;" align="center">
- <!--[if mso | IE]><table role="presentation" border="0" cellpadding="0" cellspacing="0"><tr><td class="" style="vertical-align:top;width:600px;" ><![endif]-->
-
- <div class="mj-column-per-100 mj-outlook-group-fix" style="font-size:0px;text-align:left;direction:ltr;display:inline-block;vertical-align:top;width:100%;">
-
- <table border="0" cellpadding="0" cellspacing="0" role="presentation" style="vertical-align:top;" width="100%">
- <tbody>
-
- <tr>
- <td align="left" style="font-size: 0px; padding: 10px 25px; word-break: break-word;">
-
- <div style="font-family:Ubuntu, Helvetica, Arial, sans-serif;font-size:13px;line-height:1;text-align:left;color:#000000;">{{#if order}}
- <script type="application/ld+json">
- {{{{raw}}}}{{schema_markup}}{{{{/raw}}}}
- </script>
- {{/if}}</div>
-
- </td>
- </tr>
-
- </tbody>
- </table>
-
- </div>
-
- <!--[if mso | IE]></td></tr></table><![endif]-->
+ <!--[if mso | IE]></td></tr></table></td></tr></table><![endif]-->
</td>
</tr>
</tbody>
@@ -411,5 +450,5 @@
</div>
- </body>
- </html>
+ </body>
+</html>
diff --git a/saleor/static/images/saleor-logo-sign.png b/saleor/static/images/saleor-logo-sign.png
new file mode 100644
index 0000000000..3db31e0cc9
Binary files /dev/null and b/saleor/static/images/saleor-logo-sign.png differ