Synchronization code

This commit is contained in:
sunkaixuan 2024-07-14 21:10:43 +08:00
parent d5202602e7
commit 47924769e6
3 changed files with 10 additions and 0 deletions

View File

@ -45,6 +45,10 @@ namespace SqlSugar
}
public UpdateCommonMethodInfo IgnoreColumns(params string[] ignoreColumns)
{
if (Context == null)
{
return new UpdateCommonMethodInfo();
}
var inertable = MethodInfo.Invoke(Context, new object[] { objectValue });
var newMethod = inertable.GetType().GetMyMethod("IgnoreColumns", 1,typeof(string[]));
var result = newMethod.Invoke(inertable, new object[] { ignoreColumns });

View File

@ -225,6 +225,11 @@ namespace SqlSugar
result.updateableObj.UpdateBuilder.ShortName = joinExpress.Parameters.FirstOrDefault()?.Name;
return result;
}
public IUpdateable<T, T2> InnerJoin<T2>(ISugarQueryable<T> queryable, Expression<Func<T, T2, bool>> joinExpress)
{
var tableName=$" ({queryable.Clone().ToSqlString()}) ";;
return this.InnerJoin(joinExpress, tableName);
}
public IUpdateable<T, T2> InnerJoin<T2>(Expression<Func<T, T2, bool>> joinExpress,string TableName)
{
UpdateableProvider<T, T2> result = new UpdateableProvider<T, T2>();

View File

@ -119,6 +119,7 @@ namespace SqlSugar
IUpdateable<T> Clone();
IUpdateable<T,T2> InnerJoin<T2>(Expression<Func<T,T2,bool>> joinExpress);
IUpdateable<T, T2> InnerJoin<T2>(Expression<Func<T, T2, bool>> joinExpress,string tableName);
IUpdateable<T, T2> InnerJoin<T2>(ISugarQueryable<T> queryable,Expression<Func<T, T2, bool>> joinExpress);
UpdateablePage<T> PageSize(int pageSize);
IUpdateable<T> In(object[] ids);
ParameterUpdateable<T> UseParameter();