Merge pull request #17322 from nabinhait/salary-structure-child-docstatus

Salary structure child docstatus
diff --git a/erpnext/patches.txt b/erpnext/patches.txt
index ccfd37d..e0002ab 100644
--- a/erpnext/patches.txt
+++ b/erpnext/patches.txt
@@ -597,3 +597,4 @@
 erpnext.patches.v12_0.move_item_tax_to_item_tax_template
 erpnext.patches.v11_1.set_variant_based_on
 erpnext.patches.v11_1.woocommerce_set_creation_user
+erpnext.patches.v11_1.set_salary_details_submittable
diff --git a/erpnext/patches/v11_1/set_salary_details_submittable.py b/erpnext/patches/v11_1/set_salary_details_submittable.py
new file mode 100644
index 0000000..f4477d9
--- /dev/null
+++ b/erpnext/patches/v11_1/set_salary_details_submittable.py
@@ -0,0 +1,11 @@
+from __future__ import unicode_literals
+import frappe
+
+def execute():
+	frappe.db.sql("""
+		update `tabSalary Structure` ss, `tabSalary Detail` sd
+		set sd.docstatus=1
+		where ss.name=sd.parent and ss.docstatus=1 and sd.parenttype='Salary Structure'
+	""")
+	
+