mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-09 02:42:47 +00:00
fix bug of org admin change user active status (#4715)
Co-authored-by: lian <lian@seafile.com>
This commit is contained in:
@@ -77,16 +77,16 @@ class UserItem extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
changeStatus = (st) => {
|
changeStatus = (st) => {
|
||||||
let statusCode;
|
let isActive;
|
||||||
if (st == 'active') {
|
if (st == 'active') {
|
||||||
statusCode = 1;
|
isActive = 'true';
|
||||||
} else {
|
} else {
|
||||||
statusCode = 0;
|
isActive = 'false';
|
||||||
}
|
}
|
||||||
|
|
||||||
seafileAPI.orgAdminChangeOrgUserStatus(this.props.user.id, statusCode).then(res => {
|
seafileAPI.orgAdminChangeOrgUserStatus(orgID, this.props.user.email, isActive).then(res => {
|
||||||
this.setState({
|
this.setState({
|
||||||
currentStatus: statusCode == 1 ? 'active' : 'inactive',
|
currentStatus: isActive == 'true' ? 'active' : 'inactive',
|
||||||
highlight: false,
|
highlight: false,
|
||||||
showMenu: false,
|
showMenu: false,
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user