Пример #1
0
        public IEnumerable <ApplicationGroup> GetAll(int page, int pageSize, out int totalRow, string filter = null)
        {
            var query = _appGroupRepository.GetAll();

            if (!string.IsNullOrEmpty(filter))
            {
                query = query.Where(x => x.Name.Contains(filter));
            }

            totalRow = query.Count();
            return(query.OrderBy(x => x.Name).Skip(page * pageSize).Take(pageSize));
        }
 public IEnumerable <ApplicationGroup> GetAll(string keyword)
 {
     if (!string.IsNullOrEmpty(keyword))
     {
         return(_appGroupRepository.GetMulti(x => x.Name.Contains(keyword)));
     }
     else
     {
         return(_appGroupRepository.GetAll());
     }
 }
Пример #3
0
 public IEnumerable <ApplicationGroup> GetAll()
 {
     return(_appGroupRepository.GetAll());
 }
Пример #4
0
 public async Task <IEnumerable <ApplicationGroup> > GetAll()
 {
     return(await _appGroupRepository.GetAll());
 }