From 89a2917935fd310a97181825e02ec69e796d3c88 Mon Sep 17 00:00:00 2001 From: Jannis R Date: Mon, 7 Nov 2016 15:13:22 +0100 Subject: [PATCH] boilerplate for third step --- .../modals/SMSVerification/SMSVerification.js | 27 +++++++++++++++---- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/js/src/modals/SMSVerification/SMSVerification.js b/js/src/modals/SMSVerification/SMSVerification.js index 478b0b953..6af633fd3 100644 --- a/js/src/modals/SMSVerification/SMSVerification.js +++ b/js/src/modals/SMSVerification/SMSVerification.js @@ -26,6 +26,7 @@ const contract = '0x7B3F58965439b22ef1dA4BB78f16191d11ab80B0'; import CheckIfCertified from './CheckIfCertified'; import GatherData from './GatherData'; +import SendRequest from './SendRequest'; export default class SMSVerification extends Component { static contextTypes = { @@ -62,7 +63,7 @@ export default class SMSVerification extends Component { title='verify your account via SMS' visible scroll current={ step } - steps={ ['first step', 'second step'] } + steps={ ['first step', 'second step', 'third step'] } > { this.renderStep() } @@ -81,7 +82,7 @@ export default class SMSVerification extends Component { /> ); - if (step === 1) { + if (step === 2) { return (
{ cancel } @@ -108,8 +109,15 @@ export default class SMSVerification extends Component { } renderStep () { + const { contract } = this.state; + if (!contract) { + return null; + } + const { step } = this.state; - if (step === 1) { + if (step === 2) { + return this.renderThirdStep(); + } else if (step === 1) { return this.renderSecondStep(); } else { return this.renderFirstStep(); @@ -148,15 +156,24 @@ export default class SMSVerification extends Component { renderSecondStep () { return ( ); } - renderSecondStep () { + renderThirdStep () { + const { account } = this.props; + const { contract, data } = this.state; + return ( - second step + ); } }