Learn More, Pay Less!
Limited Time Offer!
Open Closed

Login screen tenant localization #8712


User avatar
0
stephanobalbinot created
  • ABP Framework version: v9.0.0
  • UI Type: Angular
  • Database System: EF Core (PostgreSQL)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes
  • Exception message and full stack trace:
  • Steps to reproduce the issue:

Is it possible to change localizations of the tenant related text on the login screen?


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

    Hi,

    Localizations comes from here: https://github.com/abpframework/abp/blob/664af59cd7778b40b635540d6213d7b6b0985dea/framework/src/Volo.Abp.AspNetCore.Mvc.UI.MultiTenancy/Volo/Abp/AspNetCore/Mvc/UI/MultiTenancy/Localization/en.json#L4-L11

    You can add this keys into localization json file and override AbpUiMultiTenancyResource by following this documentation: https://abp.io/docs/latest/framework/fundamentals/localization#extending-existing-resource

    
    Configure<AbpLocalizationOptions>(options =>
    {
        // ...
    
        options.Resources
            .Get<AbpUiMultiTenancyResource>()
            .AddVirtualJson("/Localization/YourProjectResource");
    
        // ...
    });
    

    Note that: Your .Domain.Shared module probably won't have reference for AbpUiMultiTenancyResource class. So, you'll need to do that in the host application such as .Web or HttpApi.Host or .AuthServer according to your configuration.

  • User Avatar
    1
    enisn created
    Support Team .NET Developer

    Alternatively

    If you use Language management module, you'll need to update value in the UI

    • Navigate to Language Management > Language Texts in the menu.
    • Choose AbpUiMultiTenancy in the Resource Name dropdown and update translation of given texts.
  • User Avatar
    0
    stephanobalbinot created

    Thanks!

  • User Avatar
    0
    stephanobalbinot created

    I added this code in my AuthServerModule.cs ConfigureServices method

    and this in my AuthServer.csproj

    Also added this in my HttpApiHostModule.cs ConfigureServices method

    and this in my HttpApi.Host.csproj

    But it didn't work, the localization texts doesn't appear on the UI, neither are on the database.

    I tried creating a development environment from scratch, cleaning and building the solution, deleting existing databases, clearing redis cache and running dbmigrator then authserver, api and angular frontend.

  • User Avatar
    0
    stephanobalbinot created

    I'm extending some localization resources in my Domain.Shared project and it's working fine there.

    DomainSharedModule.cs

    Domain.Shared.csproj

  • User Avatar
    0
    mtozdemir created
    Support Team

    Should we assume that this ticket is resolved?

Made with ❤️ on ABP v9.2.0-preview. Updated on February 13, 2025, 10:35