public async Task <IHttpActionResult> CommentFlatOwnerUpdate([FromBody] CommentFlatOwnerViewModel viewmodel) { var model = Mapper.Map <CommentFlatOwner>(viewmodel); await _commentService.Update(model); return(Ok()); }
public async Task <IHttpActionResult> CommentFlatOwnerAdd([FromBody] CommentFlatOwnerViewModel viewmodel) { var model = Mapper.Map <CommentFlatOwner>(viewmodel); return(Ok(Mapper.Map <CommentFlatOwnerViewModel>(await _commentService.New(model, CurrentUser)))); }