[fixes] rename ctype to doctype

This commit is contained in:
Saurabh
2016-06-24 11:36:31 +05:30
parent 001d4d74fa
commit dc2fa86222
4 changed files with 16 additions and 19 deletions

View File

@@ -12,7 +12,6 @@ def execute():
"parent_warehouse", "is_group"]):
set_parent_to_warehouses(warehouse, company)
set_parent_to_warehouse_acounts(warehouse, company)
frappe.db.commit()
def set_parent_to_warehouses(warehouse, company):
warehouse = frappe.get_doc("Warehouse", warehouse.name)
@@ -31,10 +30,6 @@ def set_parent_to_warehouse_acounts(warehouse, company):
if account and account != "{0} - {1}".format(_("All Warehouses"), company.abbr):
account = frappe.get_doc("Account", account)
if warehouse.is_group == "Yes":
account.is_group = 1
account.account_type = ""
if warehouse.create_account_under == stock_group or not warehouse.create_account_under:
if not warehouse.parent_warehouse:
account.parent_account = "{0} - {1}".format(_("All Warehouses"), company.abbr)