Single select with belongsToMany relationship
I have a tenant system, users with teams. I want to create user and attach it to teams (team_user database), but I want to select only one team on select form because user can be in one team only, not on multiple. how can I do this correctly?
Solution:Jump to solution
I use normal Select or relationship (without multiple) and handle manually using Lifecycle Hooks
3 Replies
Not best solution but maybe you can use like this;
This prevent multi select, but UI is not great IMO
Solution
I use normal Select or relationship (without multiple) and handle manually using Lifecycle Hooks