© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•15mo ago•
2 replies
lukaveck1

Soft deleted records don't show after applying filter

I'm having weird problem with filament, I have 4 soft deleted profiles and added a filter to show them in ProfileResource, but none are getting shown in table, if I dd the query it's also showing correct SQL for return $query->onlyTrashed():

Sql dump:
"select * from `profiles` where `profiles`.`deleted_at` is not null and `profiles`.`account_id` in (?)" // app/Filament/App/Resources/ProfileResource.php:327

array:1 [▼ // app/Filament/App/Resources/ProfileResource.php:327
  0 => 422
]
"select * from `profiles` where `profiles`.`deleted_at` is not null and `profiles`.`account_id` in (?)" // app/Filament/App/Resources/ProfileResource.php:327

array:1 [▼ // app/Filament/App/Resources/ProfileResource.php:327
  0 => 422
]


ProfileResource.php

->filters([
    Tables\Filters\Filter::make('Trashed')
        ->query(fn ($query) => ( dd($query->onlyTrashed()->toSql(), $query->getBindings() )))
        ->label('Trashed')
        ->toggle()
])
->filters([
    Tables\Filters\Filter::make('Trashed')
        ->query(fn ($query) => ( dd($query->onlyTrashed()->toSql(), $query->getBindings() )))
        ->label('Trashed')
        ->toggle()
])
image.png
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

unique validation on soft-deleted records
FilamentFFilament / ❓┊help
3y ago
Soft-deleted relations
FilamentFFilament / ❓┊help
2y ago
Soft-deleted relations
FilamentFFilament / ❓┊help
2y ago