add action on infolist/view on relation manager?

Hello,

I have a relation manager between "customers" and "events".
So, on my customer resources pages I can see all their events.

When I click on one, I open an infolist.
Is there a way to add a button on the infolist when we're on a relation manager ?

I can't find anything about that

Thx!
Solution
I think you can just add the Infolist Actions component

so in you RelationManager class:

public function infolist(Infolist $infolist): Infolist
{
    return $infolist
        ->schema([
            TextEntry::make('id'),
            Actions::make([
                Actions\Action::make('custom_action')
                    ->action(fn () => dd('Custom action'))
            ]),
        ]);
}
Was this page helpful?