[patch] remove employee name salary structure (#10817)
* [patch] remove employee name salary structure
* Update remove_employee_from_salary_structure_parent.py
diff --git a/erpnext/patches.txt b/erpnext/patches.txt
index 74bd37a..1fea308 100644
--- a/erpnext/patches.txt
+++ b/erpnext/patches.txt
@@ -437,4 +437,5 @@
erpnext.patches.v8_6.rename_bom_update_tool
erpnext.patches.v8_9.set_print_zero_amount_taxes
erpnext.patches.v8_9.set_default_customer_group
-erpnext.patches.v8_9.delete_gst_doctypes_for_outside_india_accounts
\ No newline at end of file
+erpnext.patches.v8_9.remove_employee_from_salary_structure_parent
+erpnext.patches.v8_9.delete_gst_doctypes_for_outside_india_accounts
diff --git a/erpnext/patches/v8_9/remove_employee_from_salary_structure_parent.py b/erpnext/patches/v8_9/remove_employee_from_salary_structure_parent.py
new file mode 100644
index 0000000..53911a1
--- /dev/null
+++ b/erpnext/patches/v8_9/remove_employee_from_salary_structure_parent.py
@@ -0,0 +1,5 @@
+import frappe
+
+def execute():
+ if 'employee' in frappe.db.get_table_columns("Salary Structure"):
+ frappe.db.sql("alter table `tabEmployee` drop column employee")