From ac24d0fa986431980510a2e0ba0487831788a576 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Mon, 1 Jul 2013 14:03:08 +0530 Subject: [PATCH] [fixes] ignore single doctypes in chekcing linked documents --- patches/patch_list.py | 1 + utilities/cleanup_data.py | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/patches/patch_list.py b/patches/patch_list.py index efd4d51cce..4955c75e6c 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -242,4 +242,5 @@ patch_list = [ "execute:webnotes.delete_doc('DocType', 'System Console')", "patches.june_2013.p04_fix_event_for_lead_oppty_project", "patches.june_2013.p05_remove_search_criteria_reports", + "execute:webnotes.delete_doc('DocType', 'Update Delivery Date')", ] \ No newline at end of file diff --git a/utilities/cleanup_data.py b/utilities/cleanup_data.py index c9de4a5e23..df7f4be159 100644 --- a/utilities/cleanup_data.py +++ b/utilities/cleanup_data.py @@ -20,14 +20,16 @@ import webnotes def delete_transactions(): print "Deleting transactions..." - trans = ['Timesheet', 'Task', 'Support Ticket', 'Stock Reconciliation', 'Stock Ledger Entry', + trans = ['Task', 'Support Ticket', 'Stock Reconciliation', 'Stock Ledger Entry', 'Stock Entry', 'Sales Order', 'Salary Slip','Sales Invoice', 'Quotation', 'Quality Inspection', 'Purchase Receipt', 'Purchase Order', 'Production Order', 'POS Setting', 'Period Closing Voucher', 'Purchase Invoice', 'Maintenance Visit', 'Maintenance Schedule', 'Leave Application', 'Leave Allocation', 'Lead', 'Journal Voucher', 'Installation Note', 'Material Request', 'GL Entry', 'Expense Claim', 'Opportunity', 'Delivery Note', 'Customer Issue', 'Bin', 'Authorization Rule', 'Attendance', 'C-Form', - 'Appraisal', 'Installation Note', 'Communication', "Supplier Quotation"] + 'Appraisal', 'Installation Note', 'Communication', "Supplier Quotation", "Newsletter", + "Job Applicant", "Web Page", "Website Slideshow", "Blog Post", "Blog Category", "Blogger", + "Time Log", "Time Log Batch", "Workflow"] for d in trans: for t in webnotes.conn.sql("select options from tabDocField where parent='%s' and fieldtype='Table'" % d): webnotes.conn.sql("delete from `tab%s`" % (t)) @@ -66,6 +68,7 @@ def delete_masters(): 'Item Group': ['All Item Groups', 'Default'], 'Item': '', 'Holiday List': '', + 'Activity Type': '', 'Grade': '', 'Feed': '', 'Expense Claim Type': ['Travel', 'Medical', 'Calls', 'Food', 'Others'],