예제 #1
0
 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store()
 {
     $studies = new Study();
     $studies->study_code = Input::get('study_code');
     $studies->study_name = Input::get('study_name');
     $studies->faculty_code = Input::get('faculty_code');
     $studies->stage = Input::get('stage');
     $studies->save();
     Session::flash('message', 'You have successfully added study');
     return Redirect::to('dashboard/admin/studies');
 }
예제 #2
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function edit($id)
 {
     $courses = Course::find($id);
     $programStudies = ProgramStudy::lists('name', 'id');
     $faculties = Faculty::lists('faculty_name', 'faculty_code');
     $studies = Study::lists('study_name', 'id');
     return view('dashboard.admin.course.edit', ['course' => $courses, 'programStudy' => $programStudies, 'faculty' => $faculties, 'study' => $studies]);
 }
예제 #3
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function edit($id)
 {
     $students = Student::find($id);
     $faculties = Faculty::lists('faculty_name', 'faculty_code');
     $studies = Study::lists('study_name', 'id');
     $programStudies = ProgramStudy::lists('name', 'id');
     $academicRegistrations = AcademicRegistration::lists('academic_year', 'id');
     $religions = Religion::lists('name', 'id');
     return view('dashboard.admin.student.edit', ['student' => $students, 'faculty' => $faculties, 'study' => $studies, 'programStudy' => $programStudies, 'academicRegistration' => $academicRegistrations, 'religion' => $religions]);
 }
예제 #4
0
 /**
  * Remove the specified resource from storage.
  *
  * @param  int  $id
  * @return Response
  */
 public function destroy($id)
 {
     $studies = Study::find($id);
     $studies->delete();
     Session::flash('message', 'You have successfully deleted study');
     return Redirect::to('dashboard/admin/studies');
 }
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function edit($id)
 {
     $schedules = Schedule::find($id);
     $academicRegistrations = AcademicRegistration::lists('academic_year', 'id');
     $programStudies = ProgramStudy::lists('name', 'id');
     $courses = Course::lists('course_name', 'id');
     $studies = Study::lists('study_name', 'id');
     $lecturers = Lecturer::lists('name', 'id');
     $days = Day::lists('day', 'id');
     return view('dashboard.admin.schedule.edit', ['schedule' => $schedules, 'academicRegistration' => $academicRegistrations, 'programStudy' => $programStudies, 'course' => $courses, 'study' => $studies, 'lecturer' => $lecturers, 'day' => $days]);
 }