Ejemplo n.º 1
0
        public async Task <IActionResult> GetAtomFeed([FromServices] IOptions <FeedOptions> feedOptions,
                                                      [FromQuery] Int32 page = 1)
        {
            var storiesPage = await _blogStoryManager.GetPageWithTagsAsync(GetStoriesRequest.ToPublishedQuery(page, PageSize), Cancel);

            return(new AtomStoriesResult(storiesPage, feedOptions));
        }
Ejemplo n.º 2
0
        public async Task <IActionResult> Index([FromQuery] Int32 page = 1)
        {
            var storiesPage = await _blogStoryManager.GetPageWithTagsAsync(GetStoriesRequest.ToPublishedQuery(page, PageSize), Cancel);

            var topTags = await _tagManager.GetTopPublishedAsync(Cancel);

            return(View("IndexPub", new MainPageViewModel(storiesPage,
                                                          topTags,
                                                          page)));
        }