Skip to content

Commit

Permalink
revert: enable variable based on taxable salary for Income Tax compon…
Browse files Browse the repository at this point in the history
…ent (backport #820) (#821)

Co-authored-by: Rucha Mahabal <[email protected]>
  • Loading branch information
mergify[bot] and ruchamahabal authored Aug 25, 2023
1 parent 3664517 commit b6989f2
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 12 deletions.
5 changes: 0 additions & 5 deletions hrms/payroll/doctype/salary_component/salary_component.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,6 @@ frappe.ui.form.on('Salary Component', {
frm.set_value("is_flexible_benefit", 0);
}
},
is_income_tax_component: function(frm) {
if (cint(frm.doc.is_income_tax_component)) {
frm.set_value("variable_based_on_taxable_salary", 1);
}
},
variable_based_on_taxable_salary: function(frm) {
if(frm.doc.variable_based_on_taxable_salary){
set_value_for_condition_and_formula(frm);
Expand Down
4 changes: 2 additions & 2 deletions hrms/payroll/doctype/salary_component/salary_component.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
"column_break_4",
"depends_on_payment_days",
"is_tax_applicable",
"is_income_tax_component",
"deduct_full_tax_on_selected_payroll_date",
"variable_based_on_taxable_salary",
"is_income_tax_component",
"exempted_from_income_tax",
"round_to_the_nearest_integer",
"statistical_component",
Expand Down Expand Up @@ -266,7 +266,7 @@
"icon": "fa fa-flag",
"index_web_pages_for_search": 1,
"links": [],
"modified": "2023-07-31 13:35:37.413696",
"modified": "2023-08-25 13:35:37.413696",
"modified_by": "Administrator",
"module": "Payroll",
"name": "Salary Component",
Expand Down
5 changes: 0 additions & 5 deletions hrms/payroll/doctype/salary_component/salary_component.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,6 @@
class SalaryComponent(Document):
def validate(self):
self.validate_abbr()
self.set_tax_component()

def set_tax_component(self):
if self.is_income_tax_component:
self.variable_based_on_taxable_salary = 1

def on_update(self):
self.invalidate_cache()
Expand Down

0 comments on commit b6989f2

Please sign in to comment.