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

Add UserConfirmed workflow event for user email confirmation #16584

Merged

Conversation

davidpuplava
Copy link
Contributor

Context

SaaS and newsletter websites send user registration emails to the registered email address to confirm user ownership of the entered email address. OrchardCore does this out of the box.

After a user confirms ownership of an email address, it is common to send a "Welcome to the site!" email welcoming the new user.

Rationale

While it may be possible to construct a timer workflow to determine when a user has confirmed their email address, a more straightforward approach is to trigger an event when a user confirms their email, which can then be used to send the email.

This PR intends to implement that.

Here is a GIF demonstrating that experience, and showing the new User Confirmed workflow event:
orchardcore-user-email-confirmed

Copy link
Member

@MikeAlhayek MikeAlhayek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please also add this new change to the 2.0.0.md release notes.

Lastly, instead of using UserContext I would suggest using a new ConfirmedUserContext class that would inherit from UserContext with one more property "ConfirmationType" This conformation type would have Email or Phone this way we can utilize this event to also confirm phone in the future. I would not add "Phone" in this PR, but I would add the type of the confirmation.

davidpuplava and others added 10 commits August 20, 2024 12:13
Co-authored-by: Mike Alhayek <mike@crestapps.com>
…serEventHandler.cs

Co-authored-by: Mike Alhayek <mike@crestapps.com>
Co-authored-by: Mike Alhayek <mike@crestapps.com>
Co-authored-by: Mike Alhayek <mike@crestapps.com>
Co-authored-by: Mike Alhayek <mike@crestapps.com>
…idpuplava/OrchardCore into davidpuplava/user-confirmed-activity
…ements; Add UserConfirmContext with UserConfirmationType enum
@MikeAlhayek MikeAlhayek enabled auto-merge (squash) August 20, 2024 18:35
@MikeAlhayek MikeAlhayek merged commit aa071dd into OrchardCMS:main Aug 20, 2024
11 checks passed
Copy link
Contributor

Congratulations on your first PR merge! 🎉 Thank you for your contribution! We're looking forward to welcoming other contributions of yours in the future. @all-contributors please add @davidpuplava for code.

If you like Orchard Core, please star our repo and join our community channels.

Copy link
Contributor

@github-actions[bot]

I couldn't determine any contributions to add, did you specify any contributions?
Please make sure to use valid contribution names.

I've put up a pull request to add @davidpuplava! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants