product.xml 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <?xml version="1.0"?>
  2. <odoo>
  3. <data>
  4. <record id="product_template_base_meggit_view" model="ir.ui.view">
  5. <field name="name">product.template.base.meggit.form</field>
  6. <field name="model">product.template</field>
  7. <field name="inherit_id" ref="product.product_template_only_form_view"/>
  8. <field name="arch" type="xml">
  9. <field name="barcode" position="after">
  10. <field name="segment_id" attrs="{'invisible': [('product_variant_count', '>', 1)]}" options="{'no_open': 1, 'no_create': 1}"/>
  11. <field name="platform" attrs="{'invisible': [('product_variant_count', '>', 1)]}"/>
  12. <field name="site" attrs="{'invisible': [('product_variant_count', '>', 1)]}"/>
  13. <field name="custom_sales_id" attrs="{'invisible': [('product_variant_count', '>', 1)]}"/>
  14. <field name="custom_sales" invisible="1"/>
  15. </field>
  16. </field>
  17. </record>
  18. <record id="product_normal_form_base_meggit_view" model="ir.ui.view">
  19. <field name="name">product.product.base.meggit.form</field>
  20. <field name="model">product.product</field>
  21. <field name="inherit_id" ref="product.product_normal_form_view"/>
  22. <field name="arch" type="xml">
  23. <field name="barcode" position="after">
  24. <field name="segment_id" options="{'no_open': 1, 'no_create': 1}"/>
  25. <field name="platform"/>
  26. <field name="site"/>
  27. <field name="custom_sales_id"/>
  28. <field name="custom_sales" invisible="1"/>
  29. </field>
  30. </field>
  31. </record>
  32. <record id="product_template_custom_sales_action" model="ir.actions.act_window">
  33. <field name="name">Products</field>
  34. <field name="type">ir.actions.act_window</field>
  35. <field name="res_model">product.template</field>
  36. <field name="view_mode">kanban,tree,form</field>
  37. <field name="view_type">form</field>
  38. <field name="view_id" ref="product.product_template_kanban_view"/>
  39. <field name="context">{"search_default_filter_to_sell":1}</field>
  40. <field name="domain">[('custom_sales','=',True)]</field>
  41. <field name="help" type="html">
  42. <p class="oe_view_nocontent_create">
  43. Click to define a new product.
  44. </p><p>
  45. You must define a product for everything you sell, whether it's a physical product, a consumable or a service you offer to customers.
  46. </p><p>
  47. The product form contains information to simplify the sale process: price, notes in the quotation, accounting data, procurement methods, etc.
  48. </p>
  49. </field>
  50. </record>
  51. </data>
  52. </odoo>