abp icon indicating copy to clipboard operation
abp copied to clipboard

Disable ABP module

Open duard-sf opened this issue 6 years ago • 3 comments

I would like to disable the Volo.Abp.Account.Web module, because its routing is taking precedence. This prevents initial routing to any account/ routes I have set up in my Angular app.

I tried using PreConfigureServices to remove the application part (see code below), but this does not seem to work.

public override void PreConfigureServices(ServiceConfigurationContext context)
{
    PreConfigure<IMvcBuilder>(mvcBuilder =>
    {
        mvcBuilder.PartManager.ApplicationParts.Remove(mvcBuilder.PartManager.ApplicationParts.FirstOrDefault(p => p.Name == "Volo.Abp.Account.Web"));
    });
}

Is there any way to achieve this?

duard-sf avatar Jan 16 '20 09:01 duard-sf

see https://github.com/abpframework/abp/issues/2604

maliming avatar Jan 16 '20 09:01 maliming

So should I disable the following two settings?

  • Abp.Account.IsSelfRegistrationEnabled
  • Abp.Account.EnableLocalLogin

I did so in appsettings.json (following the docs), but still no change.

"Settings": {
  "Abp.Account.IsSelfRegistrationEnabled": "False",
  "Abp.Account.EnableLocalLogin": "False"
}

duard-sf avatar Jan 16 '20 09:01 duard-sf

Ah, no worries, I followed the advice from mehdihadeli which solves the issue!

Thanks very much for you help.

duard-sf avatar Jan 16 '20 10:01 duard-sf