EH HR Payroll Accounting
Post payslips to your ledger as balanced, reversible journal entries.
Why this module
EH HR Payroll Accounting
Entries that balance by construction
Each posted move is built so debits equal credits, whether it comes from per-rule account mapping or the single net expense and payable fallback. The automated tests assert the totals balance on both paths.
One bad slip never breaks the run
Every payslip posts inside its own database savepoint. A locked period or a rejected account.move rolls that one slip back and clears its link so it retries cleanly, while the rest of the confirmations carry on.
Posting is idempotent
A move_id link on the payslip is checked before any posting attempt, so confirming, paying, or pressing the manual button a second time is a no-op. Cancelling a slip reverses its posted entry instead of leaving the ledger out of step.
Day in the life
From payslip to posted ledger entry
You set a general journal on the payslip and either map debit and credit accounts on the salary rules or fill in a fallback expense and payable account. When you confirm the slip, the bridge posts one balanced journal entry: salary expense debited, net payable credited, or a line pair per mapped rule. Paying the slip is a safety net that still posts the move if it was confirmed before accounting was set up. If you cancel a confirmed slip, its posted entry is reversed automatically so the cancellation reaches the ledger. Slips with no journal or accounts are simply skipped, so accounting setup never blocks a pay run.
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.
Each slip posts inside its own cr.savepoint(). A locked fiscal period or a rejected account.move rolls back only that slip and clears its move_id, leaving it in a clean, retryable state without aborting the rest of the confirmations.
The move_id link is checked by every caller before posting. Confirming, paying, or pressing the manual button again creates no second entry. The test suite asserts exactly one move exists per slip after repeated attempts.
Cancelling a slip with a posted entry posts a linked reversal that mirrors the original, so the two net to zero on the ledger. A still-draft move (where posting was deferred) is cancelled instead of reversed.
If salary rules carry no debit and credit accounts, the bridge falls back to a single net expense and payable pair, so it works whether or not the rules are mapped. With mapped rules it builds one internally balanced debit and credit per rule line.
The automatic path silently skips a misconfigured slip so payroll never fails. The manual Post to journal button, which the user pressed deliberately, raises a clear UserError if the journal or accounts are missing.
What is inside
Built to do the job, end to end.
- Adds to the payslip. A general journal field, fallback salary expense and payable account fields, a read-only posted move link, and a reversal move link, all set copy=False so they never carry across a duplicated slip.
- Adds to salary rules. Optional debit account and credit account fields on each salary rule, surfaced on a new Accounting page, so an entry can be split per rule and per category rather than collapsed to a single net pair.
- Lifecycle wiring. Extends action_confirm to create and post the balanced move, action_pay as a post safety net, and action_cancel to reverse it, with a manual Post to journal button on the payslip header for slips already paid.
- Built on. Depends on eh_hr_payroll and the standard Odoo account module. It adds no models of its own; it extends the payslip and salary rule and writes standard account.move records.
Honest about the edges
What this does not do, so nothing surprises you.
- Posts to a general journal only (domain restricted to type general); it does not register bank or cash payments or reconcile the payable.
- Entries use the payslip company currency through the related currency field; there is no multi-currency or per-line currency conversion.
- Reversal runs on cancellation; it does not detect or correct entries edited directly in accounting after posting.
- It does not push payroll cost analytics, analytic distribution, or tax computation into the move beyond the accounts you map.
- It is an optional bridge: with no journal or accounts configured a slip posts nothing, by design, so payroll is never blocked by missing accounting setup.
odoo payroll accounting, payslip journal entry, salary expense payable posting, payroll general ledger odoo, odoo 17 payroll bridge, per rule debit credit account, payroll journal entry odoo community, reverse payslip journal entry, post payslip to accounting, eh hr payroll accounting
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