odoo/tutorials#885
Created by Rohit Varshney (rvar)
Blocked
- Merge method
- Review
-
CI
- ci/style: (runtime 2s)
- ci/tutorial: (runtime 79s)
- label
- odoo-dev:18.0-automated_email_action-rvar
- head
- 90f9b11765cf391d89ca1571aaff6388d2b197f3
odoo/tutorials | |
---|---|
18.0 | #885 missing r+ |
master |
[ADD] auto_invoice_email: Auto-send posted invoices older than configured days
The motivation behind this PR:
- To automate the process of sending posted invoices via email for all invoices older than a configurable number of days. This ensures timely communication with customers without requiring manual intervention.
The behavior before this PR:
- Only invoices with an exact invoice_date
equal to today's date minus the configured number of days (= target_date
) were selected. Older invoices were skipped, even if they were still unsent.
The desired behavior after this PR:
- Now, the system selects all posted invoices where invoice_date
is less than the calculated target_date
, allowing pending older invoices to be sent automatically via the scheduled cron job.