'MIN(allVariants.width) as minWidth',
'MAX(allVariants.width) as maxWidth',
'MIN(allVariants.length) as minLength',
'MAX(allVariants.length) as maxLength',
]);
$query->
setMaxResults(1
);
$stats =
$query->
execute()->
fetch(PDO::FETCH_ASSOC
);
$results =
[];
foreach ($criteria->
getFacets() as $criteriaFacet) { if (!
$criteriaFacet instanceof WeightFacet
&& !
$criteriaFacet instanceof WidthFacet
&& !
$criteriaFacet instanceof LengthFacet
&& !
$criteriaFacet instanceof HeightFacet
) { continue;
} $facetResult =
$this->
createRangeFacet($criteriaFacet,
$stats,
$criteria);
if ($facetResult === null
) { continue;
}