Create columns for custom fields in new table Salary Detail and Component
diff --git a/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py b/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py
index 03595a5..05a2c49 100644
--- a/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py
+++ b/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py
@@ -9,4 +9,8 @@
for dt in ("Salary Structure Earning", "Salary Structure Deduction", "Salary Slip Earning",
"Salary Slip Deduction", "Earning Type", "Deduction Type"):
frappe.delete_doc("DocType", dt)
-
\ No newline at end of file
+
+
+ for d in frappe.db.sql("""select name from `tabCustom Field`
+ where dt in ('Salary Detail', 'Salary Component')"""):
+ frappe.get_doc("Custom Field", d[0]).save()
\ No newline at end of file