FilamentF
Filament3y ago
mxc

Custom route with path parameters for custom page

Hi there,

I have create a custom page with

php artisan make:filament-page MyPage


I would like to change the path and add a path parameter but can't find how to do it. I read I should override the method "public static function route($record)" in my page class but this has had no effect. How do I modify the route for a generated custom page?

Thanks
Solution
Ok the error is due to as I had it registered for navigation and it requires an id in the url. I removed it from the navigation component with "protected static bool $shouldRegisterNavigation = false;" Now it works.
Was this page helpful?