How to redirect / route to list page after create #1153
Replies: 6 comments 6 replies
-
Try this, on the Create page class:
|
Beta Was this translation helpful? Give feedback.
-
It worked. Thank you very much.
…On Fri, 7 Jan 2022, 1:48 am Dan Harrin, ***@***.***> wrote:
Try this, on the Create page class:
protected function getRedirectUrl(): ?string
{
return static::getResource()::getUrl('index');
}
—
Reply to this email directly, view it on GitHub
<#1153 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEF3YBFQEBUIIVE3W7BQQWDUUX2HXANCNFSM5LMJZFYA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you authored the thread.Message ID:
***@***.***
com>
|
Beta Was this translation helpful? Give feedback.
-
Hi, I tried but I got this:
|
Beta Was this translation helpful? Give feedback.
-
Hi. I am looking for exactly the same. I found lots of defaults for all my resources I would like to customize. I know there is a place to customize this. Some boot method somewhere... |
Beta Was this translation helpful? Give feedback.
-
Send to edit page: protected function getRedirectUrl(): string {
return static::getResource()::getUrl('edit', [
'record' => $this->record
]);
} |
Beta Was this translation helpful? Give feedback.
-
Any way to set global redirect for createRecord using serviceProvider ? |
Beta Was this translation helpful? Give feedback.
-
Hello everyone. I am new to Laravel as well as to Filament. I am trying to create a small project and I have a small query. After the record is created I would like to route/redirect to the list page rather than edit page. I tried multiple ways but ended up either getting errors, redirected to edit page or end up in the same page. Any help would be much appreciated. Thanks
Beta Was this translation helpful? Give feedback.
All reactions