You are here

protected function ShipmentListBuilder::getEntityIds in Commerce Shipping 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/ShipmentListBuilder.php, line 78

Class

ShipmentListBuilder
Defines the list builder for shipments.

Namespace

Drupal\commerce_shipping

Code

protected function getEntityIds() {
  $order_id = $this->routeMatch
    ->getRawParameter('commerce_order');
  $query = $this
    ->getStorage()
    ->getQuery()
    ->accessCheck(FALSE)
    ->condition('order_id', $order_id)
    ->sort($this->entityType
    ->getKey('id'));

  // Only add the pager if a limit is specified.
  if ($this->limit) {
    $query
      ->pager($this->limit);
  }
  return $query
    ->execute();
}