mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-19 04:59:18 +00:00
[fix] removed validation of conversion rate equals 1 from all transaction
This commit is contained in:
@@ -432,14 +432,7 @@ def validate_conversion_rate(currency, conversion_rate, conversion_rate_label, c
|
||||
|
||||
company_currency = webnotes.conn.get_value("Company", company, "default_currency")
|
||||
|
||||
# parenthesis for 'OR' are necessary as we want it to evaluate as
|
||||
# mandatory valid condition and (1st optional valid condition
|
||||
# or 2nd optional valid condition)
|
||||
valid_conversion_rate = (conversion_rate and
|
||||
((currency == company_currency and conversion_rate == 1.00)
|
||||
or (currency != company_currency and conversion_rate != 1.00)))
|
||||
|
||||
if not valid_conversion_rate:
|
||||
if not conversion_rate:
|
||||
msgprint(_('Please enter valid ') + conversion_rate_label + (': ')
|
||||
+ ("1 %s = [?] %s" % (currency, company_currency)),
|
||||
raise_exception=True)
|
||||
|
||||
Reference in New Issue
Block a user