-
Notifications
You must be signed in to change notification settings - Fork 16
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
Add a form object for selecting an address #2739
Conversation
Review app deployed to https://s118d02-app-pr-2739-as.azurewebsites.net/additional-payments/claim |
d12baf5
to
704c210
Compare
redirect_to claim_path(current_journey_routing_name, "no-address-found") and return | ||
else | ||
# otherwise it takes you to "no-address-found" on the backlink from the slug sequence | ||
@backlink_path = claim_path(current_journey_routing_name, "postcode-search") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this backlink path logic might be missing now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The backlink path is now defined in the form object. Does that fit with where you'd expect to find it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep! if it's not just a backlink to the previous slug i.e. there's some logic behind it, we override the backlink_path
in the base form 👍
b892a23
to
eb91264
Compare
When the user is adding their home address, we have a hard-coded address selection form that can be migrated to a form object. This change allows us to remove the AddressDetails concern from the controller as the functionality it adds is moved into the form objects. Also, the rescue block in the show action of the ClaimsController is no longer called from anywhere and we can safely remove it too.
8ce9cbf
to
a8e345d
Compare
When the user is adding their home address, we have a hard-coded address
selection form that can be migrated to a form object.
This change allows us to remove the AddressDetails concern from the
controller as the functionality it adds is moved into the form objects.