Feature #22434
closed
Added by Evgeniy Dushistov almost 10 years ago.
Updated over 5 years ago.
Description
According to Rest_Users there is no way to change user state to blocked.
This is very useful feature for script that automate person discharge.
I have script that do suitable magic with LDAP, but for redmine I can only delete user, not block, so every time I have to block user account in redmine by hands.
You can set the status of the user using a PUT request. There, you can set the status as follows (here using json):
{
"user": {
"status": 3
}
}
The status values are as follows:
- STATUS_ACTIVE = 1 (User can login and use their account)
- STATUS_REGISTERED = 2 (User has registered but not yet confirmed their email address or was not yet activated by an administrator. User can not login)
- STATUS_LOCKED = 3 (User was once active and is now locked, User can not login)
- Description updated (diff)
- Status changed from New to Closed
- Resolution set to Invalid
Also available in: Atom
PDF