mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-07-15 05:13:27 +08:00
Update json 2 sql
This commit is contained in:
parent
c33cd5d19f
commit
37e7bb8aa6
@ -645,7 +645,11 @@ namespace SqlSugar
|
|||||||
this.Where<T>(whereString, whereObj);
|
this.Where<T>(whereString, whereObj);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public virtual ISugarQueryable<T> Where(IFuncModel funcModel)
|
||||||
|
{
|
||||||
|
var obj= this.SqlBuilder.FuncModelToSql(funcModel);
|
||||||
|
return this.Where(obj.Key, obj.Value);
|
||||||
|
}
|
||||||
public virtual ISugarQueryable<T> Where(List<IConditionalModel> conditionalModels)
|
public virtual ISugarQueryable<T> Where(List<IConditionalModel> conditionalModels)
|
||||||
{
|
{
|
||||||
if (conditionalModels.IsNullOrEmpty()) return this;
|
if (conditionalModels.IsNullOrEmpty()) return this;
|
||||||
@ -3626,7 +3630,11 @@ namespace SqlSugar
|
|||||||
base.Where(conditionalModels);
|
base.Where(conditionalModels);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public new ISugarQueryable<T,T2> Where(IFuncModel funcModel)
|
||||||
|
{
|
||||||
|
var obj = this.SqlBuilder.FuncModelToSql(funcModel);
|
||||||
|
return this.Where(obj.Key, obj.Value);
|
||||||
|
}
|
||||||
public new ISugarQueryable<T, T2> WhereIF(bool isWhere, string whereString, object whereObj)
|
public new ISugarQueryable<T, T2> WhereIF(bool isWhere, string whereString, object whereObj)
|
||||||
{
|
{
|
||||||
if (!isWhere) return this;
|
if (!isWhere) return this;
|
||||||
@ -4233,7 +4241,11 @@ namespace SqlSugar
|
|||||||
base.Where(conditionalModels);
|
base.Where(conditionalModels);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public new ISugarQueryable<T, T2,T3> Where(IFuncModel funcModel)
|
||||||
|
{
|
||||||
|
var obj = this.SqlBuilder.FuncModelToSql(funcModel);
|
||||||
|
return this.Where(obj.Key, obj.Value);
|
||||||
|
}
|
||||||
public ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression)
|
public ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression)
|
||||||
{
|
{
|
||||||
if (isWhere)
|
if (isWhere)
|
||||||
@ -4619,7 +4631,11 @@ namespace SqlSugar
|
|||||||
base.Where(conditionalModels);
|
base.Where(conditionalModels);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public new ISugarQueryable<T, T2,T3,T4> Where(IFuncModel funcModel)
|
||||||
|
{
|
||||||
|
var obj = this.SqlBuilder.FuncModelToSql(funcModel);
|
||||||
|
return this.Where(obj.Key, obj.Value);
|
||||||
|
}
|
||||||
public new ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
public new ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
||||||
{
|
{
|
||||||
if (isWhere)
|
if (isWhere)
|
||||||
@ -5229,7 +5245,11 @@ namespace SqlSugar
|
|||||||
base.Where(conditionalModels);
|
base.Where(conditionalModels);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public new ISugarQueryable<T, T2, T3, T4,T5> Where(IFuncModel funcModel)
|
||||||
|
{
|
||||||
|
var obj = this.SqlBuilder.FuncModelToSql(funcModel);
|
||||||
|
return this.Where(obj.Key, obj.Value);
|
||||||
|
}
|
||||||
public new ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
public new ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
||||||
{
|
{
|
||||||
if (isWhere)
|
if (isWhere)
|
||||||
@ -5778,7 +5798,11 @@ namespace SqlSugar
|
|||||||
base.Where(conditionalModels);
|
base.Where(conditionalModels);
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
public new ISugarQueryable<T, T2, T3, T4, T5,T6> Where(IFuncModel funcModel)
|
||||||
|
{
|
||||||
|
var obj = this.SqlBuilder.FuncModelToSql(funcModel);
|
||||||
|
return this.Where(obj.Key, obj.Value);
|
||||||
|
}
|
||||||
public new ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
public new ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, bool>> expression)
|
||||||
{
|
{
|
||||||
if (isWhere)
|
if (isWhere)
|
||||||
|
@ -61,6 +61,7 @@ namespace SqlSugar
|
|||||||
ISugarQueryable<T> TranLock(DbLockType? LockType = DbLockType.Wait);
|
ISugarQueryable<T> TranLock(DbLockType? LockType = DbLockType.Wait);
|
||||||
ISugarQueryable<T> Where(Expression<Func<T, bool>> expression);
|
ISugarQueryable<T> Where(Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T> Where(string whereString, object parameters = null);
|
ISugarQueryable<T> Where(string whereString, object parameters = null);
|
||||||
|
ISugarQueryable<T> Where(IFuncModel funcModel);
|
||||||
ISugarQueryable<T> Where(List<IConditionalModel> conditionalModels);
|
ISugarQueryable<T> Where(List<IConditionalModel> conditionalModels);
|
||||||
ISugarQueryable<T> Where(List<IConditionalModel> conditionalModels,bool isWrap);
|
ISugarQueryable<T> Where(List<IConditionalModel> conditionalModels,bool isWrap);
|
||||||
ISugarQueryable<T> Where(string fieldName, string conditionalType, object fieldValue);
|
ISugarQueryable<T> Where(string fieldName, string conditionalType, object fieldValue);
|
||||||
@ -220,6 +221,7 @@ namespace SqlSugar
|
|||||||
new ISugarQueryable<T, T2> Where(Expression<Func<T, bool>> expression);
|
new ISugarQueryable<T, T2> Where(Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T, T2> Where(Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2> Where(Expression<Func<T, T2, bool>> expression);
|
||||||
new ISugarQueryable<T, T2> Where(List<IConditionalModel> conditionalModels);
|
new ISugarQueryable<T, T2> Where(List<IConditionalModel> conditionalModels);
|
||||||
|
new ISugarQueryable<T,T2> Where(IFuncModel funcModel);
|
||||||
|
|
||||||
new ISugarQueryable<T, T2> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
new ISugarQueryable<T, T2> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T, T2> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
||||||
@ -319,7 +321,7 @@ namespace SqlSugar
|
|||||||
ISugarQueryable<T, T2, T3> Where(Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2, T3> Where(Expression<Func<T, T2, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3> Where(Expression<Func<T, T2, T3, bool>> expression);
|
ISugarQueryable<T, T2, T3> Where(Expression<Func<T, T2, T3, bool>> expression);
|
||||||
new ISugarQueryable<T, T2, T3> Where(List<IConditionalModel> conditionalModels);
|
new ISugarQueryable<T, T2, T3> Where(List<IConditionalModel> conditionalModels);
|
||||||
|
new ISugarQueryable<T, T2,T3> Where(IFuncModel funcModel);
|
||||||
new ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
new ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
ISugarQueryable<T, T2, T3> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
||||||
@ -434,7 +436,7 @@ namespace SqlSugar
|
|||||||
ISugarQueryable<T, T2, T3, T4> Where(Expression<Func<T, T2, T3, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4> Where(Expression<Func<T, T2, T3, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4> Where(Expression<Func<T, T2, T3, T4, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4> Where(Expression<Func<T, T2, T3, T4, bool>> expression);
|
||||||
new ISugarQueryable<T, T2, T3, T4> Where(List<IConditionalModel> conditionalModels);
|
new ISugarQueryable<T, T2, T3, T4> Where(List<IConditionalModel> conditionalModels);
|
||||||
|
new ISugarQueryable<T, T2, T3,T4> Where(IFuncModel funcModel);
|
||||||
new ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
new ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
||||||
@ -560,7 +562,7 @@ namespace SqlSugar
|
|||||||
ISugarQueryable<T, T2, T3, T4, T5> Where(Expression<Func<T, T2, T3, T4, T5, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5> Where(Expression<Func<T, T2, T3, T4, T5, bool>> expression);
|
||||||
new ISugarQueryable<T, T2, T3, T4, T5> Where(List<IConditionalModel> conditionalModels);
|
new ISugarQueryable<T, T2, T3, T4, T5> Where(List<IConditionalModel> conditionalModels);
|
||||||
|
|
||||||
|
new ISugarQueryable<T, T2, T3, T4,T5> Where(IFuncModel funcModel);
|
||||||
new ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
new ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
||||||
@ -678,7 +680,7 @@ namespace SqlSugar
|
|||||||
ISugarQueryable<T, T2, T3, T4, T5, T6> Where(Expression<Func<T, T2, T3, T4, T5, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5, T6> Where(Expression<Func<T, T2, T3, T4, T5, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4, T5, T6> Where(Expression<Func<T, T2, T3, T4, T5, T6, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5, T6> Where(Expression<Func<T, T2, T3, T4, T5, T6, bool>> expression);
|
||||||
new ISugarQueryable<T, T2, T3, T4, T5, T6> Where(List<IConditionalModel> conditionalModels);
|
new ISugarQueryable<T, T2, T3, T4, T5, T6> Where(List<IConditionalModel> conditionalModels);
|
||||||
|
new ISugarQueryable<T, T2, T3, T4, T5,T6> Where(IFuncModel funcModel);
|
||||||
new ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
new ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, T2, bool>> expression);
|
||||||
ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
ISugarQueryable<T, T2, T3, T4, T5, T6> WhereIF(bool isWhere, Expression<Func<T, T2, T3, bool>> expression);
|
||||||
|
@ -8,7 +8,7 @@ namespace SqlSugar
|
|||||||
public abstract partial class SqlBuilderProvider : SqlBuilderAccessory, ISqlBuilder
|
public abstract partial class SqlBuilderProvider : SqlBuilderAccessory, ISqlBuilder
|
||||||
{
|
{
|
||||||
#region Variable
|
#region Variable
|
||||||
private string[] SqlSplicingOperator = new string[] { ">", ">=", "<", "<=", "(", ")", "=", "||", "&&","&","|" };
|
private string[] SqlSplicingOperator = new string[] { ">", ">=", "<", "<=", "(", ")", "=", "||", "&&","&","|","null","is","isnot" };
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Root
|
#region Root
|
||||||
|
Loading…
Reference in New Issue
Block a user