mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
->when($this->country
This commit is contained in:
@@ -69,13 +69,13 @@ class MeetupTable extends DataTableComponent
|
||||
public function builder(): Builder
|
||||
{
|
||||
return Meetup::query()
|
||||
->when($this->country, fn($query, $country) => $query->whereHas('city.country',
|
||||
fn($query) => $query->where('code', $this->country)))
|
||||
->with([
|
||||
'users',
|
||||
'city.country',
|
||||
'meetupEvents',
|
||||
])
|
||||
->when($this->country, fn($query, $country) => $query->whereHas('city.country',
|
||||
fn($query) => $query->where('code', $this->country)))
|
||||
->withCount([
|
||||
'users',
|
||||
'meetupEvents' => fn($query) => $query->where('start', '>=', now()),
|
||||
|
||||
Reference in New Issue
Block a user