From 4d91fe661fb6003546ab7bc1395b35a6f5b99040 Mon Sep 17 00:00:00 2001
From: Ketan <73937490+devketanpro@users.noreply.github.com>
Date: Fri, 24 May 2024 16:35:54 +0530
Subject: [PATCH] update real email alerts templates [CPCN-531] (#172)

---
 server/theme/email_item.fr_ca.html |  8 ++++----
 server/theme/email_item.fr_ca.txt  |  9 +++++----
 server/theme/email_item.html       | 11 +++++------
 server/theme/email_item.txt        |  9 +++++----
 4 files changed, 19 insertions(+), 18 deletions(-)

diff --git a/server/theme/email_item.fr_ca.html b/server/theme/email_item.fr_ca.html
index 9442a65..05cd2ee 100644
--- a/server/theme/email_item.fr_ca.html
+++ b/server/theme/email_item.fr_ca.html
@@ -1,16 +1,16 @@
 <h1>{{ get_highlighted_field(item, ["headline"]) | safe }}</h1>
 
 <p style="font-size: 0.875rem; font-weight: 400; line-height: 1.3; font-family: 'Lato', sans-serif; color: #444;">
-    <span style="font-weight: 600;">Voir cet élément dans votre compte: </span><a href="{{ url_for_wire(item, True, section) }}">{{ url_for_wire(item, True, section) }}</a><br />
+    {% if item.slugline %}<span style="font-weight: 600;">Titre de rappel: </span>{{ get_highlighted_field(item, ["slugline"]) | safe }}<br />{% endif %}
+    {% if item.source %}<span style="font-weight: 600;">Source: </span>{{ item.source }}<br />{% endif %}
+    <span style="font-weight: 600;">Publié: </span>{{ item.versioncreated | datetime_long }}<br />
     {% if topic_name %}<span style="font-weight: 600;">Nouvel élément pour votre sujet suivi: </span>{{ topic_name }}<br />{% endif %}
     {% if item.service %}<span style="font-weight: 600;">Catégorie: </span>{{ item.service[0].name }}<br />{% endif %}
     <span style="font-weight: 600;">Nombre de mots: </span>{{ item.wordcount }}<br />
 </p>
 
 <p style="font-size: 0.875rem; font-weight: 400; line-height: 1.3; font-family: 'Lato', sans-serif; color: #444;">
-    {% if item.slugline %}<span style="font-weight: 600;">Titre de rappel: </span>{{ get_highlighted_field(item, ["slugline"]) | safe }}<br />{% endif %}
-    {% if item.source %}<span style="font-weight: 600;">Source: </span>{{ item.source }}<br />{% endif %}
-    <span style="font-weight: 600;">Publié: </span>{{ item.versioncreated | datetime_long }}<br />
+    <span style="font-weight: 600;">Voir cet élément dans votre compte: </span><a href="{{ url_for_wire(item, True, section) }}">{{ url_for_wire(item, True, section) }}</a><br />
     {% if item.byline %}<span style="font-weight: 600;">{{ item.byline }}</span>{% endif %}
 </p>
 
diff --git a/server/theme/email_item.fr_ca.txt b/server/theme/email_item.fr_ca.txt
index 39d35af..1d14168 100644
--- a/server/theme/email_item.fr_ca.txt
+++ b/server/theme/email_item.fr_ca.txt
@@ -1,12 +1,13 @@
 {{ item.headline }}
-Voir cet élément dans votre compte: {{ url_for_wire(item, True, section) }}
-{% if topic_name %}Nouvel élément pour votre sujet suivi: {{ topic_name }}{% endif %}
-{% if item.service %}Catégorie: {{ item.service[0].name }}{% endif %}
-Nombre de mots: {{ item.wordcount }}
 
 {% if item.slugline %}Titre de rappel: {{ item.slugline }}{% endif %}
 {% if item.source %}Source: {{ item.source }}{% endif %}
 Publié: {{ item.versioncreated | datetime_long }}
+{% if topic_name %}Nouvel élément pour votre sujet suivi: {{ topic_name }}{% endif %}
+{% if item.service %}Catégorie: {{ item.service[0].name }}{% endif %}
+Nombre de mots: {{ item.wordcount }}
+
+Voir cet élément dans votre compte: {{ url_for_wire(item, True, section) }}
 
 {% if item.byline %}{{ item.byline }}{% endif %}
 
diff --git a/server/theme/email_item.html b/server/theme/email_item.html
index abe404d..cc49ad3 100644
--- a/server/theme/email_item.html
+++ b/server/theme/email_item.html
@@ -2,18 +2,17 @@ <h1 style="font-size: 1.5rem; font-weight: 700; line-height: 1.4; font-family: '
     {{ get_highlighted_field(item, ["headline"]) | safe }}
 </h1>
 <p style="font-size: 0.875rem; font-weight: 400; line-height: 1.3; font-family: 'Lato', sans-serif; color: #444;">
-    <span style="font-weight: 600;">View this item in your account: </span><a href="{{ url_for_wire(item, True, section) }}">{{ url_for_wire(item, True, section) }}</a>
+    {% if item.slugline %}<span style="font-weight: 600;">Slugline: </span>{{ get_highlighted_field(item, ["slugline"]) | safe }}<br />{% endif %}
+    {% if item.source %}<span style="font-weight: 600;">Source: </span>{{ item.source }}<br />{% endif %}
+    <span style="font-weight: 600;">Published: </span>{{ item.versioncreated | datetime_long }}<br />
     {% if topic_name %}<span style="font-weight: 600;">New item for followed topic: </span>{{ topic_name }}<br />{% endif %}
     {% if item.service %}<span style="font-weight: 600;">Category: </span>{{ item.service[0].name }}<br />{% endif %}
     <span style="font-weight: 600;">Word count: </span>{{ item.wordcount }}<br />
-    <br />
 </p>
-
 <p style="font-size: 0.875rem; font-weight: 400; line-height: 1.3; font-family: 'Lato', sans-serif; color: #444;">
-    {% if item.slugline %}<span style="font-weight: 600;">Slugline: </span>{{ get_highlighted_field(item, ["slugline"]) | safe }}<br />{% endif %}
-    {% if item.source %}<span style="font-weight: 600;">Source: </span>{{ item.source }}<br />{% endif %}
-    <span style="font-weight: 600;">Published: </span>{{ item.versioncreated | datetime_long }}<br />
+    <span style="font-weight: 600;">View this item in your account: </span><a href="{{ url_for_wire(item, True, section) }}">{{ url_for_wire(item, True, section) }}</a>
     {% if item.byline %}<span style="font-weight: 600;">{{ item.byline }}</span>{% endif %}
+    <br />
 </p>
 
 <div style="font-size: 0.9375rem; font-weight: 400; line-height: 1.55; font-family: 'Lato', sans-serif; color: #333">
diff --git a/server/theme/email_item.txt b/server/theme/email_item.txt
index 6eb99d5..3fa3cd9 100644
--- a/server/theme/email_item.txt
+++ b/server/theme/email_item.txt
@@ -1,12 +1,13 @@
 {{ item.headline }}
-View this item in your account: {{ url_for_wire(item, True, section) }}
-{% if topic_name %}New item for followed topic: {{ topic_name }}{% endif %}
-{% if item.service %}Category: {{ item.service[0].name }}{% endif %}
-Word count: {{ item.wordcount }}
 
 {% if item.slugline %}Slugline: {{ item.slugline }}{% endif %}
 {% if item.source %}Source: {{ item.source }}{% endif %}
 Published: {{ item.versioncreated | datetime_long }}
+{% if topic_name %}New item for followed topic: {{ topic_name }}{% endif %}
+{% if item.service %}Category: {{ item.service[0].name }}{% endif %}
+Word count: {{ item.wordcount }}
+
+View this item in your account: {{ url_for_wire(item, True, section) }}
 
 {% if item.byline %}{{ item.byline }}{% endif %}