Resources / Simple resources

I have a resource that I'm working with. When I set my actions with ->url(null), it transforms my page into a form modal. I'm wondering if this is the correct approach when I want to set my resource (or a specific page) as "simple," or if I should regenerate my resource with the "simple" option instead.
class ListPosts extends ListRecords
{
protected static string $resource = PostResource::class;

protected function getHeaderActions(): array
{
return [
Actions\CreateAction::make()
->url(null),
];
}
}
class ListPosts extends ListRecords
{
protected static string $resource = PostResource::class;

protected function getHeaderActions(): array
{
return [
Actions\CreateAction::make()
->url(null),
];
}
}
2 Replies
Dan Harrin
Dan Harrin14mo ago
just remove the pages from getPages() in the resource leave the list page you dont need to url(null)
LeandroFerreira
LeandroFerreira14mo ago
Perfect! thank you!