1. Site contacts and work order contacts now get set on create and write
of all FSM project tasks. If the task has no parent_id, it will try
to set them from the sale order if it has one. Otherwise, they are
simply inherited from the parent.
2. Changing the site or work order contact on a task no longer feeds
back to the sale order.
3. Changing the site or work order contacts on a parent task propagates
the change to its subtasks.
Fixes a problem where the propagate assignment checkbox on project
tasks was not effectively propagating task assignment to descendants.
Also added some intelligence around checking / unchecking the box such
that the setting change propagates to children. This allows for
interesting configurations for assignment propagation, such as limiting
propagation only to one level or only starting it at a given level of
subtasks.
- Got rid of planned_date_begin and planned_date_end fields. Commented
out all related code for now. These were fields pending actual
feature development anyway.
- Added a product cateogory with income account and expense account to
the _generate_product common test method. This fixes an error where
Odoo complained about needing a due date for lines with account type
= 'asset_receivable'.
- Rewrote and refactored Task.action_fsm_validate to have it match with
code from industry_fsm in 16.0.
NOTE: This change depends on code pushed in:
- sale_workflow [16.0 ba7402471]
- odoo_addons [16.0 766cd78]
- PurchasedAddons [16.0 e5e9b7b]
All sale orders containing a line that will produce an FSM task,
i.e. lines that are linked to a product of type service and with
service_tracking set to task_global_project, will be processed
to make sure that all such lines fall under a service visit. If
a visit already exists on the SO but lines are not covered by it,
the visit will be promoted to be the top item on the order before
confirmation. Otherwise, a default visit will be added to the top
of the order prior to proceeding with confirmation.
Added a test to confirm that marking the task associated to a visit
does not create an additional sale order line like it did before.
FixesDur-Pro/bemade-addons#93