trigger setScheme when a new set of schemes come in

上级 a26250f5
......@@ -20,6 +20,12 @@ export default class Schemes extends React.Component {
this.setScheme( e.target.value )
}
componentWillReceiveProps(nextProps) {
if(nextProps.schemes !== this.props.schemes) {
this.setScheme(nextProps.schemes.first())
}
}
setScheme =( value ) => {
let { path, method, specActions } = this.props
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册