mirror of
https://github.com/OCA/rma.git
synced 2025-02-16 17:11:47 +02:00
[IMP] rma_sale_mrp: black, isort, prettier
This commit is contained in:
committed by
Pedro M. Baeza
parent
2cb2c73c74
commit
5b67cc30f5
@@ -38,14 +38,11 @@ class SaleOrder(models.Model):
|
||||
component_index = data_list.index(first_component_dict)
|
||||
# Prevent miscalculation if there partial deliveries
|
||||
quantity = sum(
|
||||
[
|
||||
x.get("quantity", 0)
|
||||
for x in data_list
|
||||
if x.get("sale_line_id")
|
||||
and x.get("product") == first_component_dict.get("product")
|
||||
and x.get("sale_line_id")
|
||||
== first_component_dict.get("sale_line_id")
|
||||
]
|
||||
x.get("quantity", 0)
|
||||
for x in data_list
|
||||
if x.get("sale_line_id")
|
||||
and x.get("product") == first_component_dict.get("product")
|
||||
and x.get("sale_line_id") == first_component_dict.get("sale_line_id")
|
||||
)
|
||||
data_list.insert(
|
||||
component_index,
|
||||
|
||||
Reference in New Issue
Block a user