TIP: You can type at any time to perform a new search.
Leave Accruals
hr_leave_accruals · OCA/hr
Security findings
Migration considerations
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.tools` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.tools.translate` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- Imports from the old `openerp.osv` namespace: renamed to `odoo` since Odoo 10.0. migration-openerp-import · source
- For a target of Odoo 10.0+: use the `__manifest__.py` manifest name instead of `__openerp__.py`. The filename alone does not establish module age or compatibility. migration-openerp-manifest · source
hr_employee— Class 'hr_employee' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_employee— Class 'hr_employee' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_holidays— Class 'hr_holidays' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_holidays— Class 'hr_holidays' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_holidays_status— Class 'hr_holidays_status' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_holidays_status— Class 'hr_holidays_status' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_holidays_status_accrual_line— Class 'hr_holidays_status_accrual_line' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_holidays_status_accrual_line— Class 'hr_holidays_status_accrual_line' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_holidays_status_accrual_line— Class 'hr_holidays_status_accrual_line' declares `_defaults` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_leave_accrual— Class 'hr_leave_accrual' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_leave_accrual— Class 'hr_leave_accrual' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_leave_accrual_line— Class 'hr_leave_accrual_line' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_leave_accrual_line— Class 'hr_leave_accrual_line' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_leave_accrual_line— Class 'hr_leave_accrual_line' declares `_defaults` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourcehr_payslip— Class 'hr_payslip' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourcehr_payslip— Class 'hr_payslip' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourceres_company— Class 'res_company' still inherits from the old-style `orm.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourceres_company— Class 'res_company' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourceres_company— Class 'res_company' declares `_defaults` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourceview_leave_accrual_form— For a target of Odoo 17.0+: view 'view_leave_accrual_form' uses `attrs=`/`states=`, which are no longer supported. Convert modifiers to direct Python boolean expressions in `invisible`/`readonly`/`required`; preserve the original AND/OR logic. migration-view-attrs-states · sourceview_leave_accrual_tree— View 'view_leave_accrual_tree' is defined with a `<tree>` root tag: renamed to `<list>` in Odoo 18.0. migration-view-tree-tag · source
Migration review checklist, not a compatibility verdict. No target version is selected: apply version-specific advice only when migrating to that version or later.
- Repository
- OCA/hr · module folder · Try on Runboat
- Module version
- 1.0
- Category
- Generic Modules/Human Resources
- Folder size
- 0.4 MB
- License
- AGPL-3
- Application
- No
- Auto-installable
- No
- Website
- https://www.savoirfairelinux.com/
- Last tracking update
- 2026-08-07 06:56:12
- Authors
- Savoir-faire Linux, Odoo Community Association (OCA)
- Maintainers
- Savoir-faire Linux, Odoo Community Association (OCA)
- Committers
- Alexandre Fayolle, OCA Transbot, dufresnedavid
- Odoo dependencies
- Python dependencies
- None
- System dependencies
- None
- Required by
- None
- Description
Leave Accruals ============== This module adds leave accruals on employees and a mechanism to compute these automaticaly. Contributors ------------ * David Dufresne <david.dufresne@savoirfairelinux.com> * Pierre Lamarche <pierre.lamarche@savoirfairelinux.com>
Code Analysis
Views touched (6)
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
view holidays_status_form |
hr.holidays.status.form | hr.holidays.status | form | Inherits hr_holidays.edit_holiday_status_form |
view_company_form |
res.company.form | res.company | form | Inherits base.view_company_form |
view_employee_form |
hr.employee.form | hr.employee | form | Inherits hr.view_employee_form |
view_hr_leave_accrual_filter |
hr.leave.accrual.select | hr.leave.accrual | search | New |
view_leave_accrual_form |
hr.leave.accrual.form | hr.leave.accrual | form | New |
view_leave_accrual_tree |
hr.leave.accrual.tree | hr.leave.accrual | tree | New |
HTTP endpoints (0)
No HTTP endpoints found for this module.
Models touched (8)
New fields (0)
No new fields.
Public methods (1)-
get_leave_accrual_id(self, cr, uid, employee_id, accrual_code=False, leave_type_id=False, context=None)Get a leave accrual of an employee that matches a leave_code :return: the id of a leave accrual
New fields (0)
No new fields.
Public methods (2)-
holidays_refuse(self, cr, uid, ids, context=None)After an allocation of holidays is refused, remove the leave accrual line related -
holidays_validate(self, cr, uid, ids, context=None)After an allocation of holidays is validated, add hours to the related leave accrual of the employee
New fields (0)
No new fields.
Public methods (0)No public methods.
New fields (0)
No new fields.
Public methods (0)No public methods.
New fields (0)
No new fields.
Public methods (0)No public methods.
New fields (0)
No new fields.
Public methods (0)No public methods.
New fields (0)
No new fields.
Public methods (2)-
compute_leave_accrual_lines(self, cr, uid, ids, context=None)Update an employee's leave accruals with the amounts computed in the payslip. -
compute_sheet(self, cr, uid, ids, context=None)
New fields (0)
No new fields.
Public methods (0)No public methods.