-
-
Notifications
You must be signed in to change notification settings - Fork 214
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
Disabling invite a deactivated user #35144
Conversation
corehq/apps/registration/forms.py
Outdated
web_user = WebUser.get_by_username(email) | ||
if web_user and not web_user.is_active: | ||
raise forms.ValidationError(_("A user with this email address is deactivated. " | ||
"Please reactivate this user first.")) |
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.
Not blocking: it'd be a nice UX improvement to turn "reactivate this user" into a link to the edit page for the relevant web user. (Granted, then you have to make sure whatever code catches this error ultimately displays it as HTML.)
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.
Thanks Jenny. Usually we don't deactivate user, deactivation and reactivation can be operated by us in Admin>Look up user by email. So having that link might not be very helpful for most customers, because they won't have access to that tool. For SSO user who get auto-deactivated, they need first add the user back to their identity provider, then ask the user to relogin, I feel this is too long in a error message?
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.
I see. If most users won't have access, perhaps we shouldn't tell them to reactivate the user? We have other messages that say to contact support (if that's the appropriate action), or maybe just removing the second sentence would be fine.
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.
Yes, removed in 409c134 ...
Most user won't know how to reactivate a user, so it is not helpful.
Product Description
One of our customer thought, by invite an deactivated user who is already a member of the domain with a new role, the new role will overwrite the old role, which is not the case. Theoretically you should not invite someone who is already a member again.
So I decide to disable invitation for deactivated user. This is discussed and approved in product meeting.
Technical Summary
Ticket: https://dimagi.atlassian.net/browse/SAAS-15997
Safety Assurance
Safety story
Tested locally. The change is very straightforward.
Automated test coverage
QA Plan
No QA
Rollback instructions
Labels & Review