public void AddCource(string title, string stream, string type, DateTime start_date, DateTime end_date) { int current_id = Courses.Count + 1; var course = new Course(current_id, title, stream, type, start_date, end_date); Courses.Add(course); PrivateSchool.OutputCourses(course); }
static void set_course_trainer(PrivateSchool CodingBootcamp) { CodingBootcamp.OutputCourses(); int user_cource_data = CommonTools.CourseUserSelection(); Console.WriteLine("\n\n\n\n\n\n\n\n\n\n"); CodingBootcamp.OutputTrainer(); int user_trainer_data = CommonTools.TrainerUserSelection(); CodingBootcamp.TrainersCourses.Add(new TrainersCourse(user_cource_data, user_trainer_data)); }
static void set_course_student(PrivateSchool CodingBootcamp) { CodingBootcamp.OutputCourses(); int user_cource_data = CommonTools.CourseUserSelection(); Console.WriteLine("\n\n\n\n\n\n\n\n\n\n"); CodingBootcamp.OutputStudents(); int user_student_data = CommonTools.StudentUserSelection(); CodingBootcamp.StudentsCourses.Add(new StudentsCourse(user_cource_data, user_student_data)); }
static void UserMenuCase(PrivateSchool CodingBootcamp) { int user_case; do { try { PrintUserMenu(); user_case = Convert.ToInt32(Console.ReadLine()); Console.WriteLine("\n\n\n\n\n\n\n"); switch (user_case) { case 1: //Add Student add_student(CodingBootcamp); break; case 2: //Print Students CodingBootcamp.OutputStudents(); break; case 3: //Add Trainer add_teacher(CodingBootcamp); break; case 4: //Print Trainers CodingBootcamp.OutputTrainer(); break; case 5: //Add Course add_course(CodingBootcamp); break; case 6: //Print Courses CodingBootcamp.OutputCourses(); break; case 7: //Add Assignment add_assignment(CodingBootcamp); break; case 8: //Print Assignments CodingBootcamp.OutputAssignments(); break; case 9: //Assign Cource to Trainers set_course_trainer(CodingBootcamp); break; case 10: //Assign Cource to Students set_course_student(CodingBootcamp); break; case 11: //Assign Assignments to Students set_assignment_student(CodingBootcamp); break; case 12: //Print Cources Assigned to Trainers CodingBootcamp.OutputCoursesTrainers(); break; case 13: //Print Cources Assigned to Students CodingBootcamp.OutputCoursesStudents(); break; case 14: //Print Assignments Assigned to Students CodingBootcamp.OutputAssignmentsStudents(); break; case 15: //Print Students that have More than 1 assignment CodingBootcamp.OutputStudentsTwoAssignments(); break; case 16: //Print Assignments that have to be submited on day set_assignment_week(CodingBootcamp); break; default: Console.WriteLine("Please select a correct option!Please try again"); continue; } } catch (Exception e) { Console.WriteLine(e); Console.WriteLine("\nUse Input Fields Correctly Please!\n\n\n"); continue; } } while (true); }