© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
3 replies
Noxo

Pagination inside modal

Any idea how to implement pagination inside modal?
It would be ideal to implement infinite scrolling, but this is still a dream.

i tried a way with pagination component but got redirect to -
https://demo.test/livewire/update?page=3
https://demo.test/livewire/update?page=3


with error:

The GET method is not supported for route livewire/update. Supported methods: POST.
The GET method is not supported for route livewire/update. Supported methods: POST.



My code:

Action class
class StockHistory extends Action
{
    public static function getDefaultName(): ?string
    {
        return 'stock-history';
    }

    protected function setUp(): void
    {
        parent::setUp();

        $this->label(__('admin.actions.stock_history.label'));
        $this->modalHeading(__('admin.actions.stock_history.heading'));
        $this->slideOver();
        $this->modalSubmitAction(false);
        $this->modalCancelAction(false);
        $this->color(ColorService::blue());
        $this->modalWidth(MaxWidth::Medium);
        $this->modalContent(function ($record): View {
            $history = $record->stockHistory()->paginate(4);

            return view('filament.stock-history', ['history' => $history]);
        });
    }
}
class StockHistory extends Action
{
    public static function getDefaultName(): ?string
    {
        return 'stock-history';
    }

    protected function setUp(): void
    {
        parent::setUp();

        $this->label(__('admin.actions.stock_history.label'));
        $this->modalHeading(__('admin.actions.stock_history.heading'));
        $this->slideOver();
        $this->modalSubmitAction(false);
        $this->modalCancelAction(false);
        $this->color(ColorService::blue());
        $this->modalWidth(MaxWidth::Medium);
        $this->modalContent(function ($record): View {
            $history = $record->stockHistory()->paginate(4);

            return view('filament.stock-history', ['history' => $history]);
        });
    }
}



Template file
{{ $history }}

<x-filament::pagination :paginator="$history" />
{{ $history }}

<x-filament::pagination :paginator="$history" />
Solution
Solution https://x.com/enunomaduro/status/1764566425421644025
Nuno Maduro (@enunomaduro) on X
Livewire Infinite Scrolling. 🤌🏻
Nuno Maduro (@enunomaduro) on X

Twitter

•

3/4/24, 8:19 AM

Jump to solution
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources
Was this page helpful?

Similar Threads

Recent Announcements

Similar Threads

Open action modals inside a modal
FilamentFFilament / ❓┊help
3y ago
open modal inside a modal
FilamentFFilament / ❓┊help
3y ago
Table inside Modal
FilamentFFilament / ❓┊help
8mo ago
Actions inside modal
FilamentFFilament / ❓┊help
3y ago