示例#1
0
        public async Task <IActionResult> PostComment(string app, Guid commentsId, [FromBody] UpsertCommentDto request)
        {
            var command = request.ToCreateCommand(commentsId);
            var context = await CommandBus.PublishAsync(command);

            var response = CommentDto.FromCommand(command);

            return(CreatedAtAction(nameof(GetComments), new { commentsId }, response));
        }