Exemplo n.º 1
0
        // GET: UCRMS
        public async Task <ActionResult> IndexEnrollCourse()
        {
            VM_EnrollCourse enrolledCourse = new VM_EnrollCourse();
            await Task.Run(() => enrolledCourse.EnrolledCourse());

            return(View(enrolledCourse));
        }
Exemplo n.º 2
0
        // GET: UCRMS/Delete/5
        public ActionResult DeleteEnrollCourse(int?id)
        {
            VM_EnrollCourse ec = new VM_EnrollCourse();

            ViewBag.enrolled = ec.EnrollCourse(id);
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            EnrollCourse enrollCourse = db.EnrollCourses.Find(id);

            if (enrollCourse == null)
            {
                return(HttpNotFound());
            }
            return(View(enrollCourse));
        }