$aggregations->
remove('configurators'
);
$aggregations->
remove('options'
);
$aggregations->
add(new EntityResult('properties',
$grouped));
} /**
* @param array<string>|null $groupIds
*/
private function getPropertyFilter(Request
$request, ?array
$groupIds = null
): Filter
{ $ids =
$this->
getPropertyIds($request);
$propertyAggregation =
new TermsAggregation('properties', 'product.properties.id'
);
$optionAggregation =
new TermsAggregation('options', 'product.options.id'
);
if ($groupIds) { $propertyAggregation =
new FilterAggregation( 'properties-filter',
$propertyAggregation,
[new EqualsAnyFilter('product.properties.groupId',
$groupIds)] );