EH HR Overtime for Odoo 17
Turn attendance overtime minutes into approved, compensated, audit chained overtime entries.
Why this module
EH HR Overtime for Odoo 17
Overtime comes from real attendance
Entries are generated from the attendance day overtime minutes projection, converting minutes to hours, so the number you approve traces back to recorded time rather than a free typed figure. Manual entry stays available when needed.
One entry per attendance day, enforced
Generation checks for an existing entry before creating, and a unique database constraint on the attendance day guarantees a single overtime record per day even under repeated runs or concurrent calls.
Workflow and audit are not reinvented
Submit, approve, refuse, and mark compensated run on the shared workflow engine. Every create, write, and unlink is captured into the append only hash chained audit log. This module ships no parallel approval or audit code of its own.
Day in the life
From a worked late shift to an approved, compensated line
A late shift lands in attendance with overtime minutes on the day projection. The generate service converts those minutes to hours and creates a single draft overtime entry tagged as auto, linked back to the attendance day. The employee submits it, a manager approves or refuses it, and once paid out or banked as time in lieu it is marked compensated. The compensated hours field shows hours multiplied by the configured multiplier, every state change is tracked in chatter, and each step is written to the hash chained audit log under the owning company.
Edge cases
The cases most modules quietly ignore.
In the shipped code today, each one a place where a cheaper module silently does the wrong thing.
Re generating a date range that already has overtime entries creates nothing new. The service skips any attendance day that already has an entry, and a unique constraint on attendance_day_id backs the guarantee at the database level.
The unique(attendance_day_id) constraint makes a second auto entry for the same day impossible, so concurrent generation runs cannot race a duplicate into existence.
A CHECK (hours >= 0) constraint rejects negative overtime at the database level, whether the value arrives from generation or manual entry.
Compensated and refused are marked final. The workflow engine refuses any further transition out of a final state, even one a misconfigured definition might declare, so a closed entry cannot be reopened by a stray button.
Submit is limited to self service employees, while approve, refuse, and mark compensated require the HR manager group. A user outside the allowed groups is refused the transition with a clear error.
The company aware mixin defaults each entry to the active company, requires it, and refuses any create or write that points the record at a company the user does not belong to.
Every create, write, and unlink emits a sha256 hash chained row to the append only audit log, where each row binds to the previous one so a silent edit breaks the chain.
Reference numbers come from a dated sequence. If the sequence cannot yield a value the create still completes under a deterministic fallback reference rather than failing.
What is inside
Built to do the job, end to end.
- Overtime entry model. eh.hr.overtime carries employee, date, hours, source, the linked attendance day, multiplier, compensation type, reason, and a stored computed compensated hours equal to hours times multiplier. It composes the workflow, audited, and company aware mixins plus mail thread for chatter.
- Generation service. The eh.hr.overtime.generate service scans the attendance day projection over a date range for positive overtime minutes, converts to hours, and creates one auto entry per day, skipping days that already have one. Company can be passed to scope the run.
- Four step workflow. A shipped workflow definition wires draft, submitted, approved, compensated, and refused states with submit, approve, refuse, and complete transitions, each gated to the right HR group, with compensated and refused marked final.
- Security and views. Access rules cover HR admin, manager, and self service employee. A list and form view with a status bar and transition buttons, a top level menu, a dated sequence, and a post install test suite covering compute, transitions, and idempotent generation are included.
Honest about the edges
What this does not do, so nothing surprises you.
- Generation runs through the service API and is not driven by a scheduled cron in this module. There is no shipped ir.cron that calls it automatically, so you trigger generation from your own action or job.
- Requires the EH HR Platform. It depends on eh_hr_core, eh_hr_compat, eh_hr_engine_workflow, and eh_hr_attendance_pro, and will not function standalone.
- This module does not post overtime to payroll or to time off allocations. It records hours, a multiplier, and a paid or time in lieu intent, leaving payout and leave accrual to your payroll or leave configuration.
- Transitions are gated by group membership only. There is no separate self approval block, so a user who holds the HR manager group can approve overtime they submitted.
- The multiplier defaults to 1.5 and is a single editable value per entry. The module does not apply tiered or weekday versus weekend multiplier rules automatically.
- Auto generation reads the overtime minutes already computed on the attendance day projection. It does not itself calculate thresholds; those are owned by attendance policy.
odoo 17 overtime, overtime management odoo, overtime approval workflow, attendance overtime odoo, time off in lieu odoo, TOIL odoo, overtime multiplier, HR overtime tracking, payroll overtime hours, multi company overtime, overtime audit trail, odoo HR platform overtime, compensated hours odoo, overtime from attendance
Need this fitted to the way you work?
ERP Heritage delivers end to end Odoo work: Odoo Implementation, Customization and Development, Integration, Migration, Consultation, Support and Training. We help teams put this module into production, shape it to their process, and keep it running.
We work with businesses across Australia (Melbourne, Sydney, Brisbane, Perth, Adelaide, Canberra) and the Middle East (Dubai, Abu Dhabi, Riyadh, Jeddah, Doha, Kuwait City, Muscat). Start a conversation at erpheritage.com.au or email info@erpheritage.com.au.
Languages
Available in 19 languages
The interface ships translated out of the box. Switch language in Odoo and the fields, menus, and messages follow.
Please log in to comment on this module