Skip to content

Commit

Permalink
[fix] market fiat excange calculator fixed.
Browse files Browse the repository at this point in the history
  • Loading branch information
Aklix committed May 26, 2022
1 parent 4db610e commit e199963
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/python/mainApp.py
Original file line number Diff line number Diff line change
Expand Up @@ -3317,15 +3317,15 @@ def market_fiat_changed(self):
def calculate_usd_price(self):
if self.mcl_amount_lineEdit.text():
current_fiat = self.market_fiat_comboBox.currentText()
price = float(self.mcl_exchange_ticker_result.get('quotes').get(current_fiat).get('price'))
price = float(self.mcl_exchange_ticker_result.get(current_fiat).get('price'))
calculation = float(self.mcl_amount_lineEdit.text()) * price
self.usd_amount_lineEdit.setText(str('%.8f' % calculation))

@pyqtSlot()
def calculate_mcl_price(self):
if self.usd_amount_lineEdit.text():
current_fiat = self.market_fiat_comboBox.currentText()
price = float(self.mcl_exchange_ticker_result.get('quotes').get(current_fiat).get('price'))
price = float(self.mcl_exchange_ticker_result.get(current_fiat).get('price'))
calculation = float(self.usd_amount_lineEdit.text()) / price
self.mcl_amount_lineEdit.setText(str('%.8f' % calculation))

Expand Down

0 comments on commit e199963

Please sign in to comment.