Files
odoo_source/addons/pad_project/views/project_views.xml
T
Denis Ledoux c2a5d6031c [FIX] pad_project: do not write on task description when using pad.
This revision is similar to
6e8faf40bd
but for the opposite case:
When the task is using the pad,
somehow the regular `description` pad
was written as well on save, making both field
being saved together,
and when description is saved
its content is written on the pad.
Therefore, whatever you written in the pad,
the pad was overriden with the current content of
the task regular description field

opw-787773
2017-12-21 14:45:40 +01:00

30 lines
1.3 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="view_task_form2_inherit_pad_project" model="ir.ui.view">
<field name="name">project.task.form.inherit</field>
<field name="model">project.task</field>
<field name="inherit_id" ref="project.view_task_form2"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='description']" position="attributes">
<attribute name="attrs">{'invisible': [('use_pad', '=', True)], 'readonly': [('use_pad', '=', True)]}</attribute>
</xpath>
<field name="description" position="after">
<field name="use_pad" invisible="1"/>
<field name="description_pad" widget="pad" attrs="{'invisible': [('use_pad', '=', False)], 'readonly': [('use_pad', '=', False)]}"/>
</field>
</field>
</record>
<record id="project_project_view_form" model="ir.ui.view">
<field name="name">project.project.view.form</field>
<field name="model">project.project</field>
<field name="inherit_id" ref="project.edit_project"/>
<field name="arch" type="xml">
<field name="partner_id" position="after">
<field name="use_pads"/>
</field>
</field>
</record>
</odoo>