merge
[odoo/odoo.git] / addons / stock / report / report_stock_view.xml
index acb8c34..ec15f12 100644 (file)
@@ -9,13 +9,13 @@
             <field name="arch" type="xml">
                 <search string="Search Location">
                     <group col="10" colspan="4">
-                        <filter icon="terp-stock" name="in_location" string="Internal Locations" domain="[('location_id.usage', '=', 'internal')]" help="Internal Locations" />
-                        <filter icon="terp-stock" string="Customer Locations" domain="[('location_id.usage', '=', 'customer')]" help="Customer Locations" />
-                        <filter icon="terp-stock" string="Supplier Locations" domain="[('location_id.usage', '=', 'supplier')]" help="Supplier Locations" />
+                        <filter icon="terp-stock" name="in_location" string="Internal" domain="[('location_id.usage', '=', 'internal')]" help="Internal Locations" />
+                        <filter icon="terp-stock" string="Customer" domain="[('location_id.usage', '=', 'customer')]" help="Customer Locations" />
+                        <filter icon="terp-stock" string="Supplier" domain="[('location_id.usage', '=', 'supplier')]" help="Supplier Locations" />
 
                         <separator orientation="vertical"/>
-                        <field name="location_id" select="1" />
-                        <field name="product_id" select="1" />
+                        <field name="location_id" select="1"/>
+                        <field name="product_id" select="1" default="1"/>
                     </group>
                     <newline/>
                     <group expand="1" string="Group By..." colspan="4" col="10">
@@ -35,7 +35,7 @@
                 <form string="Stock by Lots">
                     <field name="location_id"/>
                     <field name="product_id"/>
-                    <field name="prodlot_id"/>
+                    <field name="prodlot_id" groups="base.group_extended"/>
                     <field name="name"/>
                 </form>
             </field>
                 <tree string="Stock by Lots">
                     <field name="location_id"/>
                     <field name="product_id"/>
-                    <field name="prodlot_id"/>
+                    <field name="prodlot_id" groups="base.group_extended"/>
                     <field name="name"/>
                 </tree>
             </field>
         </record>
 
+        <record id="stock_report_prodlots_graph" model="ir.ui.view">
+            <field name="name">stock.report.prodlots.view</field>
+            <field name="model">stock.report.prodlots</field>
+            <field name="type">graph</field>
+            <field name="arch" type="xml">
+                <graph string="Stock by Lots" type="bar">
+                    <field name="product_id"/>
+                    <field name="name"/>
+                </graph>
+            </field>
+        </record>
+
+
         <record id="action_stock_report_prodlots_form" model="ir.actions.act_window">
             <field name="name">Inventory by Location</field>
             <field name="type">ir.actions.act_window</field>
             <field name="res_model">stock.report.prodlots</field>
             <field name="view_type">form</field>
-            <field name="view_mode">tree,form</field>
+            <field name="view_mode">tree,graph</field>
             <field name="context">{'full':'1',"search_default_in_location":1}</field>
             <field name="search_view_id" ref="view_stock_report_prodlots_filter" />
         </record>