Преглед изворни кода

🤓升级SqlSugar大文本string新处理模式

zuohuaijun пре 3 година
родитељ
комит
ddf04aca22

+ 1 - 1
Admin.NET/Admin.NET.Core/Entity/SysCodeGenConfig.cs

@@ -142,7 +142,7 @@ public class SysCodeGenConfig : EntityBase
     /// <summary>
     /// <summary>
     /// 显示文本字段
     /// 显示文本字段
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "显示文本字段", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "显示文本字段", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? DisplayColumn { get; set; }
     public string? DisplayColumn { get; set; }
 
 
     /// <summary>
     /// <summary>

+ 2 - 2
Admin.NET/Admin.NET.Core/Entity/SysJobDetail.cs

@@ -57,7 +57,7 @@ public class SysJobDetail : EntityBaseId
     /// <summary>
     /// <summary>
     /// 额外数据
     /// 额外数据
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "额外数据", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "额外数据", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Properties { get; set; } = "{}";
     public string? Properties { get; set; } = "{}";
 
 
     /// <summary>
     /// <summary>
@@ -69,6 +69,6 @@ public class SysJobDetail : EntityBaseId
     /// <summary>
     /// <summary>
     /// 脚本代码
     /// 脚本代码
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "脚本代码", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "脚本代码", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? ScriptCode { get; set; }
     public string? ScriptCode { get; set; }
 }
 }

+ 2 - 2
Admin.NET/Admin.NET.Core/Entity/SysLogAudit.cs

@@ -24,13 +24,13 @@ public class SysLogAudit : EntityBase
     /// <summary>
     /// <summary>
     /// 新值
     /// 新值
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "新值", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "新值", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? NewValue { get; set; }
     public string? NewValue { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 旧值
     /// 旧值
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "旧值", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "旧值", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? OldValue { get; set; }
     public string? OldValue { get; set; }
 
 
     /// <summary>
     /// <summary>

+ 6 - 6
Admin.NET/Admin.NET.Core/Entity/SysLogDiff.cs

@@ -10,37 +10,37 @@ public class SysLogDiff : EntityBase
     /// <summary>
     /// <summary>
     /// 操作前记录
     /// 操作前记录
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "操作前记录", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "操作前记录", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? BeforeData { get; set; }
     public string? BeforeData { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 操作后记录
     /// 操作后记录
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "操作后记录", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "操作后记录", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? AfterData { get; set; }
     public string? AfterData { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// Sql
     /// Sql
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "Sql", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "Sql", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Sql { get; set; }
     public string? Sql { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 参数  手动传入的参数
     /// 参数  手动传入的参数
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "参数", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "参数", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Parameters { get; set; }
     public string? Parameters { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 业务对象
     /// 业务对象
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "业务对象", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "业务对象", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? BusinessData { get; set; }
     public string? BusinessData { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 差异操作
     /// 差异操作
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "差异操作", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "差异操作", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? DiffType { get; set; }
     public string? DiffType { get; set; }
 
 
     /// <summary>
     /// <summary>

+ 4 - 4
Admin.NET/Admin.NET.Core/Entity/SysLogEx.cs

@@ -24,25 +24,25 @@ public class SysLogEx : EntityTenant
     /// <summary>
     /// <summary>
     /// 事件Id
     /// 事件Id
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "事件Id", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "事件Id", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? EventId { get; set; }
     public string? EventId { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 日志消息
     /// 日志消息
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "日志消息", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "日志消息", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Message { get; set; }
     public string? Message { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 异常对象
     /// 异常对象
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "异常对象", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "异常对象", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Exception { get; set; }
     public string? Exception { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 当前状态值
     /// 当前状态值
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "当前状态值", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "当前状态值", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? State { get; set; }
     public string? State { get; set; }
 
 
     /// <summary>
     /// <summary>

+ 4 - 4
Admin.NET/Admin.NET.Core/Entity/SysLogOp.cs

@@ -24,25 +24,25 @@ public class SysLogOp : EntityTenant
     /// <summary>
     /// <summary>
     /// 事件Id
     /// 事件Id
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "事件Id", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "事件Id", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? EventId { get; set; }
     public string? EventId { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 日志消息
     /// 日志消息
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "日志消息", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "日志消息", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Message { get; set; }
     public string? Message { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 异常对象
     /// 异常对象
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "异常对象", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "异常对象", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Exception { get; set; }
     public string? Exception { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// 当前状态值
     /// 当前状态值
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "当前状态值", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "当前状态值", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? State { get; set; }
     public string? State { get; set; }
 
 
     /// <summary>
     /// <summary>

+ 1 - 1
Admin.NET/Admin.NET.Core/Entity/SysLogVis.cs

@@ -16,7 +16,7 @@ public class SysLogVis : EntityTenant
     /// <summary>
     /// <summary>
     /// 具体消息
     /// 具体消息
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "具体消息", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "具体消息", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? Message { get; set; }
     public string? Message { get; set; }
 
 
     /// <summary>
     /// <summary>

+ 1 - 1
Admin.NET/Admin.NET.Core/Entity/SysNotice.cs

@@ -17,7 +17,7 @@ public class SysNotice : EntityBase
     /// <summary>
     /// <summary>
     /// 内容
     /// 内容
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "内容", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "内容", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     [Required]
     [Required]
     public virtual string Content { get; set; }
     public virtual string Content { get; set; }
 
 

+ 2 - 2
Admin.NET/Admin.NET.Core/Entity/SysWechatUser.cs

@@ -105,13 +105,13 @@ public class SysWechatUser : EntityBase
     /// <summary>
     /// <summary>
     /// AccessToken
     /// AccessToken
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "AccessToken", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "AccessToken", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? AccessToken { get; set; }
     public string? AccessToken { get; set; }
 
 
     /// <summary>
     /// <summary>
     /// RefreshToken
     /// RefreshToken
     /// </summary>
     /// </summary>
-    [SugarColumn(ColumnDescription = "RefreshToken", ColumnDataType = "longtext,text,clob")]
+    [SugarColumn(ColumnDescription = "RefreshToken", ColumnDataType = StaticConfig.CodeFirst_BigString)]
     public string? RefreshToken { get; set; }
     public string? RefreshToken { get; set; }
 
 
     /// <summary>
     /// <summary>