Пример #1
0
        public ActionResult <Hater> Post([FromBody] Reason reason)
        {
            var model         = _mapper.Map <Model.Reason>(reason);
            var createdReason = _reasonService.CreateReason(model);
            var result        = _mapper.Map <Reason>(createdReason);

            return(Created(Url.Action("Get", new { id = result.Id }), result));
        }