Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/party pages update #1624

Merged
merged 5 commits into from
Jul 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
132 changes: 88 additions & 44 deletions locale/cy/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-05-11 15:40+0100\n"
"POT-Creation-Date: 2023-06-16 12:53+0100\n"
"PO-Revision-Date: 2022-03-24 09:04+0000\n"
"Last-Translator: Sym Roe <sym@talusdesign.co.uk>, 2022\n"
"Language-Team: Welsh (https://www.transifex.com/democracy-club/teams/61326/"
Expand Down Expand Up @@ -116,7 +116,7 @@ msgid "All Elections in the UK"
msgstr "Pob Etholiad yn y DU"

#: wcivf/apps/elections/templates/elections/elections_view.html:18
#: wcivf/templates/base.html:107
#: wcivf/templates/base.html:102
msgid "All Elections"
msgstr "Pob Etholiad"

Expand Down Expand Up @@ -229,7 +229,7 @@ msgstr "Rydych chi yma"
#: wcivf/apps/parties/templates/parties/party_detail.html:17
#: wcivf/apps/parties/templates/parties/speaker_seeking_reelection.html:17
#: wcivf/apps/people/templates/people/person_detail.html:27
#: wcivf/templates/base.html:106
#: wcivf/templates/base.html:101
msgid "Home"
msgstr "Cartref"

Expand Down Expand Up @@ -331,16 +331,16 @@ msgstr "Symbol y blaid"
msgid "Show %(num_candidates)s candidates"
msgstr "Dangos %(num_candidates)s ymgeiswyr"

#: wcivf/apps/elections/templates/elections/includes/_person_card.html:23
#: wcivf/apps/elections/templates/elections/includes/_person_card.html:18
msgid "Elected"
msgstr "Etholwyd"

#: wcivf/apps/elections/templates/elections/includes/_person_card.html:30
#: wcivf/apps/elections/templates/elections/includes/_person_card.html:25
#, fuzzy, python-format
msgid "%(votes_cast)s votes"
msgstr "%(votes_cast)s pleidlais (etholwyd)"

#: wcivf/apps/elections/templates/elections/includes/_person_card.html:38
#: wcivf/apps/elections/templates/elections/includes/_person_card.html:33
#, python-format
msgid "Photo of %(person_name)s"
msgstr "Llun o %(person_name)s"
Expand Down Expand Up @@ -1147,8 +1147,8 @@ msgid "Current: %(party_name)s"
msgstr "Ar hyn o bryd: %(party_name)s"

#: wcivf/apps/parties/templates/parties/independent_candidate.html:30
#: wcivf/apps/parties/templates/parties/party_detail.html:35
#: wcivf/apps/parties/templates/parties/party_detail.html:51
#: wcivf/apps/parties/templates/parties/party_detail.html:38
#: wcivf/apps/parties/templates/parties/party_detail.html:54
#: wcivf/apps/parties/templates/parties/speaker_seeking_reelection.html:30
#, fuzzy, python-format
#| msgid "%(num_candidates)s candidate%(pluralize_candidates)s"
Expand All @@ -1166,33 +1166,39 @@ msgid ""
"\"%(ballot_name)s\", or with no description at all."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:40
#: wcivf/apps/parties/templates/parties/party_detail.html:56
msgid "Read more on wikipedia"
msgstr "Darllenwch fwy ar wikipedia"
#: wcivf/apps/parties/templates/parties/party_detail.html:36
#, fuzzy, python-format
#| msgid "Current: %(party_name)s"
msgid "Alternative name: %(alt_name)s"
msgstr "Ar hyn o bryd: %(party_name)s"

#: wcivf/apps/parties/templates/parties/party_detail.html:43
#: wcivf/apps/parties/templates/parties/party_detail.html:59
msgid "Read more on wikipedia"
msgstr "Darllenwch fwy ar wikipedia"

#: wcivf/apps/parties/templates/parties/party_detail.html:46
#: wcivf/apps/parties/templates/parties/party_detail.html:62
#, python-format
msgid ""
"This political party was deregistered on %(dereg_date)s, and can no longer "
"field candidates. "
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:65
#: wcivf/apps/parties/templates/parties/party_detail.html:68
#, fuzzy, python-format
#| msgid "This election was held <strong>%(election_date)s</strong>."
msgid ""
"<p>This party %(was_is)s on the <strong>%(register)s</strong> register.</p>"
msgstr "Cynhaliwyd yr etholiad hwn <strong>%(election_date)s</strong>"

#: wcivf/apps/parties/templates/parties/party_detail.html:76
#: wcivf/apps/parties/templates/parties/party_detail.html:79
#, fuzzy
#| msgid " %(description)s "
msgid "Joint description"
msgstr " %(description)s "

#: wcivf/apps/parties/templates/parties/party_detail.html:79
#: wcivf/apps/parties/templates/parties/party_detail.html:82
#, fuzzy, python-format
#| msgid ""
#| "\n"
Expand All @@ -1206,35 +1212,67 @@ msgstr ""
"\n"
" %(num_votes)s pleidlais (etholwyd)\n"

#: wcivf/apps/parties/templates/parties/party_detail.html:88
#: wcivf/apps/parties/templates/parties/party_detail.html:91
#, python-format
msgid ""
"View the entry for the %(party_name)s in the register of political parties."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:98
#: wcivf/apps/parties/templates/parties/party_detail.html:101
msgid "View this party's entry in the register of political parties."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:105
#: wcivf/apps/parties/templates/parties/party_detail.html:108
#, fuzzy
#| msgid " %(description)s "
msgid "Ballot descriptions"
msgstr " %(description)s "

#: wcivf/apps/parties/templates/parties/party_detail.html:106
#: wcivf/apps/parties/templates/parties/party_detail.html:110
#, python-format
msgid ""
"This party may appear on the ballot paper as \"%(ballot_name)s\", or any of "
"the following names:"
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:115
#: wcivf/apps/parties/templates/parties/party_detail.html:122
msgid "This party currently has no alternative descriptions."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:129
#, fuzzy
#| msgid " %(description)s "
msgid "Previous Descriptions"
msgstr " %(description)s "

#: wcivf/apps/parties/templates/parties/party_detail.html:131
msgid ""
"These descriptions are no longer registered with the Electoral Commission "
"and cannot be used."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:144
#, fuzzy
#| msgid "emblem"
msgid "Emblems"
msgstr "symbol"

#: wcivf/apps/parties/templates/parties/party_detail.html:154
msgid "This party currently has no alternative emblems."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_detail.html:161
#, fuzzy
#| msgid "emblem"
msgid "Previous Emblems"
msgstr "symbol"

#: wcivf/apps/parties/templates/parties/party_detail.html:163
msgid ""
"These emblems are no longer registered with the Electoral Commission and "
"cannot be used."
msgstr ""

#: wcivf/apps/parties/templates/parties/party_list.html:4
#: wcivf/apps/parties/templates/parties/party_list.html:5
msgid "UK Political Parties"
Expand Down Expand Up @@ -1431,7 +1469,7 @@ msgid "%(person_name)s's home page"
msgstr "Hafan %(person_name)s"

#: wcivf/apps/people/templates/people/includes/_person_contact_card.html:54
#: wcivf/templates/base.html:114
#: wcivf/templates/base.html:110
msgid "Blog"
msgstr "Blog"

Expand Down Expand Up @@ -1535,30 +1573,30 @@ msgstr ""
msgid "Ask the candidate for more information &raquo;"
msgstr "Holwch yr ymgeisydd am fwy o wybodaeth &raquo;"

#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:15
#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:12
msgid "an,a"
msgstr ""

#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:15
#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:12
#, python-format
msgid "is %(a_or_an)s %(party_name)s candidate in the following elections:"
msgstr "yw %(a_or_an)s ymgeisydd y %(party_name)s yn yr etholiadau canlynol:"

#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:23
#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:20
#, python-format
msgid "%(election)s for"
msgstr "%(election)s ar gyfer"

#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:28
#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:25
#, python-format
msgid "%(num_votes)s votes"
msgstr "%(num_votes)s pleidlais"

#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:33
#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:30
msgid "(elected)"
msgstr "(etholwyd)"

#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:51
#: wcivf/apps/people/templates/people/includes/_person_intro_card.html:48
#, python-format
msgid "profile photo of %(person)s"
msgstr "Llun proffil %(person)s"
Expand Down Expand Up @@ -1911,13 +1949,13 @@ msgstr ""
"href=\"%(post_url)s\">%(post_label)s</a> yn yr <a href=\"%(election_url)s\" "
"title=\"%(election_name)s\">%(election_name)s</a>."

#: wcivf/apps/people/templates/people/not_current_person_detail.html:27
#: wcivf/apps/people/templates/people/not_current_person_detail.html:24
#, python-format
msgid "%(person_name)s stood for election %(past_candidacy_count)s times."
msgstr ""
"Ymgeisiodd%(person_name)smewn etholiad %(past_candidacy_count)s o weithiau."

#: wcivf/apps/people/templates/people/not_current_person_detail.html:32
#: wcivf/apps/people/templates/people/not_current_person_detail.html:29
#, python-format
msgid "profile photo of %(object.name)s"
msgstr "Llun proffil %(object.name)s"
Expand Down Expand Up @@ -2032,70 +2070,76 @@ msgstr "Dim canlyniadau eto"
msgid "Language:"
msgstr "Iaith:"

#: wcivf/templates/base.html:108
#: wcivf/templates/base.html:103
#, fuzzy
#| msgid "Parties"
msgid "All Parties"
msgstr "Pleidiau"

#: wcivf/templates/base.html:104
msgid "Standing as a candidate?"
msgstr "Sefyll fel ymgeisydd?"

#: wcivf/templates/base.html:109
#: wcivf/templates/base.html:105
#, python-format
msgid "About %(SITE_TITLE)s"
msgstr "Ynglŷn %(SITE_TITLE)s"

#: wcivf/templates/base.html:110
#: wcivf/templates/base.html:106
msgid "Privacy"
msgstr "Preifatrwydd"

#: wcivf/templates/base.html:111
#: wcivf/templates/base.html:107
msgid "Source code"
msgstr "Cod ffynhonnell"

#: wcivf/templates/base.html:112
#: wcivf/templates/base.html:108
msgid "About Democracy Club"
msgstr "Ynglŷn â'r Clwb Democratiaeth"

#: wcivf/templates/base.html:113
#: wcivf/templates/base.html:109
msgid "Contact Us"
msgstr "Cysylltwch â Ni"

#: wcivf/templates/base.html:115
#: wcivf/templates/base.html:111
msgid "Twitter"
msgstr "Trydar"

#: wcivf/templates/base.html:116
#: wcivf/templates/base.html:112
msgid "GitHub"
msgstr "GitHub"

#: wcivf/templates/base.html:123
#: wcivf/templates/base.html:119
msgid "democracy"
msgstr "democratiaeth"

#: wcivf/templates/base.html:123
#: wcivf/templates/base.html:119
msgid "club"
msgstr "clwb"

#: wcivf/templates/base.html:129 wcivf/templates/home.html:5
#: wcivf/templates/base.html:125 wcivf/templates/home.html:5
#: wcivf/templates/home.html:6
msgid "Who Can I Vote For?"
msgstr "Pwy alla i bleidleisio ar gyfer?"

#: wcivf/templates/base.html:133
#: wcivf/templates/base.html:129
#, python-format
msgid "Copyright &copy; %(current_year)s"
msgstr "Hawlfraint © %(current_year)s"

#: wcivf/templates/base.html:134
#: wcivf/templates/base.html:130
msgid "Democracy Club Community Interest Company"
msgstr "Cwmni Buddiannau Cymunedol y Clwb Democratiaeth"

#: wcivf/templates/base.html:135
#: wcivf/templates/base.html:131
msgid ""
"Company No: <a href=\"https://beta.companieshouse.gov.uk/"
"company/09461226\">09461226</a>"
msgstr ""
"Rhif y Cwmni: <a href=\"https://beta.companieshouse.gov.uk/"
"company/09461226\">09461226</a>"

#: wcivf/templates/base.html:137
#: wcivf/templates/base.html:133
msgid ""
"Democracy Club is a UK-based Community Interest Company that builds the "
"digital infrastructure needed for a 21st century democracy"
Expand Down
4 changes: 3 additions & 1 deletion wcivf/apps/parties/management/commands/import_parties.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ def add_party_descriptions(self, party_obj, descriptions):
defaults={
"date_description_approved": description[
"date_description_approved"
]
],
"active": description["active"],
},
)

Expand All @@ -38,6 +39,7 @@ def add_party_emblems(self, party_obj, emblems):
"description": emblem["description"],
"date_approved": emblem["date_approved"],
"default": emblem["default"],
"active": emblem["active"],
},
)

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Generated by Django 4.1.6 on 2023-06-14 15:01

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
("parties", "0018_alter_partydescription_options"),
]

operations = [
migrations.AlterModelOptions(
name="partydescription",
options={"ordering": ["-active", "date_description_approved"]},
),
migrations.AlterModelOptions(
name="partyemblem",
options={"ordering": ("-default", "-active", "ec_emblem_id")},
),
migrations.AddField(
model_name="partydescription",
name="active",
field=models.BooleanField(default=False),
),
migrations.AddField(
model_name="partyemblem",
name="active",
field=models.BooleanField(default=False),
),
]
Loading