Hello Odoo Community,
I'm facing an issue with the subscription module in Odoo. When I validate a subscription quotation with a recurrence of 2 months, I can immediately create the first invoice. However, when the recurrence is set to 36 months, I can't create the initial invoice right away.
Upon attempting, I'm getting the following error message:
"There's nothing to invoice!"
The reasons for this behavior can be:
- You need to deliver your products before invoicing them.
- You need to adjust your product's invoicing policy: Open the product, navigate to the "Sales" tab, and switch the invoicing policy from "delivered quantities" to "ordered quantities". For services, you should change the service invoicing policy to 'Prepaid'.
- You must wait until the end of the current subscription period. New quantities ready for invoicing will be available at the end of the ongoing period. Negative recurring lines are deemed to be free.
I've inspected the code, especially the _create_recurring_invoice and action_invoice_subscription methods, but I can't pinpoint where this distinction is made based on the recurrence period.
Has anyone encountered this issue or could guide me on where to look in the code or configurations?
Thank you in advance for your assistance!