public async Task <IActionResult> Create([Bind("course_ID,course_Name,start_date,end_date,course_duration")] Course_details course_details)
        {
            if (ModelState.IsValid)
            {
                _context.Add(course_details);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(course_details));
        }
        public async Task <IActionResult> Create([Bind("tutor_ID,tutor_Name,tutor_Email,tutor_Mobile,tutor_Address")] Tutor_details tutor_details)
        {
            if (ModelState.IsValid)
            {
                _context.Add(tutor_details);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(tutor_details));
        }
Ejemplo n.º 3
0
        public async Task <IActionResult> Create([Bind("student_ID,student_Name,student_Email,student_Mobile,student_Address")] student_Details student_Details)
        {
            if (ModelState.IsValid)
            {
                _context.Add(student_Details);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(student_Details));
        }
Ejemplo n.º 4
0
        public async Task <IActionResult> Create([Bind("Student_Enrollment_ID,student_ID,course_ID,tutor_ID")] Student_enrollment student_enrollment)
        {
            if (ModelState.IsValid)
            {
                _context.Add(student_enrollment);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(student_enrollment));
        }