fix: patch check_is_income_tax_component (#22371)

This commit is contained in:
Anurag Mishra 2020-06-22 12:17:29 +05:30 committed by GitHub
parent 39a7516252
commit 8ffb9f852f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
29 changed files with 50 additions and 31 deletions

View File

@ -702,6 +702,6 @@ erpnext.patches.v12_0.update_address_template_for_india
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

View File

@ -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)

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",

View File

@ -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",