dashed-slug.net › Forums › Exchange extension support › fees › Reply To: fees
Hello,
There is no shortcode to display the fees.
The maker and taker fee percentages are in the following JavaScript fields:
walletsExchangeUserData.makerFee
walletsExchangeUserData.takerFee
So you can use these to display fees. The amounts that the user enters into the limit buy / limit sell forms are in wp.wallets.viewModels.walletsExchange.exchangeBuyAmount()
and wp.wallets.viewModels.walletsExchange.exchangeSellAmount()
. So you could do the multiplication and display fees.
But until the order is executed, you do not know how much of it is going to be charged with maker fees and how much with taker fees. For that you would have to run the algorithm through a snapshot of the order book. So it is much easier to give a low and a high estimate for the fees.
Hope this helps.
with regards