Assign current team when User is created

I have managed to integrate roles and permissions with users and multi-tenancy. My issue arises when registering a new user. I have created a new resource and properly associated the relationships between Team and User. In the user creation form, I have added the necessary fields to register a user. However, upon registration, the user is not being assigned to the current team. I am unsure which file I need to configure in order to assign the current team as soon as the user is saved.
11 Replies
krekas
krekas17mo ago
overwrite the base register class
Kerchack
KerchackOP17mo ago
Issue is not wit Team (Tenant) registrarion but with the user registration. I need, upon creating the user, for them to be assigned to the team where I am registering them.
krekas
krekas17mo ago
So you need custom registration
Kerchack
KerchackOP17mo ago
I've created filament resource for User. I think there is a way to assign current team on user creation but don't know how
Kerchack
KerchackOP17mo ago
I've found this
No description
Kerchack
KerchackOP17mo ago
That one better
No description
Kerchack
KerchackOP17mo ago
Last one solved my issue! 🙂
RichtheKid
RichtheKid17mo ago
@kerchack_ast Could you explain what you did exactly? Cannot seem to figure it out.
Jeff
Jeff16mo ago
@Kerchack - Any additional details or hints would be great. I can do this from ADMIN when adding a user, but how to do it on a public registration page?
ingmontoya
ingmontoya14mo ago
How did you manage the roles and permissions integration? did you use a plugin?

Did you find this page helpful?