This commit is contained in:
James Cole 2020-08-08 17:17:09 +02:00
parent 6d627be679
commit 87c134322d
No known key found for this signature in database
GPG Key ID: B5669F9493CDE38D
3 changed files with 1 additions and 17 deletions

View File

@ -88,7 +88,6 @@ class SearchController extends Controller
$searcher->parseQuery($fullQuery);
$searcher->setPage($page);
$searcher->setLimit((int) config('firefly.search_result_limit'));
$groups = $searcher->searchTransactions();
$hasPages = $groups->hasPages();
$searchTime = round($searcher->searchTime(), 3); // in seconds

View File

@ -48,8 +48,6 @@ class Search implements SearchInterface
private $budgetRepository;
/** @var CategoryRepositoryInterface */
private $categoryRepository;
/** @var int */
private $limit = 100;
/** @var Collection */
private $modifiers;
/** @var string */
@ -156,7 +154,7 @@ class Search implements SearchInterface
public function searchTransactions(): LengthAwarePaginator
{
Log::debug('Start of searchTransactions()');
$pageSize = 50;
$pageSize = (int) config('firefly.search_result_limit');
/** @var GroupCollectorInterface $collector */
$collector = app(GroupCollectorInterface::class);
@ -172,14 +170,6 @@ class Search implements SearchInterface
}
/**
* @param int $limit
*/
public function setLimit(int $limit): void
{
$this->limit = $limit;
}
/**
* @param User $user
*/

View File

@ -66,11 +66,6 @@ interface SearchInterface
*/
public function searchTransactions(): LengthAwarePaginator;
/**
* @param int $limit
*/
public function setLimit(int $limit);
/**
* @param User $user
*/