minor fix

This commit is contained in:
wilson gomez sanchez 2021-04-15 15:34:30 -05:00
parent 11b31b6019
commit 3ff7dca5b6

View file

@ -217,7 +217,7 @@ class Sale(metaclass=PoolMeta):
('type', '=', 'production'),
])
location_ = locations[0] if locations else None
if not line.sale:
if not hasattr(line, 'sale'):
return
sale = line.sale
date_ = sale.sale_date