From f576c570c99a86f53875f03ef2ec003342177694 Mon Sep 17 00:00:00 2001 From: Ranjith Kurungadam Date: Mon, 4 Jun 2018 12:53:23 +0530 Subject: [PATCH] Salary Slip - fix when no pyroll period found for tax calc (#14335) --- erpnext/hr/doctype/salary_slip/salary_slip.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/hr/doctype/salary_slip/salary_slip.py b/erpnext/hr/doctype/salary_slip/salary_slip.py index ace962852f..24ecf26a66 100644 --- a/erpnext/hr/doctype/salary_slip/salary_slip.py +++ b/erpnext/hr/doctype/salary_slip/salary_slip.py @@ -501,7 +501,7 @@ class SalarySlip(TransactionBase): if not payroll_period: frappe.msgprint(_("Start and end dates not in a valid Payroll Period, \ cannot calculate {0}.").format(tax_component)) - return + return False, False if self.deduct_tax_for_unclaimed_employee_benefits and not self.deduct_tax_for_unsubmitted_tax_exemption_proof: total_taxable_benefit = self.calculate_unclaimed_benefit_amount(payroll_period) total_taxable_benefit += self.get_taxable_earnings(only_flexi=True)