[FIX] stock_account: avoid getting 'stock.picking()' as reference
In the new api an empty recordset converted to string is the name its class while previously it was converted to an empty string. The valid v7 condition sould have probably been move.picking_id and move.picking_id.name or False but in v8, simply move.picking_id.name is enough and avoids getting these accounting entries strangly named when there is no picking.
This commit is contained in:
parent
bdd5ec8216
commit
c3de121988
|
@ -241,7 +241,7 @@ class stock_quant(osv.osv):
|
|||
'line_id': move_lines,
|
||||
'period_id': period_id,
|
||||
'date': move.date,
|
||||
'ref': move.picking_id and move.picking_id.name}, context=context)
|
||||
'ref': move.picking_id.name}, context=context)
|
||||
|
||||
#def _reconcile_single_negative_quant(self, cr, uid, to_solve_quant, quant, quant_neg, qty, context=None):
|
||||
# move = self._get_latest_move(cr, uid, to_solve_quant, context=context)
|
||||
|
|
Loading…
Reference in New Issue