Thursday, February 29, 2024
3 changes · saas-17.1
Enhancements to existing features
This update enhances how Odoo generates PDF reports by creating attachments more efficiently. Previously, attachment values needed to be manually overridden for some reports. This change introduces a new process to prepare these attachment values during PDF generation, ensuring consistent and accurate attachment creation without altering the core report functionality.
Original PR description
Description of the issue/feature this PR addresses: Previously, an `ir_actions_report` refactor landed on: - [ ] https://github.com/odoo/odoo/pull/85150 It totally makes sense to create `ir.attachment` from the streams if needed during PDF generation. For some of the projects we still need to override attachment values. This PR provides a hook to prepare attachment values needed for attachments creation during the pdf report generation. Nothing changes in the sense of business logic. Ping @smetl @xmo-odoo --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#153086 Forward-Port-Of: odoo/odoo#138159
This update makes it easier for developers to customize how clicks are handled within the Odoo dropdown menu. Previously, changes required extensive modifications, but now a simpler approach allows for quicker and more efficient updates. This improves the overall flexibility and maintainability of the Odoo web interface.
Original PR description
With this commit, overriding the `onWindowClick` function from `dropdown.js` becomes much simpler. Previously, it necessitated overriding the entire function, but now it can be done with minimal effort by just overriding this specific part. task-3717014 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#155326 Forward-Port-Of: odoo/odoo#154315
This update enhances the testing of Odoo's email functionality, specifically focusing on how event attendee emails are sent in batches. The changes include new tests for batch email sending, improved test setup for event scheduling, and added checks for registration emails. These improvements ensure more reliable email delivery and scalability.
Original PR description
PURPOSE Mail: add tests for MailTemplate send_mail Several flows use MailTemplate.send_mail() in batch, notably event email scheduler which sends emails to event attendee in batch. This commit adds…
PURPOSE
Mail: add tests for MailTemplate send_mail
Several flows use MailTemplate.send_mail() in batch, notably event email
scheduler which sends emails to event attendee in batch. This commit adds
tests around 'send_mail' method of MailTemplate model
* add tests for batch: it is currently not supported hence using a loop but
batch is going to be added soon, allowing to test the batch version works
as intended;
* add query counters, notably for batch mode and when dynamic reports are
involved in templates;
Event: improve mail scheduler tests
Make them easier to improve and modify
* use a dedicated setup (allowing to add specific unit tests on test data);
* move initial asserts into its own unit test (to keep other tests shorter);
* use available mocks for freezetime and sql.now;
Then add tests for registration emails, to check what happens for communication
scheduled right at registration time.
LINKS
Part of Task-3764894: Event: Allow using cron triggers for communication
Part of Task-3764891: Mail: Batch-ize MailTemplate send_mail
Part of Task-3164278: Mail: Batch send: ensure limit, avoid force
Part of Task-3084943: Event: Improve communication scheduler scalability
Forward-Port-Of: odoo/odoo#155717