election_day.models.election_compound.election_compound
Attributes
Classes
Mixin providing a meta/content JSON pair. Meta is a JSON column loaded |
Module Contents
- class election_day.models.election_compound.election_compound.ElectionCompound[source]
Bases:
onegov.core.orm.Base,onegov.core.orm.mixins.ContentMixin,onegov.election_day.models.mixins.LastModifiedMixin,onegov.election_day.models.mixins.DomainOfInfluenceMixin,onegov.election_day.models.mixins.TitleTranslationsMixin,onegov.election_day.models.mixins.IdFromTitlesMixin,onegov.election_day.models.party_result.mixins.PartyResultsOptionsMixin,onegov.election_day.models.party_result.mixins.PartyResultsCheckMixin,onegov.election_day.models.party_result.mixins.HistoricalPartyResultsMixin,onegov.election_day.models.mixins.ExplanationsPdfMixin,onegov.election_day.models.election_compound.mixins.DerivedAttributesMixinMixin providing a meta/content JSON pair. Meta is a JSON column loaded with each request, content is a JSON column loaded deferred (to be shown only in the detail view).
- property polymorphic_base: type[ElectionCompound][source]
- title_observer(title_translations: collections.abc.Mapping[str, str], short_title_translations: collections.abc.Mapping[str, str]) None[source]
- referencing_compounds: rel[onegov.core.types.AppenderQuery[onegov.election_day.models.ElectionCompoundRelationship]][source]
- domain_elections: onegov.core.orm.mixins.dict_property[onegov.election_day.types.DomainOfInfluence][source]
- elections_observer(elections: collections.abc.Collection[onegov.election_day.models.Election]) None[source]
- property progress: tuple[int, int][source]
Returns a tuple with the current progress.
If the elections define a domain_supersegment (i.e. superregions), this is the number of fully counted supersegments vs. the total number of supersegments.
If no domain_supersegment is defined, this is the number of counted elections vs. the total number of elections.
- property elected_candidates: list[tuple[str, str]][source]
Returns the first and last names of the elected candidates.
- notifications: sqlalchemy.orm.relationship[onegov.core.types.AppenderQuery[onegov.election_day.models.Notification]][source]
- screens: sqlalchemy.orm.relationship[onegov.core.types.AppenderQuery[onegov.election_day.models.Screen]][source]