public IHttpActionResult updateExamClass(examclass_details edupdate) { Boolean up = new ExamClassDetails().updateExamClassDetails(edupdate); if (up) { rss.code = 200; rss.message = "succesfully data has been updated"; return(Content(HttpStatusCode.OK, rss)); } else { rss.code = 100; rss.message = "failed to update"; return(Content(HttpStatusCode.OK, rss)); } }
public IHttpActionResult deleteExamClass(examclass_details eclass) { Boolean s = new ExamClassDetails().deleteClass(eclass); if (s) { rss.code = 200; rss.message = "succesfully data hasbeen deleted"; return(Content(HttpStatusCode.OK, rss)); } else { rss.code = 100; rss.message = "failed to delete"; return(Content(HttpStatusCode.OK, rss)); } }
public IHttpActionResult addingExamClasses(examclass_details exdetails) { Boolean ww = new ExamClassDetails().addingExamClassDetails(exdetails); if (ww) { exdetails.insert_date = DateTime.Now; entity.examclass_details.Add(exdetails); entity.SaveChanges(); rss.code = 200; rss.message = "succesfully data has inserted"; return(Content(HttpStatusCode.OK, rss)); } else { rss.code = 100; rss.message = "failed to insert data"; return(Content(HttpStatusCode.OK, rss)); } }