- 修复 InsertOrUpdateDict Oracle byte[] 长度判断问题;#1462

This commit is contained in:
2881099 2023-03-15 20:34:44 +08:00
parent 9a15a9781e
commit 09664cb3ad
3 changed files with 15 additions and 20 deletions

File diff suppressed because one or more lines are too long

View File

@ -733,15 +733,6 @@
<param name="modelBuilder"></param> <param name="modelBuilder"></param>
<returns></returns> <returns></returns>
</member> </member>
<member name="M:FreeSqlDbContextExtensions.ApplyConfigurationsFromAssembly(FreeSql.ICodeFirst,System.Reflection.Assembly,System.Func{System.Type,System.Boolean})">
<summary>
根据Assembly扫描所有继承IEntityTypeConfiguration&lt;T&gt;的配置类
</summary>
<param name="codeFirst"></param>
<param name="assembly"></param>
<param name="predicate"></param>
<returns></returns>
</member>
<member name="M:FreeSqlDbContextExtensions.CreateDbContext(IFreeSql)"> <member name="M:FreeSqlDbContextExtensions.CreateDbContext(IFreeSql)">
<summary> <summary>
创建普通数据上下文档对象 创建普通数据上下文档对象
@ -800,14 +791,5 @@
<param name="that"></param> <param name="that"></param>
<returns></returns> <returns></returns>
</member> </member>
<member name="M:Microsoft.Extensions.DependencyInjection.FreeSqlRepositoryDependencyInjection.AddFreeRepository(Microsoft.Extensions.DependencyInjection.IServiceCollection,System.Action{FreeSql.FluentDataFilter},System.Reflection.Assembly[])">
<summary>
批量注入 Repository可以参考代码自行调整
</summary>
<param name="services"></param>
<param name="globalDataFilter"></param>
<param name="assemblies"></param>
<returns></returns>
</member>
</members> </members>
</doc> </doc>

View File

@ -602,12 +602,17 @@ namespace FreeSql.Internal.CommonProvider
table.Type = typeof(Dictionary<string, object>); table.Type = typeof(Dictionary<string, object>);
table.CsName = dic.TryGetValue("", out var tryval) ? string.Concat(tryval) : ""; table.CsName = dic.TryGetValue("", out var tryval) ? string.Concat(tryval) : "";
table.DbName = table.CsName; table.DbName = table.CsName;
if (orm.CodeFirst.IsSyncStructureToLower) table.DbName = table.DbName.ToLower();
if (orm.CodeFirst.IsSyncStructureToUpper) table.DbName = table.DbName.ToUpper();
table.DisableSyncStructure = true; table.DisableSyncStructure = true;
table.IsDictionaryType = true; table.IsDictionaryType = true;
var colpos = new List<ColumnInfo>(); var colpos = new List<ColumnInfo>();
foreach (var kv in dic) foreach (var kv in dic)
{ {
var colName = kv.Key; var colName = kv.Key;
if (string.IsNullOrWhiteSpace(colName)) continue;
var colType = kv.Value == null ? typeof(object) : kv.Value.GetType();
if (orm.CodeFirst.IsSyncStructureToLower) colName = colName.ToLower(); if (orm.CodeFirst.IsSyncStructureToLower) colName = colName.ToLower();
if (orm.CodeFirst.IsSyncStructureToUpper) colName = colName.ToUpper(); if (orm.CodeFirst.IsSyncStructureToUpper) colName = colName.ToUpper();
var col = new ColumnInfo var col = new ColumnInfo
@ -617,9 +622,9 @@ namespace FreeSql.Internal.CommonProvider
Attribute = new DataAnnotations.ColumnAttribute Attribute = new DataAnnotations.ColumnAttribute
{ {
Name = colName, Name = colName,
MapType = typeof(object) MapType = colType
}, },
CsType = typeof(object) CsType = colType
}; };
table.Columns.Add(colName, col); table.Columns.Add(colName, col);
table.ColumnsByCs.Add(kv.Key, col); table.ColumnsByCs.Add(kv.Key, col);