chore: Update allow on submit for Sales Invoice fields
This commit is contained in:
@@ -143,6 +143,12 @@ var get_payment_mode_account = function(frm, mode_of_payment, callback) {
|
||||
|
||||
cur_frm.cscript.account_head = function(doc, cdt, cdn) {
|
||||
var d = locals[cdt][cdn];
|
||||
|
||||
if (doc.docstatus == 1) {
|
||||
// Should not trigger any changes on change post submit
|
||||
return;
|
||||
}
|
||||
|
||||
if(!d.charge_type && d.account_head){
|
||||
frappe.msgprint(__("Please select Charge Type first"));
|
||||
frappe.model.set_value(cdt, cdn, "account_head", "");
|
||||
|
||||
Reference in New Issue
Block a user