election_day.layouts.election_compound

Classes

ElectionCompoundLayout

A common base layout for election and votes which caches some values

Module Contents

class election_day.layouts.election_compound.ElectionCompoundLayout(model: onegov.election_day.models.ElectionCompound, request: onegov.election_day.request.ElectionDayRequest, tab: str | None = None)[source]

Bases: onegov.election_day.layouts.detail.DetailLayout

A common base layout for election and votes which caches some values used in the macros.

model: onegov.election_day.models.ElectionCompound[source]
tab[source]
tabs_with_embedded_tables = ('seat-allocation', 'list-groups', 'superregions', 'districts', 'candidates', 'party-strengths',...[source]
majorz = False[source]
proporz = True[source]
type = 'compound'[source]
property all_tabs: tuple[str, Ellipsis][source]

Return the tabs in order of their appearance.

property results: list[onegov.election_day.models.election_compound.mixins.ResultRow][source]
property totals: onegov.election_day.models.election_compound.mixins.TotalRow[source]
property has_districts: bool[source]
property has_superregions: bool[source]
label(value: str) str[source]
title(tab: str | None = None) str[source]
tab_visible(tab: str | None) bool[source]
property has_party_results: bool[source]
property has_party_panachage_results: bool[source]
property visible: bool[source]
property main_view: str[source]
property menu: election_day.layouts.election.NestedMenu[source]
property pdf_path: str | None[source]

Returns the path to the PDF file or None, if it is not available.

property svg_path: str | None[source]

Returns the path to the SVG or None, if it is not available.

Returns a link to the SVG download view.

property svg_name: str[source]

Returns a nice to read SVG filename.

property summarize: bool[source]
property related_compounds: list[tuple[str | None, str]][source]