mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-18 00:00:00 +00:00
fix org page warnings
This commit is contained in:
@@ -5,6 +5,8 @@ import { gettext, orgID } from '../../utils/constants';
|
|||||||
import { seafileAPI } from '../../utils/seafile-api';
|
import { seafileAPI } from '../../utils/seafile-api';
|
||||||
|
|
||||||
const propTypes = {
|
const propTypes = {
|
||||||
|
groupID: PropTypes.string,
|
||||||
|
parentGroupID: PropTypes.string,
|
||||||
toggle: PropTypes.func.isRequired,
|
toggle: PropTypes.func.isRequired,
|
||||||
onDepartChanged: PropTypes.func.isRequired,
|
onDepartChanged: PropTypes.func.isRequired,
|
||||||
};
|
};
|
||||||
|
@@ -7,6 +7,7 @@ import UserSelect from '../user-select.js';
|
|||||||
|
|
||||||
const propTypes = {
|
const propTypes = {
|
||||||
toggle: PropTypes.func.isRequired,
|
toggle: PropTypes.func.isRequired,
|
||||||
|
groupID: PropTypes.string.isRequired,
|
||||||
onMemberChanged: PropTypes.func.isRequired
|
onMemberChanged: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -6,6 +6,7 @@ import { seafileAPI } from '../../utils/seafile-api';
|
|||||||
|
|
||||||
const propTypes = {
|
const propTypes = {
|
||||||
toggle: PropTypes.func.isRequired,
|
toggle: PropTypes.func.isRequired,
|
||||||
|
groupID: PropTypes.string.isRequired,
|
||||||
onRepoChanged: PropTypes.func.isRequired,
|
onRepoChanged: PropTypes.func.isRequired,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -7,6 +7,7 @@ import { Utils } from '../../utils/utils';
|
|||||||
|
|
||||||
const propTypes = {
|
const propTypes = {
|
||||||
groupName: PropTypes.string,
|
groupName: PropTypes.string,
|
||||||
|
groupID: PropTypes.number.isRequired,
|
||||||
toggle: PropTypes.func.isRequired,
|
toggle: PropTypes.func.isRequired,
|
||||||
onDepartChanged: PropTypes.func.isRequired
|
onDepartChanged: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
@@ -7,6 +7,7 @@ import { Utils } from '../../utils/utils';
|
|||||||
|
|
||||||
const propTypes = {
|
const propTypes = {
|
||||||
member: PropTypes.object.isRequired,
|
member: PropTypes.object.isRequired,
|
||||||
|
groupID: PropTypes.string.isRequired,
|
||||||
toggle: PropTypes.func.isRequired,
|
toggle: PropTypes.func.isRequired,
|
||||||
onMemberChanged: PropTypes.func.isRequired
|
onMemberChanged: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
@@ -41,6 +41,7 @@ class DeleteRepoDialog extends React.Component {
|
|||||||
const propTypes = {
|
const propTypes = {
|
||||||
repo: PropTypes.object.isRequired,
|
repo: PropTypes.object.isRequired,
|
||||||
toggle: PropTypes.func.isRequired,
|
toggle: PropTypes.func.isRequired,
|
||||||
|
groupID: PropTypes.string.isRequired,
|
||||||
onRepoChanged: PropTypes.func.isRequired
|
onRepoChanged: PropTypes.func.isRequired
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -420,6 +420,7 @@ class MemberItem extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const MemberItemPropTypes = {
|
const MemberItemPropTypes = {
|
||||||
|
groupID: PropTypes.string.isRequired,
|
||||||
member: PropTypes.object.isRequired,
|
member: PropTypes.object.isRequired,
|
||||||
isItemFreezed: PropTypes.bool.isRequired,
|
isItemFreezed: PropTypes.bool.isRequired,
|
||||||
onMemberChanged: PropTypes.func.isRequired,
|
onMemberChanged: PropTypes.func.isRequired,
|
||||||
@@ -509,6 +510,7 @@ class GroupItem extends React.Component {
|
|||||||
|
|
||||||
const GroupItemPropTypes = {
|
const GroupItemPropTypes = {
|
||||||
group: PropTypes.object.isRequired,
|
group: PropTypes.object.isRequired,
|
||||||
|
groupID: PropTypes.string,
|
||||||
showSetGroupQuotaDialog: PropTypes.func.isRequired,
|
showSetGroupQuotaDialog: PropTypes.func.isRequired,
|
||||||
showDeleteDepartDialog: PropTypes.func.isRequired,
|
showDeleteDepartDialog: PropTypes.func.isRequired,
|
||||||
isSubdepartChanged: PropTypes.bool,
|
isSubdepartChanged: PropTypes.bool,
|
||||||
@@ -516,4 +518,11 @@ const GroupItemPropTypes = {
|
|||||||
|
|
||||||
GroupItem.propTypes = GroupItemPropTypes;
|
GroupItem.propTypes = GroupItemPropTypes;
|
||||||
|
|
||||||
|
|
||||||
|
const OrgDepartmentItemPropTypes = {
|
||||||
|
groupID: PropTypes.string,
|
||||||
|
};
|
||||||
|
|
||||||
|
OrgDepartmentItem.propTypes = OrgDepartmentItemPropTypes;
|
||||||
|
|
||||||
export default OrgDepartmentItem;
|
export default OrgDepartmentItem;
|
@@ -20,7 +20,7 @@ class OrgDepartmentsList extends React.Component {
|
|||||||
super(props);
|
super(props);
|
||||||
this.state = {
|
this.state = {
|
||||||
groups: null,
|
groups: null,
|
||||||
groupID: -1,
|
groupID: '',
|
||||||
groupName: '',
|
groupName: '',
|
||||||
showDeleteDepartDialog: false,
|
showDeleteDepartDialog: false,
|
||||||
showSetGroupQuotaDialog: false,
|
showSetGroupQuotaDialog: false,
|
||||||
@@ -71,7 +71,6 @@ class OrgDepartmentsList extends React.Component {
|
|||||||
<ModalPortal>
|
<ModalPortal>
|
||||||
<AddDepartDialog
|
<AddDepartDialog
|
||||||
onDepartChanged={this.onDepartChanged}
|
onDepartChanged={this.onDepartChanged}
|
||||||
parentGroupID={this.props.groupID}
|
|
||||||
groupID={this.state.groupID}
|
groupID={this.state.groupID}
|
||||||
toggle={this.toggleAddDepartDialog}
|
toggle={this.toggleAddDepartDialog}
|
||||||
/>
|
/>
|
||||||
|
Reference in New Issue
Block a user