(nextProps)
| 77 | } |
| 78 | |
| 79 | componentWillReceiveProps (nextProps) { |
| 80 | if (!deepEqual(this.props.data, nextProps.data)) { |
| 81 | this.setState({ data: nextProps.data }); |
| 82 | |
| 83 | // if data changed, clear validation |
| 84 | forEach(this.items, (item) => { |
| 85 | delete item.$validation; |
| 86 | }); |
| 87 | } |
| 88 | } |
| 89 | |
| 90 | validate () { |
| 91 | let success = true; |