BlockPo / BlockPo-to-Tradelayer

Incubation Repo for the TradeLayer protocol, 0.2.0
http://www.tradelayer.org
Other
8 stars 8 forks source link

Vesting Token Checking Trade Channel Volume #152

Closed patrickdugan closed 4 years ago

patrickdugan commented 4 years ago

Lihki's original implementation didn't account for the new Trade Channel type tx's so let's add support for the 3 kinds of TC trades.

santos177 commented 4 years ago

LTC volume is yet added in the channels.

patrickdugan commented 4 years ago

Please add volume for on-chain contractDex trades and trade channel contractDex trades as well. We will skip token-to-token since that is less important to the overall ecosystem, especially early on, and save some time.

The formula for contractDex volume is: trade amount contract notional the LTC price of the collateral currency. So you'd look at that collateral currency id parameter in the contract object, then look up the LTC dex data on it, and if there are no trades that block then look at the last trade that occured. If no trades have occured then don't include the volume. (This could be a junk coin with fake wash-trading fees paid in the junk coin, for instance).

santos177 commented 4 years ago

working on volume branch