]> git.openstreetmap.org Git - osqa.git/blobdiff - forum/skins/default/templates/notifications/answeraccepted.html
Erroneous setting being used.
[osqa.git] / forum / skins / default / templates / notifications / answeraccepted.html
index 8dac6ce21ff583c0aa77a289fddb9307e303a23d..7658087f9fc2e0eca44aa5589bdf995a134a7a25 100644 (file)
@@ -1,23 +1,20 @@
 {% load i18n extra_tags email_tags %}
 
 {% declare %}
-    prefix = settings.EMAIL_SUBJECT_PREFIX
-    app_name = settings.APP_SHORT_NAME
-    answer_author = answer.author.username
+    prefix = html.mark_safe(settings.EMAIL_SUBJECT_PREFIX)
+    answer_author = html.mark_safe(answer.author.username)
     question = answer.question
-    question_title = question.title
-    accepted_by = answer.nstate.accepted.by.username
+    question_title = html.mark_safe(question.title)
+    accepted_by = html.mark_safe(answer.nstate.accepted.by.username)
+    accepted_by_link = html.objlink(answer.nstate.accepted.by, style=settings.EMAIL_ANCHOR_STYLE)
+    answer_author_link = html.objlink(answer.author, style=settings.EMAIL_ANCHOR_STYLE)
+    question_link = html.objlink(question, style=settings.EMAIL_ANCHOR_STYLE)
 {% enddeclare %}
 
 {% email %}
-    {% subject %}{% blocktrans %}{{ prefix }} New answer to {{ question_title }}{% endblocktrans %}{% endsubject %}
+    {% subject %}{% blocktrans %}{{ prefix }} An answer to: {{ question_title }} has been accepted{% endblocktrans %}{% endsubject %}
 
     {% htmlcontent notifications/base.html %}
-        {% declare %}
-            accepted_by_link = html.objlink(answer.nstate.accepted.by, style=a_style)
-            answer_author_link = html.objlink(answer.author, style=a_style)
-            question_link = html.objlink(question, style=a_style)
-        {% enddeclare %}
         <p style="{{ p_style }}">
             {% blocktrans %}
             {{ accepted_by_link }} has just accepted {{ answer_author_link }}'s answer on his question