Exemplo n.º 1
0
        public IHttpActionResult updateExamClass(exam_details edupdate)
        {
            Boolean up = new ExamDetailsRelated().updateExamClassDetails(edupdate);

            if (up)
            {
                rs.code    = 200;
                rs.message = "succesfully data has been updated";
                return(Content(HttpStatusCode.OK, rs));
            }
            else
            {
                rs.code    = 100;
                rs.message = "failed to update";
                return(Content(HttpStatusCode.OK, rs));
            }
        }
Exemplo n.º 2
0
        public IHttpActionResult deleteExam(exam_details eds)
        {
            Boolean rr = new ExamDetailsRelated().deleteExam(eds);

            if (rr)
            {
                rs.code    = 200;
                rs.message = "succesfully data has been deleted";
                return(Content(HttpStatusCode.OK, rs));
            }
            else
            {
                rs.code    = 100;
                rs.message = "failed to delte";
                return(Content(HttpStatusCode.OK, rs));
            }
        }
Exemplo n.º 3
0
        public IHttpActionResult addingExamClasses(exam_details exdetails)
        {
            Boolean ww = new ExamDetailsRelated().addingExamClassDetails(exdetails);

            if (ww)
            {
                exdetails.insert_date = DateTime.Now;
                entity.exam_details.Add(exdetails);
                entity.SaveChanges();
                rs.code    = 200;
                rs.message = "succesfully data has inserted";
                return(Content(HttpStatusCode.OK, rs));
            }
            else
            {
                rs.code    = 100;
                rs.message = "failed to insert data";
                return(Content(HttpStatusCode.OK, rs));
            }
        }