diff --git a/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs b/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs index 8c2627d48..5b04a6de0 100644 --- a/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs +++ b/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/QueryableProvider.cs @@ -665,7 +665,7 @@ namespace SqlSugar _Where(expression); return this; } - public ISugarQueryable WhereIF(bool isWhere, Expression> expression) + public new ISugarQueryable WhereIF(bool isWhere, Expression> expression) { if (isWhere) _Where(expression); @@ -677,6 +677,18 @@ namespace SqlSugar _Where(expression); return this; } + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion #region Select @@ -802,12 +814,25 @@ namespace SqlSugar return this; } - public ISugarQueryable WhereIF(bool isWhere, Expression> expression) + public new ISugarQueryable WhereIF(bool isWhere, Expression> expression) { if (isWhere) _Where(expression); return this; } + + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion } @@ -837,7 +862,7 @@ namespace SqlSugar return this; } - public ISugarQueryable WhereIF(bool isWhere, Expression> expression) + public new ISugarQueryable WhereIF(bool isWhere, Expression> expression) { if (isWhere) _Where(expression); @@ -864,6 +889,19 @@ namespace SqlSugar _Where(expression); return this; } + + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion #region Select @@ -958,7 +996,7 @@ namespace SqlSugar return this; } - public ISugarQueryable WhereIF(bool isWhere, Expression> expression) + public new ISugarQueryable WhereIF(bool isWhere, Expression> expression) { if (isWhere) _Where(expression); @@ -992,6 +1030,19 @@ namespace SqlSugar _Where(expression); return this; } + + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion #region Select @@ -1105,7 +1156,7 @@ namespace SqlSugar return this; } - public ISugarQueryable WhereIF(bool isWhere, Expression> expression) + public new ISugarQueryable WhereIF(bool isWhere, Expression> expression) { if (isWhere) _Where(expression); @@ -1146,6 +1197,19 @@ namespace SqlSugar _Where(expression); return this; } + + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion #region Select @@ -1326,6 +1390,19 @@ namespace SqlSugar _Where(expression); return this; } + + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion #region Select @@ -1533,6 +1610,19 @@ namespace SqlSugar _Where(expression); return this; } + + public new ISugarQueryable Where(string whereString, object whereObj) + { + Where(whereString, whereObj); + return this; + } + + public new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj) + { + if (!isWhere) return this; + this.Where(whereString, whereObj); + return this; + } #endregion #region Select diff --git a/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs b/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs index 23a7c3e52..5afc40d3c 100644 --- a/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs +++ b/Src/Asp.Net/SqlSugar/Interface/IQueryable.cs @@ -99,6 +99,9 @@ namespace SqlSugar new ISugarQueryable WhereIF(bool isWhere,Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select @@ -125,6 +128,9 @@ namespace SqlSugar new ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select @@ -156,6 +162,9 @@ namespace SqlSugar ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select @@ -193,6 +202,9 @@ namespace SqlSugar ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select @@ -234,6 +246,9 @@ namespace SqlSugar ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select @@ -273,13 +288,16 @@ namespace SqlSugar ISugarQueryable Where(Expression> expression); ISugarQueryable Where(Expression> expression); - ISugarQueryable WhereIF(bool isWhere, Expression> expression); + new ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select @@ -331,6 +349,9 @@ namespace SqlSugar ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); ISugarQueryable WhereIF(bool isWhere, Expression> expression); + + new ISugarQueryable Where(string whereString, object whereObj = null); + new ISugarQueryable WhereIF(bool isWhere, string whereString, object whereObj = null); #endregion #region Select