[FIX] Inventory line store for theoretical qty

This commit is contained in:
Josse Colpaert 2015-03-03 17:03:26 +01:00
parent 603c03799d
commit 935141582f
1 changed files with 2 additions and 1 deletions

View File

@ -2815,7 +2815,8 @@ class stock_inventory_line(osv.osv):
'prod_lot_id': fields.many2one('stock.production.lot', 'Serial Number', domain="[('product_id','=',product_id)]"),
'state': fields.related('inventory_id', 'state', type='char', string='Status', readonly=True),
'theoretical_qty': fields.function(_get_theoretical_qty, type='float', digits_compute=dp.get_precision('Product Unit of Measure'),
store=True, readonly=True, string="Theoretical Quantity"),
store={'stock.inventory.line': (lambda self, cr, uid, ids, c={}: ids, ['location_id', 'product_id', 'package_id', 'product_uom_id', 'company_id', 'prod_lot_id', 'partner_id'], 20),},
readonly=True, string="Theoretical Quantity"),
'partner_id': fields.many2one('res.partner', 'Owner'),
'product_name': fields.related('product_id', 'name', type='char', string='Product Name', store={
'product.product': (_get_product_name_change, ['name', 'default_code'], 20),