236
236
class sale_order(osv.osv):
240
240
'fleet_id': fields.many2one('stock.location', 'Default Sub Fleet'), #TODO call that sub_fleet_id ?
243
243
def action_ship_create(self, cr, uid, ids, *args):
244
245
result = super(sale_order, self).action_ship_create(cr, uid, ids, *args)
246
247
for order in self.browse(cr, uid, ids):
247
249
for order_line in order.order_line:
249
251
for move in order_line.move_ids:
250
self.pool.get('stock.move').write(cr, uid, move.id, {'location_dest_id':order_line.fleet_id.id})
254
self.pool.get('stock.move').write(cr, uid, move.id, {'location_dest_id':order_line.fleet_id.id})
257
self.pool.get('stock.move').write(cr, uid, move.id, {'location_dest_id':order_line.fleet_id.id})