Let override action after login and logout

Created on 13 June 2017, about 7 years ago
Updated 19 October 2023, 8 months ago

It would be nice to let site admins or site builders define what should happen after following situations:

  • After a CAS logout.
  • After a CAS login, when "service" is not defined.

Please correct me if I am wrong, but in these situations currently the only available options are displaying a page with content defined in "Custom messages" part of CAS server config page.

In my use case I would like to set a redirection and with current code I think this is not possible without altering the module code. Maybe it's not necessary the module provides an UI for configuring all possible developer desires, but it would be useful the action could be done at least in code and currently (I think) it isn't.

The message that appears in the above situations is built in following methods:
UserActionController::generateLoggedInMessage(), UserActionController::generateUserLogoutPage()

Defining those methods as protected instead of private would let a developer override only those methods in a custom controller class and not having to override the full UserActionController class. This override can be applied then in a route alter.

Another cleaner approach would be to trigger some events in those situations that lets other modules alter the result.

✨ Feature request
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ͺπŸ‡ΈSpain budalokko Girona

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024