F
Filament8mo ago
anjama

Create child entries in RelationManager on view page of parent resource

I have a CreateAction for a RelationManager to a child resource, but it only shows up if a user navigates to the edit page of the parent resource (same with edit and delete actions in the RelationManager). It does not show up on the view page for the parent resource. This means users have to be given permissions to edit the parent resource when they shouldn't be able to do so. Am I missing something to enable adding child entries via the RelationManger from the view page of the parent resource?
2 Replies
Solution
hrank8t
hrank8t8mo ago
https://filamentphp.com/docs/3.x/panels/resources/relation-managers#read-only-mode Just use public function isReadOnly(): bool { return false; } on the relation manager and on view page you can add/edit records
anjama
anjamaOP8mo ago
Oh wow, I don't how many times I've been in the RelationManager docs and just completely missed that. Thank you
Want results from more Discord servers?
Add your server