Browse Source

Update db.Queryable

SqlSugar5
sunkaixuan 2 years ago
parent
commit
9154a88e15
  1. 4
      Src/Asp.Net/SqlSugar/Abstract/SugarProvider/SqlSugarProvider.cs
  2. 2
      Src/Asp.Net/SqlSugar/Abstract/SugarProvider/SqlSugarScopeProvider.cs
  3. 2
      Src/Asp.Net/SqlSugar/Interface/ISqlSugarClient.cs
  4. 2
      Src/Asp.Net/SqlSugar/SqlSugarClient.cs
  5. 2
      Src/Asp.Net/SqlSugar/SqlSugarScope.cs

4
Src/Asp.Net/SqlSugar/Abstract/SugarProvider/SqlSugarProvider.cs

@ -407,10 +407,10 @@ namespace SqlSugar
queryable.Where(joinExpression);
return queryable;
}
public virtual ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable) where T : class, new()
public virtual ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable)
{
var sqlobj = queryable.ToSql();
var result = this.SqlQueryable<T>(sqlobj.Key).AddParameters(sqlobj.Value);
var result = this.SqlQueryable<object>(sqlobj.Key).AddParameters(sqlobj.Value).Select<T>("*");
result.QueryBuilder.IsSqlQuery = false;
return result;
}

2
Src/Asp.Net/SqlSugar/Abstract/SugarProvider/SqlSugarScopeProvider.cs

@ -454,7 +454,7 @@ namespace SqlSugar
return ScopedContext.Queryable<T>();
}
public ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable) where T : class, new()
public ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable)
{
return ScopedContext.Queryable(queryable);
}

2
Src/Asp.Net/SqlSugar/Interface/ISqlSugarClient.cs

@ -131,7 +131,7 @@ namespace SqlSugar
where T3 : class, new()
where T4 : class, new();
ISugarQueryable<T> Queryable<T>();
ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable) where T : class, new();
ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable);
ISugarQueryable<T> Queryable<T>(string shortName);
#endregion

2
Src/Asp.Net/SqlSugar/SqlSugarClient.cs

@ -429,7 +429,7 @@ namespace SqlSugar
return this.Context.Queryable<T>();
}
public ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable) where T : class, new()
public ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable)
{
var result= this.Context.Queryable<T>(queryable);

2
Src/Asp.Net/SqlSugar/SqlSugarScope.cs

@ -440,7 +440,7 @@ namespace SqlSugar
return ScopedContext.Queryable<T>();
}
public ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable) where T : class, new()
public ISugarQueryable<T> Queryable<T>(ISugarQueryable<T> queryable)
{
return ScopedContext.Queryable(queryable);
}

Loading…
Cancel
Save