Respect pagination settings on frontend

closes #1335
This commit is contained in:
Dane Everitt 2018-11-10 12:38:35 -08:00
parent 8af50e1d1a
commit a9fa60a6fb
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
5 changed files with 8 additions and 7 deletions

View file

@ -35,7 +35,7 @@ class ClientController extends ClientApiController
*/
public function index(GetServersRequest $request): array
{
$servers = $this->repository->filterUserAccessServers($request->user(), User::FILTER_LEVEL_SUBUSER);
$servers = $this->repository->filterUserAccessServers($request->user(), User::FILTER_LEVEL_SUBUSER, config('pterodactyl.paginate.frontend.servers'));
return $this->fractal->collection($servers)
->transformWith($this->getTransformer(ServerTransformer::class))

View file

@ -56,7 +56,7 @@ class IndexController extends Controller
public function getIndex(Request $request)
{
$servers = $this->repository->setSearchTerm($request->input('query'))->filterUserAccessServers(
$request->user(), User::FILTER_LEVEL_ALL
$request->user(), User::FILTER_LEVEL_ALL, config('pterodactyl.paginate.frontend.servers')
);
return view('base.index', ['servers' => $servers]);