Base solution for your next web application
Open Closed

AUTOMATICALLY DETECT TENANT ON LOGIN #9608


User avatar
0
alfar_re created

Hi,

How can I detect the current user/ tenant from the login page without using the tenant selection or subdomain?

  • ASP.NET
  • MVC
  • .NET CORE
  • Latest ABP Framework according to Zero 9.1

28 Answer(s)
  • User Avatar
    0
    alfar_re created

    Hi @ismcagdas,

    Great. Thank you.

  • User Avatar
    0
    CrayonGroupSCA created

    Would it be possible to post the final solution here so that others (including myself) could benefit from it?

  • User Avatar
    0
    alfar_re created

    Yes, sure.

    So, I created a new action and called it AdminLogin. This is used by the admins only. The default login has a modified login method that detects tenant users automatically.