public async Task <ActionResult> CommentLike(CommentLikeModel model) { if (!ModelState.IsValid) { return(RedirectToAction("Post", new { id = model.PostId })); } BlogServices.CommentLike(model.Index, model.PostId); return(RedirectToAction("Post", new { id = model.PostId })); }
public HttpResponseMessage CommentLike(CommentLikeModel objData) { BlogServices.CommentLike(objData.Index, objData.PostId); return(Request.CreateResponse(HttpStatusCode.OK, new { Data = objData.PostId })); }