Пример #1
0
        public async Task <IViewComponentResult> InvokeAsync(GetBlogRelatedInput input)
        {
            var blog = await _blogAppService.GetByShortNameAsync(input.BlogShortName);

            var postsViews = await _postAppService.GetMostViewsListByBlogId(blog.Id);

            var blogRelatedCategory = new BlogRelatedCategoryDto();

            blogRelatedCategory.BlogShortName = blog.ShortName;

            blogRelatedCategory.postsDto = postsViews;



            return(View(blogRelatedCategory));
        }