Пример #1
0
        public async Task <ActionResult> UpdateAsync(
            [FromRoute] string id,
            [FromBody] CreateNewsFeedPublication model)
        {
            await newsFeedManager.UpdateAsync(id, model.Content);

            return(NoContent());
        }
Пример #2
0
        public async Task <ActionResult <NewsFeedPublication> > CreateAsync(
            [FromServices] ICurrentUserProvider currentUserProvider,
            [FromBody] CreateNewsFeedPublication model)
        {
            await newsFeedManager.CreateAsync(model.Content, currentUserProvider.UserId);

            return(Ok());
        }