Hello Mohammed,
The fix seems good, but needs a bit improvement in the code. Instead of checking twice for the warehouse we can do it in one go, something like this..
if requisition.warehouse_id: location_id = requisition.warehouse_id.lot_input_id.id else: lot_input_stock = self.pool.get('ir.model.data').get_object(cr, uid, 'stock', 'stock_location_stock') location_id = lot_input_stock and lot_input_stock.id
Regards, Naresh Soni, OpenERP Enterprise Services
« Back to merge proposal
Hello Mohammed,
The fix seems good, but needs a bit improvement in the code. Instead of checking twice for the warehouse we can do it in one go, something like this..
if requisition. warehouse_ id: warehouse_ id.lot_ input_id. id get('ir. model.data' ).get_object( cr, uid, 'stock', 'stock_ location_ stock')
location_id = requisition.
else:
lot_input_stock = self.pool.
location_id = lot_input_stock and lot_input_stock.id
Regards,
Naresh Soni,
OpenERP Enterprise Services