1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-03 07:55:36 +00:00

fix admin delete repo (#7352)

* fix admin delete repo

* delete useless codes

---------

Co-authored-by: 孙永强 <11704063+s-yongqiang@user.noreply.gitee.com>
Co-authored-by: Michael An <2331806369@qq.com>
This commit is contained in:
awu0403
2025-01-14 13:55:18 +08:00
committed by GitHub
parent bb48f9dd57
commit 256b1ec70d
6 changed files with 12 additions and 5 deletions

View File

@@ -31,12 +31,14 @@ class DeleteRepoDialog extends Component {
}
componentDidMount() {
seafileAPI.getRepoFolderShareInfo(this.props.repo.id).then((res) => {
this.setState({
sharedToUserCount: res.data['shared_user_emails'].length,
sharedToGroupCount: res.data['shared_group_ids'].length,
if (this.props.isGetShare) {
seafileAPI.getRepoFolderShareInfo(this.props.repo.repo_id).then((res) => {
this.setState({
sharedToUserCount: res.data['shared_user_emails'].length,
sharedToGroupCount: res.data['shared_group_ids'].length,
});
});
});
}
}
onDeleteRepo = () => {

View File

@@ -771,6 +771,7 @@ class SharedRepoListItem extends React.Component {
isRepoDeleted={this.state.isRepoDeleted}
onDeleteRepo={this.onItemDelete}
toggle={this.onItemDeleteToggle}
isGetShare={true}
/>
</ModalPortal>
}