public PagedList(IPageInfo page) { this.pageInfo = page; this.TotalCount = pageInfo.TotalCount; this.PageSize = pageInfo.PageSize; this.PageIndex = pageInfo.PageIndex + 1; }
public ProductController(ICatalogApi catApi, IProductViewModelBuilder prodViewModelBuilder, IRequestLogger logger, ILinkGenerator linkGenerator, IPageInfo pageInfo) : base(logger, linkGenerator, catApi) { _pageInfo = pageInfo; _prodViewModelBuilder = prodViewModelBuilder; _catApi = catApi; }
public void PageInfo_Throw_ArgumentNullException() { //Arrange IPageInfo pageInfo = null; ArgumentException exception = null; //Act try { // ReSharper disable once ExpressionIsAlwaysNull pageInfo.CalculateSkip(); } catch (ArgumentException e) { exception = e; } //Assert Assert.Multiple(() => { Assert.IsInstanceOf <ArgumentNullException>(exception); // ReSharper disable once PossibleNullReferenceException Assert.AreEqual("pageInfo", exception.ParamName); }); }
public IPageableList <Resource> GetResources(string text, IPageInfo pageInfo) { using (var repositoriesContainer = new InnostarRepositoriesContainer()) { return(repositoriesContainer.RepositoryFor <Resource>().GetPageableBy(new PageableQuery <Resource>(pageInfo).AddFilterClause(e => e.Title.Contains(text) || string.IsNullOrEmpty(text)))); } }
/// ------------------------------------------------------------------------------------ /// <summary> /// Creates a new HFSetupDlgVC /// </summary> /// <param name="page">The PageInfo for use in creating the view</param> /// <param name="wsDefault">ID of default writing system</param> /// <param name="printDateTime">Printing date/time</param> /// <param name="cache">The cache.</param> /// ------------------------------------------------------------------------------------ public HFSetupDlgVC(IPageInfo page, int wsDefault, DateTime printDateTime, FdoCache cache) : base(page, wsDefault, printDateTime, cache) { m_resources = new ResourceManager( "SIL.FieldWorks.Common.PrintLayout.FwPrintLayoutStrings", Assembly.GetExecutingAssembly()); }
/// ------------------------------------------------------------------------------------- /// <summary> /// Creates and returns the footer view construtor for the layout. /// </summary> /// <param name="page">Page info</param> /// <returns>the footer view constructor</returns> /// ------------------------------------------------------------------------------------- public override IVwViewConstructor MakeFooterVc(IPageInfo page) { TeHeaderFooterVc vc = new TeHeaderFooterVc(m_fdoCache, page, m_wsDefault, m_printDateTime, m_filterInstance, m_sectionTag); vc.SetDa(m_fdoCache.MainCacheAccessor); return vc; }
public async Task <IBasicPagedResult <PostDto> > PostsAsync(string search, IPageInfo paging) { return(await new PostsPagedQuery(Dispatcher) { Search = search, Paging = paging }.ExecuteAsync()); }
public IPageableList <Person> GetPersons(string text, IPageInfo pageInfo) { using (var repositoriesContainer = new InnostarRepositoriesContainer()) { return(repositoriesContainer.RepositoryFor <Person>().GetPageableBy(new PageableQuery <Person>(pageInfo).AddFilterClause(e => (e.LastName + " " + e.Name + " " + e.MiddleName).Contains(text) || string.IsNullOrEmpty(text)))); } }
public static void SetPageInfo(IPageInfo pageInfo, ProductDetailPageViewModel model, string pageName) { pageInfo.PageName = pageName; if (model == null) { pageInfo.ProductStatus = "unavailable"; } else { if (!model.Product.HasVariations() || model.Product.Variations == null) { pageInfo.ProductName = model.Product.DisplayName; if (model.Product.Pricing.ListPrice != null) { pageInfo.ProductPrice = model.Product.Pricing.ListPrice.Value; } } else { var productVariation = model.Product.Variations.Product.FirstOrDefault(); if (productVariation != null) { pageInfo.ProductName = model.Product.DisplayName; if (model.Product.Pricing.ListPrice != null) { pageInfo.ProductPrice = productVariation.Pricing.ListPrice.Value; } } } } }
/// ------------------------------------------------------------------------------------- /// <summary> /// Creates and returns the footer view construtor for the layout. /// </summary> /// <param name="page">Page info</param> /// <returns>the footer view construtor</returns> /// ------------------------------------------------------------------------------------- public virtual IVwViewConstructor MakeFooterVc(IPageInfo page) { // TODO: Supply params to configure footer based on the header/footer set being used. HeaderFooterVc vc = new HeaderFooterVc(page, m_wsDefault, m_printDateTime, m_fdoCache); vc.SetDa(m_fdoCache.MainCacheAccessor); return vc; }
/// <summary> /// 开始记录数,传递给数据库,计数从0开始 /// </summary> /// <returns></returns> private static int GetBeginIndex(IPageInfo page) { if (page.PageIndex < 1 || page.PageSize < 1) { throw new Exception("查询页码以及每页记录数不能为空"); } return((page.PageIndex - 1) * page.PageSize); }
public Pageable(IPageInfo pageInfo) : base() { if (pageInfo != null) { this.PageIndex = pageInfo.PageIndex; this.PageSize = pageInfo.PageSize; } }
static public IQueryable <TElem> Page <TElem>(this IQueryable <TElem> _this, IPageInfo pageInfo) where TElem : IObjectWithId { return(_this .OrderBy(x => x.Id) .Select(x => (TElem)x) .Skip(pageInfo.PageNumber * pageInfo.PageSize) .Take(pageInfo.PageSize)); }
public Task <IResultWithTotalCount <QuestionDto> > GetAnsweredAsync(IPageInfo pagingSettings, CancellationToken cancellationToken = default) { var query = GetQuery <PagedAnsweredQuestionsQuery>(); query.Paging = pagingSettings; return(query.ExecuteAsync(cancellationToken)); }
/// ------------------------------------------------------------------------------------ /// <summary> /// Initializes a new instance of the <see cref="TeHeaderFooterVc"/> class. /// </summary> /// <param name="cache">DB Connection</param> /// <param name="page">Page information</param> /// <param name="wsDefault">ID of default writing system</param> /// <param name="printDateTime">printing date/time</param> /// <param name="filterInstance">book filter instance</param> /// ------------------------------------------------------------------------------------ public TeHeaderFooterVc(FdoCache cache, IPageInfo page, int wsDefault, DateTime printDateTime, int filterInstance) : base(page, wsDefault, printDateTime, cache) { m_scr = m_cache.LangProject.TranslatedScriptureOA; m_bookFilter = m_cache.ServiceLocator.GetInstance<IFilteredScrBookRepository>().GetFilterInstance(filterInstance); m_autoAdjustColumns = true; }
public PageSupplemental(IPageInfo dates) { Info = new PageInfo(); Info.Kontext = dates.Kontext; Info.Bericht = dates.Bericht; Info.Benutzer = dates.Benutzer; initDataTemplates(); }
public void Exception_When_PageInfo_Is_Null() { //Arrange IPageInfo info = null; //Act and Assert Assert.Throws <ArgumentNullException>(() => info.CalculateSkip()); }
/// ------------------------------------------------------------------------------------- /// <summary> /// Creates and returns the footer view construtor for the layout. /// </summary> /// <param name="page">Page info</param> /// <returns>the footer view construtor</returns> /// ------------------------------------------------------------------------------------- public virtual IVwViewConstructor MakeFooterVc(IPageInfo page) { // TODO: Supply params to configure footer based on the header/footer set being used. HeaderFooterVc vc = new HeaderFooterVc(page, m_wsDefault, m_printDateTime, m_fdoCache); vc.SetDa(m_fdoCache.MainCacheAccessor); return(vc); }
/// ------------------------------------------------------------------------------------ /// <summary> /// Initializes a new instance of the <see cref="TeHeaderFooterVc"/> class. /// </summary> /// <param name="cache">DB Connection</param> /// <param name="page">Page information</param> /// <param name="wsDefault">ID of default writing system</param> /// <param name="printDateTime">printing date/time</param> /// <param name="filterInstance">book filter instance</param> /// ------------------------------------------------------------------------------------ public TeHeaderFooterVc(FdoCache cache, IPageInfo page, int wsDefault, DateTime printDateTime, int filterInstance) : base(page, wsDefault, printDateTime, cache) { m_scr = m_cache.LangProject.TranslatedScriptureOA; m_bookFilter = m_cache.ServiceLocator.GetInstance <IFilteredScrBookRepository>().GetFilterInstance(filterInstance); m_autoAdjustColumns = true; }
/// ------------------------------------------------------------------------------------- /// <summary> /// Creates and returns the footer view construtor for the layout. /// </summary> /// <param name="page">Page info</param> /// <returns>the footer view constructor</returns> /// ------------------------------------------------------------------------------------- public override IVwViewConstructor MakeFooterVc(IPageInfo page) { TeHeaderFooterVc vc = new TeHeaderFooterVc(m_fdoCache, page, m_wsDefault, m_printDateTime, m_filterInstance, m_sectionTag); vc.SetDa(m_fdoCache.MainCacheAccessor); return(vc); }
public ShoppingCartController(ICartApi cartApi, IRequestLogger logger, ILinkGenerator linkGenerator, IPageInfo pageInfo, IOffersViewModelBuilder offersViewModelBuilder, IShoppingCartViewModelBuilder shoppingCartViewModelBuilder, ICatalogApi catalogApi) : base(logger, linkGenerator, catalogApi) { CartApi = cartApi; ShoppingCartViewModelBuilder = shoppingCartViewModelBuilder; PageInfo = pageInfo; OffersViewModelBuilder = offersViewModelBuilder; }
/// ------------------------------------------------------------------------------------ /// <summary> /// Constructor /// </summary> /// <param name="page">Page info</param> /// <param name="wsDefault">default writing system</param> /// <param name="printDateTime">Printing date/time</param> /// <param name="cache">The cache.</param> /// ------------------------------------------------------------------------------------ public HeaderFooterVc(IPageInfo page, int wsDefault, DateTime printDateTime, FdoCache cache) : base(wsDefault) { m_page = page; m_printDateTime = printDateTime; m_cache = cache; IWritingSystem defWs = m_cache.ServiceLocator.WritingSystemManager.Get(m_wsDefault); RightToLeft = defWs.RightToLeftScript; }
public void UnInitialize() { this.isInitialized = false; currentPage = null; pageToNavigate = null; exampleProgress = 0; this.cachedPages.RemoveCache(); }
public static int CalculateSkip(this IPageInfo pageInfo) { if (pageInfo == null) { throw new ArgumentNullException(nameof(pageInfo)); } return((pageInfo.NumberOfSelectedPage - 1) * pageInfo.PageSize); }
public CatalogController(IRequestLogger logger, ICategoryViewModelBuilder catViewModelBuilder, ILinkGenerator linkGenerator, IPageInfo pageInfo, ICatalogApi catalogApi) : base(logger, linkGenerator, catalogApi) { _pageInfo = pageInfo; _linkGenerator = linkGenerator; _catViewModelBuilder = catViewModelBuilder; }
/// ------------------------------------------------------------------------------------ /// <summary> /// Initializes a new instance of the <see cref="TeHeaderFooterVc"/> class. /// </summary> /// <param name="cache">DB Connection</param> /// <param name="page">Page information</param> /// <param name="wsDefault">ID of default writing system</param> /// <param name="printDateTime">printing date/time</param> /// <param name="filterInstance">book filter instance</param> /// <param name="sectionsTag">The sections tag.</param> /// ------------------------------------------------------------------------------------ public TeHeaderFooterVc(FdoCache cache, IPageInfo page, int wsDefault, DateTime printDateTime, int filterInstance, int sectionsTag) : base(page, wsDefault, printDateTime, cache) { m_scr = m_cache.LangProject.TranslatedScriptureOA; m_bookFilter = FilteredScrBooks.GetFilterInstance(m_cache, filterInstance); m_autoAdjustColumns = true; m_sectionsTag = sectionsTag; }
public void NavigateToExample(IPageInfo pageInfo) { if (this.currentPage == null) { this.currentPage = pageInfo; } PageLoader.Instance.LoadPage(pageInfo); }
public Connection( IPageInfo pageInfo, IReadOnlyCollection <Edge <T> > edges) { PageInfo = pageInfo ?? throw new ArgumentNullException(nameof(pageInfo)); Edges = edges ?? throw new ArgumentNullException(nameof(edges)); }
public ExpressionEvaluatorFacade(IPageInfo pageInfo) { compiler = new ReportingLanguageCompiler(); this.context = new ExpressionContext(null); context.ResolveUnknownVariable += VariableStore; context.ResolveMissingFunction += FunctionStore; SinglePage = pageInfo; compiler.SinglePage = pageInfo; }
public Page(IPageInfo pageInfo,Size pageSize) { if (pageInfo == null) { throw new ArgumentNullException("pageInfo"); } PageInfo = pageInfo; Name = "Page"; Size = pageSize; exportedItems = new List<IExportColumn>(); }
/// ------------------------------------------------------------------------------------ /// <summary> /// Constructor /// </summary> /// <param name="page">Page info</param> /// <param name="wsDefault">default writing system</param> /// <param name="printDateTime">Printing date/time</param> /// <param name="cache">The cache.</param> /// ------------------------------------------------------------------------------------ public HeaderFooterVc(IPageInfo page, int wsDefault, DateTime printDateTime, FdoCache cache) { m_page = page; m_wsDefault = wsDefault; m_printDateTime = printDateTime; m_cache = cache; LgWritingSystem defWs = new LgWritingSystem(m_cache, m_wsDefault); RightToLeft = defWs.RightToLeft; }
public void LoadPage(IPageInfo pageInfo) { var newExample = pageInfo; this.pageToNavigate = newExample; //this.currentPage = this.pageToNavigate; var moduleName = this.pageToNavigate.PackageName; this.LoadNormalPage(moduleName, null); }
public static void AddPageInfo (this ReportingExpressionEvaluator app,IPageInfo pageInfo) { if (pageInfo == null) throw new ArgumentNullException("pageInfo"); if (!app.Globals.ContainsKey("PageInfo")) { app.Globals.Add("PageInfo",pageInfo); } else { app.Globals["PageInfo"] = pageInfo; } }
public static IPage <TResultItem> FromPageInfo <TResultItem>(IPageInfo pageInfo, IReadOnlyCollection <TResultItem> items, int countAll) { return(new PageDto <TResultItem> { Items = items, PageNumber = pageInfo.PageNumber, PageSize = pageInfo.PageSize, CountAll = countAll }); }
private static void ViewModel_Changed(DependencyObject d, DependencyPropertyChangedEventArgs e) { IPageInfo pageInfo = d as IPageInfo; if (pageInfo == null) { return; } IPagingViewModel vm = e.OldValue as IPagingViewModel; if (vm != null) { pageInfo.UnNotifyOn("PageCount"); pageInfo.UnNotifyOn("CurrentPageRect"); } vm = e.NewValue as IPagingViewModel; if (vm != null) { pageInfo.NotifyOn("PageCount", (newValue, oldValue) => { vm.TotalPages = (int)newValue; if (vm.TotalPages > 0) { vm.RestoreSelection(); } }); pageInfo.NotifyOn("CurrentPageRect", (newValue, oldValue) => { Rect rect = (Rect)newValue; if (rect.IsEmpty) { return; } vm.PageWidth = rect.Width; vm.PageLeft = rect.Left; }); var binding = new Binding("CurrentPage") { Source = vm, Mode = BindingMode.TwoWay }; BindingOperations.SetBinding(d, VirtualizingSmartPanel.CurrentPageProperty, binding); var element = d as FrameworkElement; if (element != null) { element.Unloaded += (sender, args) => { BindingOperations.ClearBinding((DependencyObject)sender, VirtualizingSmartPanel.CurrentPageProperty); }; } } }
private GetPagedAccommodationItems GetPagedAccommodationItems( IPageInfo pagingSettings, int languageId, Func <IQueryable <LocalizedAccommodation>, IOrderedQueryable <LocalizedAccommodation> > sorting ) { var query = QueryProvider.Create <GetPagedAccommodationItems>(); query.Paging = pagingSettings; query.LanguageId = languageId; query.Sorting = sorting; return(query); }
private static void ApplyPageValues(SPListItem item, IPageInfo page) { if (page.Values != null) { foreach (FieldValueInfo value in page.Values) { value.ApplyOnItem(item); } } item.Update(); }
public IPageableList<ProjectUser> GetProjectUsers(string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<ProjectUser>(pageInfo); query.Include(e => e.User); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause( e => e.User.FullName.ToLower().StartsWith(searchString) || e.User.FullName.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { return repositoriesContainer.ProjectUsersRepository.GetPageableBy(query); } }
public IPageableList<Group> GetGroupsPageable(string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Group>(pageInfo); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause( e => e.Name.ToLower().StartsWith(searchString) || e.Name.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias).Include(g => g.Students); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { var groups = repositoriesContainer.GroupsRepository.GetPageableBy(query); return groups; } }
public IPageableList<Bug> GetAllBugs(string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Bug>(pageInfo); query.Include(e => e.Status); query.Include(e => e.Severity); query.Include(e => e.Symptom); query.Include(e => e.Project); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause( e => e.Summary.ToLower().StartsWith(searchString) || e.Summary.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { return repositoriesContainer.BugsRepository.GetPageableBy(query); } }
public IPageableList<Student> GetStudentsPageable(string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Student>(pageInfo); query.Include(e => e.Group).Include(e => e.User); if (!string.IsNullOrWhiteSpace(searchString)) { searchString = searchString.Replace(" ", string.Empty); //search by full name query.AddFilterClause( e => (e.LastName + e.FirstName + e.MiddleName).Contains(searchString) || e.Group.Name.ToLower().Contains(searchString)); } using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { var students = repositoriesContainer.StudentsRepository.GetPageableBy(query); return students; } }
public IPageableList<Lecturer> GetLecturersPageable(string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Lecturer>(pageInfo); query.Include(l => l.SubjectLecturers).Include(e => e.User); if (!string.IsNullOrWhiteSpace(searchString)) { searchString = searchString.Replace(" ", string.Empty); //search by full name query.AddFilterClause( e => (e.LastName + e.FirstName + e.MiddleName).Contains(searchString)); } query.OrderBy(sortCriterias); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { var lecturers = repositoriesContainer.LecturerRepository.GetPageableBy(query); return lecturers; } }
public IPageableList<Subject> GetSubjectsLecturer(int lecturerId, string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Subject>(pageInfo, e => e.SubjectLecturers.Any(x => x.LecturerId == lecturerId && !e.IsArchive)); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause( e => e.Name.ToLower().StartsWith(searchString) || e.Name.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { return repositoriesContainer.SubjectRepository.GetPageableBy(query); } }
/// ------------------------------------------------------------------------------------ /// <summary> /// </summary> /// <param name="pageInfo"></param> /// <param name="wsDefault">ID of default writing system</param> /// <param name="printDateTime">printing date/time</param> /// ------------------------------------------------------------------------------------ public DummyHFSetupDlgVC(IPageInfo pageInfo, int wsDefault, DateTime printDateTime, FdoCache cache) : base(pageInfo, wsDefault, printDateTime, cache) { }
public IPageableList<Question> GetPageableQuestions(int testId, string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Question>(pageInfo, question => question.TestId == testId); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause(question => question.Description.ToLower().Contains(searchString) || question.Title.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { return repositoriesContainer.QuestionsRepository.GetPageableBy(query); } }
/// ------------------------------------------------------------------------------------- /// <summary> /// Creates and returns the header view construtor for the layout. /// </summary> /// <param name="page">Ignored</param> /// <returns>the header view construtor</returns> /// ------------------------------------------------------------------------------------- public IVwViewConstructor MakeHeaderVc(IPageInfo page) { return Vc; }
/// ------------------------------------------------------------------------------------ /// <summary> /// Executes in two distinct scenarios. /// /// 1. If disposing is true, the method has been called directly /// or indirectly by a user's code via the Dispose method. /// Both managed and unmanaged resources can be disposed. /// /// 2. If disposing is false, the method has been called by the /// runtime from inside the finalizer and you should not reference (access) /// other managed objects, as they already have been garbage collected. /// Only unmanaged resources can be disposed. /// </summary> /// <param name="disposing"></param> /// <remarks> /// If any exceptions are thrown, that is fine. /// If the method is being done in a finalizer, it will be ignored. /// If it is thrown by client code calling Dispose, /// it needs to be handled by fixing the bug. /// /// If subclasses override this method, they should call the base implementation. /// </remarks> /// ------------------------------------------------------------------------------------ protected override void Dispose(bool disposing) { // Must not be run more than once. if (IsDisposed) return; if (disposing) { // Dispose managed resources here. } // Dispose unmanaged resources here, whether disposing is true or false. m_page = null; m_sda = null; base.Dispose(disposing); }
/// ------------------------------------------------------------------------------------- /// <summary> /// Creates and returns the header view construtor for the layout. /// </summary> /// <param name="page">Ignored</param> /// <returns>the header view construtor</returns> /// ------------------------------------------------------------------------------------- public IVwViewConstructor MakeHeaderVc(IPageInfo page) { return new DummyHfVc(); }
public IPageableList<Test> GetPageableTests(int subjectId, string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<Test>(pageInfo, test => test.SubjectId == subjectId); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause(test => test.Description.ToLower().Contains(searchString) || test.Title.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias); query.Include(test => test.TestUnlocks); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { return repositoriesContainer.TestsRepository.GetPageableBy(query); } }
public IPageableList<UserMessages> GetUserMessagesPageable(int userId, bool? incoming = null, string searchString = null, IPageInfo pageInfo = null, IEnumerable<ISortCriteria> sortCriterias = null) { var query = new PageableQuery<UserMessages>(pageInfo); if (!incoming.HasValue) { query.AddFilterClause(e => e.AuthorId == userId || e.Recipient.Id == userId); } else { if (incoming.Value) { query.AddFilterClause(e => e.Recipient.Id == userId); } else { query.AddFilterClause(e => e.AuthorId == userId); } } query.Include(e => e.Message.Attachments).Include(e => e.Recipient) .Include(e => e.Author.Lecturer).Include(e => e.Author.Student); if (!string.IsNullOrEmpty(searchString)) { query.AddFilterClause( e => e.Message.Text.ToLower().StartsWith(searchString) || e.Message.Text.ToLower().Contains(searchString)); } query.OrderBy(sortCriterias); using (var repositoriesContainer = new LmPlatformRepositoriesContainer()) { var userMessages = repositoriesContainer.RepositoryFor<UserMessages>().GetPageableBy(query); return userMessages; } }