예제 #1
0
        public int AddSocialNetwork(SocialNetworksStudent socialNetworksStudent)
        {
            int resultToReturn;

            using (var context = new Entities())
            {
                resultToReturn = context.InsertUpdateSocialNetworkStudent(socialNetworksStudent.Id,
                                                                          socialNetworksStudent.StudentId,
                                                                          socialNetworksStudent.Url,
                                                                          socialNetworksStudent.SocialNetworksNameId,
                                                                          "Insert");
            }
            return(resultToReturn);
        }
 public JsonResult AddSocialNetwork(SocialNetworksStudent socialNetworksStudent)
 {
     return(Json(StudentDataEF.AddSocialNetwork(socialNetworksStudent), JsonRequestBehavior.AllowGet));
 }