diff options
-rw-r--r-- | mail/example_resources/templates/template_a/html/mail.html | 5 | ||||
-rw-r--r-- | mail/example_resources/templates/template_a/logo.png (renamed from mail/example_resources/templates/template_a/html/logo.png) | bin | 343 -> 343 bytes | |||
-rw-r--r-- | mail/example_resources/templates/template_a/mail.html (renamed from mail/example_resources/tera_base/base_mail.html) | 5 | ||||
-rw-r--r-- | mail/example_resources/templates/template_a/mail.txt (renamed from mail/example_resources/templates/template_a/text/mail.txt) | 0 | ||||
-rw-r--r-- | mail/example_resources/templates/template_a/template.toml | 16 |
5 files changed, 19 insertions, 7 deletions
diff --git a/mail/example_resources/templates/template_a/html/mail.html b/mail/example_resources/templates/template_a/html/mail.html deleted file mode 100644 index a377e53..0000000 --- a/mail/example_resources/templates/template_a/html/mail.html +++ /dev/null @@ -1,5 +0,0 @@ -{% extends "base_mail.html" %} - -{% block head %}<meta charset="utf-8">{% endblock head %} - -{% block body %}logo: <img src="cid:{{cids.logo}}"> Hy {{data.name}}.{% endblock body %} diff --git a/mail/example_resources/templates/template_a/html/logo.png b/mail/example_resources/templates/template_a/logo.png Binary files differindex f58bea6..f58bea6 100644 --- a/mail/example_resources/templates/template_a/html/logo.png +++ b/mail/example_resources/templates/template_a/logo.png diff --git a/mail/example_resources/tera_base/base_mail.html b/mail/example_resources/templates/template_a/mail.html index 4bd251a..146f8f4 100644 --- a/mail/example_resources/tera_base/base_mail.html +++ b/mail/example_resources/templates/template_a/mail.html @@ -2,9 +2,10 @@ <html> <head> <!-- NOTE THAT THIS IS JUST AN EXAMPLE FOR THE TEMPLATE ENGINE NOT FOR MAIL ON ITSELF --> - {% block head %}{% endblock head %} + <meta charset="utf-8"> </head> <body> - {% block body %}{% endblock body %} + <img src="cid:{{cids.logo}}"> <br> + <h1> Hy {{data.name}},</h1> </body> </html> diff --git a/mail/example_resources/templates/template_a/text/mail.txt b/mail/example_resources/templates/template_a/mail.txt index 903c8ce..903c8ce 100644 --- a/mail/example_resources/templates/template_a/text/mail.txt +++ b/mail/example_resources/templates/template_a/mail.txt diff --git a/mail/example_resources/templates/template_a/template.toml b/mail/example_resources/templates/template_a/template.toml new file mode 100644 index 0000000..4da0f10 --- /dev/null +++ b/mail/example_resources/templates/template_a/template.toml @@ -0,0 +1,16 @@ +name = "template_a" +subject = "Hy dear {{name}}" + +[[bodies]] +path = "mail.txt" + +[[bodies]] +path = "mail.html" + + [bodies.embeddings] + logo = "logo.png" + +[[attachments]] +iri = "path:./portfolio.pdf" +media_type = "application/pdf" + |