© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
6 replies
Hasith

Notification inside a table action

How can i add notification inside an action?

    ->actions([

          Tables\Actions\ViewAction::make(),
          TableAction::make('delete')
          ->requiresConfirmation()
          ->color('danger')
          ->icon('heroicon-s-trash')
          ->action(function (User $record) {

              Log::info($record);
              if($record->id == 1){
                  Notification::make()
                  ->success()
                  ->title('User deleted')
                  ->body('The user has been deleted successfully.');
              }else{
                  return;
              }

            }),
      ])
    ->actions([

          Tables\Actions\ViewAction::make(),
          TableAction::make('delete')
          ->requiresConfirmation()
          ->color('danger')
          ->icon('heroicon-s-trash')
          ->action(function (User $record) {

              Log::info($record);
              if($record->id == 1){
                  Notification::make()
                  ->success()
                  ->title('User deleted')
                  ->body('The user has been deleted successfully.');
              }else{
                  return;
              }

            }),
      ])
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

notification inside action not showing
FilamentFFilament / ❓┊help
2y ago
Modal action or table inside form
FilamentFFilament / ❓┊help
2y ago
Notification after successful edit via table action
FilamentFFilament / ❓┊help
3y ago
How to dispatch action using Notification inside a ListRecord class
FilamentFFilament / ❓┊help
2y ago