diff --git a/sale_order_lot_selection/model/stock.py b/sale_order_lot_selection/model/stock.py index 4d83bd38c5a..36c431e05c6 100644 --- a/sale_order_lot_selection/model/stock.py +++ b/sale_order_lot_selection/model/stock.py @@ -10,8 +10,9 @@ class StockMove(models.Model): _inherit = 'stock.move' - @api.model - def _prepare_procurement_from_move(self, move): - vals = super(StockMove, self)._prepare_procurement_from_move(move) - vals['lot_id'] = move.restrict_lot_id.id + @api.multi + def _prepare_procurement_from_move(self): + self.ensure_one() + vals = super(StockMove, self)._prepare_procurement_from_move() + vals['lot_id'] = self.restrict_lot_id.id return vals