refactor: move set_missing_ref_detials out of set_missing_values
This commit is contained in:
parent
5c75894065
commit
11cb2db3fe
@ -60,6 +60,7 @@ class PaymentEntry(AccountsController):
|
||||
def validate(self):
|
||||
self.setup_party_account_field()
|
||||
self.set_missing_values()
|
||||
self.set_missing_ref_details()
|
||||
self.validate_payment_type()
|
||||
self.validate_party_details()
|
||||
self.set_exchange_rate()
|
||||
@ -219,8 +220,6 @@ class PaymentEntry(AccountsController):
|
||||
else self.paid_to_account_currency
|
||||
)
|
||||
|
||||
self.set_missing_ref_details()
|
||||
|
||||
def set_missing_ref_details(self, force=False):
|
||||
for d in self.get("references"):
|
||||
if d.allocated_amount:
|
||||
@ -1811,6 +1810,7 @@ def get_payment_entry(
|
||||
|
||||
pe.setup_party_account_field()
|
||||
pe.set_missing_values()
|
||||
pe.set_missing_ref_details()
|
||||
|
||||
update_accounting_dimensions(pe, doc)
|
||||
|
||||
|
@ -646,6 +646,7 @@ def update_reference_in_payment_entry(d, payment_entry, do_not_save=False):
|
||||
payment_entry.flags.ignore_validate_update_after_submit = True
|
||||
payment_entry.setup_party_account_field()
|
||||
payment_entry.set_missing_values()
|
||||
payment_entry.set_missing_ref_details()
|
||||
payment_entry.set_amounts()
|
||||
|
||||
if not do_not_save:
|
||||
|
Loading…
x
Reference in New Issue
Block a user