mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-05-17 05:29:33 +08:00
Synchronization code
This commit is contained in:
parent
006b336a7b
commit
a12ca13d73
@ -250,8 +250,11 @@ namespace SqlSugar
|
||||
return this;
|
||||
}
|
||||
public IDeleteable<T> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
||||
{
|
||||
if (DeleteBuilder.WhereInfos.Any() != true)
|
||||
{
|
||||
Check.ExceptionEasy(!StaticConfig.EnableAllWhereIF, "Need to program startup configuration StaticConfig. EnableAllWhereIF = true; Tip: This operation is very risky if there are no conditions it is easy to update the entire table", " 需要程序启动时配置StaticConfig.EnableAllWhereIF=true; 提示:该操作存在很大的风险如果没有条件很容易将整个表全部更新");
|
||||
}
|
||||
if (isWhere)
|
||||
{
|
||||
return Where(expression);
|
||||
|
@ -897,8 +897,11 @@ namespace SqlSugar
|
||||
return this;
|
||||
}
|
||||
public IUpdateable<T> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
||||
{
|
||||
if (UpdateBuilder.WhereValues.Any() != true)
|
||||
{
|
||||
Check.ExceptionEasy(!StaticConfig.EnableAllWhereIF, "Need to program startup configuration StaticConfig. EnableAllWhereIF = true; Tip: This operation is very risky if there are no conditions it is easy to update the entire table", " 需要程序启动时配置StaticConfig.EnableAllWhereIF=true; 提示:该操作存在很大的风险如果没有条件很容易将整个表全部更新");
|
||||
}
|
||||
if (isWhere)
|
||||
{
|
||||
return Where(expression);
|
||||
|
Loading…
Reference in New Issue
Block a user