From 6cea73b8344777502b6a7d50855c6b4e27557040 Mon Sep 17 00:00:00 2001 From: rohitwaghchaure Date: Mon, 18 Sep 2017 16:58:05 +0530 Subject: [PATCH] [fix] Subscription patch (#10827) --- .../patches/v8_7/make_subscription_from_recurring_data.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/erpnext/patches/v8_7/make_subscription_from_recurring_data.py b/erpnext/patches/v8_7/make_subscription_from_recurring_data.py index 89eca1a0ec..89830a22f8 100644 --- a/erpnext/patches/v8_7/make_subscription_from_recurring_data.py +++ b/erpnext/patches/v8_7/make_subscription_from_recurring_data.py @@ -18,7 +18,7 @@ def execute(): make_subscription(doctype, data) def get_data(doctype): - return frappe.db.sql(""" select name, from_date, end_date, recurring_type,recurring_id + return frappe.db.sql(""" select name, from_date, end_date, recurring_type,recurring_id, next_date, notify_by_email, notification_email_address, recurring_print_format, repeat_on_day_of_month, submit_on_creation from `tab{0}` where is_recurring = 1 and next_date >= %s @@ -39,7 +39,4 @@ def make_subscription(doctype, data): 'submit_on_creation': data.submit_on_creation }).insert(ignore_permissions=True) - doc.submit() - - if not doc.subscription: - frappe.db.set_value(doctype, data.name, "subscription", doc.name) \ No newline at end of file + doc.submit() \ No newline at end of file