Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

myregistration's avatar

Route query string values don't persist with pagination in Filament Resource

I'm using a query string to set a value I need to persist between pagination pages because I use the request() field value with the Resource's getEloquentQuery() method to alter the query results for the Resource. I used dd() for testing and can see the first visit of the Resource page contains the request() field value, but when visit subsequent pagination pages, the value is null. If I refresh that page, the request field is available again. This makes me think request query string values are not getting persisted between pages when using pagination. The value of url()->current() is http://localhost/livewire/update when pages are missing the request() field value. Is this a bug? How can I resolve this? One way I've gotten it to persist is to use request()->session()->put() and request()->session()->get(), but this seems kludgy.

1 like
0 replies

Please or to participate in this conversation.