Part 6: Withdraw from Main Wallet

Today, we will talk in detail, about the specification of fiat money withdrawal from customer main wallet.


Watch on Youtube    Back to Course Index 

Hi. Good morning guys.

Welcome. This is your one stop channel to become a full stack blockchain engineer.

This is part 6 of the whole course on how to build a Crypto E-Wallet and Exchange System using Odoo.

As defined in the system features before, our application should provide a functionality for every customer to withdraw fiat money from his main wallet, as well as from his crypto wallet to any other external blockchain network.

Before continuing, please consider to like, share, and subscribe our channel if you find it useful, as we will update the topics of Building Crypto E-wallet Exchange System with Odoo regularly. 

Ok, now let's talk about the specification details.

We will talk about the fiat money withdrawal mechanism first.

As before, we will be interfacing with third party payment gateway system to interact with fiat money bank account.

[picture] 

When Customer decided to make a withdrawal request on his wallet, then our system must submit a disbursement request to the payment gateway, as per the virtual account for the customer.

The payment gateway execute the disbursement backend processes with the bank from our company account, on behalf of customer's virtual account.

Once the disbursement is executed, the payment gateway will send a callback to our system, so that we can decrease the customer fiat wallet balance according to the disbursement sent amount. 

As we defined in the previous section, at the customer dashboard, he can see shortcut of all his favorite wallets and it's balances, as well as the list of crypto currency he is watching the price for.



To withdraw from the main wallet, customer must select the main wallet which he want to Deposit, Withdraw, Send, and Receive.

The selected main wallet page will appear as follows:


The page shows the current total wallet balance and the transaction history.

To withdraw fiat money from this main wallet, he will click the Withdraw button.

Then, a page to enter the withdrawal amount and registered withdrawal bank account as the withdrawal destination will appear as follows. 


In this page, customer enter the withdrawal amount which must not bigger than his wallet balance. Otherwise a warning pop up message will appear and the Continue button will stay inactive.

He can click "All" button to withdraw all his wallet.

Next, a bank account details is displayed, for customer to confirm as the withdrawal destination, if one already registered.

Customer can add one or more bank account by clicking the Add Bank Account button.

A page to add new bank account is shown.


In this page, customer must select the available bank supported by Odoo system.

Then, enter the account number and bank account name. The name must be exactly the same as the account profile name.

Click Continue button to save the bank account details.

We will be back to the withdrawal page again.


When the Continue button is clicked here, our backend system will submit disbursement request to the payment gateway.

Then, the payment gateway will execute the backend processes of this disbursement request, which will be including, but not limited to contacting the bank, checking for the account balance and validity, etc.

We will wait until the disbursement is completed, where the payment gateway will send us a callback request.

When we receive that callback, me must update the corresponding wallet balance by decreasing it, for the withdrawal amount executed.



Some modifications must be done in Odoo partner form.

 


We will add a new tab called Withdrawal, that will list all of the existing withdrawal transactions on every wallets, including the fiat and crypto currency wallet.

In this tab, Name, is the wallet name.

Withdrawal type, is the withdrawal type, whether fiat or crypto coin deposit.

Trx Date, is the withdrawal transaction date.

Amount curr, is the withdrawal amount in each wallet currency.

Amount, is the withdrawal amount converted into the company currency.

Currency, is the wallet currency.

Notes, is any additional notes if exists.

State, is the withdrawal transaction state, whether it is draft or approved withdrawal.


Ok guys, those are the minimum feature specification for the withdrawal transaction management.

Don't forget to like, share, and subscribe our channel if you find it useful, as we will update the topics of Building Crypto E-wallet Exchange system with Odoo regularly.

Thanks for watching.