[16.0] hr_expense_invoice: duplicated expense journal entry
Opened this issue · 7 comments
Module
hr_expense_invoice
#234
Describe the bug
If i have this expense report:
Journal entries details will be:
So, untaxed amount does not match:
- Journal items = 3.102,60
- Expense report = 1.743,41
To Reproduce
Affected versions: 16
Steps to reproduce the behavior:
- Make a expense report with 2 lines of expense
- Create a vendor invoice of one of them and publish
- "Post Journal Entries" from the expense report
When you introduce a vendor bill, taxes are automatically emptied, so that's the problem. How did you get to have the taxes filled?
I put it to make more clear the error on expense entries -> 3.102,60 - 1.743,41 = 1.359,19
I'm not getting such problem in runboat with just hr_expense_invoice
installed.
Check http://oca-hr-expense-16-0-4e4ed2640742.runboat.odoo-community.org/web?debug=1#id=5&cids=1&menu_id=194&active_id=18&model=hr.expense.sheet&view_type=form (with the DB base-only):
"6000000 Expense" account amount it's wrong, the only difference is the tax: 30,58 * 1,15 = 35,17
Double imputation to expense, without #234 it didn't happen
@SoniaViciana there's no BILL/2024/05/0002 in the DB I'm mentioning (you have to logout and go to the other DB):
The problem that I have reported in this issue is when within a report there are 2 or more expense lines, one with an invoice and the other without.
The test you have done does not represent the reported problem because there is only one expense line.
Do we limit users from being able to include more than one expense line in a report?
OK, I will try that case.