election_day.views.archive

Functions

view_municipality_redirect(self, request) → webob.response.Response

view_archive(self, request) → onegov.core.types.RenderData

Shows all the results from the elections and votes for a given year

view_archive_municipal(self, request) → onegov.core.types.RenderData

view_archive_all_municipal(self, request) → onegov.core.types.RenderData

_municipality_archive_url(mun_archive, slug, ...) → str

_municipality_display_name(sanitized, request) → str

_municipality_view_data(self, request[, year]) → onegov.core.types.RenderData

view_archive_municipality(self, request) → onegov.core.types.RenderData

view_archive_municipality_year(self, request) → onegov.core.types.RenderData

view_archive_json(self, request) → onegov.core.types.JSON_ro

Shows all the results from the elections and votes for a given year

view_principal(self, request) → onegov.core.types.RenderData

Shows all the results from the elections and votes of the last election

view_principal_json(self, request) → onegov.core.types.JSON_ro

Shows all the results from the elections and votes of the last election

search_form(model, request[, form]) → type[onegov.election_day.forms.ArchiveSearchFormVote | onegov.election_day.forms.ArchiveSearchFormElection]

view_archive_search(self, request, form) → onegov.core.types.RenderData

Shows all the results from the elections and votes of the last election

view_archive_download(self, request) → morepath.request.Response

Module Contents

election_day.views.archive.view_municipality_redirect(self: onegov.election_day.models.MunicipalityRedirect, request: onegov.election_day.request.ElectionDayRequest) → webob.response.Response[source]
election_day.views.archive.view_archive(self: onegov.election_day.collections.ArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.RenderData[source]

Shows all the results from the elections and votes for a given year or date.

election_day.views.archive.view_archive_municipal(self: onegov.election_day.collections.MunicipalArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.RenderData[source]
election_day.views.archive.view_archive_all_municipal(self: onegov.election_day.collections.AllMunicipalArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.RenderData[source]
election_day.views.archive._municipality_archive_url(mun_archive: onegov.election_day.collections.MunicipalityArchivedResultCollection, slug: str, latest_years: dict[str, int], request: onegov.election_day.request.ElectionDayRequest) → str[source]
election_day.views.archive._municipality_display_name(sanitized: str, request: onegov.election_day.request.ElectionDayRequest) → str[source]
election_day.views.archive._municipality_view_data(self: onegov.election_day.collections.MunicipalityArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest, year: int | None = None) → onegov.core.types.RenderData[source]
election_day.views.archive.view_archive_municipality(self: onegov.election_day.collections.MunicipalityArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.RenderData[source]
election_day.views.archive.view_archive_municipality_year(self: onegov.election_day.collections.MunicipalityYearArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.RenderData[source]
election_day.views.archive.view_archive_json(self: onegov.election_day.collections.ArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.JSON_ro[source]

Shows all the results from the elections and votes for a given year or date as JSON.

election_day.views.archive.view_principal(self: onegov.election_day.models.Principal, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.RenderData[source]

Shows all the results from the elections and votes of the last election day. It’s the landing page.

election_day.views.archive.view_principal_json(self: onegov.election_day.models.Principal, request: onegov.election_day.request.ElectionDayRequest) → onegov.core.types.JSON_ro[source]

Shows all the results from the elections and votes of the last election day as JSON.

election_day.views.archive.search_form(model: onegov.election_day.collections.SearchableArchivedResultCollection, request: onegov.election_day.request.ElectionDayRequest, form: None = None) → type[onegov.election_day.forms.ArchiveSearchFormVote | onegov.election_day.forms.ArchiveSearchFormElection][source]

Shows all the results from the elections and votes of the last election day. It’s the landing page.

election_day.views.archive.view_archive_download(self: onegov.election_day.models.Principal, request: onegov.election_day.request.ElectionDayRequest) → morepath.request.Response[source]