ir_actions_server_views.xml 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <odoo>
  3. <data>
  4. <record model="ir.ui.view" id="view_server_action_form_website">
  5. <field name="name">ir.actions.server.form.website</field>
  6. <field name="model">ir.actions.server</field>
  7. <field name="inherit_id" ref="base.view_server_action_form"/>
  8. <field name="arch" type="xml">
  9. <data>
  10. <xpath expr="//field[@name='state']" position="after">
  11. <field name="website_published"
  12. attrs="{'invisible': [('state', '!=', 'code')]}"/>
  13. <field name="xml_id" invisible="1"/>
  14. <field name="website_path"
  15. attrs="{'invisible': ['|', ('website_published', '!=', True), ('state', '!=', 'code')]}"/>
  16. <field name="website_url" readonly="1" widget="url"
  17. attrs="{'invisible': ['|', ('website_published', '!=', True), ('state', '!=', 'code')]}"/>
  18. </xpath>
  19. </data>
  20. </field>
  21. </record>
  22. <record model="ir.ui.view" id="view_server_action_tree_website">
  23. <field name="name">ir.actions.server.tree.website</field>
  24. <field name="model">ir.actions.server</field>
  25. <field name="inherit_id" ref="base.view_server_action_tree"/>
  26. <field name="arch" type="xml">
  27. <xpath expr="//field[@name='model_id']" position="after">
  28. <field name="website_url"/>
  29. </xpath>
  30. </field>
  31. </record>
  32. <record model="ir.ui.view" id="view_server_action_search_website">
  33. <field name="name">ir.actions.server.search.website</field>
  34. <field name="model">ir.actions.server</field>
  35. <field name="inherit_id" ref="base.view_server_action_search"/>
  36. <field name="arch" type="xml">
  37. <xpath expr="//field[@name='state']" position="after">
  38. <filter string="Website" name="website"
  39. domain="[('website_published', '=', True), ('state', '=', 'code')]"/>
  40. </xpath>
  41. </field>
  42. </record>
  43. </data>
  44. </odoo>