fix: patch check_is_income_tax_component (#22371)
diff --git a/erpnext/patches.txt b/erpnext/patches.txt
index b17cc47..928c0ab 100644
--- a/erpnext/patches.txt
+++ b/erpnext/patches.txt
@@ -702,6 +702,6 @@
erpnext.patches.v12_0.set_multi_uom_in_rfq
erpnext.patches.v13_0.delete_old_sales_reports
execute:frappe.delete_doc_if_exists("DocType", "Bank Reconciliation")
-erpnext.patches.v13_0.move_doctype_reports_and_notification_from_hr_to_payroll
-erpnext.patches.v13_0.move_payroll_setting_separately_from_hr_settings
-erpnext.patches.v13_0.check_is_income_tax_component
+erpnext.patches.v13_0.move_doctype_reports_and_notification_from_hr_to_payroll #22-06-2020
+erpnext.patches.v13_0.move_payroll_setting_separately_from_hr_settings #22-06-2020
+erpnext.patches.v13_0.check_is_income_tax_component #22-06-2020
diff --git a/erpnext/patches/v13_0/check_is_income_tax_component.py b/erpnext/patches/v13_0/check_is_income_tax_component.py
index f69412c..9ad48e2 100644
--- a/erpnext/patches/v13_0/check_is_income_tax_component.py
+++ b/erpnext/patches/v13_0/check_is_income_tax_component.py
@@ -4,9 +4,28 @@
from __future__ import unicode_literals
import frappe, erpnext
+from erpnext.regional.india.setup import setup
def execute():
- frappe.reload_doc('Payroll', 'doctype', 'salary_structure')
+
+ doctypes = ['salary_component',
+ 'Employee Tax Exemption Declaration',
+ 'Employee Tax Exemption Proof Submission',
+ 'Employee Tax Exemption Declaration Category',
+ 'Employee Tax Exemption Proof Submission Detail'
+ ]
+
+ for doctype in doctypes:
+ frappe.reload_doc('Payroll', 'doctype', doctype)
+
+
+ reports = ['Professional Tax Deductions', 'Provident Fund Deductions']
+ for report in reports:
+ frappe.reload_doc('Regional', 'Report', report)
+ frappe.reload_doc('Regional', 'Report', report)
+
+ if erpnext.get_region() == "India":
+ setup(patch=True)
if frappe.db.exists("Salary Component", "Income Tax"):
frappe.db.set_value("Salary Component", "Income Tax", "is_income_tax_component", 1)
diff --git a/erpnext/payroll/doctype/additional_salary/additional_salary.json b/erpnext/payroll/doctype/additional_salary/additional_salary.json
index ad64289..69cb5da 100644
--- a/erpnext/payroll/doctype/additional_salary/additional_salary.json
+++ b/erpnext/payroll/doctype/additional_salary/additional_salary.json
@@ -163,7 +163,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 21:10:50.374063",
+ "modified": "2020-06-22 21:10:50.374063",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Additional Salary",
diff --git a/erpnext/payroll/doctype/employee_benefit_application/employee_benefit_application.json b/erpnext/payroll/doctype/employee_benefit_application/employee_benefit_application.json
index 275c855..b0c1bd6 100644
--- a/erpnext/payroll/doctype/employee_benefit_application/employee_benefit_application.json
+++ b/erpnext/payroll/doctype/employee_benefit_application/employee_benefit_application.json
@@ -119,7 +119,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 22:58:31.271922",
+ "modified": "2020-06-22 22:58:31.271922",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Benefit Application",
diff --git a/erpnext/payroll/doctype/employee_benefit_application_detail/employee_benefit_application_detail.json b/erpnext/payroll/doctype/employee_benefit_application_detail/employee_benefit_application_detail.json
index f0415d2..fa6b4da 100644
--- a/erpnext/payroll/doctype/employee_benefit_application_detail/employee_benefit_application_detail.json
+++ b/erpnext/payroll/doctype/employee_benefit_application_detail/employee_benefit_application_detail.json
@@ -45,7 +45,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:45:00.519134",
+ "modified": "2020-06-22 23:45:00.519134",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Benefit Application Detail",
diff --git a/erpnext/payroll/doctype/employee_benefit_claim/employee_benefit_claim.json b/erpnext/payroll/doctype/employee_benefit_claim/employee_benefit_claim.json
index 7fea59f..ae4c218 100644
--- a/erpnext/payroll/doctype/employee_benefit_claim/employee_benefit_claim.json
+++ b/erpnext/payroll/doctype/employee_benefit_claim/employee_benefit_claim.json
@@ -123,7 +123,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 23:01:50.791676",
+ "modified": "2020-06-22 23:01:50.791676",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Benefit Claim",
diff --git a/erpnext/payroll/doctype/employee_incentive/employee_incentive.json b/erpnext/payroll/doctype/employee_incentive/employee_incentive.json
index 81ff865..204c9a4 100644
--- a/erpnext/payroll/doctype/employee_incentive/employee_incentive.json
+++ b/erpnext/payroll/doctype/employee_incentive/employee_incentive.json
@@ -74,7 +74,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 22:42:51.209630",
+ "modified": "2020-06-22 22:42:51.209630",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Incentive",
diff --git a/erpnext/payroll/doctype/employee_other_income/employee_other_income.json b/erpnext/payroll/doctype/employee_other_income/employee_other_income.json
index c5a2a73..14f63e4 100644
--- a/erpnext/payroll/doctype/employee_other_income/employee_other_income.json
+++ b/erpnext/payroll/doctype/employee_other_income/employee_other_income.json
@@ -76,7 +76,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 22:55:17.604688",
+ "modified": "2020-06-22 22:55:17.604688",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Other Income",
diff --git a/erpnext/payroll/doctype/employee_tax_exemption_category/employee_tax_exemption_category.json b/erpnext/payroll/doctype/employee_tax_exemption_category/employee_tax_exemption_category.json
index c097082..f2556d7 100644
--- a/erpnext/payroll/doctype/employee_tax_exemption_category/employee_tax_exemption_category.json
+++ b/erpnext/payroll/doctype/employee_tax_exemption_category/employee_tax_exemption_category.json
@@ -26,7 +26,7 @@
}
],
"links": [],
- "modified": "2020-05-27 23:16:47.472910",
+ "modified": "2020-06-22 23:16:47.472910",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Tax Exemption Category",
diff --git a/erpnext/payroll/doctype/employee_tax_exemption_declaration/employee_tax_exemption_declaration.json b/erpnext/payroll/doctype/employee_tax_exemption_declaration/employee_tax_exemption_declaration.json
index 5423365..de7c348 100644
--- a/erpnext/payroll/doctype/employee_tax_exemption_declaration/employee_tax_exemption_declaration.json
+++ b/erpnext/payroll/doctype/employee_tax_exemption_declaration/employee_tax_exemption_declaration.json
@@ -107,7 +107,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 22:49:43.829892",
+ "modified": "2020-06-22 22:49:43.829892",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Tax Exemption Declaration",
diff --git a/erpnext/payroll/doctype/employee_tax_exemption_declaration_category/employee_tax_exemption_declaration_category.json b/erpnext/payroll/doctype/employee_tax_exemption_declaration_category/employee_tax_exemption_declaration_category.json
index eddaec2..8c2f9aa 100644
--- a/erpnext/payroll/doctype/employee_tax_exemption_declaration_category/employee_tax_exemption_declaration_category.json
+++ b/erpnext/payroll/doctype/employee_tax_exemption_declaration_category/employee_tax_exemption_declaration_category.json
@@ -48,7 +48,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:41:03.638739",
+ "modified": "2020-06-22 23:41:03.638739",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Tax Exemption Declaration Category",
diff --git a/erpnext/payroll/doctype/employee_tax_exemption_proof_submission/employee_tax_exemption_proof_submission.json b/erpnext/payroll/doctype/employee_tax_exemption_proof_submission/employee_tax_exemption_proof_submission.json
index de8fa09..b62b5aa 100644
--- a/erpnext/payroll/doctype/employee_tax_exemption_proof_submission/employee_tax_exemption_proof_submission.json
+++ b/erpnext/payroll/doctype/employee_tax_exemption_proof_submission/employee_tax_exemption_proof_submission.json
@@ -130,7 +130,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 22:53:10.412321",
+ "modified": "2020-06-22 22:53:10.412321",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Tax Exemption Proof Submission",
diff --git a/erpnext/payroll/doctype/employee_tax_exemption_proof_submission_detail/employee_tax_exemption_proof_submission_detail.json b/erpnext/payroll/doctype/employee_tax_exemption_proof_submission_detail/employee_tax_exemption_proof_submission_detail.json
index 4c53bd3..c1f5320 100644
--- a/erpnext/payroll/doctype/employee_tax_exemption_proof_submission_detail/employee_tax_exemption_proof_submission_detail.json
+++ b/erpnext/payroll/doctype/employee_tax_exemption_proof_submission_detail/employee_tax_exemption_proof_submission_detail.json
@@ -53,7 +53,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:37:08.265600",
+ "modified": "2020-06-22 23:37:08.265600",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Tax Exemption Proof Submission Detail",
diff --git a/erpnext/payroll/doctype/employee_tax_exemption_sub_category/employee_tax_exemption_sub_category.json b/erpnext/payroll/doctype/employee_tax_exemption_sub_category/employee_tax_exemption_sub_category.json
index b89d9c1..f8c4b8b 100644
--- a/erpnext/payroll/doctype/employee_tax_exemption_sub_category/employee_tax_exemption_sub_category.json
+++ b/erpnext/payroll/doctype/employee_tax_exemption_sub_category/employee_tax_exemption_sub_category.json
@@ -38,7 +38,7 @@
}
],
"links": [],
- "modified": "2020-05-27 23:18:08.254645",
+ "modified": "2020-06-22 23:18:08.254645",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Employee Tax Exemption Sub Category",
diff --git a/erpnext/payroll/doctype/income_tax_slab/income_tax_slab.json b/erpnext/payroll/doctype/income_tax_slab/income_tax_slab.json
index 72b4332..6337d5a 100644
--- a/erpnext/payroll/doctype/income_tax_slab/income_tax_slab.json
+++ b/erpnext/payroll/doctype/income_tax_slab/income_tax_slab.json
@@ -94,7 +94,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 20:27:13.425084",
+ "modified": "2020-06-22 20:27:13.425084",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Income Tax Slab",
diff --git a/erpnext/payroll/doctype/income_tax_slab_other_charges/income_tax_slab_other_charges.json b/erpnext/payroll/doctype/income_tax_slab_other_charges/income_tax_slab_other_charges.json
index 2531c79..7f21204 100644
--- a/erpnext/payroll/doctype/income_tax_slab_other_charges/income_tax_slab_other_charges.json
+++ b/erpnext/payroll/doctype/income_tax_slab_other_charges/income_tax_slab_other_charges.json
@@ -62,7 +62,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:33:17.931912",
+ "modified": "2020-06-22 23:33:17.931912",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Income Tax Slab Other Charges",
diff --git a/erpnext/payroll/doctype/payroll_employee_detail/payroll_employee_detail.json b/erpnext/payroll/doctype/payroll_employee_detail/payroll_employee_detail.json
index b22e5de..bb68e18 100644
--- a/erpnext/payroll/doctype/payroll_employee_detail/payroll_employee_detail.json
+++ b/erpnext/payroll/doctype/payroll_employee_detail/payroll_employee_detail.json
@@ -52,7 +52,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:25:13.779032",
+ "modified": "2020-06-22 23:25:13.779032",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Payroll Employee Detail",
diff --git a/erpnext/payroll/doctype/payroll_entry/payroll_entry.json b/erpnext/payroll/doctype/payroll_entry/payroll_entry.json
index 4888be2..31a8996 100644
--- a/erpnext/payroll/doctype/payroll_entry/payroll_entry.json
+++ b/erpnext/payroll/doctype/payroll_entry/payroll_entry.json
@@ -262,7 +262,7 @@
"icon": "fa fa-cog",
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 20:06:06.953904",
+ "modified": "2020-06-22 20:06:06.953904",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Payroll Entry",
diff --git a/erpnext/payroll/doctype/payroll_period/payroll_period.json b/erpnext/payroll/doctype/payroll_period/payroll_period.json
index 345a241..c919b4f 100644
--- a/erpnext/payroll/doctype/payroll_period/payroll_period.json
+++ b/erpnext/payroll/doctype/payroll_period/payroll_period.json
@@ -53,7 +53,7 @@
}
],
"links": [],
- "modified": "2020-05-27 20:12:32.684189",
+ "modified": "2020-06-22 20:12:32.684189",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Payroll Period",
diff --git a/erpnext/payroll/doctype/payroll_period_date/payroll_period_date.json b/erpnext/payroll/doctype/payroll_period_date/payroll_period_date.json
index d745fcd..4a2f383 100644
--- a/erpnext/payroll/doctype/payroll_period_date/payroll_period_date.json
+++ b/erpnext/payroll/doctype/payroll_period_date/payroll_period_date.json
@@ -26,7 +26,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:30:15.943356",
+ "modified": "2020-06-22 23:30:15.943356",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Payroll Period Date",
diff --git a/erpnext/payroll/doctype/payroll_settings/payroll_settings.json b/erpnext/payroll/doctype/payroll_settings/payroll_settings.json
index e3b8b3e..e14b478 100644
--- a/erpnext/payroll/doctype/payroll_settings/payroll_settings.json
+++ b/erpnext/payroll/doctype/payroll_settings/payroll_settings.json
@@ -109,7 +109,7 @@
"icon": "fa fa-cog",
"issingle": 1,
"links": [],
- "modified": "2020-06-05 12:35:34.861674",
+ "modified": "2020-06-22 12:35:34.861674",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Payroll Settings",
diff --git a/erpnext/payroll/doctype/retention_bonus/retention_bonus.json b/erpnext/payroll/doctype/retention_bonus/retention_bonus.json
index 53fe17f..da884c2 100644
--- a/erpnext/payroll/doctype/retention_bonus/retention_bonus.json
+++ b/erpnext/payroll/doctype/retention_bonus/retention_bonus.json
@@ -93,7 +93,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 22:42:05.251951",
+ "modified": "2020-06-22 22:42:05.251951",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Retention Bonus",
diff --git a/erpnext/payroll/doctype/salary_component/salary_component.json b/erpnext/payroll/doctype/salary_component/salary_component.json
index f1e5cf0..225b048 100644
--- a/erpnext/payroll/doctype/salary_component/salary_component.json
+++ b/erpnext/payroll/doctype/salary_component/salary_component.json
@@ -245,7 +245,7 @@
],
"icon": "fa fa-flag",
"links": [],
- "modified": "2020-06-01 15:39:20.826565",
+ "modified": "2020-06-22 15:39:20.826565",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Component",
diff --git a/erpnext/payroll/doctype/salary_detail/salary_detail.json b/erpnext/payroll/doctype/salary_detail/salary_detail.json
index b7d2bc1..adb54f2 100644
--- a/erpnext/payroll/doctype/salary_detail/salary_detail.json
+++ b/erpnext/payroll/doctype/salary_detail/salary_detail.json
@@ -211,7 +211,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:21:26.300951",
+ "modified": "2020-06-22 23:21:26.300951",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Detail",
diff --git a/erpnext/payroll/doctype/salary_slip/salary_slip.json b/erpnext/payroll/doctype/salary_slip/salary_slip.json
index a6337de..663a3ef 100644
--- a/erpnext/payroll/doctype/salary_slip/salary_slip.json
+++ b/erpnext/payroll/doctype/salary_slip/salary_slip.json
@@ -616,7 +616,7 @@
"idx": 9,
"is_submittable": 1,
"links": [],
- "modified": "2020-06-05 14:42:43.921828",
+ "modified": "2020-06-22 14:42:43.921828",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Slip",
diff --git a/erpnext/payroll/doctype/salary_slip_timesheet/salary_slip_timesheet.json b/erpnext/payroll/doctype/salary_slip_timesheet/salary_slip_timesheet.json
index 028c195..9930c53 100644
--- a/erpnext/payroll/doctype/salary_slip_timesheet/salary_slip_timesheet.json
+++ b/erpnext/payroll/doctype/salary_slip_timesheet/salary_slip_timesheet.json
@@ -28,7 +28,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:27:43.463532",
+ "modified": "2020-06-22 23:27:43.463532",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Slip Timesheet",
diff --git a/erpnext/payroll/doctype/salary_structure/salary_structure.json b/erpnext/payroll/doctype/salary_structure/salary_structure.json
index e710f6b..5f94929 100644
--- a/erpnext/payroll/doctype/salary_structure/salary_structure.json
+++ b/erpnext/payroll/doctype/salary_structure/salary_structure.json
@@ -282,7 +282,7 @@
"idx": 1,
"is_submittable": 1,
"links": [],
- "modified": "2020-06-05 17:07:26.129355",
+ "modified": "2020-06-22 17:07:26.129355",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Structure",
diff --git a/erpnext/payroll/doctype/salary_structure_assignment/salary_structure_assignment.json b/erpnext/payroll/doctype/salary_structure_assignment/salary_structure_assignment.json
index 4f74a7f..c84e034 100644
--- a/erpnext/payroll/doctype/salary_structure_assignment/salary_structure_assignment.json
+++ b/erpnext/payroll/doctype/salary_structure_assignment/salary_structure_assignment.json
@@ -124,7 +124,7 @@
],
"is_submittable": 1,
"links": [],
- "modified": "2020-05-27 19:58:09.964692",
+ "modified": "2020-06-22 19:58:09.964692",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Structure Assignment",
diff --git a/erpnext/payroll/doctype/taxable_salary_slab/taxable_salary_slab.json b/erpnext/payroll/doctype/taxable_salary_slab/taxable_salary_slab.json
index 277576e..ce9512f 100644
--- a/erpnext/payroll/doctype/taxable_salary_slab/taxable_salary_slab.json
+++ b/erpnext/payroll/doctype/taxable_salary_slab/taxable_salary_slab.json
@@ -51,7 +51,7 @@
],
"istable": 1,
"links": [],
- "modified": "2020-05-27 23:32:47.253106",
+ "modified": "2020-06-22 23:32:47.253106",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Taxable Salary Slab",