//点赞实现
        public JsonResult GetThumbupCount()
        {
            string aritcleId = Request["articleId"];
            string type      = Request["type"];
            var    articleid = 0;

            if (!string.IsNullOrEmpty(aritcleId))
            {
                articleid = int.Parse(aritcleId);
            }

            var num = _objService.UpdateArticleThumbsUp(articleid, ViewBag.LillyId, type);

            return(Json(new { count = num }, JsonRequestBehavior.AllowGet));
        }
Example #2
0
        //点赞实现
        public JsonResult GetThumbupCount()
        {
            if (objLoginInfo == null || string.IsNullOrEmpty(objLoginInfo.UserName))
            {
                return(ErrorNotification("请先关注公众号!"));
            }
            string aritcleId = Request["articleId"];
            string type      = Request["type"];
            var    articleid = 0;

            if (!string.IsNullOrEmpty(aritcleId))
            {
                articleid = int.Parse(aritcleId);
            }

            var num = _objService.UpdateArticleThumbsUp(articleid, objLoginInfo.WeChatUserID, type);

            return(Json(new { count = num }, JsonRequestBehavior.AllowGet));
        }