You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Tab component seems to be the only layout component that does not allow you to define a relationship on it, and I can't seem to figure out why - no discussion about it possibly being implemented but it being discarded for a valid reason, no mention of it being the case previously but it being removed because of some issue, no mention of it not being the case nor why in the documentation.
I've personally found myself with multiple HasOne relationships which I'd like to group into tabs, and currently the only way to do it is to put another layout component inside each Tab to define the relationship. I find this to be needlessly cumbersome.
Testing locally, just by adding the relevant interface and trait (Filament\Schemas\Components\Contracts\CanEntangleWithSingularRelationships and Filament\Schemas\Components\Concerns\EntanglesStateWithSingularRelationship) to the Tab class, it seems to be working and existing tests didn't break.
I guess my question is, why is this not a thing already? Are there some hidden challenges in implementing this?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
The Tab component seems to be the only layout component that does not allow you to define a relationship on it, and I can't seem to figure out why - no discussion about it possibly being implemented but it being discarded for a valid reason, no mention of it being the case previously but it being removed because of some issue, no mention of it not being the case nor why in the documentation.
I've personally found myself with multiple HasOne relationships which I'd like to group into tabs, and currently the only way to do it is to put another layout component inside each Tab to define the relationship. I find this to be needlessly cumbersome.
Testing locally, just by adding the relevant interface and trait (
Filament\Schemas\Components\Contracts\CanEntangleWithSingularRelationships
andFilament\Schemas\Components\Concerns\EntanglesStateWithSingularRelationship
) to the Tab class, it seems to be working and existing tests didn't break.I guess my question is, why is this not a thing already? Are there some hidden challenges in implementing this?
Beta Was this translation helpful? Give feedback.
All reactions