Пример #1
0
        public IListExpression <TRequest, TEntity, TResult> SortColumn(Expression <Func <TRequest, string> > property, Action <ISortColumnExpression <TRequest, TEntity, TResult> > action = null)
        {
            var expression = new SortColumnExpression <TRequest, TEntity, TResult>(property);

            action?.Invoke(expression);
            SortColumnDefinition = expression;
            return(this);
        }
Пример #2
0
        public IListExpression <TRequest, TEntity, TResult> SortColumn(string name = null, Action <ISortColumnExpression <TRequest, TEntity, TResult> > action = null)
        {
            name = !string.IsNullOrWhiteSpace(name) ? name : null;
            var expression = new SortColumnExpression <TRequest, TEntity, TResult>(name);

            action?.Invoke(expression);
            SortColumnDefinition = expression;
            return(this);
        }