protected function PriceListItemListBuilder::getEntityIds in Commerce Pricelist 8.2
Loads entity IDs using a pager sorted by the entity id.
Return value
array An array of entity IDs.
Overrides EntityListBuilder::getEntityIds
File
- src/
PriceListItemListBuilder.php, line 63
Class
- PriceListItemListBuilder
- Defines the list builder for price list items.
Namespace
Drupal\commerce_pricelistCode
protected function getEntityIds() {
$price_list = $this->routeMatch
->getParameter('commerce_pricelist');
$query = $this
->getStorage()
->getQuery()
->condition('price_list_id', $price_list
->id())
->sort('purchasable_entity')
->sort('quantity');
// Only add the pager if a limit is specified.
if ($this->limit) {
$query
->pager($this->limit);
}
return $query
->execute();
}