From 99fa247fd5f73034260a66a3d71a951b8b598a51 Mon Sep 17 00:00:00 2001 From: j Date: Sat, 23 Sep 2023 17:30:03 +0200 Subject: [PATCH] always add title --- app/listmonk/views.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/listmonk/views.py b/app/listmonk/views.py index 7d901c7..dd81e09 100644 --- a/app/listmonk/views.py +++ b/app/listmonk/views.py @@ -24,10 +24,11 @@ def week(year, month, day): year = int(year) archive_week = archive.filter(year=year, week=week).order_by('published') context['weeks'] = get_weeks(archive) - context['this_week'] = date.strftime('%Y-%m-%d') + monday = context['this_week'] = date.strftime('%Y-%m-%d') context['this_year'] = date.strftime('%Y') + context['week_title'] = 'Phantas.ma weekly update %s' % views.format_week(monday) extra = models.Week.objects.filter(monday=context['this_week']).first() if extra: - context['week_title'] = extra.title + context['week_title'] += ': ' + extra.title context['items'] = archive_week return render_to_string("weekly_email.html", context)