From 737849a0f5e004b88cef3426eda63750a0b31f12 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 25 Feb 2016 15:16:02 +0530 Subject: [PATCH] [patch] Update stopped status to close --- erpnext/patches.txt | 1 + erpnext/patches/v6_23/__init__.py | 0 erpnext/patches/v6_23/update_stopped_status_to_closed.py | 9 +++++++++ 3 files changed, 10 insertions(+) create mode 100644 erpnext/patches/v6_23/__init__.py create mode 100644 erpnext/patches/v6_23/update_stopped_status_to_closed.py diff --git a/erpnext/patches.txt b/erpnext/patches.txt index 76bffc2de9..2348777661 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -249,3 +249,4 @@ erpnext.patches.v6_20.set_party_account_currency_in_orders #erpnext.patches.v6_19.comment_feed_communication erpnext.patches.v6_21.fix_reorder_level erpnext.patches.v6_21.rename_material_request_fields +erpnext.patches.v6_23.update_stopped_status_to_closed \ No newline at end of file diff --git a/erpnext/patches/v6_23/__init__.py b/erpnext/patches/v6_23/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/erpnext/patches/v6_23/update_stopped_status_to_closed.py b/erpnext/patches/v6_23/update_stopped_status_to_closed.py new file mode 100644 index 0000000000..79d1e0ac30 --- /dev/null +++ b/erpnext/patches/v6_23/update_stopped_status_to_closed.py @@ -0,0 +1,9 @@ +# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors +# License: GNU General Public License v3. See license.txt + +from __future__ import unicode_literals +import frappe + +def execute(): + for dt in ("Sales Order", "Purchase Order"): + frappe.db.sql("update `tab{0}` set status='Closed' where status='Stopped'".format(dt)) \ No newline at end of file