Activities of "maliming"

hi

I will contact you by WeChat.

hi @abpVAndy

请分享这个请求的详细日志. 请把日志级别调整到最低Trace或者Debug

if you could just point us in the direction of an example that does what we're trying to achieve

ok, Please create a new brand project and send it to me, I will update it and get back to you. liming.ma@volosoft.com

hi

I think you can add email to id_token in your azure AD settings. https://docs.microsoft.com/en-us/azure/active-directory/develop/active-directory-optional-claims

or you can test with the below code.

private void ConfigureExternalProviders(ServiceConfigurationContext context)
    {
        context.Services.AddAuthentication()
            .AddMicrosoftIdentityWebApp(
                microsoftIdentityOptions =>
                {
                    microsoftIdentityOptions.Instance = "https://login.microsoftonline.com/";
                    microsoftIdentityOptions.Domain = "xxx";
                    microsoftIdentityOptions.TenantId = "xxx";
                    microsoftIdentityOptions.ClientId = "xxx";
                    microsoftIdentityOptions.ClientSecret = "xxx";
                    microsoftIdentityOptions.CallbackPath = "/signin-azuread-oidc";
                    microsoftIdentityOptions.SignedOutCallbackPath = "/signout-callback-oidc";

                    microsoftIdentityOptions.SignInScheme = IdentityConstants.ExternalScheme;
                },
                cookieAuthenticationOptions => { },
                OpenIdConnectDefaults.AuthenticationScheme,
                null);

        context.Services.PostConfigure<OpenIdConnectOptions>(OpenIdConnectDefaults.AuthenticationScheme, options =>
        {
            // Add email to id_token in your azure AD settings.
            options.ClaimActions.Add(new AddEmailClaim());
        });
    }
public class AddEmailClaim : ClaimAction
{
    public AddEmailClaim()
        : base(null, null)
    {
    }

    public override void Run(JsonElement userData, ClaimsIdentity identity, string issuer)
    {
        var preferred_username = identity.Claims.FirstOrDefault(x => x.Type == "preferred_username");
        if (preferred_username != null)
        {
            identity.AddClaim(new Claim(AbpClaimTypes.Email, preferred_username.Value));
        }
    }
}

hi

The LocalizationSettingNames.DefaultLanguage is a setting so you can change via https://docs.abp.io/en/abp/latest/Settings

how I can use it to translate string

https://docs.abp.io/en/abp/latest/Localization

hi

Yes, I will test is asap.

hi

Let's discuss this in https://support.abp.io/QA/Questions/3604#answer-999438a9-65ca-2b2d-72d6-3a060dff6511

hi

You can get language settings after changing to the tenant.

using (CurrentTenant.Change(tenantId))
{
    var defaultLanguage = await settingProvider.GetOrNullAsync(LocalizationSettingNames.DefaultLanguage);
}

hi

https://community.abp.io/posts/unifying-dbcontexts-for-ef-core-removing-the-ef-core-migrations-project-nsyhrtna

hi

You just need to share your azure info like

and a test account username & password

I will check `we know that claim is certainly available - but it does not appear to be working.

Showing 7581 to 7590 of 10651 entries
Learn More, Pay Less
33% OFF
All Trainings!
Get Your Deal
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.0.0-preview. Updated on September 12, 2025, 07:47