react中页面间带参数跳转与获取

跳转页面带参数:

hashHistory.push({pathname:'CancellationDetails',state:{value:res.beans,number:num}})

pathname:跳转路径

state:参数

*********************************************************************************************************

页面获取参数:

let detailIdAndValue = this.props.location.state;

dataArr = detailIdAndValue.value;

userMobile = detailIdAndValue.number;

猜你喜欢

转载自blog.csdn.net/qq_40753946/article/details/83826050