Open Closed

adding the multi-tenancy feature #8841


User avatar
0
LiSong created
  • ABP Framework version: v9.X.X

  • UI Type: MVC

  • Database System: SQL Server

  • Tiered (for MVC) or Auth Server Separated (for Angular): no

  • Exception message and full stack trace:

  • Steps to reproduce the issue:

I have a running ABP website that does not support multi-tenancy. How should I add the multi-tenancy feature to this website?


6 Answer(s)
  • User Avatar
    0
    enisn created
    Support Team .NET Developer

    Hi there,

    Can you provide me more information?

    Didn't you check this checkbox while creating a new project?

    image.png

    If not, your project is still configured to use multi-tenancy and it's disabled, Navigate to MultiTenancyConsts.cs and enable it easily:

    public static class MultiTenancyConsts
    {
        // Set this to 'true' 👇
        public const bool IsEnabled = true;
    }
    
  • User Avatar
    0
    LiSong created

    my project was not configured to use multi-tenacy when I created it. I enabled it through code
    I created a new project with "enable multi tenancy" checkbox
    and then, I checked the database schema, seems like they are different

  • User Avatar
    0
    berkansasmaz created
    Support Team .NET Developer

    Yes, this is normal, adding the TenantId column. If you want to activate MultiTenancy after creating the project. You can follow the steps below:

    1. Navigate to MultiTenancyConsts.cs and enable it easily:

    public static class MultiTenancyConsts
    {
        // Set this to 'true' 👇
        public const bool IsEnabled = true;
    }
    
    1. Add new migration

    2. Run DBMigrator

  • User Avatar
    0
    LiSong created

    I need to modify the title and content of the Email Confirmation email template. Is there a way to apply my modifications to all tenants? Or can tenants inherit the title and content from the tenant with tenantId set to null (host)? so I don't need to update for each tenant one by one.

    These modifications involve language texts and text templates.

    Screenshot 2025-03-03 122453.png
    Screenshot 2025-03-03 122533.png

  • User Avatar
    0
    LiSong created

    hi can you look at the question above? or should I create a new ticket?

  • User Avatar
    0
    berkansasmaz created
    Support Team .NET Developer

    Hello,

    You can create a new ticket. Thanks

Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
Do you need assistance from an ABP expert?
Schedule a Meeting
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v9.2.0-preview. Updated on March 13, 2025, 04:08