Ejemplo n.º 1
0
 public QuerySet <T> SortDesc(params Expression <Func <T, object> >[] Expr)
 {
     foreach (var x in Expr)
     {
         List <string> Fields = SortCompiler.GetFields(x);
         foreach (var f in Fields)
         {
             this.sortList.Add(new SortingInfo()
             {
                 FieldName = f,
                 SortType  = "desc"
             });
         }
     }
     return(this);
 }
Ejemplo n.º 2
0
        public QuerySet <T> SortDesc(Expression <Func <T, object> > Expr)
        {
            var           Body   = ((LambdaExpression)Expr).Body;
            List <string> Fields = SortCompiler.GetFields(Body);

            foreach (var f in Fields)
            {
                this.sortList.Add(new SortingInfo()
                {
                    FieldName = f,
                    SortType  = "desc"
                });
            }

            return(this);
        }