Small changes
This commit is contained in:
parent
fb7704027b
commit
33b236d881
|
|
@ -27,7 +27,7 @@ public function index(Client $client, Request $request)
|
|||
->where('person.full_name', 'ilike', '%'.$search.'%')
|
||||
->groupBy('clients.id');
|
||||
})
|
||||
->where('clients.active', 1)
|
||||
//->where('clients.active', 1)
|
||||
// Use LEFT JOINs for aggregated data to avoid subqueries
|
||||
->leftJoin('client_cases', 'client_cases.client_id', '=', 'clients.id')
|
||||
->leftJoin('contracts', function ($join) {
|
||||
|
|
@ -51,7 +51,7 @@ public function index(Client $client, Request $request)
|
|||
|
||||
return Inertia::render('Client/Index', [
|
||||
'clients' => $query
|
||||
->paginate($request->integer('per_page', 15))
|
||||
->paginate($request->integer('per_page', default: 100))
|
||||
->withQueryString(),
|
||||
'filters' => $request->only(['search']),
|
||||
]);
|
||||
|
|
|
|||
|
|
@ -162,7 +162,7 @@ const fmtCurrency = (v) => {
|
|||
</script>
|
||||
|
||||
<template>
|
||||
<AppLayout>
|
||||
<AppLayout title="Clients">
|
||||
<template #header> </template>
|
||||
<div class="py-6">
|
||||
<div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
|
||||
|
|
@ -201,6 +201,7 @@ const fmtCurrency = (v) => {
|
|||
:show-pagination="false"
|
||||
:show-toolbar="true"
|
||||
:hoverable="true"
|
||||
:page-size="100"
|
||||
row-key="uuid"
|
||||
:striped="true"
|
||||
empty-text="Ni najdenih naročnikov."
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user