You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

35 lines
1.4 KiB

<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<record id="view_attachment_queue_form" model="ir.ui.view">
<field name="model">attachment.queue</field>
<field name="inherit_id" ref="attachment_queue.view_attachment_queue_form" />
<field name="arch" type="xml">
<!-- Add Related Task and Backend -->
<xpath expr="//field[@name='url']" position="after">
<field name="method_type" invisible="1"/>
<field
name="task_id"
domain="[('method_type', '!=', 'import')]"
attrs="{'required': [('file_type', '=', 'export')], 'readonly': [('method_type', '=', 'import')]}"
/>
<field name="storage_backend_id"/>
</xpath>
</field>
</record>
<record id="view_attachment_queue_tree" model="ir.ui.view">
<field name="model">attachment.queue</field>
<field name="inherit_id" ref="attachment_queue.view_attachment_queue_tree" />
<field name="arch" type="xml">
<xpath expr="//tree" position="attributes">
<attribute name="decoration-muted">state == 'done'</attribute>
</xpath>
<xpath expr="//field[@name='file_type']" position="after">
<field name="task_id"/>
<field name="storage_backend_id"/>
</xpath>
</field>
</record>
</odoo>