[FIX]purchase_view: add a filter to remove purchase_order_line with state cancelled from view

bzr revid: csn@openerp.com-20130604134841-86styi4njsfir4al
This commit is contained in:
Cedric Snauwaert
2013-06-04 15:48:41 +02:00
parent a6ac384199
commit 901423cdf8
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -493,6 +493,7 @@
<field name="order_id"/>
<field name="product_id"/>
<field name="partner_id" string="Supplier" filter_domain="[('partner_id', 'child_of', self)]"/>
<filter name="hide_cancelled" string="Hide cancelled lines" domain="[('state', '!=', 'cancel')]"/>
<group expand="0" string="Group By...">
<filter name="groupby_supplier" string="Supplier" icon="terp-partner" domain="[]" context="{'group_by' : 'partner_id'}" />
<filter name="groupby_product" string="Product" icon="terp-accessories-archiver" domain="[]" context="{'group_by' : 'product_id'}" />
@@ -153,6 +153,7 @@ class purchase_requisition(osv.osv):
po_ids.append(po.id)
res['context'].update({
'search_default_groupby_product' : True,
'search_default_hide_cancelled': True,
})
res['domain'] = [('id','in', po_ids)]
return res