Skip to content

[19.0][MIG] hr_expense_employee_payment#362

Open
Shide wants to merge 3 commits into
OCA:19.0from
moduon:19.0-mig-hr_expense_employee_payment
Open

[19.0][MIG] hr_expense_employee_payment#362
Shide wants to merge 3 commits into
OCA:19.0from
moduon:19.0-mig-hr_expense_employee_payment

Conversation

@Shide

@Shide Shide commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Complete refactor because hr expense sheet doesn't exists in v19 and payment flow has been changed too.

https://www.loom.com/share/501d770824e345089396de3f7ae4c931

MT-14678 @moduon @yajo @EmilioPascual @fcvalgar @Gelojr @chienandalu please review if you want 😄

@OCA-git-bot OCA-git-bot added series:19.0 mod:hr_expense_employee_payment Module hr_expense_employee_payment labels Jun 10, 2026
@Shide Shide force-pushed the 19.0-mig-hr_expense_employee_payment branch from 7e1d01c to dd4a42f Compare June 11, 2026 06:57
Adding this field prepares this module to an easy migration process
@Shide Shide force-pushed the 19.0-mig-hr_expense_employee_payment branch from dd4a42f to dbc0be5 Compare June 11, 2026 08:24

@fcvalgar fcvalgar left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the work on this module @Shide . I reviewed the employee-paid expense flows, but I cannot approve it yet because the payment flow is blocked by a validation error in the Purchase Receipt case. When trying to pay a posted employee expense generated as a Purchase Receipt, Odoo raises: “Missing required value for the field ‘Date’ (date). Model: Journal Entry (account.move)”. If Purchase Receipts are not meant to be supported by this module, the flow should be clearly excluded or controlled to avoid this technical error.

Test 1: OK - An employee-paid expense can be created, submitted, approved and posted as a Vendor Bill.
Test 2: OK - The payment flow for an employee-paid expense generated as a Vendor Bill can be completed and the employee reimbursement flow works as expected.
Test 3: OK - The conciliation entry is created and linked to the expense in the Vendor Bill flow.
Test 4: OK - Partial payment support works correctly in the Vendor Bill flow.
Test 5: Not OK - Registering the payment from an employee-paid expense generated as a Purchase Receipt fails with a validation error because the generated journal entry has no Date.
Test 6: Not OK - The conciliation/payment flow for Purchase Receipts cannot be validated because the payment action is blocked by the Date validation error.

Please review the payment/conciliation move creation for the Purchase Receipt flow, or explicitly prevent/control this case if it is outside the intended scope. Once this is fixed or clarified, I can retest the affected flow.

Image

@Gelojr Gelojr left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A review is required before this PR can be approved. At this stage, I cannot approve the PR because the main payment flow is not working as expected.

The following tests have been performed:

  • Test 1: Intermediate Expense Journal Configuration - Verified that Employee Expense Journal and Employee Expense Intermediate Journal can be configured successfully. OK
  • Test 2: Expense Creation and Approval Flow - Verified that an employee-paid expense can be created, submitted and approved successfully. OK
  • Test 3: Employee Expense Payment Flow - NOK. After configuring "Employee Expense Journal" and "Employee Expense Intermediate Journal" (using "Miscellaneous Operations" as the intermediate journal), an expense was created, submitted and approved successfully. The purchase receipt was generated correctly, but when attempting to proceed with the payment flow, Odoo displayed a warning indicating that the operation could not be completed.

Please review Test 3: Employee Expense Payment Flow.

Steps to reproduce:

  1. Configure an Employee Expense Journal.
  2. Configure an Employee Expense Intermediate Journal using a Miscellaneous Operations journal.
  3. Create an expense paid by the employee.
  4. Submit and approve the expense.
  5. Generate the purchase receipt through the standard expense workflow.
  6. Attempt to proceed with the payment process.
  7. Odoo displays a warning indicating that the operation cannot be completed as just like @fcvalgar
Image

@yajo yajo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review.

@Shide Shide force-pushed the 19.0-mig-hr_expense_employee_payment branch from dbc0be5 to eae1a5a Compare June 18, 2026 07:52
@Shide Shide requested review from Gelojr and fcvalgar June 18, 2026 07:52

@fcvalgar fcvalgar left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you @Shide @yajo

Test 5: OK - Registering the payment from an employee-paid expense generated as a Purchase Receipt fails with a validation error because the generated journal entry has no Date.
Test 6: OK - The conciliation/payment flow for Purchase Receipts cannot be validated because the payment action is blocked by the Date validation error.

@BhaveshHeliconia BhaveshHeliconia left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

mod:hr_expense_employee_payment Module hr_expense_employee_payment series:19.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants