Denis Ledoux e331d96412 [FIX] web: FormView: ensure defaultFields to fields
Since [1], a call to getView no longer returns the all models the
list of all their fields, because a lot of them aren't necessary.

However, it caused an issue in the following situation:
    - have a form view with an x2many displayed as a list
    - in the list, have a field using the widget many2many_tags
      along the color_field option
    - in the arch, the x2many form view isn't inline
      list must be present, without the color_field option,
      and the color field must not be present,
    - in readonly mode, the user clicks on a row, which will open
    the x2many form view
    - since the form view isn't inline, a call to getView is done
    - in the returned form view, the color field isn't present,
      the field using many2many_tags/color_field in the
      list is present, and without the color_field option.

Since [1], it crashed at this point because A wasn't part of the
known fields in the form view (but it was in the fieldsInfo,
since they are shared between the x2many list and form).

This commit fixes the issue by adding the color field not only
in fieldsInfo, but also in fields.

[1] odoo/odoo@4636620004

closes odoo/odoo#100479

Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
2022-09-19 13:20:48 +02:00
…
2022-09-09 11:12:25 +02: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%