Activities of "Spospisil"

  • ABP Framework version: v4.4.0
  • 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:"

I have an ABP project that has the Identity Server project seperated but what I would like to do is to have the tables that it creates residing in a seperate database from all the other ABP tables that get created during the initial migration. I want no other ABP tables in this same database and I would also like to change the default prefix of the table that get created for Identity Server. How can this be done?

Hi,

I'm assuming you have created the Account folder in the Pages folder of the MyProjectName.IdentityServer project :)

CustomLoginModel.cshtml in Account folder

    [Dependency(ReplaceServices = true)]  
    [ExposeServices(typeof(LoginModel))]  
    public class CustomLoginModel : LoginModel  
    {  
        public CustomLoginModel(  
            IAuthenticationSchemeProvider schemeProvider,   
            IOptions<AbpAccountOptions> accountOptions,   
            IAbpRecaptchaValidatorFactory recaptchaValidatorFactory,   
            IAccountExternalProviderAppService accountExternalProviderAppService,   
            ICurrentPrincipalAccessor currentPrincipalAccessor,   
            IOptions<IdentityOptions> identityOptions,   
            IOptionsSnapshot<reCAPTCHAOptions> reCaptchaOptions) :   
            base(schemeProvider,   
                accountOptions,   
                recaptchaValidatorFactory,   
                accountExternalProviderAppService,   
                currentPrincipalAccessor,   
                identityOptions,   
                reCaptchaOptions)  
        {  
            Console.WriteLine("Test QA Question");  
        }  
    }  

Please let us know if it works after you try it.

I'm a little confused by your response as you mentioned that this should be done in the cshtml file not the class. Could you list exactly what I need to do in order to do this as I've seend some conflicting information in the documentation.

Thanks

To be more specific I want to override the look of of the login page, meaning I don't want the tennant selector and I also want to add/remove items in the login box and do custom code (calling different services) behind the various button clicks.

Hi,

I'm assuming you have created the Account folder in the Pages folder of the MyProjectName.IdentityServer project :)

CustomLoginModel.cshtml in Account folder

    [Dependency(ReplaceServices = true)] 
    [ExposeServices(typeof(LoginModel))] 
    public class CustomLoginModel : LoginModel 
    { 
        public CustomLoginModel( 
            IAuthenticationSchemeProvider schemeProvider,  
            IOptions<AbpAccountOptions> accountOptions,  
            IAbpRecaptchaValidatorFactory recaptchaValidatorFactory,  
            IAccountExternalProviderAppService accountExternalProviderAppService,  
            ICurrentPrincipalAccessor currentPrincipalAccessor,  
            IOptions<IdentityOptions> identityOptions,  
            IOptionsSnapshot<reCAPTCHAOptions> reCaptchaOptions) :  
            base(schemeProvider,  
                accountOptions,  
                recaptchaValidatorFactory,  
                accountExternalProviderAppService,  
                currentPrincipalAccessor,  
                identityOptions,  
                reCaptchaOptions) 
        { 
            Console.WriteLine("Test QA Question"); 
        } 
    } 

Please let us know if it works after you try it.

I'm a little confused by your response as you mentioned that this should be done in the cshtml file not the class. Could you list exactly what I need to do in order to do this as I've seend some conflicting information in the documentation.

Thanks

How can I override the UI of the login page using Identity server/Blazor. There is an article in the community section however it appears to be based on a earlier version of ABP where the 'LoginModel' class is in a different namespace.

ABP Framework version:** v4.4 UI type**: Blazor DB provider**: EF Core Identity Server Separated: yes

  • ABP Framework version: v4.4.0
  • UI type: Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes

When producing source using ABP Suite, I run the DbMigrator and get the following error

[15:37:12 INF] Creating initial migration... [15:37:13 INF] ABP CLI (https://abp.io) [15:37:13 INF] Version 4.4.0 (Stable) [15:37:19 ERR] Migrations failed! A migration command didn't run successfully:

Build started... Build succeeded. More than one DbContext was found. Specify which one to use. Use the '-Context' parameter for PowerShell commands and the '--context' parameter for dotnet commands.

[15:37:19 ERR] Migrations failed! A migration command didn't run successfully:

Build started... Build succeeded. More than one DbContext was found. Specify which one to use. Use the '-Context' parameter for PowerShell commands and the '--context' parameter for dotnet commands.

System.Exception: Migrations failed! A migration command didn't run successfully:

Build started... Build succeeded. More than one DbContext was found. Specify which one to use. Use the '-Context' parameter for PowerShell commands and the '--context' parameter for dotnet commands.

at Volo.Abp.Cli.Commands.CreateMigrationAndRunMigratorCommand.ExecuteAsync(CommandLineArgs commandLineArgs) in D:\ci\Jenkins\workspace\abp-framework-release\abp\framework\src\Volo.Abp.Cli.Core\Volo\Abp\Cli\Commands\CreateMigrationAndRunMigratorCommand.cs:line 67 at Volo.Abp.Cli.CliService.RunInternalAsync(CommandLineArgs commandLineArgs) in D:\ci\Jenkins\workspace\abp-framework-release\abp\framework\src\Volo.Abp.Cli.Core\Volo\Abp\Cli\CliService.cs:line 158 at Volo.Abp.Cli.CliService.RunAsync(String[] args) in D:\ci\Jenkins\workspace\abp-framework-release\abp\framework\src\Volo.Abp.Cli.Core\Volo\Abp\Cli\CliService.cs:line 66

C:\Source Code\StructureWeb\src\StructureWeb.DbMigrator\bin\Debug\net5.0\StructureWeb.DbMigrator.exe (process 36876) exited with code 0. To automatically close the console when debugging stops, enable Tools->Options->Debugging->Automatically close the console when debugging stops. Press any key to close this window . . .

Showing 241 to 245 of 245 entries
Made with ❤️ on ABP v8.2.0-preview Updated on March 25, 2024, 15:11