diff --git a/js/src/modals/SMSVerification/GatherData/gatherData.js b/js/src/modals/SMSVerification/GatherData/gatherData.js index 92317567b..fd5d00791 100644 --- a/js/src/modals/SMSVerification/GatherData/gatherData.js +++ b/js/src/modals/SMSVerification/GatherData/gatherData.js @@ -18,27 +18,41 @@ import React, { Component, PropTypes } from 'react'; import { Checkbox } from 'material-ui'; import phone from 'phoneformat.js'; +import { fromWei } from '../../../api/util/wei'; import { Form, Input } from '../../../ui'; import styles from './gatherData.css'; export default class GatherData extends Component { static propTypes = { + contract: PropTypes.object.isRequired, + data: PropTypes.object.isRequired, + onData: PropTypes.func.isRequired, onDataIsValid: PropTypes.func.isRequired, - onDataIsInvalid: PropTypes.func.isRequired, - onData: PropTypes.func.isRequired + onDataIsInvalid: PropTypes.func.isRequired } state = { + init: true, numberIsValid: null, consentGiven: false }; + componentWillMount () { + const { init } = this.state; + if (init) { + this.queryFee(); + this.setState({ init: false }); + } + } + render () { + const { fee } = this.props.data; const { numberIsValid } = this.state; return (