Ejemplo n.º 1
0
        public override IQueryable ApplyQuery(IQueryable queryable, System.Web.OData.Query.ODataQueryOptions queryOptions)
        {
            System.Linq.IQueryable <string> c;

            var x = base.ApplyQuery(queryable, queryOptions);
//            x.addGroupBy
            var expression = x.Expression;

//            System.Linq.Expressions.MethodCallExpressionN ex = (System.Linq.Expressions.MethodCallExpressionN)expression;
            return(x);
        }
Ejemplo n.º 2
0
        public static async Task <List <Person> > GetPersonAsync(System.Web.OData.Query.ODataQueryOptions <Person> queryOptions)
        {
            IMongoCollection <Person> collection = db.GetCollection <Person>(collectionName);

            return(await collection.Find <Person>(x => x.Name != null).ToListAsync());
        }
Ejemplo n.º 3
0
 public override void ValidateQuery(System.Net.Http.HttpRequestMessage request, System.Web.OData.Query.ODataQueryOptions queryOptions)
 {
     //base.ValidateQuery(request, queryOptions);
 }
Ejemplo n.º 4
0
 public override object ApplyQuery(object entity, System.Web.OData.Query.ODataQueryOptions queryOptions)
 {
     return(base.ApplyQuery(entity, queryOptions));
 }