fix: payment entry exchange gain loss issue
(cherry picked from commit 2dbef23244)
This commit is contained in:
@@ -258,6 +258,10 @@ frappe.ui.form.on("Payment Entry", {
|
|||||||
frappe.flags.allocate_payment_amount = true;
|
frappe.flags.allocate_payment_amount = true;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
validate: async function (frm) {
|
||||||
|
await frm.events.set_exchange_gain_loss_deduction(frm);
|
||||||
|
},
|
||||||
|
|
||||||
validate_company: (frm) => {
|
validate_company: (frm) => {
|
||||||
if (!frm.doc.company) {
|
if (!frm.doc.company) {
|
||||||
frappe.throw({ message: __("Please select a Company first."), title: __("Mandatory") });
|
frappe.throw({ message: __("Please select a Company first."), title: __("Mandatory") });
|
||||||
@@ -1893,8 +1897,6 @@ function prompt_for_missing_account(frm, account) {
|
|||||||
(values) => resolve(values?.[account]),
|
(values) => resolve(values?.[account]),
|
||||||
__("Please Specify Account")
|
__("Please Specify Account")
|
||||||
);
|
);
|
||||||
|
|
||||||
dialog.on_hide = () => resolve("");
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user