A simple deposit and profit bytom dapp demo
Revision | 97b80f0be02adf255cc380e44acb4740671a6bcc (tree) |
---|---|
Zeit | 2019-03-07 11:34:54 |
Autor | Zhiting Lin <zlin035@uott...> |
Commiter | Zhiting Lin |
update the read me doc
@@ -1,2 +1,16 @@ | ||
1 | 1 | # Bytom-Dapp-Demo(Front-end) |
2 | -A simple deposit and profit bytom dapp demo, required the Chrome extenstion. | |
2 | +A simple deposit and profit bytom dapp demo, Bytom-Chrome-Extension needed before it can be used. | |
3 | + | |
4 | +## Contract configuration | |
5 | +Network and smart contract control program configurations are stored under the `configure.json.js` file. | |
6 | +You may edit the configure after an new control program is launched. | |
7 | + | |
8 | +### Send transaction | |
9 | +After the banker deploy the FixedLimitCollect smart contract. The users can use the dapp demo to build an input and output object. | |
10 | +Send an smart contract transaction based on the either [Deposit smart contract](https://github.com/Bytom/equity/blob/master/compiler/equitytest/FixedLimitCollect) | |
11 | + or [Profit smart contract](https://github.com/Bytom/equity/blob/master/compiler/equitytest/FixedLimitProfit). | |
12 | + | |
13 | +### Injection of Chrome-Extension | |
14 | +Since the [chrome-extension](https://github.com/Bytom/Bystore) injected the global bytom into the window. | |
15 | +Use the `window.bytom.advancedTransfer` to send a transaction. Note that `window.bytom.advancedTransfer` contain | |
16 | +`buildTx`, `signTx` and `submitTx`. |