|
@@ 451-461 (lines=11) @@
|
| 448 |
|
* |
| 449 |
|
* @throws InvalidArgumentException Thrown if invalid parameters are received |
| 450 |
|
*/ |
| 451 |
|
public function selectByIdList($idList = [0], $useJoins = true, $slimMode = false) |
| 452 |
|
{ |
| 453 |
|
$qb = $this->genericBaseQuery('', '', $useJoins, $slimMode); |
| 454 |
|
$qb = $this->addIdListFilter($idList, $qb); |
| 455 |
|
|
| 456 |
|
$query = $this->getQueryFromBuilder($qb); |
| 457 |
|
|
| 458 |
|
$results = $query->getResult(); |
| 459 |
|
|
| 460 |
|
return (count($results) > 0) ? $results : null; |
| 461 |
|
} |
| 462 |
|
|
| 463 |
|
/** |
| 464 |
|
* Adds where clauses excluding desired identifiers from selection. |
|
@@ 554-563 (lines=10) @@
|
| 551 |
|
* |
| 552 |
|
* @return array with retrieved collection and amount of total records affected by this query |
| 553 |
|
*/ |
| 554 |
|
public function selectWherePaginated($where = '', $orderBy = '', $currentPage = 1, $resultsPerPage = 25, $useJoins = true, $slimMode = false) |
| 555 |
|
{ |
| 556 |
|
$qb = $this->genericBaseQuery($where, $orderBy, $useJoins, $slimMode); |
| 557 |
|
|
| 558 |
|
$page = $currentPage; |
| 559 |
|
|
| 560 |
|
$query = $this->getSelectWherePaginatedQuery($qb, $page, $resultsPerPage); |
| 561 |
|
|
| 562 |
|
return $this->retrieveCollectionResult($query, $orderBy, true); |
| 563 |
|
} |
| 564 |
|
|
| 565 |
|
/** |
| 566 |
|
* Adds quick navigation related filter options as where clauses. |