30
Views
4
Comments
Solved
Create user on different user provider
Question

Hello,

I'm developing a new application which consists in 2 espaces:

Espace 1: accessible by company users, using a specific user provider that we created based on what we need.

Espace 2: accessible by our customers, using the default user provider, but in a specific tenant.


On Espace 1, our company users need to be able to create the users that will access espace 2, but when i try to use CreateOrUpdate_User from the default users module, it creates on the specific user provider that we have, and not on the default one. If i try to do a TenantSwitch before the create action, it throws me an error stating that i can't switch to a tenant from a different user provider.

Doing an advanced query with insert statement works fine, but when trying to log in it throws invalid username or password, probably because of the password encryption method.


Any ideais on how to achieve this?

Thanks.

mvp_badge
MVP
Rank: #56
Solution

Hi Rafael ,

When you use a different user provider and than Users (Default)  and use it in other application than at the time of login platform internally matches this users with the users who are created using the new user Provider and not with the users created by default User Provider .

You have to create users with the new user provider and than you can use these user to login wherever you are using this module as User Provider.


Regards,

-PJ- 

mvp_badge
MVP
Rank: #157

Hi Rafael,

Did you use the EncryptPassword action?


mvp_badge
MVP
Rank: #56
Solution

Hi Rafael ,

When you use a different user provider and than Users (Default)  and use it in other application than at the time of login platform internally matches this users with the users who are created using the new user Provider and not with the users created by default User Provider .

You have to create users with the new user provider and than you can use these user to login wherever you are using this module as User Provider.


Regards,

-PJ-