Hibou Odoo Suite: Human Resources (HR) Modules: HR Payroll Payment

Purpose

This documentation outlines the processes associated with Hibou's Payroll Payments module for Odoo 16. Payroll Payments adds the ability to register payments on Payroll Payslips.

Process

First thing's first, we need to install the module! Navigate to the Apps application.


Once there, remove the 'Apps' filter, then search for 'Payroll Payments'. When ready, click ACTIVATE .


Good to Know!

This module requires both the Payroll Accounting and Payment Acquirer modules. However, if you do not already have these modules  installed, Odoo will install them for you during this module's installation!


Getting Started

To get started, navigate to the Payroll app.


Registering a Payment on an Employee Payslip

Once there, go to Payslips  > to Pay, then select a payslip from the list.



Compute Sheet + Create Draft Payment

If you see the REGISTER PAYMENT button, skip to the next step. Otherwise, click COMPUTE SHEET



Once the sheet has been computed, you'll see the amounts and totals under the SALARY COMPUTATION tab. This will display any Payroll Rules that apply to the employee being paid, which is determined by Payroll Form set on the Employee Contract. You can then click CREATE DRAFT ENTRY



Register Payment

Next, click the MARK AS PAID button, which was added by this module.


Technical

This module adds a new HR Payroll Register Payment Wizard transient model with the following fields:

  • `partner_id` Many2one field for the Partner

  • `journal_id` Many2one field for the Payment Method

  • `company_id` Many2one field for the Company (related to the journals company_id)

  • `payment_method_id` Many2one field for the Payment Type

  • `payment_method_code` Char field (related to the `payment_method_id.code`)

  • `payment_trasaction_id` Many2one field for the saved payment token

  • `payment_token_id` Many2one field for the Saved payment token

  • `amount` Monetary field for the Payment Amount

  • `currency_id` Many2one field for the Currency, defaults to the user's company's currency

  • `payment_date` Date field for the Payment date, defaults to the current date

  • `communication` Char field for the Memo

  • `hide_payment_method` computed Boolean field that hides the payment method if the selected journal has only one available (Manual)

The `payroll_post_payment` Wizard method create's a payment with the fields and posts it. Then it looks up the payable account move lines and reconciles the payment and payroll.

Additionally, there is an action button added to the Payslip Form view that brings up the HR Payroll Register Payment Wizard form view, with all new fields necessary for creating the payment.

The `hr.payslip` model receives a new computed Boolean field `is_paid` that checks if it is payable and has been reconciled. This field is added to the Payslip filter view to easily find payslips that still require payment as well as the Payslip Form view.