be9f264011363565333f450d7601e2bafea3c409
Adds basic support to filter possible m2x values based on another record. This is necessary for the website_appointment snippet introduced within this bundle (see related ENT PR). An important need implemented here is to not store a list of valid IDs in the DOM but fetch them based on data stored by a different widget. Use case covered: Model A has a Many2Many relationship with Model B via a `model_b_ids` field. A first widget (Wa) on a snippet's options allows to select a record of Model A. A second widget (Wb) allows to select records of Model B. ```xml <!--Widget A--> <we-many2many data-model="model.a" data-m2o-field="name" data-fakem2m="true".../> <!--Widget B--> <we-many2many data-model="model.a" data-m2o-field="model_b_ids" data-filter-in="true" .../> ``` Before this commit, the second widget would only be able to show all records of Model B linked to any Model A record and matching a static domain provided as attribute, which is still supported. This commit allows, after having selected `record_a` in the first widget, to only populate the second widget with the records of Model B that are in `record_a.model_b_ids`. Implementing this is done by * Adding `data-filter-in` to Wb's xml attributes (as above) * Calling `Wb.setFilterInDomainIds()` when another record is selected in Wa. Task-2574175 odoo/odoo#90748 See odoo/enterprise#23750 Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
…
…
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
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%