-
Notifications
You must be signed in to change notification settings - Fork 1
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
Redirect users to organisations index/show after sign in #87
Conversation
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.
Looking good!
In claims we need to redirect our users to the organisations index page. Some users do have only one organisation(school) so for those users we will redirect them to the school show page, we do this via another redirect in the schools controller just to make sure a user with one school doesn't land on the organisation(school) index page. This change also affects placements where we will always redirect the user after sign in to the organisations index page.
d9d4df0
to
fb5f471
Compare
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.
🚀
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.
Tested locally, looks fine to me.
Context
In claims we need to redirect our users to the organisations index page. Some users do have only one organisation(school) so for those users we will redirect them to the school show page, we do this via another redirect in the schools controller just to make sure a user with one school doesn't land on the organisation(school) index page.
This change also affects placements where we will always redirect the user after sign in to the organisations index page, allowing placements to add their logic in their controllers
Also I didn't want to add too much logic in the application controller.
Changes proposed in this pull request
Application controller
Scholl Controller
Guidance to review
Claims:
Placements:
Screenshots
Peek.2024-01-08.13-07.mp4