Activities of "liangshiwei"

Okay, please email me shiwei.liang@volosoft.com.

Also, We will write a guide to help switch to MongoDB, I will reply when the guide is complete.

https://support.abp.io/QA/Questions/2048#answer-19bfe83b-b01c-b16e-b693-39ffee15987a

Just a reminder:

When you upgrade to 5.0, please replace "Volo.Abp.Identity.EntityFrameworkCore.IIdentityProDbContext" with AbpIdentityDbProperties.ConnectionStringName

Hi,

Can you proivde full steps to reproduce? thanks.

Solved, you should use the latest version of redis

Hi,

There are many steps to change to mongodb. so I made an example, will send to your email, you can check it.

As the documentation suggests, I added AbpQuartzBackgroundJobs dependency to fix this, but this did not help

You can try:

Is is so that I cannot use the default background job abstractions in this case and have to use only Quartz's abstractions all the way?

We fixed the problem in the 5.0: https://github.com/abpframework/abp/pull/9821 You can use the default background job when you upgrade to 5.0.

Can you check adding and removing a permission in BIMS. It is not reflecting

I checked, there is no problem. I didn't change anything. just run the project.

Hi,

We have no plan support MongoDB for microservice template yet. but I will give you some suggestions to switch to MongoDB.

Hi,

I used the project you provided, but I didn't get it. there is no problem.

Hi,

For now you can try:

public static class RefreshEditionIdMiddlewareExtension
{
    public static IApplicationBuilder UseRefreshEditionIdMiddleware(this IApplicationBuilder app)
    {
        return app.Use(async (ctx, next) =>
        {
            var currentTenant = ctx.RequestServices.GetRequiredService<ICurrentTenant>();
            var currentUser = ctx.RequestServices.GetRequiredService<ICurrentUser>();

            if (!currentUser.IsAuthenticated || !currentUser.TenantId.HasValue)
            {
                await next();
                return;
            }

            var tenantStore = ctx.RequestServices.GetRequiredService<ITenantRepository>();
            var currentPrincipalAccessor = ctx.RequestServices.GetRequiredService<ICurrentPrincipalAccessor>();
            var tenant = await tenantStore.FindAsync(currentTenant.GetId());
            var claims = currentPrincipalAccessor.Principal.Claims.ToList();

            claims.ReplaceOne(x => x.Type == AbpClaimTypes.EditionId,
                new Claim(AbpClaimTypes.EditionId, tenant.EditionId?.ToString() ?? string.Empty));

            using (currentPrincipalAccessor.Change(claims))
            {
                await next();
            }
        });
    }
}

....
app.UseAuthorization();

app.UseRefreshEditionIdMiddleware(); // add behind to `UseAuthorization`

Showing 4791 to 4800 of 6014 entries
Made with ❤️ on ABP v9.1.0-preview. Updated on November 19, 2024, 12:56