- Fix: partners can no longer have default carrier accounts that are
archived.
- Refactor: remove write/create overrides to replace them with
computed/stored fields.
Fixes a bug where sale orders with a partner_shipping_id not within the
same commercial entity as their partner_id could not have collect
carrier accounts set after being confirmed.
The issue stemmed from the fact that the sale order's recipient_id field
was being set to partner_id, while the created delivery order had
recipient_id set to its partner_id, which is the partner_shipping_id of
the sale order. In other words, the sale order recipient was incorrectly
set to the main partner instead of the shipping address.
This commit adds a test that was previously failing in this scenario. It
also properly sets the recipient_id on the transport selection wizard
and on sale orders themselves, fixing the issue.
- Disable sending of notification emails when events are created or updated
in Odoo during a CalDAV server synchronization.
- General code cleanup with improved type hints.
Prior to this fix, the organizer on events was being incorrectly set to
the database's admin user in some cases, when synchronizing an event
from the CalDAV server.
* Fixed an issue where accepting events from an external organizer would send emails
to the all event attendees upon synchronization.
* Corrected the data model for events where multiple Odoo users are attendees for the
same event. Now, only one event is created in Odoo, with all the attendees on the
same event. This conforms to Odoo's existing calendar event data model.
* Updated the setting of the organizer field (user_id) on the calendar events upon
synchronization. Previously, the organizer field was always set to the current user
whose events were being synchronized. Now, it is set based on the ORGANIZER parameter
of the iCalendar event, if present. If not present, it defaults to the current synchronizing
user. In the case that the organizer is external, the user_id field is left blank.
Prior to this commit, subtasks that were added (from task templates) as
part of a visit (from sales orders), were having their partner_id set to
False by a built-in Odoo _compute_partner_id method.
This fix (and previous commits) introduce a test that correctly failed
when this behaviour was broken as well as modifications to the behaviour
of sale order lines and tasks to ensure that all tasks created from a
sale order for an FSM project correctly get their partner_id set to the
sale order's delivery address.
* Fixed an issue where accepting events from an external organizer would send emails
to the all event attendees upon synchronization.
* Corrected the data model for events where multiple Odoo users are attendees for the
same event. Now, only one event is created in Odoo, with all the attendees on the
same event. This conforms to Odoo's existing calendar event data model.
* Updated the setting of the organizer field (user_id) on the calendar events upon
synchronization. Previously, the organizer field was always set to the current user
whose events were being synchronized. Now, it is set based on the ORGANIZER parameter
of the iCalendar event, if present. If not present, it defaults to the current synchronizing
user. In the case that the organizer is external, the user_id field is left blank.