1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-04-27 11:01:14 +00:00

fix sys-admin transfer group (#7326)

This commit is contained in:
Michael An 2025-01-07 17:33:09 +08:00 committed by GitHub
parent 50b6acbcfb
commit 4b33271e5b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -17,22 +17,24 @@ class SysAdminTransferGroupDialog extends React.Component {
constructor(props) {
super(props);
this.state = {
selectedOption: null,
selectedOptions: null,
submitBtnDisabled: true
};
}
handleSelectChange = (option) => {
handleSelectChange = (options) => {
this.setState({
selectedOption: option,
submitBtnDisabled: option == null
selectedOptions: options,
submitBtnDisabled: options == null
});
};
submit = () => {
const receiver = this.state.selectedOption.email;
this.props.transferGroup(receiver);
this.props.toggleDialog();
if (this.state.selectedOptions) {
const receiver = this.state.selectedOptions[0].email;
this.props.transferGroup(receiver);
this.props.toggleDialog();
}
};
render() {