lase@odoo.com 6a133f736d [FIX] snailmail_account: generate snailmail
Current behavior:

If a customer has no email set, creating an invoice for that
customer and clicking on send and print will not generate a snailmail
for the invoice, even if, the checkbox (checkbox_send_by_post) is True.

Expected behavior:

A snailmail should be sent to the customer.

Steps to reproduce:

Using module_account from saas-16.2 to 17.0.

Create a customer invoice for a customer without email > print and
send > check "By Post" > send and print.

Cause of the issue:

The action action_send_and_print defined in account_move_send.py
filters the moves that trigger a mail creation in the var "success".
This variable filters out all moves without a partner_id.email.
This makes perfect sense for emails but not for snailmails.
However, creations of both types of mails are triggered by the
_hook_if_success method taking "success" as an argument.

Fix:

To allow snailmail creations and correctly trigger email creation,
we filter the moves with a partner email after the _hook_if_success
method and only for email creation, not for snailmails.

opw-3668487

closes odoo/odoo#152506

X-original-commit: b17a2c594aed08248c30842c62d2030de3087b51
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
Signed-off-by: Lancelot Semal (lase) <lase@odoo.com>
2024-02-06 18:49:05 +00:00
2023-11-02 21:02:44 +00:00
2024-02-05 07:24:23 +00:00
…
…
…

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%