Update SimpleClient

This commit is contained in:
sunkaixuan 2018-12-02 22:56:43 +08:00
parent 58928e07be
commit 72a1763059

View File

@ -80,7 +80,7 @@ namespace SqlSugar
{
return this.Context.Insertable(insertObjs).ExecuteCommand() > 0;
}
public bool InsertRange<T>(List<T>[] insertObjs) where T : class, new()
public bool InsertRange<T>(List<T> insertObjs) where T : class, new()
{
return this.Context.Insertable(insertObjs).ExecuteCommand() > 0;
}
@ -92,6 +92,10 @@ namespace SqlSugar
{
return this.Context.Updateable(updateObjs).ExecuteCommand() > 0;
}
public bool UpdateRange<T>(List<T> updateObjs) where T : class, new()
{
return this.Context.Updateable(updateObjs).ExecuteCommand() > 0;
}
public bool Update<T>(Expression<Func<T, T>> columns, Expression<Func<T, bool>> whereExpression) where T : class, new()
{
return this.Context.Updateable<T>().UpdateColumns(columns).Where(whereExpression).ExecuteCommand() > 0;
@ -193,7 +197,7 @@ namespace SqlSugar
{
return this.Context.Insertable(insertObjs).ExecuteCommand() > 0;
}
public bool InsertRange(List<T>[] insertObjs)
public bool InsertRange(List<T> insertObjs)
{
return this.Context.Insertable(insertObjs).ExecuteCommand() > 0;
}
@ -205,6 +209,10 @@ namespace SqlSugar
{
return this.Context.Updateable(updateObjs).ExecuteCommand() > 0;
}
public bool UpdateRange(List<T> updateObjs)
{
return this.Context.Updateable(updateObjs).ExecuteCommand() > 0;
}
public bool Update(Expression<Func<T, T>> columns, Expression<Func<T, bool>> whereExpression)
{
return this.Context.Updateable<T>().UpdateColumns(columns).Where(whereExpression).ExecuteCommand() > 0;