mirror of
https://github.com/frappe/erpnext.git
synced 2026-04-03 12:18:46 +02:00
fix: validate working day list against holidays
This commit is contained in:
@@ -326,6 +326,8 @@ class SalarySlip(TransactionBase):
|
|||||||
|
|
||||||
if not cint(include_holidays_in_total_working_days):
|
if not cint(include_holidays_in_total_working_days):
|
||||||
working_days -= len(holidays)
|
working_days -= len(holidays)
|
||||||
|
working_days_list = [cstr(day) for day in working_days_list if cstr(day) not in holidays]
|
||||||
|
|
||||||
if working_days < 0:
|
if working_days < 0:
|
||||||
frappe.throw(_("There are more holidays than working days this month."))
|
frappe.throw(_("There are more holidays than working days this month."))
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user