pricelist_view.xml 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <openerp>
  3. <data>
  4. <record id="product_pricelist_view" model="ir.ui.view">
  5. <field name="model">product.pricelist</field>
  6. <field name="inherit_id" ref="product.product_pricelist_view"/>
  7. <field name="arch" type="xml">
  8. <field name="type" position="after">
  9. <field name="price_grid"/>
  10. </field>
  11. </field>
  12. </record>
  13. <record id="product_pricelist_view_tree" model="ir.ui.view">
  14. <field name="model">product.pricelist</field>
  15. <field name="inherit_id" ref="product.product_pricelist_view_tree"/>
  16. <field name="arch" type="xml">
  17. <field name="type" position="after">
  18. <field name="price_grid"/>
  19. </field>
  20. </field>
  21. </record>
  22. <record id="product_pricelist_version_form_view" model="ir.ui.view">
  23. <field name="model">product.pricelist.version</field>
  24. <field name="inherit_id" ref="product.product_pricelist_version_form_view"/>
  25. <field name="arch" type="xml">
  26. <field name="pricelist_id" position="after">
  27. <field name="price_grid"/>
  28. </field>
  29. <xpath expr="//group[1]" position="attributes">
  30. <attribute name="col">6</attribute>
  31. </xpath>
  32. <xpath expr="//group[1]" position="inside">
  33. <group attrs="{'invisible': [('price_grid', '=', False)]}" col="4">
  34. <div>
  35. <button name="button_template_in_version"
  36. class="oe_inline oe_stat_button" type="object"
  37. icon="fa-cube"
  38. help="Products templates with this version (click to see them)">
  39. <field name="tmpl_in_count" widget="statinfo"
  40. string="Show Products"
  41. attrs="{'invisible': [('price_grid', '=', False)]}"/>
  42. </button>
  43. </div>
  44. </group>
  45. </xpath>
  46. <xpath expr="//notebook/page[@string='Item List']"
  47. position="attributes">
  48. <attribute name="attrs">{'invisible': [('price_grid', '=', True)]}</attribute>
  49. </xpath>
  50. <xpath expr="//notebook[last()]" position="inside">
  51. <page name="grid" string="Grid"
  52. attrs="{'invisible': [('price_grid', '=', False)]}">
  53. <group col="4">
  54. <field name="item_grid_ids" nolabel="1">
  55. <tree string="Price Grid" editable="1">
  56. <field name="id" invisible="1"/>
  57. <field name="sequence" widget="handle"/>
  58. <field name="price_surcharge" string="Price"/>
  59. <field name="product_tmpl_id"/>
  60. <button name="button_product"
  61. icon="terp-stock_symbol-selection"
  62. class="oe_link" type="object"
  63. attrs="{'invisible': [
  64. ('product_tmpl_id', '=', False),
  65. ('product_id', '=', False)]}"
  66. help="Click to see this product"/>
  67. <field name="product_id"/>
  68. <field name="related_sequence"/>
  69. <field name="price_discount" string="Disc." invisible="1"/>
  70. <field name="base" string="Base" invisible="1"/>
  71. </tree>
  72. </field>
  73. </group>
  74. </page>
  75. </xpath>
  76. </field>
  77. </record>
  78. </data>
  79. </openerp>