好的,已经修复完成
This commit is contained in:
@@ -19,7 +19,7 @@ namespace Yi.Framework.Core.Sqlsugar.Extensions
|
||||
var db = app.ApplicationServices.GetRequiredService<ISqlSugarClient>();
|
||||
var options = app.ApplicationServices.GetRequiredService<IOptions<DbConnOptions>>();
|
||||
|
||||
//if (options.Value.EnabledCodeFirst == false) return;
|
||||
if (options.Value.EnabledCodeFirst == false) return;
|
||||
|
||||
var assemblys = new List<Assembly>();
|
||||
|
||||
|
||||
@@ -22,22 +22,22 @@ namespace Yi.Framework.Core.Sqlsugar.Options
|
||||
/// <summary>
|
||||
/// 开启种子数据
|
||||
/// </summary>
|
||||
public bool EnabledDbSeed = false;
|
||||
public bool EnabledDbSeed { get; set; } = false;
|
||||
|
||||
/// <summary>
|
||||
/// 开启读写分离
|
||||
/// </summary>
|
||||
public bool EnabledReadWrite = false;
|
||||
public bool EnabledReadWrite { get; set; } = false;
|
||||
|
||||
/// <summary>
|
||||
/// 开启codefirst
|
||||
/// </summary>
|
||||
public bool EnabledCodeFirst = false;
|
||||
public bool EnabledCodeFirst { get; set; }=false;
|
||||
|
||||
/// <summary>
|
||||
/// 实体程序集
|
||||
/// </summary>
|
||||
public List<string>? EntityAssembly;
|
||||
public List<string>? EntityAssembly { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 读写分离
|
||||
|
||||
@@ -29,7 +29,6 @@ namespace Yi.Framework.Core.Sqlsugar
|
||||
|
||||
//这里替换过滤器实现
|
||||
services.AddScoped<IDataFilter, SqlsugarDataFilter>();
|
||||
var ss= Appsettings.appConfiguration("DbConnOptions", "EnabledCodeFirst");
|
||||
services.Configure<DbConnOptions>(Appsettings.appConfiguration("DbConnOptions"));
|
||||
services.AddSqlsugarServer();
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@ using Yi.Framework.Web;
|
||||
|
||||
TimeTest.Start();
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>url
|
||||
builder.WebHost.UseStartUrlsServer(builder.Configuration);
|
||||
|
||||
|
||||
@@ -83,3 +83,4 @@
|
||||
2023:01:21-22:21:52本次运行启动时间为:1563毫秒
|
||||
2023:01:21-22:29:30本次运行启动时间为:9099毫秒
|
||||
2023:01:21-22:30:38本次运行启动时间为:2136毫秒
|
||||
2023:01:21-23:15:24本次运行启动时间为:1944毫秒
|
||||
|
||||
Reference in New Issue
Block a user