mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-05 15:29:50 +00:00
rename methods for more clarity
This commit is contained in:
parent
dadde29bc2
commit
d6b1216021
@ -34,8 +34,8 @@ class NewsItemHistoryController extends AbstractController
|
||||
public function listAction(Request $request): Response
|
||||
{
|
||||
$filter = $this->buildFilterOrder(false);
|
||||
$total = $this->newsItemRepository->countAllFilteredByUser($filter->getQueryString());
|
||||
$newsItems = $this->newsItemRepository->findAllFilteredByUser($filter->getQueryString());
|
||||
$total = $this->newsItemRepository->countAllFilteredBySearchTerm($filter->getQueryString());
|
||||
$newsItems = $this->newsItemRepository->findAllFilteredBySearchTerm($filter->getQueryString());
|
||||
|
||||
$pagination = $this->paginatorFactory->create($total);
|
||||
|
||||
|
@ -71,7 +71,7 @@ class NewsItemRepository implements ObjectRepository
|
||||
return $qb;
|
||||
}
|
||||
|
||||
public function findAllFilteredByUser(string $pattern = null)
|
||||
public function findAllFilteredBySearchTerm(string $pattern = null)
|
||||
{
|
||||
$qb = $this->buildBaseQuery($pattern);
|
||||
$qb->addOrderBy('n.startDate', 'DESC')
|
||||
@ -97,7 +97,7 @@ class NewsItemRepository implements ObjectRepository
|
||||
->getResult();
|
||||
}
|
||||
|
||||
public function countAllFilteredByUser(string $pattern = null)
|
||||
public function countAllFilteredBySearchTerm(string $pattern = null)
|
||||
{
|
||||
$qb = $this->buildBaseQuery($pattern);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user