[FIX] stock_landed_costs : Automatic computation of landed cost when we save the record.
bzr revid: mdi@tinyerp.com-20140424130403-3tqm8okdqwgzkm73
This commit is contained in:
parent
301b9a70eb
commit
f5a285267c
|
@ -104,6 +104,11 @@ class stock_landed_cost(osv.osv):
|
|||
'date': lambda *a: time.strftime('%Y-%m-%d'),
|
||||
}
|
||||
|
||||
def write(self, cr, uid, ids, vals, context=None):
|
||||
res = super(stock_landed_cost, self).write(cr, uid, ids, vals, context=context)
|
||||
self.compute_landed_cost(cr, uid, ids, context=context)
|
||||
return res
|
||||
|
||||
def copy(self, cr, uid, id, default=None, context=None):
|
||||
default = {} if default is None else default.copy()
|
||||
default.update({
|
||||
|
|
Loading…
Reference in New Issue