修复abp的bug的demo
This commit is contained in:
parent
7373763e9f
commit
fc0781a313
|
@ -50,7 +50,7 @@ namespace Samples.AbpSharding
|
||||||
if (dbContext is AbpDbContext<TDbContext> abpDbContext && abpDbContext.LazyServiceProvider == null)
|
if (dbContext is AbpDbContext<TDbContext> abpDbContext && abpDbContext.LazyServiceProvider == null)
|
||||||
{
|
{
|
||||||
abpDbContext.LazyServiceProvider = this.LazyServiceProvider;
|
abpDbContext.LazyServiceProvider = this.LazyServiceProvider;
|
||||||
if (dbContext is IAbpEfCoreDbContext abpEfCoreDbContext)
|
if (dbContext is IAbpEfCoreDbContext abpEfCoreDbContext&&this.UnitOfWorkManager.Current!=null)
|
||||||
{
|
{
|
||||||
abpEfCoreDbContext.Initialize(
|
abpEfCoreDbContext.Initialize(
|
||||||
new AbpEfCoreDbContextInitializationContext(
|
new AbpEfCoreDbContextInitializationContext(
|
||||||
|
|
Loading…
Reference in New Issue