fix: remove agriculture module from patch (#31369)
This commit is contained in:
		| @@ -339,7 +339,7 @@ erpnext.patches.v14_0.delete_shopify_doctypes | ||||
| erpnext.patches.v14_0.delete_healthcare_doctypes | ||||
| erpnext.patches.v14_0.delete_hub_doctypes | ||||
| erpnext.patches.v14_0.delete_hospitality_doctypes # 20-01-2022 | ||||
| erpnext.patches.v14_0.delete_agriculture_doctypes | ||||
| erpnext.patches.v14_0.delete_agriculture_doctypes # 15-06-2022 | ||||
| erpnext.patches.v14_0.delete_education_doctypes | ||||
| erpnext.patches.v14_0.delete_datev_doctypes | ||||
| erpnext.patches.v14_0.rearrange_company_fields | ||||
|   | ||||
| @@ -2,6 +2,9 @@ import frappe | ||||
|  | ||||
|  | ||||
| def execute(): | ||||
| 	if "agriculture" in frappe.get_installed_apps(): | ||||
| 		return | ||||
|  | ||||
| 	frappe.delete_doc("Module Def", "Agriculture", ignore_missing=True, force=True) | ||||
|  | ||||
| 	frappe.delete_doc("Workspace", "Agriculture", ignore_missing=True, force=True) | ||||
| @@ -19,3 +22,5 @@ def execute(): | ||||
| 	doctypes = frappe.get_all("DocType", {"module": "agriculture", "custom": 0}, pluck="name") | ||||
| 	for doctype in doctypes: | ||||
| 		frappe.delete_doc("DocType", doctype, ignore_missing=True) | ||||
|  | ||||
| 	frappe.delete_doc("Module Def", "Agriculture", ignore_missing=True, force=True) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Ankush Menat
					Ankush Menat