Commit ac25de78 by zhanghaozhe

ai-test

parent e0236b44
...@@ -55,6 +55,14 @@ class Scores extends Component { ...@@ -55,6 +55,14 @@ class Scores extends Component {
} }
} }
componentDidUpdate(prevProps, prevState) {
if (this.props.user.hasError !== prevProps.user.hasError) {
this.getUserScores(0)
this.getUserAddress()
}
}
handleChange = (e) => { handleChange = (e) => {
const isNeverSHow = e.target.checked const isNeverSHow = e.target.checked
this.setState({ this.setState({
...@@ -243,9 +251,9 @@ class Scores extends Component { ...@@ -243,9 +251,9 @@ class Scores extends Component {
<div> <div>
<span>仅显示前50</span> <span>仅显示前50</span>
<a href="javascript:void(0);" onClick={() => { <a href="javascript:void(0);" onClick={() => {
if(user.hasError){ if (user.hasError) {
history.push('/passport') history.push('/passport')
}else { } else {
this.setState({ this.setState({
isShowUserAddress: true, isShowUserAddress: true,
}) })
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment