mirror of
https://github.com/OCA/stock-logistics-warehouse.git
synced 2025-01-21 14:27:28 +02:00
FIX stock_inventory_preparation_filter search EAN13 for scanned products
When using the feature 'allows to make an inventory based on scanned products', users might expect they can use the EAN13 barcode for scanning their products.
This commit is contained in:
committed by
Sergio Teruel
parent
deddc08ebc
commit
3946e33532
@@ -109,8 +109,10 @@ class StockInventory(models.Model):
|
||||
tmp_lines[line.product_code] = line.product_qty
|
||||
inventory.empty_line_ids.unlink()
|
||||
for product_code in tmp_lines.keys():
|
||||
products = product_obj.search(
|
||||
[('default_code', '=', product_code)])
|
||||
products = product_obj.search([
|
||||
'|', ('default_code', '=', product_code),
|
||||
('ean13', '=', product_code),
|
||||
])
|
||||
if products:
|
||||
product = products[0]
|
||||
fake_inventory = StockInventoryFake(
|
||||
|
||||
Reference in New Issue
Block a user