Simplified Delete

This commit is contained in:
sunkaixuan 2017-07-03 02:59:52 +08:00
parent ae7f4b1dbf
commit 2a9ac296ef
2 changed files with 26 additions and 2 deletions

View File

@ -31,5 +31,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("4.1.0.5")]
[assembly: AssemblyFileVersion("4.1.0.5")]
[assembly: AssemblyVersion("4.1.0.6")]
[assembly: AssemblyFileVersion("4.1.0.6")]

View File

@ -251,6 +251,30 @@ namespace SqlSugar
DeleteableProvider<T> reval = base.CreateDeleteable<T>();
return reval;
}
public virtual IDeleteable<T> Deleteable<T>(Expression<Func<T, bool>> expression) where T : class, new()
{
return this.Deleteable<T>().Where(expression);
}
public virtual IDeleteable<T> Deleteable<T>(dynamic primaryKeyValue) where T : class, new()
{
return this.Deleteable<T>().In(primaryKeyValue);
}
public virtual IDeleteable<T> Deleteable<T>(dynamic [] primaryKeyValues) where T : class, new()
{
return this.Deleteable<T>().In(primaryKeyValues);
}
public virtual IDeleteable<T> Deleteable<T>(List<dynamic> pkValue) where T : class, new()
{
return this.Deleteable<T>().In(pkValue);
}
public virtual IDeleteable<T> Deleteable<T>(T deleteObj) where T : class, new()
{
return this.Deleteable<T>().Where(deleteObj);
}
public virtual IDeleteable<T> Deleteable<T>(List<T> deleteObjs) where T : class, new()
{
return this.Deleteable<T>().Where(deleteObjs);
}
#endregion
#region Updateable