Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
c366347
[14.0] web_m2x_options_manager: New module to manage create/edit opti…
SilvioC2C Aug 2, 2021
4e15935
[UPD] Update web_m2x_options_manager.pot
oca-travis Oct 14, 2021
6816166
[UPD] README.rst
OCA-git-bot Oct 14, 2021
f537a78
[UPD] web_m2x_options_manager: Add option to prevent Create/Edit wiza…
yankinmax Oct 18, 2021
1c718b0
[UPD] Update web_m2x_options_manager.pot
oca-travis Oct 22, 2021
c313015
web_m2x_options_manager 14.0.1.1.0
OCA-git-bot Oct 22, 2021
8bc886c
Added translation using Weblate (Italian)
francesco-ooops Mar 21, 2023
170129c
Translated using Weblate (Italian)
francesco-ooops Mar 21, 2023
9241701
[UPD] README.rst
OCA-git-bot Sep 3, 2023
3e95785
Update translation files
weblate Oct 9, 2023
226b795
[FIX] all: fix pre-commit new checks
HekkiMelody Oct 30, 2023
d3e660c
[UPD] Update web_m2x_options_manager.pot
Oct 30, 2023
dc5b48d
[BOT] post-merge updates
OCA-git-bot Oct 30, 2023
e4b87db
Update translation files
weblate Oct 30, 2023
57472af
Translated using Weblate (Italian)
mymage Jan 16, 2025
f90f88e
[FIX] web_m2x_options_manager: writing mode when create/edit wizard i…
Chionne27 Apr 9, 2025
77c75fc
[BOT] post-merge updates
OCA-git-bot Apr 14, 2025
9408dcc
[IMP] web_m2x_options_manager: pre-commit auto fixes
SilvioC2C Nov 6, 2025
35a613a
[MIG] web_m2x_options_manager: Migration to 17.0
SilvioC2C Nov 6, 2025
03ffa22
[UPD] Update web_m2x_options_manager.pot
Nov 18, 2025
47b653b
[BOT] post-merge updates
OCA-git-bot Nov 18, 2025
c799fa1
[IMP] web_m2x_options_manager: pre-commit auto fixes
SilvioC2C Nov 20, 2025
936c959
[MIG] web_m2x_options_manager: Migration to 18.0
SilvioC2C Nov 20, 2025
c749d88
Merge PR #3361 into 18.0
OCA-git-bot Nov 21, 2025
b2b8746
[UPD] Update web_m2x_options_manager.pot
Nov 21, 2025
c729a3b
[BOT] post-merge updates
OCA-git-bot Nov 21, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ addon | version | maintainers | summary
[web_ir_actions_act_multi](web_ir_actions_act_multi/) | 18.0.1.0.0 | | Enables triggering of more than one action on ActionManager
[web_ir_actions_act_window_message](web_ir_actions_act_window_message/) | 18.0.1.0.1 | | Show a message box to users
[web_m2x_options](web_m2x_options/) | 18.0.1.0.1 | | web_m2x_options
[web_m2x_options_manager](web_m2x_options_manager/) | 18.0.1.0.0 | | Adds an interface to manage the "Create" and "Create and Edit" options for specific models and fields.
[web_no_bubble](web_no_bubble/) | 18.0.1.0.0 | | Remove the bubbles from the web interface
[web_notify](web_notify/) | 18.0.1.1.1 | | Send notification messages to user
[web_notify_channel_message](web_notify_channel_message/) | 18.0.1.0.1 | | Send an instant notification to channel users when a new message is posted
Expand Down
3 changes: 2 additions & 1 deletion setup/_metapackage/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "odoo-addons-oca-web"
version = "18.0.20251117.0"
version = "18.0.20251121.0"
dependencies = [
"odoo-addon-web_calendar_slot_duration==18.0.*",
"odoo-addon-web_chatter_position==18.0.*",
Expand All @@ -20,6 +20,7 @@ dependencies = [
"odoo-addon-web_ir_actions_act_multi==18.0.*",
"odoo-addon-web_ir_actions_act_window_message==18.0.*",
"odoo-addon-web_m2x_options==18.0.*",
"odoo-addon-web_m2x_options_manager==18.0.*",
"odoo-addon-web_no_bubble==18.0.*",
"odoo-addon-web_notify==18.0.*",
"odoo-addon-web_notify_channel_message==18.0.*",
Expand Down
1 change: 1 addition & 0 deletions test-requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
odoo_test_helper
102 changes: 102 additions & 0 deletions web_m2x_options_manager/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

=======================
Web M2X Options Manager
=======================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:eef4fc342b7a72c18d973d245be784f04f46ae4eea4de8db676b961608a80a38
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/license-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fweb-lightgray.png?logo=github
:target: https://github.com/OCA/web/tree/18.0/web_m2x_options_manager
:alt: OCA/web
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/web-18-0/web-18-0-web_m2x_options_manager
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/web&target_branch=18.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

Allows managing the "Create..." and "Create and Edit..." options for
``Many2one`` and ``Many2many`` fields directly from the ``ir.model``
form view.

**Table of contents**

.. contents::
:local:

Usage
=====

Go to Settings > Technical > Models.

Choose the model you wish to edit, and open its form view. Go to the
"Create/Edit Options" tab, and add the fields you want to manage in 2
different sections:

- the first list view allows you to handle fields for the selected model
- the second list view allows you to handle fields where the selected
model is the comodel

For both sections:

- button "Fill" will add every missing field to the options
- button "Empty" will remove every option

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/web/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/web/issues/new?body=module:%20web_m2x_options_manager%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
-------

* Camptocamp

Contributors
------------

- `Camptocamp <https://www.camptocamp.com>`__:

- Silvio Gregorini

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

This module is part of the `OCA/web <https://github.com/OCA/web/tree/18.0/web_m2x_options_manager>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
2 changes: 2 additions & 0 deletions web_m2x_options_manager/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
from . import models
from .hooks import pre_init_hook
30 changes: 30 additions & 0 deletions web_m2x_options_manager/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Copyright 2021 Camptocamp SA
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

{
"name": "Web M2X Options Manager",
"summary": 'Adds an interface to manage the "Create" and'
' "Create and Edit" options for specific models and'
" fields.",
"version": "18.0.1.0.0",
"author": "Camptocamp, Odoo Community Association (OCA)",
"license": "AGPL-3",
"category": "Web",
"data": [
"security/ir.model.access.csv",
"views/ir_model.xml",
"views/m2x_create_edit_option.xml",
],
"demo": [
"demo/res_partner_demo_view.xml",
],
"depends": [
# OCA/server-tools
"base_view_inheritance_extension",
# OCA/web
"web_m2x_options",
],
"website": "https://github.com/OCA/web",
"installable": True,
"pre_init_hook": "pre_init_hook",
}
28 changes: 28 additions & 0 deletions web_m2x_options_manager/demo/res_partner_demo_view.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8" ?>
<odoo>
<record id="res_partner_demo_form_view" model="ir.ui.view">
<field name="name">res.partner.demo.form.view</field>
<field name="model">res.partner</field>
<field name="priority">1000</field>
<field name="arch" type="xml">
<form>
<sheet>
<group>
<!-- Many2one w/o options -->
<field name="title" />
<!-- Many2one w/ options -->
<field
name="parent_id"
options="{'create': False, 'create_edit': False}"
/>
<!-- Many2many w/ options -->
<field
name="category_id"
options="{'create': False, 'create_edit': False}"
/>
</group>
</sheet>
</form>
</field>
</record>
</odoo>
11 changes: 11 additions & 0 deletions web_m2x_options_manager/hooks.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Copyright 2025 Camptocamp SA
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from .tools import prepare_column_can_have_options, prepare_column_comodel_id


def pre_init_hook(env):
# Pre-create and pre-fill these columns for perf reasons (might take a while to
# let Odoo do it via the ORM for huge DBs)
prepare_column_can_have_options(env.cr)
prepare_column_comodel_id(env.cr)
Loading
Loading