mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2026-01-22 02:51:58 +08:00
SimpleClient添加重载的方法;SimpleClient的属性添加virtual关键字。
This commit is contained in:
@@ -36,18 +36,18 @@ namespace SqlSugar
|
|||||||
T GetById(dynamic id);
|
T GetById(dynamic id);
|
||||||
List<T> GetList();
|
List<T> GetList();
|
||||||
List<T> GetList(Expression<Func<T, bool>> whereExpression);
|
List<T> GetList(Expression<Func<T, bool>> whereExpression);
|
||||||
|
List<T> GetList(List<IConditionalModel> conditionalList);
|
||||||
List<T> GetList(Expression<Func<T, bool>> whereExpression, List<OrderByModel> orderByModels);
|
List<T> GetList(Expression<Func<T, bool>> whereExpression, List<OrderByModel> orderByModels);
|
||||||
|
List<T> GetList(List<IConditionalModel> conditionalList, List<OrderByModel> orderByModels);
|
||||||
List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page);
|
List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page);
|
||||||
List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page, List<OrderByModel> orderByModels);
|
List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page, List<OrderByModel> orderByModels);
|
||||||
List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page, Expression<Func<T, object>> orderByExpression = null, OrderByType orderByType = OrderByType.Asc);
|
List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page, Expression<Func<T, object>> orderByExpression = null, OrderByType orderByType = OrderByType.Asc);
|
||||||
List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page);
|
List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page);
|
||||||
List<T> GetPageList(List<IConditionalModel> conditionalList, List<OrderByModel> orderByModels);
|
|
||||||
List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page, List<OrderByModel> orderByModels);
|
List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page, List<OrderByModel> orderByModels);
|
||||||
List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page, Expression<Func<T, object>> orderByExpression = null, OrderByType orderByType = OrderByType.Asc);
|
List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page, Expression<Func<T, object>> orderByExpression = null, OrderByType orderByType = OrderByType.Asc);
|
||||||
T GetSingle(Expression<Func<T, bool>> whereExpression);
|
T GetSingle(Expression<Func<T, bool>> whereExpression);
|
||||||
T GetSingle(List<IConditionalModel> conditionalModels);
|
T GetSingle(List<IConditionalModel> conditionalModels);
|
||||||
T GetFirst(Expression<Func<T, bool>> whereExpression);
|
T GetFirst(Expression<Func<T, bool>> whereExpression);
|
||||||
T GetFirst(Expression<Func<T, bool>> whereExpression, List<OrderByModel> orderByModels);
|
|
||||||
T GetFirst(List<IConditionalModel> conditionalModels);
|
T GetFirst(List<IConditionalModel> conditionalModels);
|
||||||
T GetFirst(List<IConditionalModel> conditionalModels, List<OrderByModel> orderByModels);
|
T GetFirst(List<IConditionalModel> conditionalModels, List<OrderByModel> orderByModels);
|
||||||
bool Insert(T insertObj);
|
bool Insert(T insertObj);
|
||||||
|
|||||||
@@ -707,6 +707,16 @@ namespace SqlSugar
|
|||||||
return Context.Queryable<T>().Where(whereExpression).OrderBy(orderByModels).ToList();
|
return Context.Queryable<T>().Where(whereExpression).OrderBy(orderByModels).ToList();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<T> GetList(List<IConditionalModel> conditionalList)
|
||||||
|
{
|
||||||
|
return Context.Queryable<T>().Where(conditionalList).ToList();
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<T> GetList(List<IConditionalModel> conditionalList, List<OrderByModel> orderByModels)
|
||||||
|
{
|
||||||
|
return Context.Queryable<T>().Where(conditionalList).OrderBy(orderByModels).ToList();
|
||||||
|
}
|
||||||
|
|
||||||
public List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page, List<OrderByModel> orderByModels)
|
public List<T> GetPageList(Expression<Func<T, bool>> whereExpression, PageModel page, List<OrderByModel> orderByModels)
|
||||||
{
|
{
|
||||||
var total = 0;
|
var total = 0;
|
||||||
@@ -715,11 +725,6 @@ namespace SqlSugar
|
|||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<T> GetPageList(List<IConditionalModel> conditionalList, List<OrderByModel> orderByModels)
|
|
||||||
{
|
|
||||||
return Context.Queryable<T>().Where(conditionalList).OrderBy(orderByModels).ToList();
|
|
||||||
}
|
|
||||||
|
|
||||||
public List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page, List<OrderByModel> orderByModels)
|
public List<T> GetPageList(List<IConditionalModel> conditionalList, PageModel page, List<OrderByModel> orderByModels)
|
||||||
{
|
{
|
||||||
var total = 0;
|
var total = 0;
|
||||||
@@ -752,6 +757,7 @@ namespace SqlSugar
|
|||||||
{
|
{
|
||||||
return Context.Queryable<T>().Where(conditionalModels).OrderBy(orderByModels).First();
|
return Context.Queryable<T>().Where(conditionalModels).OrderBy(orderByModels).First();
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user