election_day.utils.filenames ============================ .. py:module:: election_day.utils.filenames Functions --------- .. autoapisummary:: election_day.utils.filenames.filename_prefix election_day.utils.filenames.pdf_filename election_day.utils.filenames.svg_filename Module Contents --------------- .. py:function:: filename_prefix(item: object) -> str .. py:function:: pdf_filename(item: onegov.election_day.models.Ballot | onegov.election_day.models.Vote | onegov.election_day.models.Election | onegov.election_day.models.ElectionCompound | onegov.election_day.models.ElectionCompoundPart, locale: str, last_modified: datetime.datetime | None = None) -> str Generates a filename from an election or vote: .. code-block:: plain ['election' or 'vote']-[hash of id].[timestamp].[locale].pdf .. py:function:: svg_filename(item: onegov.election_day.models.Ballot | onegov.election_day.models.Vote | onegov.election_day.models.Election | onegov.election_day.models.ElectionCompound | onegov.election_day.models.ElectionCompoundPart, type_: str | None, locale: str, last_modified: datetime.datetime | None = None) -> str Generates a filename from an election, ballot or vote: .. code-block:: plain ['election' or 'vote']-[hash of id].[type_].[timestamp].[locale].svg