© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
1 reply
Sujay Barma

Rendering Livewire Table Using Wizard Step in Resource

Trying to display a table in multistep form Wizard. To Generate the table I am using Livewire component.
// Resource file code
 return [
            Wizard::make()
                ->steps([
                    Step::make('Select Channels')
                        ->schema([
                            TextInput::make('search')
                                ->label('Search Channels')
                                ->placeholder('Search channels...')
                                ->reactive()
                                ->afterStateUpdated(function ($state, $get, $set) {
                                }),
                            Forms\Components\ViewField::make('channelTable')
                                ->view('livewire.channel-table'), // Embed the Livewire component
                        ]),
 return [
            Wizard::make()
                ->steps([
                    Step::make('Select Channels')
                        ->schema([
                            TextInput::make('search')
                                ->label('Search Channels')
                                ->placeholder('Search channels...')
                                ->reactive()
                                ->afterStateUpdated(function ($state, $get, $set) {
                                }),
                            Forms\Components\ViewField::make('channelTable')
                                ->view('livewire.channel-table'), // Embed the Livewire component
                        ]),

// Livewire component.
class ChannelTable extends Component implements HasTable
{
    use Tables\Concerns\InteractsWithTable;
    public function table(Tables\Table $table): Tables\Table
    {
        return $table
            ->columns([CheckboxColumn::make('selected')
                    ->label('Select')
                    ->toggleable()
                    ->bulkToggleable(),
                TextColumn::make('name')
                    ->label('Channel Name')
                    ->sortable()
                    ->searchable(),
            ])
            ->filters([
                Tables\Filters\Filter::make('search')
                ->query(fn ($query, $search) => $query->where('name', 'like', "%{$search}%")),
            ])
            ->query(fn () => Channel::query()) 
            ->paginated(10) 
            ->defaultSort('name'); 
    }

    public function render()
    {
        return view('livewire.channel-table'); 
    }

    public function makeFilamentTranslatableContentDriver(): ?TranslatableContentDriver
    {
        return null; 
    }
}
class ChannelTable extends Component implements HasTable
{
    use Tables\Concerns\InteractsWithTable;
    public function table(Tables\Table $table): Tables\Table
    {
        return $table
            ->columns([CheckboxColumn::make('selected')
                    ->label('Select')
                    ->toggleable()
                    ->bulkToggleable(),
                TextColumn::make('name')
                    ->label('Channel Name')
                    ->sortable()
                    ->searchable(),
            ])
            ->filters([
                Tables\Filters\Filter::make('search')
                ->query(fn ($query, $search) => $query->where('name', 'like', "%{$search}%")),
            ])
            ->query(fn () => Channel::query()) 
            ->paginated(10) 
            ->defaultSort('name'); 
    }

    public function render()
    {
        return view('livewire.channel-table'); 
    }

    public function makeFilamentTranslatableContentDriver(): ?TranslatableContentDriver
    {
        return null; 
    }
}

//blade
 {{ $this->table }} 
 {{ $this->table }} 
loop_error.PNG
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources
Was this page helpful?

Similar Threads

Recent Announcements

Similar Threads

Resource as wizard step
FilamentFFilament / ❓┊help
7mo ago
Two Table in one resource using wizard
FilamentFFilament / ❓┊help
3y ago
Using Resource table in custom livewire component
FilamentFFilament / ❓┊help
2y ago
Showing Table in Wizard (Custom Livewire component)
FilamentFFilament / ❓┊help
5mo ago