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

Fix: Results heading on the Summary page #59

Merged
merged 6 commits into from
Jul 1, 2024

Conversation

Adnan-cds
Copy link
Contributor

@Adnan-cds Adnan-cds commented Jun 26, 2024

Varies the results heading depending on the type of the election.

How to reproduce:

  • Create a National Parliamentary election.
  • Open the summary page of this new election.
  • Look for the results.
  • The results heading says "Ward results".

This change fixes the wording of the heading to say National Parliamentary results, Parish results and so on.

Resolves #72

Varies the results heading depending on the type of the election.
Declaring the Entity type manager using constructor property.
@Adnan-cds Adnan-cds marked this pull request as ready for review June 26, 2024 17:30
@willguv
Copy link
Member

willguv commented Jun 26, 2024

Hi Adnan, thanks for making this change. Is it possible to use other words here?

We could use "Constituency results" for example

Not sure on wording for other election types but we could review

Please let me know what you think

@Adnan-cds
Copy link
Contributor Author

Is it possible to use other words here?

Hi Will, these wordings are coming from the "Type of election" dropdown of the Election type nodes:
image

These wordings are defined in a config file bundled with this module. So yes, we should be able to modify these wordings if necessary.

@willguv
Copy link
Member

willguv commented Jun 26, 2024

The type of election in this case is National Parliamentary, but the division is a constituency. Is it possible to leave the type name as it is and change the 'ward results' wording?

Also, for National parliament type elections, use the term
"Constituency results" instead of "National parliamentary results".
@Adnan-cds
Copy link
Contributor Author

Is it possible to leave the type name as it is

Done.

Election type name rendering for non-constituency elections were broken.  Fixed
now.
Copy link
Member

@chriswales95 chriswales95 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Adnan-cds, makes sense to me. Two things:

  1. is there an issue for this or something in a project somewhere?
  2. Do you think we might need a test for this?

Tests dynamic results heading text on the Election summary page.
@Adnan-cds
Copy link
Contributor Author

Two things:

  1. I have just raised Election summary page is using a hardcoded label for results #72
  2. I have added a simple one.

@chriswales95 chriswales95 self-requested a review July 1, 2024 12:50
Copy link
Member

@chriswales95 chriswales95 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sweet. Thanks @Adnan-cds !

@chriswales95 chriswales95 merged commit 3701e1e into 1.x Jul 1, 2024
8 checks passed
@chriswales95 chriswales95 deleted the fix/election-results-title branch July 1, 2024 12:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Election summary page is using a hardcoded label for results
3 participants