brotherton-erpnext/erpnext/patches/v5_0/is_group.py

10 lines
319 B
Python
Raw Normal View History

2015-04-23 07:44:17 +00:00
from __future__ import unicode_literals
import frappe
def execute():
frappe.reload_doctype("Account")
frappe.reload_doctype("Cost Center")
frappe.db.sql("update tabAccount set is_group = if(group_or_ledger='Group', 1, 0)")
frappe.db.sql("update `tabCost Center` set is_group = if(group_or_ledger='Group', 1, 0)")