fix: Incorrect indentation

(cherry picked from commit 7f06c8ca57)
This commit is contained in:
Deepesh Garg
2021-11-26 10:27:57 +05:30
committed by mergify-bot
parent 125ce5dd6d
commit 03449a09ce

View File

@@ -151,12 +151,6 @@ class AccountsController(TransactionBase):
if cint(self.allocate_advances_automatically) and not cint(self.get(pos_check_field)):
self.set_advances()
if self.doctype == 'Purchase Invoice':
self.calculate_paid_amount()
# apply tax withholding only if checked and applicable
self.set_tax_withholding()
self.set_advance_gain_or_loss()
if self.is_return:
@@ -166,6 +160,11 @@ class AccountsController(TransactionBase):
self.set_inter_company_account()
if self.doctype == 'Purchase Invoice':
self.calculate_paid_amount()
# apply tax withholding only if checked and applicable
self.set_tax_withholding()
validate_regional(self)
validate_einvoice_fields(self)