Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Same user working for Multiple Tenants? #894


User avatar
0
duncanwilson created

Good afternoon,

I have a question related to Multi Tenancy.

Let's imagine that John Doe works in the morning for Tenant 1 and in the afternoon for Tenant 2. Does he need to register twice? once for each Tenant?

Best regards, Duncan


2 Answer(s)
  • User Avatar
    0
    paddyfink created

    Hello ABP team,

    I had a similar question, so I will ask it on this thread.

    In a future scenario, I would like users to be able to sign in without specify the tenant. And in the case they belongs to multiple tenants, they would be able to select, and also change tenant via the menu like Duncan suggest.

    What would be the options to accomplish that? Write a custom AbpUserManager class?

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    @DunconWilson, I have replied your answer here #895@e63dbf3a-45c1-43a1-8e59-d04e6ae96ab5.

    If it does not cover all of your questions, lets continue from that topic.

    @Paddyfink, You can use the same scenario but if you want users to login without specifying tenant, you have to change AccountController's Login code.

    • Disable tenancy filter.
    • Find tenant of user, then login user for this tenant.
    • If there are more than one tenant matches, redirect to some tenant selection page. Then login user for selected tenant.

    I hope this helps.