This commit is contained in:
Kekskurse 2021-02-08 01:25:30 +01:00
parent 1e805fc769
commit 0ac289a1ee

View file

@ -41,7 +41,7 @@ class PublicController extends BaseController
$g = collect($galleries); $g = collect($galleries);
$r = $g->forPage($request->input("page", 1), 10); $r = $g->forPage($request->input("page", 1), 10);
return response()->json(["pagination" => ["total" => $g->count(), "pages" => ($g->count() / 10)], "data" => \App\Http\Resources\Gallery::collection($r)]); return response()->json(["pagination" => ["total" => $g->count(), "items_per_page" => 10, "pages" => ($g->count() / 10)], "data" => \App\Http\Resources\Gallery::collection($r)]);
} }
public function listGalleriesView($name, Request $request) { public function listGalleriesView($name, Request $request) {
$tenant = Tenant::query()->where("url", "=", $name)->firstOrFail(); $tenant = Tenant::query()->where("url", "=", $name)->firstOrFail();