Some parts of the platform require there to be a selected institution in the session storage. This PR moves handling of that to a dedicated middleware class instead of having manual checks throughout the application.
It also refines the UX for selecting an instition:
when the user tries to load a page requiring a selected institution, it no longer throws a nasty looking error - instead it redirects the user. Once the institution is selected, the user is redirected back to the original page.
Some parts of the platform require there to be a selected institution in the session storage. This PR moves handling of that to a dedicated middleware class instead of having manual checks throughout the application.
It also refines the UX for selecting an instition: