public List <IVolumeObjectModel> Search(IVolumeObjectSearchModel searchModel, bool asListing = false)
        {
            var results = VolumeObjectsRepository.Search(searchModel);

            return(asListing
                ? results.Select(VolumeObjectMapper.MapToModelListing).ToList()
                : results.Select(VolumeObjectMapper.MapToModelLite).ToList());
        }
コード例 #2
0
 // ReSharper disable once ReturnTypeCanBeEnumerable.Local
 // ReSharper disable once SuggestBaseTypeForParameter
 private IQueryable<IVolumeObject> SearchCommon(IVolumeObjectSearchModel searchModel, bool requireActive)
 {
     return Context.VolumeObjects
         .FilterByBaseFilters(searchModel, requireActive)
         .FilterByPaging(searchModel.Paging);
 }
コード例 #3
0
 public IEnumerable<IVolumeObject> Search(IVolumeObjectSearchModel searchModel, bool requireActive = true)
 {
     return SearchCommon(searchModel, requireActive);
 }
コード例 #4
0
 public IEnumerable<dynamic> Search(IVolumeObjectSearchModel searchModel, System.Func<IVolumeObject, dynamic> selectStatement, bool requireActive = true)
 {
     return SearchCommon(searchModel, requireActive)
         .Select(selectStatement);
 }
コード例 #5
0
 // ReSharper disable once ReturnTypeCanBeEnumerable.Local
 // ReSharper disable once SuggestBaseTypeForParameter
 private IQueryable <IVolumeObject> SearchCommon(IVolumeObjectSearchModel searchModel, bool requireActive)
 {
     return(Context.VolumeObjects
            .FilterByBaseFilters(searchModel, requireActive)
            .FilterByPaging(searchModel.Paging));
 }
コード例 #6
0
 public IEnumerable <IVolumeObject> Search(IVolumeObjectSearchModel searchModel, bool requireActive = true)
 {
     return(SearchCommon(searchModel, requireActive));
 }
コード例 #7
0
 public IEnumerable <dynamic> Search(IVolumeObjectSearchModel searchModel, System.Func <IVolumeObject, dynamic> selectStatement, bool requireActive = true)
 {
     return(SearchCommon(searchModel, requireActive)
            .Select(selectStatement));
 }
 public List<IVolumeObjectModel> Search(IVolumeObjectSearchModel searchModel, bool asListing = false)
 {
     var results = VolumeObjectsRepository.Search(searchModel);
     return asListing
         ? results.Select(VolumeObjectMapper.MapToModelListing).ToList()
         : results.Select(VolumeObjectMapper.MapToModelLite).ToList();
 }