From 66e2a510b94056bb36485e135fcd5698d0dacfe6 Mon Sep 17 00:00:00 2001 From: mbauskar Date: Thu, 22 Jun 2017 16:18:12 +0530 Subject: [PATCH] [minor] deleted deprecated reprots and changed the lead.json modified time --- erpnext/accounts/page/pos/pos.js | 4 ++-- erpnext/crm/doctype/lead/lead.json | 2 +- erpnext/patches.txt | 3 ++- erpnext/patches/v8_1/__init__.py | 0 erpnext/patches/v8_1/delete_deprecated_reports.py | 15 +++++++++++++++ 5 files changed, 20 insertions(+), 4 deletions(-) create mode 100644 erpnext/patches/v8_1/__init__.py create mode 100644 erpnext/patches/v8_1/delete_deprecated_reports.py diff --git a/erpnext/accounts/page/pos/pos.js b/erpnext/accounts/page/pos/pos.js index abe81a282a..2bbce601cd 100644 --- a/erpnext/accounts/page/pos/pos.js +++ b/erpnext/accounts/page/pos/pos.js @@ -1484,7 +1484,7 @@ erpnext.pos.PointOfSale = erpnext.taxes_and_totals.extend({ print_dialog: function () { var me = this; - this.frappe.msgprint = frappe.msgprint( + this.msgprint = frappe.msgprint( `${__('Print')} ${__('New')}`); @@ -1495,7 +1495,7 @@ erpnext.pos.PointOfSale = erpnext.taxes_and_totals.extend({ }) $('.new_doc').click(function () { - me.frappe.msgprint.hide() + me.msgprint.hide() me.make_new_cart() }) }, diff --git a/erpnext/crm/doctype/lead/lead.json b/erpnext/crm/doctype/lead/lead.json index 40b0e50ad1..e7c2d33f3c 100644 --- a/erpnext/crm/doctype/lead/lead.json +++ b/erpnext/crm/doctype/lead/lead.json @@ -1144,7 +1144,7 @@ "issingle": 0, "istable": 0, "max_attachments": 0, - "modified": "2017-06-13 14:29:12.567700", + "modified": "2017-06-22 14:29:12.700000", "modified_by": "Administrator", "module": "CRM", "name": "Lead", diff --git a/erpnext/patches.txt b/erpnext/patches.txt index 35582cb563..d0fa2e666c 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -405,4 +405,5 @@ erpnext.patches.v8_0.move_account_head_from_account_to_warehouse_for_inventory erpnext.patches.v8_0.change_in_words_varchar_length erpnext.patches.v8_0.create_domain_docs #16-05-2017 erpnext.patches.v8_0.update_sales_cost_in_project -erpnext.patches.v8_0.save_system_settings \ No newline at end of file +erpnext.patches.v8_0.save_system_settings +erpnext.patches.v8_1.delete_deprecated_reports \ No newline at end of file diff --git a/erpnext/patches/v8_1/__init__.py b/erpnext/patches/v8_1/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/erpnext/patches/v8_1/delete_deprecated_reports.py b/erpnext/patches/v8_1/delete_deprecated_reports.py new file mode 100644 index 0000000000..2cb84a9a5f --- /dev/null +++ b/erpnext/patches/v8_1/delete_deprecated_reports.py @@ -0,0 +1,15 @@ +# Copyright (c) 2017, Frappe and Contributors +# License: GNU General Public License v3. See license.txt + +from __future__ import unicode_literals +import frappe + +def execute(): + """ delete deprecated reports """ + + reports = ["Monthly Salary Register", "Customer Addresses And Contacts", + "Supplier Addresses And Contacts"] + + for report in reports: + if frappe.db.exists("Report", report): + frappe.delete_doc("Report", report, ignore_permissions=True) \ No newline at end of file