[FIX] base: ir field - set dependence as required when creating a compute field
Before this commit:
- When you create a compute field, from the model view, dependence field
was not required when creating a compute field.
- When removing the compute code, the dependence field stays marked as
required.
fine-tuning : f01c195288
opw-2003784
closes odoo/odoo#33760
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
This commit is contained in:
@@ -109,7 +109,7 @@
|
||||
</group>
|
||||
<group string="Advanced Properties" groups="base.group_no_one">
|
||||
<field name="related"/>
|
||||
<field name="depends"/>
|
||||
<field name="depends" attrs="{'required': [('compute', 'not in', [False, ''])]}"/>
|
||||
<field name="compute" widget="ace" options="{'mode': 'python'}"/>
|
||||
</group>
|
||||
<div groups="base.group_no_one">
|
||||
@@ -279,7 +279,7 @@
|
||||
</group>
|
||||
<group string="Advanced Properties" groups="base.group_no_one">
|
||||
<field name="related"/>
|
||||
<field name="depends" attrs="{'required': [('compute', '!=', False)] }"/>
|
||||
<field name="depends" attrs="{'required': [('compute', 'not in', [False, ''])]}"/>
|
||||
<field name="compute" widget="ace" options="{'mode': 'python'}"/>
|
||||
</group>
|
||||
<div groups="base.group_no_one">
|
||||
|
||||
Reference in New Issue
Block a user