feat: drop payload column
diff --git a/erpnext/non_profit/doctype/membership/membership.json b/erpnext/non_profit/doctype/membership/membership.json
index 238f4c3..95bb3a5 100644
--- a/erpnext/non_profit/doctype/membership/membership.json
+++ b/erpnext/non_profit/doctype/membership/membership.json
@@ -19,10 +19,10 @@
"paid",
"currency",
"amount",
+ "invoice",
"razorpay_details_section",
"subscription_id",
- "payment_id",
- "webhook_payload"
+ "payment_id"
],
"fields": [
{
@@ -118,17 +118,15 @@
"read_only": 1
},
{
- "fieldname": "webhook_payload",
- "fieldtype": "Code",
- "hidden": 1,
- "label": "Webhook Payload",
- "options": "JSON",
- "read_only": 1
+ "fieldname": "invoice",
+ "fieldtype": "Link",
+ "label": "Invoice",
+ "options": "Sales Invoice"
}
],
"index_web_pages_for_search": 1,
"links": [],
- "modified": "2020-07-27 14:28:11.532696",
+ "modified": "2020-07-31 13:57:02.328995",
"modified_by": "Administrator",
"module": "Non Profit",
"name": "Membership",
diff --git a/erpnext/patches.txt b/erpnext/patches.txt
index 361fe83..17b46ab 100644
--- a/erpnext/patches.txt
+++ b/erpnext/patches.txt
@@ -721,3 +721,4 @@
erpnext.patches.v13_0.stock_entry_enhancements
erpnext.patches.v12_0.update_state_code_for_daman_and_diu
erpnext.patches.v12_0.rename_lost_reason_detail
+erpnext.patches.v13_0.drop_razorpay_payload_column
diff --git a/erpnext/patches/v13_0/drop_razorpay_payload_column.py b/erpnext/patches/v13_0/drop_razorpay_payload_column.py
new file mode 100644
index 0000000..62f0373
--- /dev/null
+++ b/erpnext/patches/v13_0/drop_razorpay_payload_column.py
@@ -0,0 +1,7 @@
+from __future__ import unicode_literals
+import frappe
+
+def execute():
+ if frappe.db.exists("DocType", "Membership Settings"):
+ if 'webhook_payload' in frappe.db.get_table_columns("Membership Settings"):
+ frappe.db.sql("alter table `tabMembership Settings` drop column webhook_payload")
\ No newline at end of file