[minor] dont make tax template default, by default. #5695
This commit is contained in:
parent
5f9566f3af
commit
6ecc0888ab
@ -12,8 +12,9 @@ class SalesTaxesandChargesTemplate(Document):
|
||||
valdiate_taxes_and_charges_template(self)
|
||||
|
||||
def valdiate_taxes_and_charges_template(doc):
|
||||
if not doc.is_default and not frappe.get_all(doc.doctype, filters={"is_default": 1}):
|
||||
doc.is_default = 1
|
||||
# default should not be disabled
|
||||
# if not doc.is_default and not frappe.get_all(doc.doctype, filters={"is_default": 1}):
|
||||
# doc.is_default = 1
|
||||
|
||||
if doc.is_default == 1:
|
||||
frappe.db.sql("""update `tab{0}` set is_default = 0
|
||||
|
Loading…
x
Reference in New Issue
Block a user