mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-24 18:04:52 +08:00
Synchronization code
This commit is contained in:
parent
ebd73bb9b9
commit
bc937c1805
@ -16,6 +16,7 @@ namespace SqlSugar
|
||||
|
||||
public InsertNavTask<Root, TChild> Include<TChild>(Expression<Func<Root, TChild>> expression) where TChild : class, new()
|
||||
{
|
||||
Check.ExceptionEasy(typeof(TChild).FullName.Contains("System.Collections.Generic.List`"), " need where T: class, new() ", "需要Class,new()约束,并且类属性中不能有required修饰符");
|
||||
this.Context = insertNavProvider._Context;
|
||||
insertNavProvider.NavContext = this.NavContext;
|
||||
InsertNavTask<Root, TChild> result = new InsertNavTask<Root, TChild>();
|
||||
@ -39,6 +40,7 @@ namespace SqlSugar
|
||||
|
||||
public InsertNavTask<Root, TChild> Include<TChild>(Expression<Func<Root, TChild>> expression,InsertNavOptions options) where TChild : class, new()
|
||||
{
|
||||
Check.ExceptionEasy(typeof(TChild).FullName.Contains("System.Collections.Generic.List`"), " need where T: class, new() ", "需要Class,new()约束,并且类属性中不能有required修饰符");
|
||||
this.Context = insertNavProvider._Context;
|
||||
insertNavProvider.NavContext = this.NavContext;
|
||||
InsertNavTask<Root, TChild> result = new InsertNavTask<Root, TChild>();
|
||||
|
@ -1046,6 +1046,42 @@ namespace SqlSugar
|
||||
#endregion
|
||||
|
||||
#region OrderBy
|
||||
public new virtual ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, T4, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6,T7, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
|
||||
public new ISugarQueryable<T, T2, T3, T4, T5, T6, T7> OrderBy(string orderFileds)
|
||||
{
|
||||
base.OrderBy(orderFileds);
|
||||
@ -1737,6 +1773,46 @@ namespace SqlSugar
|
||||
#endregion
|
||||
|
||||
#region OrderBy
|
||||
public new virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6, T7, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public virtual ISugarQueryable<T, T2, T3, T4, T5, T6, T7, T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6, T7,T8, object>> expression)
|
||||
{
|
||||
this._OrderBy(expression, OrderByType.Desc);
|
||||
return this;
|
||||
}
|
||||
public new ISugarQueryable<T, T2, T3, T4, T5, T6, T7, T8> OrderBy(string orderFileds)
|
||||
{
|
||||
base.OrderBy(orderFileds);
|
||||
|
@ -982,6 +982,13 @@ namespace SqlSugar
|
||||
#endregion
|
||||
|
||||
#region OrderBy
|
||||
new ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, T4, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6,T7, object>> expression);
|
||||
new ISugarQueryable<T, T2, T3, T4, T5, T6,T7> OrderBy(string orderFileds);
|
||||
new ISugarQueryable<T, T2, T3, T4, T5, T6, T7> OrderBy(Expression<Func<T, object>> expression, OrderByType type = OrderByType.Asc);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7> OrderBy(Expression<Func<T, T2, object>> expression, OrderByType type = OrderByType.Asc);
|
||||
@ -1111,6 +1118,14 @@ namespace SqlSugar
|
||||
#endregion
|
||||
|
||||
#region OrderBy
|
||||
new ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7,T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6,T7, object>> expression);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7, T8> OrderByDescending(Expression<Func<T, T2, T3, T4, T5, T6,T7,T8, object>> expression);
|
||||
new ISugarQueryable<T, T2, T3, T4, T5, T6,T7,T8> OrderBy(string orderFileds);
|
||||
new ISugarQueryable<T, T2, T3, T4, T5, T6, T7, T8> OrderBy(Expression<Func<T, object>> expression, OrderByType type = OrderByType.Asc);
|
||||
ISugarQueryable<T, T2, T3, T4, T5, T6, T7, T8> OrderBy(Expression<Func<T, T2, object>> expression, OrderByType type = OrderByType.Asc);
|
||||
|
@ -184,7 +184,7 @@ namespace SqlSugar
|
||||
|
||||
public IInsertable<T> Insertable<T>(T insertObj) where T : class, new()
|
||||
{
|
||||
Check.Exception(typeof(T).FullName.Contains("System.Collections.Generic.List`"), " need where T: class, new() ");
|
||||
Check.ExceptionEasy(typeof(T).FullName.Contains("System.Collections.Generic.List`"), " need where T: class, new() ","需要Class,new()约束,并且类属性中不能有required修饰符");
|
||||
if (typeof(T).Name == "Object")
|
||||
{
|
||||
Check.ExceptionEasy("Object type use db.InsertableByObject(obj).ExecuteCommand()", "检测到T为Object类型,请使用 db.InsertableByObject(obj).ExecuteCommand(),Insertable不支持object,InsertableByObject可以(缺点:功能比较少)");
|
||||
|
Loading…
Reference in New Issue
Block a user