Human Resources mailing list archives

hr@odoo-community.org

Avatar

Re: [OCA/hr] [12.0][ADD] hr_holidays_accrual: Advanced accrual leave allocations (#501)

by Alexey Pelykh <notifications@github.com> - 26/03/2019 21:04:18

@alexey-pelykh commented on this pull request.


In hr_holidays_accrual/models/hr_leave_allocation.py:

> +
+            date_from += period
+
+        if (self.limit_accumulated_days
+                and balance > self.max_accumulated_days):
+            loss = self.max_accumulated_days - balance
+            accruements.append(HrLeaveAllocationAccruementEntry(
+                days_accrued=loss,
+                accrued_on=date_to.date(),
+                reason=_('Loss due to accumulation limit')
+            ))
+            balance += loss
+
+        number_of_days = balance + total_leave_days
+        _logger.info(
+            '%s days of "%s" leave allocated to employee "%s"',

day(s), leave is singular due to type


You are receiving this because you are on a team that was mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.