Group only with the fields existing on the shipment
Closes #11998 (grafted from c383c81b587c1006ceb76e71196ff3d29a2c3f53) --HG-- branch : 6.0
This commit is contained in:
@@ -31,9 +31,10 @@ class Sale(metaclass=PoolMeta):
|
||||
('state', 'in', ['draft', 'waiting']),
|
||||
]
|
||||
shipment_domain += self._get_grouped_shipment_planned_date(shipment)
|
||||
defaults = Shipment.default_get(self._shipment_grouping_fields,
|
||||
with_rec_name=False)
|
||||
for field in self._shipment_grouping_fields:
|
||||
fields = [
|
||||
f for f in self._shipment_grouping_fields if f in Shipment._fields]
|
||||
defaults = Shipment.default_get(fields, with_rec_name=False)
|
||||
for field in fields:
|
||||
shipment_domain.append((field, '=',
|
||||
getattr(shipment, field, defaults.get(field))))
|
||||
return shipment_domain
|
||||
|
||||
Reference in New Issue
Block a user