From 6bda2a086515c24c7d0593d1d419eb13aaa7fa5a Mon Sep 17 00:00:00 2001 From: Smit Vora Date: Tue, 5 Jul 2022 21:20:51 +0530 Subject: [PATCH] chore: deprecation warning for remove-india --- erpnext/patches.txt | 1 + ...show_india_localisation_deprecation_warning.py | 15 +++++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 erpnext/patches/v13_0/show_india_localisation_deprecation_warning.py diff --git a/erpnext/patches.txt b/erpnext/patches.txt index f639dc7d380..bdc43dd094a 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -368,3 +368,4 @@ erpnext.patches.v13_0.set_per_billed_in_return_delivery_note erpnext.patches.v13_0.update_employee_advance_status erpnext.patches.v13_0.job_card_status_on_hold erpnext.patches.v13_0.add_cost_center_in_loans +erpnext.patches.v13_0.show_india_localisation_deprecation_warning \ No newline at end of file diff --git a/erpnext/patches/v13_0/show_india_localisation_deprecation_warning.py b/erpnext/patches/v13_0/show_india_localisation_deprecation_warning.py new file mode 100644 index 00000000000..1d76b252192 --- /dev/null +++ b/erpnext/patches/v13_0/show_india_localisation_deprecation_warning.py @@ -0,0 +1,15 @@ +import click +import frappe + + +def execute(): + if not frappe.db.exists("Company", {"country": "India"}): + return + + click.secho( + "India-specific regional features have been moved to a separate app" + " and will be removed from ERPNext in Version 14." + " Please install India Compliance after upgrading to Version 14:\n" + "https://github.com/resilient-tech/india-compliance", + fg="yellow", + )