[fix] set title in Journal Entry only if not set
diff --git a/erpnext/accounts/doctype/journal_entry/journal_entry.py b/erpnext/accounts/doctype/journal_entry/journal_entry.py
index 9f3c337..9525a3a 100644
--- a/erpnext/accounts/doctype/journal_entry/journal_entry.py
+++ b/erpnext/accounts/doctype/journal_entry/journal_entry.py
@@ -37,7 +37,8 @@
self.validate_credit_debit_note()
self.validate_empty_accounts_table()
self.set_account_and_party_balance()
- self.set_title()
+ if not self.title:
+ self.title = self.get_title()
def on_submit(self):
self.check_credit_limit()
@@ -45,8 +46,8 @@
self.update_advance_paid()
self.update_expense_claim()
- def set_title(self):
- self.title = self.pay_to_recd_from or self.accounts[0].account
+ def get_title(self):
+ return self.pay_to_recd_from or self.accounts[0].account
def update_advance_paid(self):
advance_paid = frappe._dict()