[REM] completion in Gantt chart tasks and projects, not supported by OpenERP and...
[odoo/odoo.git] / addons / stock / product_view.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <openerp>
3     <data>
4
5         <record id="product_search_form_view_stock" model="ir.ui.view">
6             <field name="name">product.search.stock.form</field>
7             <field name="model">product.product</field>
8             <field name="type">search</field>
9             <field name="inherit_id" ref="product.product_search_form_view"/>
10             <field name="arch" type="xml">
11                    <field name="pricelist_id" position="before">
12                        <field name="location_id" widget="selection" context="{'location': self}"/>
13                        <field name="warehouse_id" widget="selection" context="{'warehouse': self}"/>
14                        <separator orientation="vertical"/>
15                    </field>
16             </field>
17         </record>
18
19         <record id="view_category_property_form" model="ir.ui.view">
20             <field name="name">product.category.stock.property.form.inherit</field>
21             <field name="model">product.category</field>
22             <field name="type">form</field>
23             <field name="inherit_id" ref="product.product_category_form_view"/>
24             <field name="arch" type="xml">
25                 <form position="inside">
26                     <group col="2" colspan="2">
27                         <separator string="Accounting Stock Properties" colspan="2"/>
28                         <field name="property_stock_account_input_categ" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
29                         <field name="property_stock_account_output_categ" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
30                         <field name="property_stock_valuation_account_id" domain="[('type','&lt;&gt;','view'), ('type','&lt;&gt;','consolidation')]"/>
31                         <field name="property_stock_journal"/>
32                     </group>
33                 </form>
34             </field>
35         </record>
36
37         <record id="view_template_property_form" model="ir.ui.view">
38             <field name="name">product.template.stock.property.form.inherit</field>
39             <field name="model">product.template</field>
40             <field name="type">form</field>
41             <field name="inherit_id" ref="product.product_template_form_view"/>
42             <field name="arch" type="xml">
43                  <page position="after" string="Information">
44                     <page string="Properties">
45                         <separator string="Counter-Part Locations Properties" colspan="4"/>
46                         <field name="property_stock_procurement" domain="[('usage','=','procurement')]"/>
47                         <field name="property_stock_production" domain="[('usage','=','production')]"/>
48                         <field name="property_stock_inventory" domain="[('usage','=','inventory')]"/>
49                         <separator string="Accounting Entries" colspan="4"/>
50                         <field name="property_stock_account_input" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
51                         <field name="property_stock_account_output" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
52                     </page>
53                 </page>
54             </field>
55         </record>
56
57         <record id="view_product_standard_price_form" model="ir.ui.view">
58             <field name="name">product.product.standard.price.form.inherit</field>
59             <field name="model">product.product</field>
60             <field name="type">form</field>
61             <field name="inherit_id" ref="product.product_normal_form_view"/>
62             <field name="arch" type="xml">
63                 <field name="standard_price" position="replace">
64                     <label string="Cost Price :" align="1.0"/>
65                     <group col="2" colspan="1">
66                         <field name="standard_price" attrs="{'readonly':[('cost_method','=','average')]}" nolabel="1"/>
67                         <button name="%(action_view_change_standard_price)d" string="Update"
68                             type="action" icon="gtk-execute" attrs="{'invisible':[('cost_method','&lt;&gt;','average')]}"/>
69                     </group>
70                 </field>
71             </field>
72         </record>
73
74         <record id="view_normal_property_acc_form" model="ir.ui.view">
75             <field name="name">product.normal.stock.acc.property.form.inherit</field>
76             <field name="model">product.product</field>
77             <field name="type">form</field>
78             <field name="inherit_id" ref="product.product_normal_form_view"/>
79             <field name="priority">26</field>
80             <field name="arch" type="xml">
81                 <xpath expr="/form/notebook/page/group[@name='properties']" position="before">
82                     <group groups="base.group_extended">
83                         <separator string="Inventory Valuation" colspan="4"/>
84                         <group colspan="2" col="2">
85                             <field name="valuation" attrs="{'readonly':[('type', '=', 'service')]}"/>
86                         </group>
87                         <group colspan="2" col="2">
88                             <field name="property_stock_account_input" attrs="{'readonly':[('valuation', '!=', 'real_time')]}"
89                                 domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" groups="base.group_extended"/>
90                             <field name="property_stock_account_output" attrs="{'readonly':[('valuation', '!=', 'real_time')]}"
91                                 domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" groups="base.group_extended"/>
92                         </group>
93                     </group>
94                     <newline/>
95                 </xpath>
96             </field>
97         </record>
98
99         <record id="view_normal_stock_property_form" model="ir.ui.view">
100             <field name="name">product.normal.stock.form.inherit</field>
101             <field name="model">product.product</field>
102             <field name="type">form</field>
103             <field name="inherit_id" ref="product.product_normal_form_view"/>
104             <field name="arch" type="xml">
105                 <group name="status" position="after">
106                     <group colspan="2" col="3">
107                         <separator string="Stocks" colspan="4"/>
108                         <field name="qty_available"/>
109                         <button name="%(action_view_change_product_quantity)d" string="Update" attrs="{'invisible': [('type', '=', 'service')]}"
110                             type="action" icon="gtk-execute" groups="stock.group_stock_manager,stock.group_stock_user"/>
111                         <newline/>
112                         <field name="virtual_available"/>
113                     </group>
114                     <group colspan="2" col="2" name="stock_variations" groups="base.group_extended">
115                         <separator string="Expected Stock Variations" colspan="2"/>
116                         <field name="incoming_qty"/>
117                         <field name="outgoing_qty"/>
118                     </group>
119                     <group colspan="2" col="2" name="lot" groups="base.group_extended">
120                         <separator string="Lots" colspan="4"/>
121                         <field name="track_production" />
122                         <field name="track_incoming" />
123                         <field name="track_outgoing" />
124                     </group>
125                 </group>
126             </field>
127         </record>
128
129         <record model="ir.ui.view" id="product.product_kanban_view">
130             <field name="name">Product Kanban</field>
131             <field name="model">product.product</field>
132             <field name="type">kanban</field>
133             <field name="arch" type="xml">
134                 <kanban>
135                     <field name="color"/>
136                     <field name="type"/>
137                     <field name="product_image"/>
138                     <field name="list_price"/>
139                     <templates>
140                         <t t-name="kanban-box">
141                             <div class="oe_product_vignette">
142                                 <div class="oe_product_img">
143                                 <a type="edit"><img t-att-src="kanban_image('product.product', 'product_image', record.id.value)" class="oe_product_photo"/></a>
144                                 </div>
145                                 <div class="oe_product_desc">
146                                     <h4><a type="edit"><field name="name"></field></a></h4>
147                                     <ul>
148                                         <li t-if="record.type.raw_value != 'service'">Stock on hand: <field name="qty_available"/> <field name="uom_id"/></li>
149                                         <li t-if="record.type.raw_value != 'service'">Stock available: <field name="virtual_available"/> <field name="uom_id"/></li>
150                                         <li>Price: <field name="lst_price"></field></li>
151                                         <li>Cost: <field name="standard_price"></field></li>
152                                     </ul>
153                                 </div>
154                             </div>
155                             <script>
156                                 $('.oe_product_photo').load(function() { if($(this).width() > $(this).height()) { $(this).addClass('oe_product_photo_wide') } });
157                             </script>
158                             <div></div>
159                         </t>
160                     </templates>
161                 </kanban>
162             </field>
163         </record>
164
165         <record id="view_normal_property_form" model="ir.ui.view">
166             <field name="name">product.normal.stock.property.form.inherit</field>
167             <field name="model">product.product</field>
168             <field name="type">form</field>
169             <field name="inherit_id" ref="product.product_normal_form_view"/>
170             <field name="arch" type="xml">
171                 <group name="store" position="after">
172                     <group col="2" colspan="2" name="store" groups="base.group_extended">
173                         <separator string="Counter-Part Locations Properties" colspan="2"/>
174                         <field name="property_stock_procurement" attrs="{'readonly':[('type','=','service')]}" domain="[('usage','=','procurement')]"/>
175                         <field name="property_stock_production" attrs="{'readonly':[('type','=','service')]}" domain="[('usage','=','production')]"/>
176                         <field name="property_stock_inventory"  attrs="{'readonly':[('type','=','service')]}" domain="[('usage','=','inventory')]"/>
177                     </group>
178                 </group>
179             </field>
180         </record>
181
182 <!--        <record id="view_product_valuation_form" model="ir.ui.view">
183             <field name="name">product.valuation.stock.form.inherit</field>
184             <field name="model">product.product</field>
185             <field name="type">form</field>
186             <field name="inherit_id" ref="product.product_normal_form_view"/>
187             <field name="arch" type="xml">
188                 <field name="cost_method" position="after">
189                     <field name="valuation"/>
190                 </field>
191             </field>
192         </record>-->
193
194     </data>
195 </openerp>