diff --git a/pretalx_broadcast_tools/exporter.py b/pretalx_broadcast_tools/exporter.py index 22ae82d..9d22788 100644 --- a/pretalx_broadcast_tools/exporter.py +++ b/pretalx_broadcast_tools/exporter.py @@ -201,7 +201,7 @@ class PDFInfoPage(Flowable): self._add( Paragraph( self.event.settings.broadcast_tools_pdf_additional_content.format( - **placeholders(self.schedule, self.talk) + **placeholders(self.schedule.event, self.talk) ), style=self.style["Meta"], ) diff --git a/pretalx_broadcast_tools/utils/placeholders.py b/pretalx_broadcast_tools/utils/placeholders.py index 6a1ce16..75ad335 100644 --- a/pretalx_broadcast_tools/utils/placeholders.py +++ b/pretalx_broadcast_tools/utils/placeholders.py @@ -1,19 +1,19 @@ from django.conf import settings -def placeholders(schedule, talk, supports_html_colour=False): +def placeholders(event, talk, supports_html_colour=False): track_name = str(talk.submission.track.name) if talk.submission.track else "" result = { "CODE": talk.submission.code, - "EVENT_SLUG": str(schedule.event.slug), + "EVENT_SLUG": str(event.slug), "FEEDBACK_URL": "{}{}".format( - schedule.event.custom_domain or settings.SITE_URL, + event.custom_domain or settings.SITE_URL, talk.submission.urls.feedback, ), "TALK_SLUG": talk.frab_slug, "TALK_URL": "{}{}".format( - schedule.event.custom_domain or settings.SITE_URL, + event.custom_domain or settings.SITE_URL, talk.submission.urls.public, ), "TRACK_NAME": track_name, diff --git a/pretalx_broadcast_tools/views/schedule.py b/pretalx_broadcast_tools/views/schedule.py index f838489..6a80d40 100644 --- a/pretalx_broadcast_tools/views/schedule.py +++ b/pretalx_broadcast_tools/views/schedule.py @@ -64,7 +64,7 @@ class BroadcastToolsScheduleView(EventPermissionRequired, ScheduleMixin, View): "room": room["name"].localize(schedule.event.locale), "infoline": infoline.format( **placeholders( - schedule, talk, supports_html_colour=True + schedule.event, talk, supports_html_colour=True ) ), "image_url": talk.submission.image_url,