Skip to content

Commit

Permalink
filter integration
Browse files Browse the repository at this point in the history
  • Loading branch information
Raza9798 committed Aug 21, 2024
1 parent 5649b62 commit 394fa48
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
use Filament\Resources\Resource;
use Filament\Tables;
use Filament\Tables\Columns\TextColumn;
use Filament\Tables\Filters\SelectFilter;
use Filament\Tables\Table;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\SoftDeletingScope;
Expand Down Expand Up @@ -75,7 +76,10 @@ public static function table(Table $table): Table
->sortable(),
])
->filters([
//
SelectFilter::make('fk_menu_id')->label('Menu')
->options(
\App\Models\Menu::all()->pluck('name', 'id')
)
])
->actions([
Tables\Actions\EditAction::make(),
Expand Down
4 changes: 2 additions & 2 deletions resources/views/livewire/webrender.blade.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<x-guest-layout>
<section>
<div>
@if ($contents)
@foreach ($contents as $element)
{!! $element['content'] !!}
@endforeach
@else
<p>No content found</p>
@endif
</section>
</div>
</x-guest-layout>

0 comments on commit 394fa48

Please sign in to comment.