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
krekas2y ago
overwrite the base register class
Kerchack
KerchackOP2y 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
krekas2y ago
So you need custom registration
Kerchack
KerchackOP2y 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
KerchackOP2y ago
I've found this
No description
Kerchack
KerchackOP2y ago
That one better
No description
Kerchack
KerchackOP2y ago
Last one solved my issue! 🙂
RichtheKid
RichtheKid2y ago
@kerchack_ast Could you explain what you did exactly? Cannot seem to figure it out.
Jeff
Jeff17mo 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
ingmontoya15mo ago
How did you manage the roles and permissions integration? did you use a plugin?

Did you find this page helpful?