[IMP] stock_account: usability of stock value at date report

bzr revid: qdp-launchpad@openerp.com-20131206165956-75u2srxtb7mbusyq
This commit is contained in:
Quentin (OpenERP) 2013-12-06 17:59:56 +01:00
parent 823e945477
commit 1e4d89bf79
2 changed files with 4 additions and 3 deletions

View File

@ -21,7 +21,8 @@ class wizard_valuation_history(osv.osv_memory):
data = self.read(cr, uid, ids, context=context)[0]
ctx = context.copy()
ctx['history_date'] = data['date']
ctx['group_by'] = ['product_id']
ctx['search_default_group_by_product'] = True
ctx['search_default_group_by_location'] = True
return {
'domain': "[('date', '<=', '" + data['date'] + "')]",
'name': _('Stock Value At Date'),

View File

@ -38,7 +38,7 @@
<field name="name">Stock Value At Date</field>
<field name="model">stock.history</field>
<field name="arch" type="xml">
<tree string="Stock Value At Date">
<tree string="Stock Value At Date" create="0">
<field name="location_id" invisible="1"/>
<field name="product_id" invisible="1"/>
<field name="move_id"/>
@ -60,7 +60,7 @@
<group expand="1" string="Group By...">
<filter string="Product" icon="terp-accessories-archiver" context="{'group_by':'product_id'}" name='group_by_product'/>
<filter string="Product Category" icon="terp-accessories-archiver" context="{'group_by':'product_categ_id'}"/>
<filter string="Location" icon="terp-accessories-archiver" context="{'group_by':'location_id'}"/>
<filter string="Location" icon="terp-accessories-archiver" context="{'group_by':'location_id'}" name='group_by_location'/>
<filter string="Move" icon="terp-accessories-archiver" context="{'group_by':'move_id'}"/>
<filter string="Company" icon="terp-go-home" context="{'group_by':'company_id'}" groups="base.group_multi_company"/>
</group>