[IMP] Small improvements
[odoo/odoo.git] / addons / website_sale / views / website_sale_backend.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <openerp>
3 <data>
4
5
6     <record id="product_normal_form_view" model="ir.ui.view">
7         <field name="name">product.normal.form.inherit</field>
8         <field name="model">product.product</field>
9         <field name="inherit_id" ref="product.product_normal_form_view"/>
10         <field name="arch" type="xml">
11             <!-- add state field in header -->
12             <xpath expr="//sheet/div" position="before">
13                 <field name="website_url" invisible="1"/>
14                 <field name="website_published" class="pull-right" widget="website_button"/>
15             </xpath>
16
17             <group name="sale" position="inside">
18                 <group name="website" string="Website">
19                     <field name="suggested_product_ids" widget="many2many_tags"/>
20                     <field name="website_style_ids" widget="many2many_tags"/>
21                 </group>
22             </group>
23         </field>
24     </record>
25
26     <record model="ir.ui.view" id="product_pricelist_view">
27         <field name="name">product.pricelist.website.form</field>
28         <field name="model">product.pricelist</field>
29         <field name="inherit_id" ref="product.product_pricelist_view"/>
30         <field name="arch" type="xml">
31             <field name="active" position="after">
32                 <field name="code"/>
33             </field>
34         </field>
35     </record>
36
37     <record model="ir.ui.view" id="product_template_form_view">
38         <field name="name">product.template.product.website.form</field>
39         <field name="model">product.template</field>
40         <field name="inherit_id" ref="product.product_template_form_view"/>
41         <field name="arch" type="xml">
42             <!-- add state field in header -->
43             <xpath expr="//sheet/div" position="before">
44                 <field name="website_url" invisible="1"/>
45                 <field name="website_published" class="pull-right" widget="website_button"/>
46             </xpath>
47             <xpath expr="//page[@string='Information']" position="inside">
48                 <group colspan="4" string="Website Options">
49                     <field name="suggested_product_ids" widget="many2many_tags"/>
50                     <field name="website_style_ids" widget="many2many_tags"/>
51                     <field colspan="4" name="website_attribute_ids" nolabel="1">
52                         <tree string="Product Attributes" editable="bottom">
53                             <field name="attribute_id" on_change="onchange_attribute_id(attribute_id)"/>
54                             <field name="type" invisible="1"/>
55                             <field name="value" attrs="{'required': [('type','=','float')]}"/>
56                             <field name="value_id"
57                                 attrs="{'required': [('type','=','distinct')]}"
58                                 context="{'default_attribute_id': attribute_id}"
59                                 domain="[('attribute_id', '=', attribute_id)]"/>
60                         </tree>
61                     </field>
62                 </group>
63             </xpath>
64
65         </field>
66     </record>
67
68     <record model="ir.ui.view" id="view_product_attribute_form">
69       <field name="name">product.attribute.form</field>
70       <field name="model">product.attribute</field>
71       <field name="arch" type="xml">
72         <form string="Product Attributes" version="7.0">
73           <group>
74             <field name="name"/>
75             <field name="type"/>
76             <field name="visible"/>
77           </group>
78         </form>
79       </field>
80     </record>
81
82  </data>
83 </openerp>