Activities of "mc86"

It's working now~ thanks

https://support.abp.io/QA/Questions/1433/How-to-add-extra-information-to-CurrentUserCheck the docs before asking a question: https://docs.abp.io/en/commercial/latest/ Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index The exact solution to your question may have been answered before, please use the search on the homepage.

If you're creating a bug/problem report, please include followings:

  • ABP Framework version: v5.1
  • UI type: Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:"

https://docs.abp.io/en/abp/latest/Authorization#advanced-topics https://support.abp.io/QA/Questions/1433/How-to-add-extra-information-to-CurrentUser Hi I want to get currentuser's OU ID, I followed the doc add codes below in my service domain project. then use this.CurrentUser.FindClaim("OrganizationId"); to get OrganizationId in my blazor project. but it always is null. what do i miss?

public class OrgClaimsPrincipalContributor : IAbpClaimsPrincipalContributor, ITransientDependency
    {
        public async Task ContributeAsync(AbpClaimsPrincipalContributorContext context)
        {
            //var identity = context.ClaimsPrincipal.Identities.FirstOrDefault();
            //var userId = identity?.FindUserId();
            //if (userId.HasValue)
            //{
            //    //var userService = context.ServiceProvider.GetRequiredService<IdentityUserAppService>(); //Your custom service
            //    //var OrgList = await userService.GetOrganizationUnitsAsync(userId.Value);
            //    //var Org = OrgList.ToList().FirstOrDefault();
            //    //if (Org != null)
            //    //{
            //    //    var Claim = new Claim("OrganizationId", "123");
            //    //    identity.AddClaim(Claim);
            //    //}

            //    var Claim = new Claim("OrganizationId", "123");
            //    identity.AddClaim(Claim);
            //}

            var identity = context.ClaimsPrincipal.Identities.FirstOrDefault();
            identity.AddClaim(new Claim("OrganizationId", "OrganizationValue"));
        }
    }
var orgid = this.CurrentUser.FindClaim("OrganizationId");

thanks gterdem .

  • ABP Framework version: v5.1.3
  • UI type: Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:" Hi In microservice-template can't use navigation properties cross services that are very inconvenient。 So any solutions?
  • ABP Framework version: v5.1.3
  • UI type: Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes
  • Exception message and stack trace:
  • Steps to reproduce the issue:"

HI somehow I got this error. now I can't log in.

System.Text.Json causes the problem. It's working now. tks.

HI maliming

still the same.

Hi maliming The problem is not caused by caching . The method get correct data but after I call it from swagger, I just got " [{},{},{}]" what do I miss?

https://docs.abp.io/en/abp/latest/Caching I see the IDistributedCache internally serializes/deserializes the cached objects in the doc.

I tested

string json = JsonConvert.SerializeObject(List<PORItem>); is worked fine.

It worked in CP.IdentityService I got data from DB but after put the DB in cache , every data is incorrect what do I miss?

Showing 81 to 90 of 122 entries
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.1.0-preview. Updated on December 17, 2025, 07:08
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.