Commit a3053ac3 authored by Viral Solani's avatar Viral Solani Committed by StyleCI Bot

Apply fixes from StyleCI

parent c7999c03
......@@ -31,9 +31,9 @@ class BlogCategoriesController extends APIController
*/
public function index(Request $request)
{
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
return BlogCategoriesResource::collection(
$this->repository->getForDataTable()->orderBy($sortBy, $orderBy)->paginate($limit)
......
......@@ -29,9 +29,9 @@ class DeactivatedUsersController extends APIController
*/
public function index(Request $request)
{
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
return UserResource::collection(
$this->repository->getForDataTable(0, false)->orderBy($sortBy, $orderBy)->paginate($limit)
......
......@@ -29,9 +29,9 @@ class DeletedUsersController extends APIController
*/
public function index(Request $request)
{
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
return UserResource::collection(
$this->repository->getForDataTable(0, true)->orderBy($sortBy, $orderBy)->paginate($limit)
......
......@@ -29,9 +29,9 @@ class FaqsController extends APIController
*/
public function index(Request $request)
{
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
return FaqsResource::collection(
$this->repository->getForDataTable()->orderBy($sortBy, $orderBy)->paginate($limit)
......
......@@ -29,9 +29,9 @@ class PagesController extends APIController
*/
public function index(Request $request)
{
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
$limit = $request->get('paginate') ? $request->get('paginate') : 25;
$orderBy = $request->get('orderBy') ? $request->get('orderBy') : 'ASC';
$sortBy = $request->get('sortBy') ? $request->get('sortBy') : 'created_at';
return PagesResource::collection(
$this->repository->getForDataTable()->orderBy($sortBy, $orderBy)->paginate($limit)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment