public JsonResult GetLikeDetail(string IDEA_ID, int table = 0) { LikeManager manager = LikeManager.GetInstance(); if (table == 1) { return(Json(manager.GetLike1(IDEA_ID))); } return(Json(manager.GetLike(IDEA_ID))); }
public JsonResult LikeIdea(EMPLOYEE EMP, string IDEA_ID) { LikeManager manager = LikeManager.GetInstance(); bool checkLiked = manager.CheckLikeIdea(EMP.EMP_ID, IDEA_ID); if (checkLiked) { return(Json(-1)); } return(Json(manager.InsertLikeIdea(IDEA_ID, EMP.EMP_ID, EMP.EMP_NAME))); }