[FIX] web: add 'no_edit_color' option to many2many_tags

This option, if set to True, prevents the user from modifying the
color of the tags.

Part of task 2070454

closes odoo/odoo#38848

X-original-commit: a62b65a8f9114493064d4efae92825814a880c04
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
This commit is contained in:
Quentin Nicolay
2019-10-16 08:26:10 +00:00
committed by fw-bot
parent 644663eb4a
commit d59b67a915
3 changed files with 32 additions and 0 deletions
+6
View File
@@ -2131,6 +2131,12 @@ Relational fields
<field name="category_id" widget="many2many_tags" options="{'color_field': 'color'}"/>
- no_edit_color: set to True to remove the possibility to change the color of the tags (default: False).
.. code-block:: xml
<field name="category_id" widget="many2many_tags" options="{'color_field': 'color', 'no_edit_color': True}"/>
- form.many2many_tags (FormFieldMany2ManyTags)
Specialization of many2many_tags widget for form views. It has some extra
code to allow editing the color of a tag.