[IMP] stock_packaging_calculator: black, isort, prettier

This commit is contained in:
Christopher Ormaza
2021-12-13 13:14:34 -05:00
committed by Thierry Ducrest
parent ef048daf86
commit acb6344463

View File

@@ -89,12 +89,12 @@ class Product(models.Model):
"_packaging_name_getter", self._packaging_name_getter
)
packagings = sorted(
[
(
Packaging(x.id, name_getter(x), x.qty, x.barcode, False)
for x in self.packaging_ids.filtered(custom_filter)
# Exclude the ones w/ zero qty as they are useless for the math
if x.qty
],
),
reverse=True,
key=lambda x: x.qty,
)