fix(Payroll): no need to set abbr specially in Salary Slip (#25877)

This commit is contained in:
Sagar Vora 2021-06-01 19:57:17 +05:30 committed by GitHub
parent 5b17f335d1
commit eff8f6fe34
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -621,16 +621,13 @@ class SalarySlip(TransactionBase):
component_row = self.append(component_type)
for attr in (
'depends_on_payment_days', 'salary_component',
'depends_on_payment_days', 'salary_component', 'abbr',
'do_not_include_in_total', 'is_tax_applicable',
'is_flexible_benefit', 'variable_based_on_taxable_salary',
'exempted_from_income_tax'
):
component_row.set(attr, component_data.get(attr))
abbr = component_data.get('abbr') or component_data.get('salary_component_abbr')
component_row.set('abbr', abbr)
if additional_salary:
component_row.default_amount = 0
component_row.additional_amount = amount