© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
9 replies
rubendn

Display Action Text in Table as Button

Using the following code below, is there a simple way to change the current Icon and Text for the Action to a button instead without having to create a custom column?

    protected function getTableActions(): array
    {
        return [
            Action::make('updateShipping')
                ->action(function (Model $record, array $data): void {
                    $record->ConfirmationNumber = $data['ConfirmationNumber'];
                    $record->save();
                    \Mail::to($record->EmailAddress)->send(new \App\Mail\TrackingNumber($record));
                })
                ->icon('heroicon-o-truck')
                ->label('SHIP')
            ->form([
                 TextInput::make('ConfirmationNumber')
                    ->label('Delivery Confirmation #')
                    ->required(),
                ])

        ];

    }
    protected function getTableActions(): array
    {
        return [
            Action::make('updateShipping')
                ->action(function (Model $record, array $data): void {
                    $record->ConfirmationNumber = $data['ConfirmationNumber'];
                    $record->save();
                    \Mail::to($record->EmailAddress)->send(new \App\Mail\TrackingNumber($record));
                })
                ->icon('heroicon-o-truck')
                ->label('SHIP')
            ->form([
                 TextInput::make('ConfirmationNumber')
                    ->label('Delivery Confirmation #')
                    ->required(),
                ])

        ];

    }
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

Button->Action to copy text?
FilamentFFilament / ❓┊help
2y ago
How to use toggle button as action button in repeater
FilamentFFilament / ❓┊help
10mo ago
Change button text for built in table actions
FilamentFFilament / ❓┊help
3y ago
table in action
FilamentFFilament / ❓┊help
2y ago