Пример #1
0
        private ResultDto <List <Dto.MemberOutDto> > GetDatas(int page = 1, int pageSize = 0, string keywords = "", bool IsReger = true, string sort = "", string order = "")
        {
            ResultDto <List <Dto.MemberOutDto> > result = new ResultDto <List <Dto.MemberOutDto> >();

            try
            {
                ResultDto <List <Members> > items = new ResultDto <List <Members> >();
                MembersService Member             = new MembersService();
                var            predicate          = PredicateBuilder.True <Members>();
                predicate = o => o.TenantId == TenantId && o.IsReger == IsReger;
                items     = Member.GetListOrderByTime(page, pageSize, predicate, keywords, sort, order);
                result    = Mapper.Map <ResultDto <List <Dto.MemberOutDto> > >(items);
                Member.Dispose();
            }
            catch (Exception ex)
            {
                result.code    = 500;
                result.message = ex.Message;
            }
            return(result);
        }