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.

66 lines
2.8 KiB

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. Copyright (C) 2018 MuK IT GmbH
  4. This program is free software: you can redistribute it and/or modify
  5. it under the terms of the GNU Affero General Public License as
  6. published by the Free Software Foundation, either version 3 of the
  7. License, or (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU Affero General Public License for more details.
  12. You should have received a copy of the GNU Affero General Public License
  13. along with this program. If not, see <http://www.gnu.org/licenses/>.
  14. -->
  15. <odoo>
  16. <record id="view_attachment_search" model="ir.ui.view">
  17. <field name="name">ir_attachment.search</field>
  18. <field name="model">ir.attachment</field>
  19. <field name="inherit_id" ref="base.view_attachment_search"/>
  20. <field name="arch" type="xml">
  21. <xpath expr="//filter[@name='url_filter']" position="before">
  22. <separator/>
  23. <filter name="all" string="All Data" domain="['|',('res_field', '=', False),('res_field', '!=', False)]"/>
  24. <filter name="set_res_field" string="Field Data" domain="[('res_field', '!=', False)]"/>
  25. <filter name="no_res_field" string="Attachments" domain="[('res_field', '=', False)]"/>
  26. <separator/>
  27. </xpath>
  28. <xpath expr="//group//filter[last()]" position="before">
  29. <separator/>
  30. <filter name="group_res_model" string="Attached Document Model" context="{'group_by': 'res_model'}" />
  31. <filter name="group_res_field" string="Attached Document Field" context="{'group_by': 'res_field'}" />
  32. </xpath>
  33. </field>
  34. </record>
  35. <record id="view_attachment_tree" model="ir.ui.view">
  36. <field name="name">ir_attachment.tree</field>
  37. <field name="model">ir.attachment</field>
  38. <field name="inherit_id" ref="base.view_attachment_tree"/>
  39. <field name="arch" type="xml">
  40. <xpath expr="//field[@name='datas_fname']" position="after">
  41. <field name="mimetype" />
  42. </xpath>
  43. </field>
  44. </record>
  45. <record id="view_attachment_form" model="ir.ui.view">
  46. <field name="name">ir_attachment.form</field>
  47. <field name="model">ir.attachment</field>
  48. <field name="inherit_id" ref="base.view_attachment_form"/>
  49. <field name="arch" type="xml">
  50. <xpath expr="//group[@name='description_group']" position="before">
  51. <group string="Storage" name="storage" groups="base.group_no_one">
  52. <field name="db_datas" readonly="1" attrs="{'invisible':[('db_datas','=',False)]}"/>
  53. <field name="store_fname" readonly="1" attrs="{'invisible':[('store_fname','=',False)]}"/>
  54. </group>
  55. </xpath>
  56. </field>
  57. </record>
  58. </odoo>