© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
13 replies
Kanalaetxebarria

Passing data to custom page through table action.

Hi, I'm trying to pass the current record to a custom page on a table action, however I can't seem to get the data. Here's my setup:

Layer resource, table actions:

->actions([
                Tables\Actions\EditAction::make(),
                Tables\Actions\Action::make('draw')
                    ->label('Draw')
                    ->url(fn (Layer $record): string => route('filament.resources.layers.draw', ['record' => $record]))
            ])
->actions([
                Tables\Actions\EditAction::make(),
                Tables\Actions\Action::make('draw')
                    ->label('Draw')
                    ->url(fn (Layer $record): string => route('filament.resources.layers.draw', ['record' => $record]))
            ])


Draw custom page blade view:

<x-filament::page>
    <div id="map">
        @dd($record)
    </div>
</x-filament::page>
<x-filament::page>
    <div id="map">
        @dd($record)
    </div>
</x-filament::page>


Error:
Undefined variable $record
Undefined variable $record
.

I can't find much on the docs. Any clues as to what might be going wrong?
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Custom Page Table Method Edit Action passing Current Record
FilamentFFilament / ❓┊help
13mo ago
Passing data to Bulk Action
FilamentFFilament / ❓┊help
3y ago
passing data to infolist action
FilamentFFilament / ❓┊help
3y ago
V4 Custom Page with Custom Data Table
FilamentFFilament / ❓┊help
8mo ago