mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-04-20 17:52:51 +08:00
- 修复 DbContext/Repository InsertOrUpdate 无变化时触发 Insert 逻辑报错;#1700
This commit is contained in:
parent
2272c46df6
commit
8f9228a612
@ -507,7 +507,7 @@ namespace FreeSql
|
|||||||
await UpdateRangePrivAsync(new[] { data }, false, cancellationToken);
|
await UpdateRangePrivAsync(new[] { data }, false, cancellationToken);
|
||||||
await DbContextFlushCommandAsync(cancellationToken);
|
await DbContextFlushCommandAsync(cancellationToken);
|
||||||
affrows = _db._affrows - affrows;
|
affrows = _db._affrows - affrows;
|
||||||
if (affrows > 0) return;
|
return;
|
||||||
}
|
}
|
||||||
if (CanAdd(data, false))
|
if (CanAdd(data, false))
|
||||||
{
|
{
|
||||||
|
@ -579,7 +579,7 @@ namespace FreeSql
|
|||||||
UpdateRangePriv(new[] { data }, false);
|
UpdateRangePriv(new[] { data }, false);
|
||||||
DbContextFlushCommand();
|
DbContextFlushCommand();
|
||||||
affrows = _db._affrows - affrows;
|
affrows = _db._affrows - affrows;
|
||||||
if (affrows > 0) return;
|
return;
|
||||||
}
|
}
|
||||||
if (CanAdd(data, false))
|
if (CanAdd(data, false))
|
||||||
{
|
{
|
||||||
|
@ -806,14 +806,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>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user