|
@@ -180,6 +180,7 @@ const TheModal = React.createClass({
|
|
|
handleCancel() {
|
|
|
this.setState({
|
|
|
visible: false,
|
|
|
+ locations:[]
|
|
|
});
|
|
|
this.props.handleReturn(false, false);
|
|
|
},
|
|
@@ -277,7 +278,7 @@ const TheModal = React.createClass({
|
|
|
this.state.theSwitch = true;
|
|
|
for (let i = 0; i < data.data.length; i++) {
|
|
|
for (let n = 0; n < this.props.currentRoles.length; n++) {
|
|
|
- if (data.data[i] === this.props.currentRoles[n]) {
|
|
|
+ if (data.data[i] === this.props.currentRoles[n] && uid != 1) {
|
|
|
this.state.theSwitch = false;
|
|
|
}
|
|
|
}
|
|
@@ -336,7 +337,7 @@ const TheModal = React.createClass({
|
|
|
email: nextProps.data ? nextProps.data.email : '',
|
|
|
mobile: nextProps.data ? nextProps.data.mobile : '',
|
|
|
position: nextProps.data ? nextProps.data.position : '',
|
|
|
- superiorId: nextProps.data ? nextProps.data.superiorId : '',
|
|
|
+ superiorId: nextProps.data ? nextProps.data.superiorId : '',
|
|
|
};
|
|
|
this.setState(nextState)
|
|
|
},
|