Fixed a bug which set the domain to None on the search_quantity method
This commit is contained in:
parent
bb93aa084c
commit
81bbb6e8ce
|
@ -54,7 +54,6 @@ class Product:
|
|||
|
||||
today = Date.today()
|
||||
context = Transaction().context
|
||||
|
||||
# not locations in context
|
||||
if not context.get('locations'):
|
||||
warehouses = Location.search([('type', '=', 'warehouse')])
|
||||
|
@ -62,4 +61,4 @@ class Product:
|
|||
with Transaction().set_context(locations=location_ids, stock_date_end=today):
|
||||
return cls._search_quantity(name, location_ids, domain)
|
||||
# return super (with locations in context)
|
||||
return super(Product, cls).search_quantity(name, domain=None)
|
||||
return super(Product, cls).search_quantity(name, domain)
|
||||
|
|
Loading…
Reference in New Issue