[FIX]:add location id and destination id when create new move use the wizard partial...
[odoo/odoo.git] / addons / stock / wizard / stock_partial_picking.py
index f666bf1..60c524c 100644 (file)
@@ -32,8 +32,8 @@ class stock_partial_picking_line(osv.TransientModel):
         'quantity' : fields.float("Quantity", digits_compute=dp.get_precision('Product UoM'), required=True),
         'product_uom': fields.many2one('product.uom', 'Unit of Measure', required=True, ondelete='CASCADE'),
         'prodlot_id' : fields.many2one('stock.production.lot', 'Production Lot', ondelete='CASCADE'),
-        'location_id': fields.many2one('stock.location', 'Location', required=True, ondelete='CASCADE'),
-        'location_dest_id': fields.many2one('stock.location', 'Dest. Location', required=True, ondelete='CASCADE'),
+        'location_id': fields.many2one('stock.location', 'Location', required=True, ondelete='CASCADE', domain = [('usage','<>','view')]),
+        'location_dest_id': fields.many2one('stock.location', 'Dest. Location', required=True, ondelete='CASCADE',domain = [('usage','<>','view')]),
         'move_id' : fields.many2one('stock.move', "Move", ondelete='CASCADE'),
         'wizard_id' : fields.many2one('stock.partial.picking', string="Wizard", ondelete='CASCADE'),
         'update_cost': fields.boolean('Need cost update'),