set default terms and condition if tc_name is available on the form
This commit is contained in:
parent
ae25e0da88
commit
585448b225
@ -349,7 +349,7 @@ erpnext.TransactionController = erpnext.taxes_and_totals.extend({
|
||||
me.frm.set_value("letter_head", company_doc.default_letter_head);
|
||||
}
|
||||
}
|
||||
if (company_doc.default_terms && me.frm.doc.doctype != "Purchase Invoice") {
|
||||
if (company_doc.default_terms && me.frm.doc.doctype != "Purchase Invoice" && frappe.meta.has_field(me.frm.doc.doctype, "tc_name")) {
|
||||
me.frm.set_value("tc_name", company_doc.default_terms);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user