Merge branch 'dev' into editor-preview-enhancements

pull/13499/head
malik masis 3 years ago
commit 71a8e2451d

@ -735,6 +735,14 @@
"ConfirmedEmailAddressRequiredToStartTrial": "You should have a confirmed email address in order to start a trial license.",
"EmailVerificationMailNotSent": "Email verification mail couldn't send.",
"GetConfirmationEmail": "<a href=\"javascript:void(0);\" id=\"{0}\">Click here to get a confirmation email</a> if you haven't got it before.",
"WhichLicenseTypeYouAreInterestedIn": "Which license type you are interested in?"
"WhichLicenseTypeYouAreInterestedIn": "Which license type you are interested in?",
"DontTakeOurWordForIt": "Don't take our word for it...",
"ReadAbpCommercialUsersWantYouToKnow": "Read what ABP Commercial users want you to know",
"Testimonial_ShortDescription_1": "The modularity of ABP made it possible for the team to deliver in time.",
"Testimonial_ShortDescription_2": "Build new features faster than before.",
"Testimonial_ShortDescription_3": "We start from out-of-the-box features and just focus on what we really need to write.",
"Testimonial_ShortDescription_4": "ABP Commercial was the best fit for our needs.",
"OnlineReviewersOnAbpCommercial": "Online Reviews on ABP Commercial",
"SeeWhatToldAboutAbpCommercial": "See what has been told about ABP Commercial and write your thoughts if you want."
}
}

@ -373,6 +373,13 @@
"MasteringAbpFramework_Book_WhoIsThisBookFor": "Who's this book for",
"MasteringAbpFramework_Book_WhoIsThisBookFor_Description": "This book is for web developers who want to learn software architectures and best practices for building\n maintainable web-based solutions using Microsoft technologies and ABP Framework. Basic knowledge of C#\n and ASP.NET Core is necessary to get started with this book.",
"ComputersAndTechnology": "Computers & Technology",
"BuildingMicroserviceSolutions": "Building Microservice Solutions",
"MicroserviceBookPracticalGuide": "This book is a reference guide for developing and managing microservice-based applications using the ABP Framework. It references the <strong>.NET Microservice Sample Reference Application</strong>: eShopOnContainers and discusses the architectural design and implementation approaches using the ABP Framework. By the end of this book, you'll learn how ABP approaches the common microservice complexities such as authorization, distributed transactions, inter-microservice communications, deployment, etc.",
"IntroducingTheSolution": "Introducing the eShopOnAbp Solution",
"RunningTheSolution": "Running the Solution",
"UnderstandingTheAuthenticationSystem": "Understanding the Authentication System",
"Authors": "Authors",
"MicroserviceEBook": "Microservice E-Book",
"SelectUITheme": "Select UI Theme",
"LeptonXLiteTheme": "LeptonX Lite Theme",
"BasicTheme": "Basic Theme",

@ -3,16 +3,17 @@ using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.DependencyInjection;
namespace Volo.Abp.AspNetCore.Components.Web.Theming.PageToolbars;
public class PageToolbarManager : IPageToolbarManager, ITransientDependency
{
protected IHybridServiceScopeFactory ServiceScopeFactory { get; }
protected IServiceScopeFactory ServiceScopeFactory { get; }
public PageToolbarManager(
IHybridServiceScopeFactory serviceScopeFactory)
IServiceScopeFactory serviceScopeFactory)
{
ServiceScopeFactory = serviceScopeFactory;
}

@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using Volo.Abp.DependencyInjection;
@ -10,11 +11,11 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.PageToolbars;
public class PageToolbarManager : IPageToolbarManager, ITransientDependency
{
protected AbpPageToolbarOptions Options { get; }
protected IHybridServiceScopeFactory ServiceScopeFactory { get; }
protected IServiceScopeFactory ServiceScopeFactory { get; }
public PageToolbarManager(
IOptions<AbpPageToolbarOptions> options,
IHybridServiceScopeFactory serviceScopeFactory)
IServiceScopeFactory serviceScopeFactory)
{
Options = options.Value;
ServiceScopeFactory = serviceScopeFactory;

@ -1,52 +0,0 @@
using System;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.DependencyInjection;
namespace Volo.Abp.AspNetCore.DependencyInjection;
[ExposeServices(
typeof(IHybridServiceScopeFactory),
typeof(HttpContextServiceScopeFactory)
)]
[Dependency(ReplaceServices = true)]
public class HttpContextServiceScopeFactory : IHybridServiceScopeFactory, ITransientDependency
{
protected IHttpContextAccessor HttpContextAccessor { get; }
protected IServiceScopeFactory ServiceScopeFactory { get; }
public HttpContextServiceScopeFactory(
IHttpContextAccessor httpContextAccessor,
IServiceScopeFactory serviceScopeFactory)
{
HttpContextAccessor = httpContextAccessor;
ServiceScopeFactory = serviceScopeFactory;
}
public virtual IServiceScope CreateScope()
{
var httpContext = HttpContextAccessor.HttpContext;
if (httpContext == null)
{
return ServiceScopeFactory.CreateScope();
}
return new NonDisposedHttpContextServiceScope(httpContext.RequestServices);
}
protected class NonDisposedHttpContextServiceScope : IServiceScope
{
public IServiceProvider ServiceProvider { get; }
public NonDisposedHttpContextServiceScope(IServiceProvider serviceProvider)
{
ServiceProvider = serviceProvider;
}
public void Dispose()
{
}
}
}

@ -1,4 +1,5 @@
using System.Text;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using Volo.Abp.Cli.ServiceProxying;
using Volo.Abp.DependencyInjection;
@ -13,7 +14,7 @@ public class GenerateProxyCommand : ProxyCommandBase<GenerateProxyCommand>
public GenerateProxyCommand(
IOptions<AbpCliServiceProxyOptions> serviceProxyOptions,
IHybridServiceScopeFactory serviceScopeFactory)
IServiceScopeFactory serviceScopeFactory)
: base(serviceProxyOptions, serviceScopeFactory)
{
}

@ -2,6 +2,7 @@
using System.IO;
using System.Text;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Logging.Abstractions;
using Microsoft.Extensions.Options;
@ -19,11 +20,11 @@ public abstract class ProxyCommandBase<T> : IConsoleCommand, ITransientDependenc
protected AbpCliServiceProxyOptions ServiceProxyOptions { get; }
protected IHybridServiceScopeFactory ServiceScopeFactory { get; }
protected IServiceScopeFactory ServiceScopeFactory { get; }
public ProxyCommandBase(
IOptions<AbpCliServiceProxyOptions> serviceProxyOptions,
IHybridServiceScopeFactory serviceScopeFactory)
IServiceScopeFactory serviceScopeFactory)
{
ServiceScopeFactory = serviceScopeFactory;
ServiceProxyOptions = serviceProxyOptions.Value;

@ -1,4 +1,5 @@
using System.Text;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using Volo.Abp.Cli.ServiceProxying;
using Volo.Abp.DependencyInjection;
@ -13,7 +14,7 @@ public class RemoveProxyCommand : ProxyCommandBase<RemoveProxyCommand>
public RemoveProxyCommand(
IOptions<AbpCliServiceProxyOptions> serviceProxyOptions,
IHybridServiceScopeFactory serviceScopeFactory)
IServiceScopeFactory serviceScopeFactory)
: base(serviceProxyOptions, serviceScopeFactory)
{
}

@ -1,22 +0,0 @@
using Microsoft.Extensions.DependencyInjection;
namespace Volo.Abp.DependencyInjection;
[ExposeServices(
typeof(IHybridServiceScopeFactory),
typeof(DefaultServiceScopeFactory)
)]
public class DefaultServiceScopeFactory : IHybridServiceScopeFactory, ITransientDependency
{
protected IServiceScopeFactory Factory { get; }
public DefaultServiceScopeFactory(IServiceScopeFactory factory)
{
Factory = factory;
}
public IServiceScope CreateScope()
{
return Factory.CreateScope();
}
}

@ -1,8 +0,0 @@
using Microsoft.Extensions.DependencyInjection;
namespace Volo.Abp.DependencyInjection;
public interface IHybridServiceScopeFactory : IServiceScopeFactory
{
}

@ -42,18 +42,6 @@ public class EntityChangeEventHelper : IEntityChangeEventHelper, ITransientDepen
Logger = NullLogger<EntityChangeEventHelper>.Instance;
}
public virtual void PublishEntityCreatingEvent(object entity)
{
TriggerEventWithEntity(
LocalEventBus,
#pragma warning disable 618
typeof(EntityCreatingEventData<>),
#pragma warning restore 618
entity,
entity
);
}
public virtual void PublishEntityCreatedEvent(object entity)
{
TriggerEventWithEntity(
@ -89,18 +77,6 @@ public class EntityChangeEventHelper : IEntityChangeEventHelper, ITransientDepen
);
}
public virtual void PublishEntityUpdatingEvent(object entity)
{
TriggerEventWithEntity(
LocalEventBus,
#pragma warning disable 618
typeof(EntityUpdatingEventData<>),
#pragma warning restore 618
entity,
entity
);
}
public virtual void PublishEntityUpdatedEvent(object entity)
{
TriggerEventWithEntity(
@ -125,18 +101,6 @@ public class EntityChangeEventHelper : IEntityChangeEventHelper, ITransientDepen
}
}
public virtual void PublishEntityDeletingEvent(object entity)
{
TriggerEventWithEntity(
LocalEventBus,
#pragma warning disable 618
typeof(EntityDeletingEventData<>),
#pragma warning restore 618
entity,
entity
);
}
public virtual void PublishEntityDeletedEvent(object entity)
{
TriggerEventWithEntity(

@ -1,23 +0,0 @@
using System;
namespace Volo.Abp.Domain.Entities.Events;
/// <summary>
/// Used to pass data for an event when an entity (<see cref="IEntity"/>) is being changed (creating, updating or deleting).
/// See <see cref="EntityCreatingEventData{TEntity}"/>, <see cref="EntityDeletingEventData{TEntity}"/> and <see cref="EntityUpdatingEventData{TEntity}"/> classes.
/// </summary>
/// <typeparam name="TEntity">Entity type</typeparam>
[Serializable]
[Obsolete("This event is no longer needed and identical to EntityChangedEventData. Please use EntityChangedEventData instead.")]
public class EntityChangingEventData<TEntity> : EntityEventData<TEntity>
{
/// <summary>
/// Constructor.
/// </summary>
/// <param name="entity">Changing entity in this event</param>
public EntityChangingEventData(TEntity entity)
: base(entity)
{
}
}

@ -1,22 +0,0 @@
using System;
namespace Volo.Abp.Domain.Entities.Events;
/// <summary>
/// This type of event is used to notify just before creation of an Entity.
/// </summary>
/// <typeparam name="TEntity">Entity type</typeparam>
[Serializable]
[Obsolete("This event is no longer needed and identical to EntityCreatedEventData. Please use EntityCreatedEventData instead.")]
public class EntityCreatingEventData<TEntity> : EntityChangingEventData<TEntity>
{
/// <summary>
/// Constructor.
/// </summary>
/// <param name="entity">The entity which is being created</param>
public EntityCreatingEventData(TEntity entity)
: base(entity)
{
}
}

@ -1,22 +0,0 @@
using System;
namespace Volo.Abp.Domain.Entities.Events;
/// <summary>
/// This type of event is used to notify just before deletion of an Entity.
/// </summary>
/// <typeparam name="TEntity">Entity type</typeparam>
[Serializable]
[Obsolete("This event is no longer needed and identical to EntityDeletedEventData. Please use EntityDeletedEventData instead.")]
public class EntityDeletingEventData<TEntity> : EntityChangingEventData<TEntity>
{
/// <summary>
/// Constructor.
/// </summary>
/// <param name="entity">The entity which is being deleted</param>
public EntityDeletingEventData(TEntity entity)
: base(entity)
{
}
}

@ -1,22 +0,0 @@
using System;
namespace Volo.Abp.Domain.Entities.Events;
/// <summary>
/// This type of event is used to notify just before update of an Entity.
/// </summary>
/// <typeparam name="TEntity">Entity type</typeparam>
[Serializable]
[Obsolete("This event is no longer needed and identical to EntityUpdatedEventData. Please use EntityUpdatedEventData instead.")]
public class EntityUpdatingEventData<TEntity> : EntityChangingEventData<TEntity>
{
/// <summary>
/// Constructor.
/// </summary>
/// <param name="entity">The entity which is being updated</param>
public EntityUpdatingEventData(TEntity entity)
: base(entity)
{
}
}

@ -5,12 +5,9 @@ namespace Volo.Abp.Domain.Entities.Events;
/// </summary>
public interface IEntityChangeEventHelper
{
void PublishEntityCreatingEvent(object entity);
void PublishEntityCreatedEvent(object entity);
void PublishEntityUpdatingEvent(object entity);
void PublishEntityUpdatedEvent(object entity);
void PublishEntityDeletingEvent(object entity);
void PublishEntityDeletedEvent(object entity);
}

@ -14,26 +14,14 @@ public class NullEntityChangeEventHelper : IEntityChangeEventHelper
{
}
public void PublishEntityCreatingEvent(object entity)
{
}
public void PublishEntityCreatedEvent(object entity)
{
}
public void PublishEntityUpdatingEvent(object entity)
{
}
public void PublishEntityUpdatedEvent(object entity)
{
}
public void PublishEntityDeletingEvent(object entity)
{
}
public void PublishEntityDeletedEvent(object entity)
{
}

@ -292,7 +292,6 @@ public abstract class AbpDbContext<TDbContext> : DbContext, IAbpEfCoreDbContext,
{
case EntityState.Added:
ApplyAbpConceptsForAddedEntity(entry);
EntityChangeEventHelper.PublishEntityCreatingEvent(entry.Entity);
EntityChangeEventHelper.PublishEntityCreatedEvent(entry.Entity);
break;
case EntityState.Modified:
@ -301,12 +300,10 @@ public abstract class AbpDbContext<TDbContext> : DbContext, IAbpEfCoreDbContext,
{
if (entry.Entity is ISoftDelete && entry.Entity.As<ISoftDelete>().IsDeleted)
{
EntityChangeEventHelper.PublishEntityDeletingEvent(entry.Entity);
EntityChangeEventHelper.PublishEntityDeletedEvent(entry.Entity);
}
else
{
EntityChangeEventHelper.PublishEntityUpdatingEvent(entry.Entity);
EntityChangeEventHelper.PublishEntityUpdatedEvent(entry.Entity);
}
}
@ -314,7 +311,6 @@ public abstract class AbpDbContext<TDbContext> : DbContext, IAbpEfCoreDbContext,
break;
case EntityState.Deleted:
ApplyAbpConceptsForDeletedEntity(entry);
EntityChangeEventHelper.PublishEntityDeletingEvent(entry.Entity);
EntityChangeEventHelper.PublishEntityDeletedEvent(entry.Entity);
break;
}

@ -159,19 +159,16 @@ public class MemoryDbRepository<TMemoryDbContext, TEntity> : RepositoryBase<TEnt
protected virtual void TriggerEntityCreateEvents(TEntity entity)
{
EntityChangeEventHelper.PublishEntityCreatingEvent(entity);
EntityChangeEventHelper.PublishEntityCreatedEvent(entity);
}
protected virtual void TriggerEntityUpdateEvents(TEntity entity)
{
EntityChangeEventHelper.PublishEntityUpdatingEvent(entity);
EntityChangeEventHelper.PublishEntityUpdatedEvent(entity);
}
protected virtual void TriggerEntityDeleteEvents(TEntity entity)
{
EntityChangeEventHelper.PublishEntityDeletingEvent(entity);
EntityChangeEventHelper.PublishEntityDeletedEvent(entity);
}

@ -597,13 +597,11 @@ public class MongoDbRepository<TMongoDbContext, TEntity>
private void TriggerEntityCreateEvents(TEntity entity)
{
EntityChangeEventHelper.PublishEntityCreatingEvent(entity);
EntityChangeEventHelper.PublishEntityCreatedEvent(entity);
}
protected virtual void TriggerEntityUpdateEvents(TEntity entity)
{
EntityChangeEventHelper.PublishEntityUpdatingEvent(entity);
EntityChangeEventHelper.PublishEntityUpdatedEvent(entity);
}
@ -616,7 +614,6 @@ public class MongoDbRepository<TMongoDbContext, TEntity>
protected virtual void TriggerEntityDeleteEvents(TEntity entity)
{
EntityChangeEventHelper.PublishEntityDeletingEvent(entity);
EntityChangeEventHelper.PublishEntityDeletedEvent(entity);
}

@ -3,6 +3,7 @@ using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using Volo.Abp.Authorization.Permissions;
using Volo.Abp.DependencyInjection;
@ -13,11 +14,11 @@ namespace Volo.Abp.UI.Navigation;
public class MenuManager : IMenuManager, ITransientDependency
{
protected AbpNavigationOptions Options { get; }
protected IHybridServiceScopeFactory ServiceScopeFactory { get; }
protected IServiceScopeFactory ServiceScopeFactory { get; }
protected ISimpleStateCheckerManager<ApplicationMenuItem> SimpleStateCheckerManager { get; }
public MenuManager(
IOptions<AbpNavigationOptions> options,
IHybridServiceScopeFactory serviceScopeFactory,
IServiceScopeFactory serviceScopeFactory,
ISimpleStateCheckerManager<ApplicationMenuItem> simpleStateCheckerManager)
{
Options = options.Value;

@ -1,71 +0,0 @@
using System;
using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
using Shouldly;
using Volo.Abp.Modularity;
using Xunit;
namespace Volo.Abp.DependencyInjection;
public class HybridServiceScopeFactory_Tests
{
[Fact]
public async Task Should_Use_Default_ServiceScopeFactory_By_Default_Async()
{
using (var application = await AbpApplicationFactory.CreateAsync<IndependentEmptyModule>())
{
application.Services.AddType(typeof(MyServiceAsync));
await application.InitializeAsync();
var serviceScopeFactory = application.ServiceProvider.GetRequiredService<IHybridServiceScopeFactory>();
using (var scope = serviceScopeFactory.CreateScope())
{
scope.ServiceProvider.GetRequiredService<MyServiceAsync>();
}
MyServiceAsync.DisposeCount.ShouldBe(1);
}
}
[Fact]
public void Should_Use_Default_ServiceScopeFactory_By_Default()
{
using (var application = AbpApplicationFactory.Create<IndependentEmptyModule>())
{
application.Services.AddType(typeof(MyService));
application.Initialize();
var serviceScopeFactory = application.ServiceProvider.GetRequiredService<IHybridServiceScopeFactory>();
using (var scope = serviceScopeFactory.CreateScope())
{
scope.ServiceProvider.GetRequiredService<MyService>();
}
MyService.DisposeCount.ShouldBe(1);
}
}
private class MyServiceAsync : ITransientDependency, IDisposable
{
public static int DisposeCount { get; private set; }
public void Dispose()
{
++DisposeCount;
}
}
private class MyService : ITransientDependency, IDisposable
{
public static int DisposeCount { get; private set; }
public void Dispose()
{
++DisposeCount;
}
}
}

@ -32,37 +32,18 @@ public abstract class EntityChangeEvents_Tests<TStartupModule> : TestAppTestBase
{
var personName = Guid.NewGuid().ToString("N");
var creatingEventTriggered = false;
var createdEventTriggered = false;
var createdEtoTriggered = false;
using (var uow = GetRequiredService<IUnitOfWorkManager>().Begin())
{
#pragma warning disable 618
LocalEventBus.Subscribe<EntityCreatingEventData<Person>>(data =>
#pragma warning restore 618
{
creatingEventTriggered.ShouldBeFalse();
createdEventTriggered.ShouldBeFalse();
creatingEventTriggered = true;
data.Entity.Name.ShouldBe(personName);
/* Want to change age from 15 to 18 */
data.Entity.Age.ShouldBe(15);
data.Entity.Age = 18;
return Task.CompletedTask;
});
LocalEventBus.Subscribe<EntityCreatedEventData<Person>>(data =>
{
creatingEventTriggered.ShouldBeTrue();
createdEventTriggered.ShouldBeFalse();
createdEventTriggered = true;
data.Entity.Age.ShouldBe(18);
data.Entity.Age.ShouldBe(15);
data.Entity.Name.ShouldBe(personName);
return Task.CompletedTask;
@ -81,8 +62,7 @@ public abstract class EntityChangeEvents_Tests<TStartupModule> : TestAppTestBase
await uow.CompleteAsync();
}
creatingEventTriggered.ShouldBeTrue();
createdEventTriggered.ShouldBeTrue();
createdEtoTriggered.ShouldBeTrue();
}

@ -56,6 +56,8 @@
"ShareOn": "Share on",
"TitleLengthWarning": "Keep your title size under 60 characters to be SEO friendly!",
"ClearCache": "Clear cache",
"ClearCacheConfirmationMessage": "Are you sure you want to clear the cache?"
"ClearCacheConfirmationMessage": "Are you sure you want to clear the cache?",
"MarkdownSupported": "Markdown is supported",
"FileUploadInfo": "Drag, drop, or paste a copied image."
}
}

@ -29,7 +29,7 @@ public class FeatureManager : IFeatureManager, ISingletonDependency
StringLocalizerFactory = stringLocalizerFactory;
Options = options.Value;
//TODO: Instead, use IHybridServiceScopeFactory and create a scope..?
//TODO: Instead, use IServiceScopeFactory and create a scope..?
_lazyProviders = new Lazy<List<IFeatureManagementProvider>>(
() => Options

@ -17,13 +17,13 @@ namespace Volo.Abp.IdentityServer;
public class AbpCorsPolicyService : ICorsPolicyService
{
public ILogger<AbpCorsPolicyService> Logger { get; set; }
protected IHybridServiceScopeFactory HybridServiceScopeFactory { get; }
protected IServiceScopeFactory HybridServiceScopeFactory { get; }
protected IDistributedCache<AllowedCorsOriginsCacheItem> Cache { get; }
protected IdentityServerOptions Options { get; }
public AbpCorsPolicyService(
IDistributedCache<AllowedCorsOriginsCacheItem> cache,
IHybridServiceScopeFactory hybridServiceScopeFactory,
IServiceScopeFactory hybridServiceScopeFactory,
IOptions<IdentityServerOptions> options)
{
Cache = cache;

@ -3,6 +3,7 @@ using System.Linq;
using System.Threading.Tasks;
using IdentityServer4.Configuration;
using Microsoft.Extensions.Options;
using Microsoft.Extensions.DependencyInjection;
using Volo.Abp.Caching;
using Volo.Abp.DependencyInjection;
using Volo.Abp.Text.Formatting;
@ -13,7 +14,7 @@ public class AbpWildcardSubdomainCorsPolicyService : AbpCorsPolicyService
{
public AbpWildcardSubdomainCorsPolicyService(
IDistributedCache<AllowedCorsOriginsCacheItem> cache,
IHybridServiceScopeFactory hybridServiceScopeFactory,
IServiceScopeFactory hybridServiceScopeFactory,
IOptions<IdentityServerOptions> options)
: base(cache, hybridServiceScopeFactory, options)
{

@ -32,7 +32,7 @@ public class AbpResourceOwnerPasswordValidator : IResourceOwnerPasswordValidator
protected IdentitySecurityLogManager IdentitySecurityLogManager { get; }
protected ILogger<ResourceOwnerPasswordValidator<IdentityUser>> Logger { get; }
protected IStringLocalizer<AbpIdentityServerResource> Localizer { get; }
protected IHybridServiceScopeFactory ServiceScopeFactory { get; }
protected IServiceScopeFactory ServiceScopeFactory { get; }
protected AbpIdentityOptions AbpIdentityOptions { get; }
protected IOptions<IdentityOptions> IdentityOptions { get; }
@ -43,7 +43,7 @@ public class AbpResourceOwnerPasswordValidator : IResourceOwnerPasswordValidator
ILogger<ResourceOwnerPasswordValidator<IdentityUser>> logger,
IStringLocalizer<AbpIdentityServerResource> localizer,
IOptions<AbpIdentityOptions> abpIdentityOptions,
IHybridServiceScopeFactory serviceScopeFactory,
IServiceScopeFactory serviceScopeFactory,
IOptions<IdentityOptions> identityOptions)
{
UserManager = userManager;

@ -10,16 +10,17 @@ export const environment = {
logoUrl: '',
},
oAuthConfig: {
issuer: 'https://localhost:44333',
issuer: 'https://localhost:44301/',
redirectUri: baseUrl,
clientId: 'Angular_App',
clientId: 'AbpApp',
dummyClientSecret: '1q2w3e*',
responseType: 'code',
scope: 'offline_access Angular',
scope: 'offline_access AbpAPI',
requireHttps: true
},
apis: {
default: {
url: 'https://localhost:44333',
url: 'https://localhost:44301',
rootNamespace: 'OpenIddict.Demo.Client.Angular',
},
},

@ -22,7 +22,7 @@ namespace Volo.Abp.OpenIddict.Controllers;
public partial class TokenController
{
protected IHybridServiceScopeFactory ServiceScopeFactory => LazyServiceProvider.LazyGetRequiredService<IHybridServiceScopeFactory>();
protected IServiceScopeFactory ServiceScopeFactory => LazyServiceProvider.LazyGetRequiredService<IServiceScopeFactory>();
protected ITenantConfigurationProvider TenantConfigurationProvider=> LazyServiceProvider.LazyGetRequiredService<ITenantConfigurationProvider>();
protected IOptions<AbpIdentityOptions> AbpIdentityOptions => LazyServiceProvider.LazyGetRequiredService<IOptions<AbpIdentityOptions>>();
protected IOptions<IdentityOptions> IdentityOptions => LazyServiceProvider.LazyGetRequiredService<IOptions<IdentityOptions>>();

@ -27,7 +27,7 @@ public class SettingManager : ISettingManager, ISingletonDependency
SettingEncryptionService = settingEncryptionService;
Options = options.Value;
//TODO: Instead, use IHybridServiceScopeFactory and create a scope..?
//TODO: Instead, use IServiceScopeFactory and create a scope..?
_lazyProviders = new Lazy<List<ISettingManagementProvider>>(
() => Options

@ -1,6 +1,5 @@
using System.Collections.Generic;
using System.Globalization;
using System.Threading;
using System.Threading.Tasks;
using Volo.Abp.AspNetCore.Mvc.UI.RazorPages;
using Volo.Abp.Localization;

@ -1,6 +1,5 @@
using System;
using System.IO;
using System.Net.Http;
using Blazorise.Bootstrap5;
using Blazorise.Icons.FontAwesome;
using Microsoft.AspNetCore.Builder;

@ -2,7 +2,6 @@
using System.Net.Http;
using Blazorise.Bootstrap5;
using Blazorise.Icons.FontAwesome;
using IdentityModel;
using Microsoft.AspNetCore.Components.WebAssembly.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
@ -16,7 +15,6 @@ using Volo.Abp.AutoMapper;
using Volo.Abp.Modularity;
using Volo.Abp.UI.Navigation;
using Volo.Abp.Identity.Blazor.WebAssembly;
using Volo.Abp.Security.Claims;
using Volo.Abp.SettingManagement.Blazor.WebAssembly;
using Volo.Abp.TenantManagement.Blazor.WebAssembly;

@ -2,7 +2,6 @@ using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using Microsoft.AspNetCore.Authentication.JwtBearer;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Cors;
@ -11,7 +10,6 @@ using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Microsoft.IdentityModel.Tokens;
using MyCompanyName.MyProjectName.EntityFrameworkCore;
using MyCompanyName.MyProjectName.MultiTenancy;
using StackExchange.Redis;
@ -19,7 +17,6 @@ using Microsoft.OpenApi.Models;
using Volo.Abp;
using Volo.Abp.AspNetCore.Mvc;
using Volo.Abp.AspNetCore.Mvc.UI.MultiTenancy;
using Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared;
using Volo.Abp.AspNetCore.Serilog;
using Volo.Abp.Autofac;
using Volo.Abp.Caching;

@ -1,4 +1,3 @@
using System;
using System.IO;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Extensions.DependencyInjection;

Loading…
Cancel
Save