mirror of
https://github.com/pretix/pretix.git
synced 2026-05-04 15:04:03 +00:00
Custom HTML email renderers and new email style (#991)
* Custom HTML email renderers * Move inline_css call * Small fixes * New HTML mail style for pretix * Thumbs * Inlinestyle for notifications * Documentation * Set line-height
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
from django.conf import settings
|
||||
from django.template.loader import get_template
|
||||
from inlinestyler.utils import inline_css
|
||||
|
||||
from pretix.base.i18n import language
|
||||
from pretix.base.models import LogEntry, NotificationSetting, User
|
||||
@@ -91,7 +92,7 @@ def send_notification_mail(notification: Notification, user: User):
|
||||
}
|
||||
|
||||
tpl_html = get_template('pretixbase/email/notification.html')
|
||||
body_html = tpl_html.render(ctx)
|
||||
body_html = inline_css(tpl_html.render(ctx))
|
||||
tpl_plain = get_template('pretixbase/email/notification.txt')
|
||||
body_plain = tpl_plain.render(ctx)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user