From 3d6697949c7c7f4beebb5c3bfe14689abe1c0650 Mon Sep 17 00:00:00 2001 From: Makarand Bauskar Date: Fri, 16 Jun 2017 14:12:28 +0530 Subject: [PATCH] [minor] fixed the child table field name (#9328) * [minor] exclude Other domain from Domains * [minor] fixed the child table field name --- erpnext/patches.txt | 2 +- erpnext/patches/v8_0/create_domain_docs.py | 4 ++-- erpnext/setup/setup_wizard/setup_wizard.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/erpnext/patches.txt b/erpnext/patches.txt index 6ff4c314e01..8068ea61e90 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -403,4 +403,4 @@ erpnext.patches.v8_0.rename_items_in_status_field_of_material_request erpnext.patches.v8_0.delete_bin_indexes erpnext.patches.v8_0.move_account_head_from_account_to_warehouse_for_inventory erpnext.patches.v8_0.change_in_words_varchar_length -erpnext.patches.v8_0.create_domain_docs \ No newline at end of file +erpnext.patches.v8_0.create_domain_docs #16-05-2017 \ No newline at end of file diff --git a/erpnext/patches/v8_0/create_domain_docs.py b/erpnext/patches/v8_0/create_domain_docs.py index f04a7e663ce..7e303c18793 100644 --- a/erpnext/patches/v8_0/create_domain_docs.py +++ b/erpnext/patches/v8_0/create_domain_docs.py @@ -21,9 +21,9 @@ def execute(): condition = "" company = erpnext.get_default_company() if company: - condition = " where name='{0}'".format(company) + condition = " and name='{0}'".format(company) - domains = frappe.db.sql_list("select distinct domain from `tabCompany` {0}".format(condition)) + domains = frappe.db.sql_list("select distinct domain from `tabCompany` where domain != 'Other' {0}".format(condition)) if not domains: return diff --git a/erpnext/setup/setup_wizard/setup_wizard.py b/erpnext/setup/setup_wizard/setup_wizard.py index 93e879d67e3..5daa4e4d9e6 100644 --- a/erpnext/setup/setup_wizard/setup_wizard.py +++ b/erpnext/setup/setup_wizard/setup_wizard.py @@ -199,7 +199,7 @@ def set_defaults(args): hr_settings.save() domain_settings = frappe.get_doc("Domain Settings") - domain_settings.append('active_domain', dict(domain=args.domain)) + domain_settings.append('active_domains', dict(domain=args.domain)) domain_settings.save() def create_feed_and_todo():