mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-16 08:47:33 +00:00
fix: cost center shouldn't update debit/credit in Exc gain/loss JV
(cherry picked from commit 398d3022ef)
This commit is contained in:
@@ -428,7 +428,10 @@ frappe.ui.form.on("Journal Entry Account", {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
cost_center: function (frm, dt, dn) {
|
cost_center: function (frm, dt, dn) {
|
||||||
erpnext.journal_entry.set_account_details(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) {
|
account: function (frm, dt, dn) {
|
||||||
|
|||||||
Reference in New Issue
Block a user