From 4fe77b89a2ff407c9181d1d110938aa2910323ad Mon Sep 17 00:00:00 2001 From: Eemaan Amir <57627710+eemaanamir@users.noreply.github.com> Date: Tue, 18 Feb 2025 12:52:11 +0500 Subject: [PATCH] fix: fixed escaped characters in goal reminder email (#36260) --- .../edx_ace/goalreminder/email/body.html | 16 +++++++++------- .../edx_ace/goalreminder/email/body.txt | 4 +++- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.html b/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.html index 902ef907a8..a94187584d 100644 --- a/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.html +++ b/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.html @@ -51,11 +51,13 @@

{% filter force_escape %} - {% blocktrans count count=days_per_week asvar goal_text %} - You set a goal of learning {start_bold}{{days_per_week}} time a week in {{course_name}}{end_bold}. You’re not quite there, but there's still time to reach that goal! - {% plural %} - You set a goal of learning {start_bold}{{days_per_week}} times a week in {{course_name}}{end_bold}. You're not quite there, but there's still time to reach that goal! - {% endblocktrans %} + {% autoescape off %} + {% blocktrans count count=days_per_week asvar goal_text %} + You set a goal of learning {start_bold}{{days_per_week}} time a week in {{course_name}}{end_bold}. You’re not quite there, but there's still time to reach that goal! + {% plural %} + You set a goal of learning {start_bold}{{days_per_week}} times a week in {{course_name}}{end_bold}. You're not quite there, but there's still time to reach that goal! + {% endblocktrans %} + {% endautoescape %} {% endfilter %} {% interpolate_html goal_text start_bold=''|safe end_bold=''|safe %}

@@ -107,7 +109,7 @@ {% filter force_escape %}{% blocktrans %} Adjust my goal {% endblocktrans %}{% endfilter %} - +
@@ -134,4 +136,4 @@ -{% endblock %} \ No newline at end of file +{% endblock %} diff --git a/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.txt b/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.txt index e5cec8a244..80bde4ea80 100644 --- a/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.txt +++ b/lms/djangoapps/course_goals/templates/course_goals/edx_ace/goalreminder/email/body.txt @@ -1,11 +1,13 @@ {% load i18n %} {% trans "You're almost there!" %} {% trans "There's still time to reach your goal" as tmsg %} +{% autoescape off %} {% blocktrans %}You set a goal of learning {{days_per_week}} times a week in {{course_name}}. You're not quite there, but there's still time to reach that goal!{% endblocktrans %} +{% endautoescape %} {% trans "Jump back in"} {{course_url}} {% blocktrans %}Remember, you can always change your learning goal. The best goal is one that you can stick to. {% endblocktrans %} {% trans "Adjust my goal"} {{course_url}} {% trans "Unsubscribe from goal reminder emails to this course"} -{{course_url}} \ No newline at end of file +{{course_url}}