Merge pull request #45411 from frappe/mergify/bp/version-15-hotfix/pr-45291

fix: don't update party-type on change of cost center in Journal Entry (backport #45291)
This commit is contained in:
ruthra kumar
2025-01-24 10:16:53 +05:30
committed by GitHub

View File

@@ -430,12 +430,6 @@ frappe.ui.form.on("Journal Entry Account", {
});
}
},
cost_center: function (frm, dt, dn) {
// Don't reset for Gain/Loss type journals, as it will make Debit and Credit values '0'
if (frm.doc.voucher_type != "Exchange Gain Or Loss") {
erpnext.journal_entry.set_account_details(frm, dt, dn);
}
},
account: function (frm, dt, dn) {
erpnext.journal_entry.set_account_details(frm, dt, dn);