byline for week

This commit is contained in:
j 2024-02-06 17:47:54 +01:00
commit 82edae60fb
7 changed files with 60 additions and 2 deletions

View file

@ -7,7 +7,7 @@ from django.utils.timezone import datetime, timedelta
from ..item import models
from ..item.views import get_weeks, format_week, get_monday
from ..item.views import get_weeks, format_week, get_monday, get_byline
def week(year, month, day):
@ -28,6 +28,7 @@ def week(year, month, day):
monday = context['this_week'] = date.strftime('%Y-%m-%d')
context['this_year'] = date.strftime('%Y')
context['week_title'] = 'Phantas.ma weekly update %s' % format_week(monday)
context['week_byline'] = get_byline(monday)
context['week_link'] = settings.URL + '/_' + monday
context['items'] = archive_week
return render_to_string("weekly_email.html", context)