partial sell using avg price

Co-Authored-By: மனோஜ்குமார் பழனிச்சாமி <smartmanoj42857@gmail.com>
This commit is contained in:
Kavinkumar
2022-03-16 21:39:46 +05:30
parent f9e983e7a3
commit 1e9cbd579f
5 changed files with 50 additions and 91 deletions

View File

@@ -294,11 +294,11 @@ class Telegram(RPCHandler):
if self._rpc._fiat_converter:
cp_fiat = self._rpc._fiat_converter.convert_amount(
msg['cumulative_profit'], msg['stake_currency'], msg['fiat_currency'])
cp_extra = f" / {cp_fiat:.3f} {msg['fiat_currency']})"
cp_extra = f" / {cp_fiat:.3f} {msg['fiat_currency']}"
else:
cp_extra = ''
cp_extra = f"*Cumulative Profit:* (`{msg['cumulative_profit']:.8f}" \
f"{msg['stake_currency']}{cp_extra}`)\n"
f" {msg['stake_currency']}{cp_extra}`)\n"
else:
cp_extra = ''
message = (