added pruchase link in product view

bzr revid: hda@tinyerp.com-20091013073144-w5g0xgos6czko872
This commit is contained in:
Raphaël Valyi 2009-10-13 13:01:44 +05:30 committed by HDA (OpenERP)
parent 68d4aa385e
commit f28d004d3a
2 changed files with 9 additions and 1 deletions

View File

@ -233,5 +233,13 @@
name="Purchase orders"
res_model="purchase.order"
src_model="res.partner"/>
<act_window
domain="[('product_id','=',active_id)]"
id="action_purchase_line_product_tree"
name="Product purchases"
res_model="purchase.order.line"
src_model="product.product"/>
</data>
</openerp>

View File

@ -225,7 +225,7 @@ class sale_order(osv.osv):
'project_id': fields.many2one('account.analytic.account', 'Analytic Account', readonly=True, states={'draft': [('readonly', False)]}),
'order_line': fields.one2many('sale.order.line', 'order_id', 'Order Lines', readonly=True, states={'draft': [('readonly', False)]}),
'invoice_ids': fields.many2many('account.invoice', 'sale_order_invoice_rel', 'order_id', 'invoice_id', 'Invoice', help="This is the list of invoices that have been generated for this sale order. The same sale order may have been invoiced in several times (by line for example)."),
'invoice_ids': fields.many2many('account.invoice', 'sale_order_invoice_rel', 'order_id', 'invoice_id', 'Invoices', help="This is the list of invoices that have been generated for this sale order. The same sale order may have been invoiced in several times (by line for example)."),
'picking_ids': fields.one2many('stock.picking', 'sale_id', 'Related Packing', readonly=True, help="This is the list of picking list that have been generated for this invoice"),
'shipped': fields.boolean('Picked', readonly=True),
'picked_rate': fields.function(_picked_rate, method=True, string='Picked', type='float'),