morkeltry / GAP-microfinance

GAP microfinance frontend and Solidity prototype
0 stars 1 forks source link

Onboarding flow: phone number page #19

Open morkeltry opened 6 years ago

morkeltry commented 6 years ago

The submit button ('Register') will either take user to auth page, or to loans flow branching logic, depending on the result of isIdBoxregistered(ethAddr, phoneNo).

isIdBoxregistered() is asychronous and takes a callback as its third parameter - which will be called with either a truthy value, or false. If truthy, user goes to loans flow branching logic, if false, user goes to auth page

This check can be done on the click/ submit event of 'Register', or before rendering auth page, as appropriate for the framework.