© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
2 replies
buhbailey

Conditionally Show RelationManager in a View

Is there a way to only show the relation manager tab below on a resource page if a certain property in the model is equal to a value? The getRelations method doesn't seem to accept any arguments. I have quite a few hasMany relationships for my main page/model and would like to eliminate a few of the tabs where they are not applicable.

For example, I have an AccountResource page. The account has 10 hasMany relationships to which I’ve created relationship managers and added them to the getRelations static function. If the account is type “A” for example, only 7 of them are applicable. If the account is type “B” a different set of 8 are applicable.

Can this be done?
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

RelationManager in view
FilamentFFilament / ❓┊help
2y ago
Click ViewAction in RelationManager to view resource
FilamentFFilament / ❓┊help
14mo ago
view for relationManager
FilamentFFilament / ❓┊help
3y ago
conditionally show editForm in Select
FilamentFFilament / ❓┊help
14mo ago