public function findForPaginateFilterBySiteIds(PaginateFinderConfiguration $configuration, array $siteIds = null)
    {
        $qa = $this->createAggregateQueryWithDeletedFilter(false);
        if (null !== $siteIds) {
            $qa->match(array('siteId' => array('$in' => $siteIds)));
        }

        $this->filterSearch($configuration, $qa);

        $order = $configuration->getOrder();
        if (!empty($order)) {
            $qa->sort($order);
        }

        $qa->skip($configuration->getSkip());
        $qa->limit($configuration->getLimit());

        return $this->hydrateAggregateQuery($qa);
    }
public function findForPaginateFilterBySiteIds(PaginateFinderConfiguration $configuration, array $siteIds = null)
    {
        $qa = $this->createAggregateQueryWithDeletedFilter(false);
        if (null !== $siteIds) {
            $qa->match(array('siteId' => array('$in' => $siteIds)));
        }

        $this->filterSearch($configuration, $qa);

        $order = $configuration->getOrder();
        if (!empty($order)) {
            $qa->sort($order);
        }

        $qa->skip($configuration->getSkip());
        $qa->limit($configuration->getLimit());

        return $this->hydrateAggregateQuery($qa);
    }
@param PaginateFinderConfiguration $configuration
@param array|null                  $siteIds

@return array