4

How to restrict/disable the form view, while click the tree view of one2many field in Odoo.

maha lakshmi
  • 61
  • 1
  • 7

3 Answers3

8

Use style:

<field name="your_o2m" style="pointer-events:none;" />
Faizan Tahir
  • 131
  • 1
  • 5
1

Try this on your field XML definition :

<field name="your_o2m" mode="tree" />
Quentin THEURET
  • 1,222
  • 6
  • 12
1

I think that no_open attribute set on the <tree> might work

<field name="o2m_field" widget="one2many" mode="tree">
    <tree no_open="1">
        <field name="name"/>
    </tree>
</field>
qdev
  • 1,371
  • 1
  • 15
  • 18