chore 优化代码
This commit is contained in:
@ -23,9 +23,9 @@ public class AdminHttpApiHostModule : AbpModule
|
||||
var configuration = context.Services.GetConfiguration();
|
||||
|
||||
SwaggerConfigurationHelper.ConfigureWithOidc(
|
||||
context: context,
|
||||
authority: configuration["AuthServer:Authority"]!,
|
||||
scopes: ["AdministrationService"],
|
||||
context,
|
||||
configuration["AuthServer:Authority"]!,
|
||||
["AdministrationService"],
|
||||
discoveryEndpoint: configuration["AuthServer:MetadataAddress"],
|
||||
apiTitle: "Administration Service API"
|
||||
);
|
||||
@ -74,4 +74,4 @@ public class AdminHttpApiHostModule : AbpModule
|
||||
app.UseAbpSerilogEnrichers();
|
||||
app.UseConfiguredEndpoints();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -9,4 +9,4 @@ public class HomeController : AbpController
|
||||
{
|
||||
return Redirect("~/swagger");
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -2,13 +2,12 @@
|
||||
using Volo.Abp.Data;
|
||||
using Volo.Abp.DependencyInjection;
|
||||
|
||||
namespace KonSoft.Admin.DbMigrations
|
||||
namespace KonSoft.Admin.DbMigrations;
|
||||
|
||||
public class AdminDataSeeder : IDataSeedContributor, ITransientDependency
|
||||
{
|
||||
public class AdminDataSeeder : IDataSeedContributor, ITransientDependency
|
||||
public Task SeedAsync(DataSeedContext context)
|
||||
{
|
||||
public Task SeedAsync(DataSeedContext context)
|
||||
{
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
return Task.CompletedTask;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -6,21 +6,20 @@ using Volo.Abp.EventBus.Distributed;
|
||||
using Volo.Abp.MultiTenancy;
|
||||
using Volo.Abp.Uow;
|
||||
|
||||
namespace KonSoft.Admin.DbMigrations
|
||||
namespace KonSoft.Admin.DbMigrations;
|
||||
|
||||
public class AdminPendingEfCoreMigrationsChecker : PendingEfCoreMigrationsChecker<AdminDbContext>
|
||||
{
|
||||
public class AdminPendingEfCoreMigrationsChecker : PendingEfCoreMigrationsChecker<AdminDbContext>
|
||||
public AdminPendingEfCoreMigrationsChecker(IUnitOfWorkManager unitOfWorkManager,
|
||||
IServiceProvider serviceProvider,
|
||||
ICurrentTenant currentTenant,
|
||||
IDistributedEventBus distributedEventBus,
|
||||
IAbpDistributedLock abpDistributedLock) : base(unitOfWorkManager,
|
||||
serviceProvider,
|
||||
currentTenant,
|
||||
distributedEventBus,
|
||||
abpDistributedLock,
|
||||
"Clean")
|
||||
{
|
||||
public AdminPendingEfCoreMigrationsChecker(IUnitOfWorkManager unitOfWorkManager,
|
||||
IServiceProvider serviceProvider,
|
||||
ICurrentTenant currentTenant,
|
||||
IDistributedEventBus distributedEventBus,
|
||||
IAbpDistributedLock abpDistributedLock) : base(unitOfWorkManager,
|
||||
serviceProvider,
|
||||
currentTenant,
|
||||
distributedEventBus,
|
||||
abpDistributedLock,
|
||||
"Clean")
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,8 +1,8 @@
|
||||
using KonSoft.Admin;
|
||||
using System;
|
||||
using KonSoft.Admin;
|
||||
using KonSoft.Shared.Hosting.AspNetCore;
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Serilog;
|
||||
using System;
|
||||
|
||||
var assemblyName = typeof(Program).Assembly.GetName().Name!;
|
||||
|
||||
|
||||
@ -1,18 +1,20 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<configuration>
|
||||
<location path="." inheritInChildApplications="false">
|
||||
<system.webServer>
|
||||
<handlers>
|
||||
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
|
||||
</handlers>
|
||||
<aspNetCore processPath="dotnet" arguments=".\KonSoft.Admin.HttpApi.Host.dll" stdoutLogEnabled="false" stdoutLogFile=".\Logs\stdout" hostingModel="inprocess" />
|
||||
</system.webServer>
|
||||
</location>
|
||||
<system.webServer>
|
||||
<httpProtocol>
|
||||
<customHeaders>
|
||||
<remove name="x-powered-by" />
|
||||
</customHeaders>
|
||||
</httpProtocol>
|
||||
</system.webServer>
|
||||
</configuration>
|
||||
<location path="." inheritInChildApplications="false">
|
||||
<system.webServer>
|
||||
<handlers>
|
||||
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
|
||||
</handlers>
|
||||
<aspNetCore processPath="dotnet" arguments=".\KonSoft.Admin.HttpApi.Host.dll" stdoutLogEnabled="false"
|
||||
stdoutLogFile=".\Logs\stdout" hostingModel="inprocess" />
|
||||
</system.webServer>
|
||||
</location>
|
||||
<system.webServer>
|
||||
<httpProtocol>
|
||||
<customHeaders>
|
||||
<remove name="x-powered-by" />
|
||||
</customHeaders>
|
||||
</httpProtocol>
|
||||
</system.webServer>
|
||||
</configuration>
|
||||
Reference in New Issue
Block a user