The account_invoice_defer module is not compatible with the analytic_invoice module
- Create an environment with the account_invoice_defer module (and its requirements)
- Install the analytic_invoice module (and its requirements)
- Configure the environment (Fiscal Years, Journals, Payment Methods, etc.).
- For this test, i used this analytic account structure:
Analytic Account Root
|-> Analytic Account View 1
| |-> Analytic Account Normal 1
| |-> Analytic Account Normal 2
|-> Analytic Account View 2
| |-> Analytic Account Normal 3
| |-> Analytic Account Normal 4
- Create the party "Supplier Party"
- Create the product "Light": -Default UOM: Unit -Type: Service
- Create a supplier invoice where the party is "Supplier Party" and with one line with the product "Light"
- In this invoice line go to Analytic page, there has to be one Analytic Account where the Root Analytic will be "Analytic Account Root"
- In the analytic line from the previous point, add the account "Analytic Account Normal 1"
- Paid this invoice
- Now, go to the menu "Supplier Invoices Deferred"
- Create a Deferred Invoice
- Add the Invoice Line from the supplier party
- In "Start date", set the date of today (in this case 10/03/22)
- In "End date", set the date of tomorrow (in this case 11/03/22)
- Execute the Deferred Invoice
- Now if we check the lines from the moves created, we can see that any of them have analytic accounts
We need to have the same analytic accounts from the invoice line, following the example of the account_asset module, i added the account_invoice_defer extra depends to the analytic_invoice module, and copy the Analytic Accounts from the invoice line to the account moves lines with the same account.