mirror of
https://github.com/YMFE/yapi.git
synced 2025-01-06 12:45:22 +08:00
fix: 修改history导致的warm
This commit is contained in:
parent
d76b0cc678
commit
d7f5be93a8
@ -65,7 +65,7 @@ export default class GroupList extends Component {
|
|||||||
if(this.props.groupList[i].group_name === groupName){
|
if(this.props.groupList[i].group_name === groupName){
|
||||||
currGroup = this.props.groupList[i];
|
currGroup = this.props.groupList[i];
|
||||||
}else{
|
}else{
|
||||||
this.props.history.push(`${currGroup.group_name}`);
|
this.props.history.replace(`${currGroup.group_name}`);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -156,7 +156,7 @@ export default class GroupList extends Component {
|
|||||||
const groupId = e.key;
|
const groupId = e.key;
|
||||||
const currGroup = this.props.groupList.find((group) => { return +group._id === +groupId });
|
const currGroup = this.props.groupList.find((group) => { return +group._id === +groupId });
|
||||||
this.props.setCurrGroup(currGroup);
|
this.props.setCurrGroup(currGroup);
|
||||||
this.props.history.push(`${currGroup.group_name}`);
|
this.props.history.replace(`${currGroup.group_name}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
@autobind
|
@autobind
|
||||||
|
Loading…
Reference in New Issue
Block a user