Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: discount ledger entry in case of multicurrency invoice #31024

Merged
merged 1 commit into from
May 17, 2022

Conversation

nextchamp-saqib
Copy link
Member

Problem:
If Discount Accounting is enabled and a discount is applied on a multicurrency invoice, then the ledger entry for the discount is posted with an incorrect base amount.
The base amount i.e debit should be in company currency.

Invoice:

CleanShot 2022-05-16 at 12 08 52@2x

Incorrect GLE:

CleanShot 2022-05-16 at 12 04 22@2x

Correct GLE:

CleanShot 2022-05-16 at 12 04 46@2x

@codecov
Copy link

codecov bot commented May 16, 2022

Codecov Report

Merging #31024 (67bd078) into develop (c05144f) will decrease coverage by 0.18%.
The diff coverage is 18.18%.

@@             Coverage Diff             @@
##           develop   #31024      +/-   ##
===========================================
- Coverage    63.01%   62.82%   -0.19%     
===========================================
  Files          983      985       +2     
  Lines        67062    67264     +202     
===========================================
+ Hits         42256    42257       +1     
- Misses       24806    25007     +201     
Impacted Files Coverage Δ
erpnext/controllers/accounts_controller.py 85.68% <ø> (+0.10%) ⬆️
erpnext/regional/india/e_invoice/utils.py 40.42% <18.18%> (-1.60%) ⬇️
...unts/report/purchase_register/purchase_register.py 34.21% <0.00%> (-44.08%) ⬇️
...ext/accounts/report/balance_sheet/balance_sheet.py 36.36% <0.00%> (-21.82%) ⬇️
...e_purchase_register/item_wise_purchase_register.py 57.42% <0.00%> (-20.80%) ⬇️
erpnext/accounts/doctype/bank/bank.py 71.42% <0.00%> (-14.29%) ⬇️
...em_wise_sales_register/item_wise_sales_register.py 51.13% <0.00%> (-12.22%) ⬇️
...t/accounts/report/sales_register/sales_register.py 70.76% <0.00%> (-7.02%) ⬇️
...urity_shortfall/process_loan_security_shortfall.py 93.75% <0.00%> (-6.25%) ⬇️
erpnext/hr/utils.py 73.10% <0.00%> (-4.63%) ⬇️
... and 58 more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant