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

EL-1982: Error Validation on Single-Category-Search Page #388

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

MazOneTwoOne
Copy link
Contributor

@MazOneTwoOne MazOneTwoOne commented Dec 11, 2024

What does this pull request do?

  • add new error state view for single search, so that it returns the correct template
  • initialise the correct form & render correct view based on tailored_results being in URL
  • add region property to SingleCategorySearchForm as it needs it to perform a search
  • Create a BaseSearch class which is shared by AdviserSearchForm & SingleCategorySearchForm - to stop code duplication
  • pass in through contexts to SingleSearchErrorState view
  • add in playwright tests

Any other changes that would benefit highlighting?

  • n/a

Checklist

  • Provided JIRA ticket number in the title, e.g. "LGA-152: Sample title"

- add new error state view for single search, so that it returns the correct template
- initialise the correct form & render correct view based on `tailored_results` being in URL
- add `region` property to `SingleCategorySearchForm` as it needs it to perform a search
- making sure `SingleSearchErrorState` view has `category_display_name` & `category_message` when presenting error page
- these comes from `CategoryMixin` and a repeat of what's in `SingleCategorySearchView`
@MazOneTwoOne MazOneTwoOne marked this pull request as ready for review December 12, 2024 16:19
@MazOneTwoOne MazOneTwoOne requested a review from a team as a code owner December 12, 2024 16:19
- create a `BaseSearch` class which is shared by AdviserSearchForm & SingleCategorySearchForm, to stop code duplication
- add and update test suite
@MazOneTwoOne MazOneTwoOne force-pushed the el-1982-error-validation-onto-wrong-form branch from b0b8c24 to 24e9265 Compare December 12, 2024 16:23
Copy link

sonarcloud bot commented Dec 12, 2024

Copy link
Contributor

@psweeting1 psweeting1 left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants