diff --git a/openedx/core/djangoapps/notifications/templates/notifications/digest_content.html b/openedx/core/djangoapps/notifications/templates/notifications/digest_content.html index 1da86f48f0..13ac89d4ec 100644 --- a/openedx/core/djangoapps/notifications/templates/notifications/digest_content.html +++ b/openedx/core/djangoapps/notifications/templates/notifications/digest_content.html @@ -33,7 +33,7 @@

- {{ notification.content | safe }} + {{ notification.content | truncatechars_html:600 | safe }}

diff --git a/openedx/core/djangoapps/notifications/templates/notifications/email_digest_preference_update.html b/openedx/core/djangoapps/notifications/templates/notifications/email_digest_preference_update.html new file mode 100644 index 0000000000..79e88012f3 --- /dev/null +++ b/openedx/core/djangoapps/notifications/templates/notifications/email_digest_preference_update.html @@ -0,0 +1,13 @@ + + + + + {{ _("Email Digest Preferences Updated") }} + + + + + diff --git a/openedx/core/djangoapps/notifications/views.py b/openedx/core/djangoapps/notifications/views.py index 858f5da9f5..ee5e282d90 100644 --- a/openedx/core/djangoapps/notifications/views.py +++ b/openedx/core/djangoapps/notifications/views.py @@ -5,8 +5,7 @@ from datetime import datetime, timedelta from django.conf import settings from django.db.models import Count -from django.http import HttpResponse -from django.shortcuts import get_object_or_404 +from django.shortcuts import get_object_or_404, render from django.utils.translation import gettext as _ from opaque_keys.edx.keys import CourseKey from pytz import UTC @@ -442,4 +441,7 @@ def preference_update_from_encrypted_username_view(request, username, patch): username and patch must be string """ update_user_preferences_from_patch(username, patch) - return HttpResponse("Success", status=status.HTTP_200_OK) + context = { + "notification_preferences_url": f"{settings.ACCOUNT_MICROFRONTEND_URL}/notifications" + } + return render(request, "notifications/email_digest_preference_update.html", context=context)