mirror of
https://github.com/Kunsi/pretalx-plugin-broadcast-tools
synced 2024-11-24 10:21:01 +00:00
make the linters happy
I wonder if someday i'll remember this before doing a release.
This commit is contained in:
parent
8dde19105d
commit
d1d3283c8e
1 changed files with 4 additions and 5 deletions
|
@ -1,6 +1,5 @@
|
||||||
from tempfile import NamedTemporaryFile
|
from tempfile import NamedTemporaryFile
|
||||||
|
|
||||||
from django.utils.timezone import now
|
|
||||||
from django.utils.translation import gettext_noop
|
from django.utils.translation import gettext_noop
|
||||||
from i18nfield.strings import LazyI18nString
|
from i18nfield.strings import LazyI18nString
|
||||||
from pretalx.schedule.exporters import ScheduleData
|
from pretalx.schedule.exporters import ScheduleData
|
||||||
|
@ -28,6 +27,7 @@ PAGE_PADDING = 10 * mm
|
||||||
def _(text):
|
def _(text):
|
||||||
return LazyI18nString.from_gettext(gettext_noop(text))
|
return LazyI18nString.from_gettext(gettext_noop(text))
|
||||||
|
|
||||||
|
|
||||||
class PDFInfoPage(Flowable):
|
class PDFInfoPage(Flowable):
|
||||||
def __init__(self, event, schedule, fahrplan_day, room_details, talk, style):
|
def __init__(self, event, schedule, fahrplan_day, room_details, talk, style):
|
||||||
super().__init__()
|
super().__init__()
|
||||||
|
@ -43,9 +43,9 @@ class PDFInfoPage(Flowable):
|
||||||
def _questions(self):
|
def _questions(self):
|
||||||
return {
|
return {
|
||||||
int(i.strip())
|
int(i.strip())
|
||||||
for i in (self.event.settings.broadcast_tools_pdf_questions_to_include or "").split(
|
for i in (
|
||||||
","
|
self.event.settings.broadcast_tools_pdf_questions_to_include or ""
|
||||||
)
|
).split(",")
|
||||||
if i
|
if i
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -361,7 +361,6 @@ class PDFExporter(ScheduleData):
|
||||||
)
|
)
|
||||||
doc.build(self._add_pages(doc))
|
doc.build(self._add_pages(doc))
|
||||||
f.seek(0)
|
f.seek(0)
|
||||||
timestamp = now().strftime("%Y-%m-%d-%H%M")
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
f"{self.event.slug}_broadcast_tools_{self.schedule.version}.pdf",
|
f"{self.event.slug}_broadcast_tools_{self.schedule.version}.pdf",
|
||||||
|
|
Loading…
Reference in a new issue