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

Provide the ability to add custom processing to the User Controller actions #82

Open
visto9259 opened this issue Jun 18, 2024 · 0 comments
Labels
enhancement New feature or request V4 To be implemented in version 4
Milestone

Comments

@visto9259
Copy link
Member

Provide the ability to add custom processing to the User Controller actions. This will make the user controller actions extensible with additional custom processing.

For example, the User Controller Index action currently only returns a View Model with no params. The user model in the client application could be more extensive with data outside of LmcUser. The index action could allow further processing like gathering more parameters for the view template to consume, attach child views to the main view, etc.

The proposed approach is to compose an event within the constroller action and have listeners to the event to perform more processing. If the result of the events is a response, then return the response, otherwise return the view model.

For each User Controller actions, there would be the following events:

  • Index action: 'index' event
  • Login action: 'login' and 'login.post' events
  • Register action: 'register' and 'register.post' events
  • Logout action: 'logout' and 'logout.post' events
  • Changepassword: 'changepassword' and 'changepassword.post' events
  • Changeemail: 'changeemail' and changeemail.post' events
  • Edit (once implemented): 'edit' and 'edit.post' events

This could be used to facilitate MFA login actions where a listener would listen to a 'login.post' and perform further processing if MFA is enabled.

@visto9259 visto9259 added enhancement New feature or request V4 To be implemented in version 4 labels Jun 18, 2024
@visto9259 visto9259 added this to the 4.0.0 milestone Jun 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request V4 To be implemented in version 4
Projects
Status: 📋 To Do
Development

No branches or pull requests

1 participant