Activities of "liangshiwei"

Hi,

Sorry, my bad, after my check, it works for me:

But strangely no migration is generated for you.

Can you share the main Main and Sub DbContext code? thanks.

Hi,

You can the following code to your MenuContributor

var identity = context.Menu.GetAdministration().GetMenuItem(IdentityMenuNames.GroupName);
identity.GetMenuItem(IdentityMenuNames.Users).RequirePermissions(IdentityPermissions.Users.Delete, IdentityPermissions.Users.Create);

I created an application with the name 'Main' then I added a new Module with the name 'Sub',

How do you add the module Sub?

The suite didn't support it, you need to add the Sub module to Main manually.

We have an example for this: https://github.com/abpframework/abp-samples/tree/master/BookStore-Modular

Hi,

Sorry, but can you explant it in detail? thanks

ok

yes,

Sorry, my bad, I copied the wrong code before, please try this:

public class AccountController : AbpAccountImpersonationChallengeAccountController
{
    [HttpGet]
    public Task<IActionResult> AccessDenied(string returnUrl = "", string returnUrlHash = "")
    {
        return Task.FromResult<IActionResult>(Challenge(new AuthenticationProperties { RedirectUri = GetRedirectUrl(returnUrl, returnUrlHash) }, ChallengeAuthenticationSchemas));
    }
}

Hi,

Also how this AccessDenied api will be called and from where and what to pass parameters?

I just answer the question, you don't need to do it yourself.

Hi,

It's a class of ASPNETCore: https://github.com/dotnet/aspnetcore/blob/main/src/Security/Authentication/OpenIdConnect/src/OpenIdConnectHandler.cs

Hi,

Sorry, try this:

public class AccountController : AbpAccountImpersonationChallengeAccountController
{
    [HttpGet]
    public Task<IActionResult> AccessDenied(string returnUrl = "", string returnUrlHash = "")
    {
        return Task.FromResult<IActionResult>(Challenge(new AuthenticationProperties()));
    }
}

Also how this AccessDenied api will be called and from where and what to pass parameters?

This is handled by OpenIdConnectHandler:

Hi,

Please add the to the Web project.

Also what returnURL and returnHash need to be passed here?

After login it can redirect to the previous page, It is recommended that you pass parameters

Showing 4211 to 4220 of 6693 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 November 04, 2025, 06:41