public function create()
 {
     $school_year = SchoolYear::orderBy('id', 'desc')->first();
     $grades = Grade::all();
     $sections = $grades->first()->sections;
     return view('matriculas.matricular')->with(compact(['school_year', 'grades', 'sections']));
 }
Example #2
0
 /**
  * Bootstrap any application services.
  *
  * @return void
  */
 public function boot()
 {
     $wards = Ward::all();
     $grades = Grade::all();
     view()->share('wards', $wards);
     view()->share('grades', $grades);
 }
Example #3
0
 /**
  * Display a listing of the resource.
  *
  * @return Response
  */
 public function index()
 {
     $learners = \App\Student::all();
     $staff = Staff::all();
     $subjects = \App\Subject::all();
     $streams = \App\Stream::all();
     $classes = \App\Grade::all();
     return view('admin.index')->with('title', 'SMS|Dashboard')->with('learners', $learners)->with('staff', $staff)->with('subjects', $subjects)->with('streams', $streams)->with('classes', $classes);
 }
 public function index($handbook_id, $grade_id)
 {
     $handbook = CourseHandbook::find($handbook_id);
     // Get all courses and grades to fill the selects
     $courses = Course::all();
     $grades = Grade::all();
     // Select the grade and its courses associated in the current handbook
     $current_grade = Grade::find($grade_id);
     $current_courses = CourseGrade::where('course_handbook_id', $handbook_id)->where('grade_id', $grade_id)->get(['course_id']);
     $current_courses = $this->convertToCourseCollection($current_courses);
     return view('configuracion.asignar-cursos')->with(compact(['handbook', 'courses', 'grades', 'current_courses', 'current_grade']));
 }
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     // Start Check Authorization
     $invalid_auth = 1;
     $authRole = Auth::user()->UserRoles->role;
     if ($authRole == 1 or $authRole == 3) {
         $invalid_auth = 0;
     }
     if ($invalid_auth == 1) {
         Alert::error('Anda tidak memilik akses ini')->persistent('close');
         return redirect('dashboard');
     }
     // End Check Authorization
     $grade = Grade::all();
     return view('dropmin/grade/index')->with('grade', $grade);
 }
Example #6
0
 public function create()
 {
     $parents = Guardian::all();
     $classes = Grade::all();
     return view('learners.create')->with('title', 'SMS|New Learner')->with('parents', $parents)->with('classes', $classes);
 }
 public function index()
 {
     $grades = Grade::all();
     return view('configuracion.grados')->with(compact(['grades']));
 }
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $grade = Grade::all();
     return view('dropmin/grade/index')->with('grade', $grade);
 }
 public function getAdd()
 {
     $data['grades'] = \App\Grade::all();
     return view('admin.class.add', $data);
 }
Example #10
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     $data = Employee::find($id);
     $province = Province::all();
     $cities = City::all();
     $citmin = City::whereRaw('id = (select min(`id`) from cities)')->get();
     $citmax = City::whereRaw('id = (select max(`id`) from cities)')->get();
     $grade = Grade::all();
     $jabatans = Jabatan::all();
     $pt = array('sd' => 'SD', 'smp' => 'SMP', 'sma' => 'SMA', 'd3' => 'D3', 's1' => 'S1', 'S2' => 'S2');
     $citsel = unserialize($data->id_cities);
     $tls = Teamleader::where('id_users', $data->id)->get();
     $pos = ProjectOfficer::where('id_users', $data->id)->get();
     $adms = Admin::where('id_users', $data->id)->get();
     return view('dropmin/data/edit')->with('data', $data)->with('province', $province)->with('grade', $grade)->with('tls', $tls)->with('pos', $pos)->with('adms', $adms)->with('jabatans', $jabatans)->with('pt', $pt)->with('citsel', $citsel)->with('cities', $cities);
 }
Example #11
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function edit($id)
 {
     // Start Check Authorization
     /**
      * 1. FullAccess - 1
      * 2. HRD - 3
      * 3. Creator - 5
      * 4. Handler - 7
      */
     $invalid_auth = 1;
     $authRole = Auth::user()->UserRoles->role;
     if ($authRole == 7 or $authRole == 1 or $authRole == 3) {
         $invalid_auth = 0;
     }
     if ($invalid_auth == 1) {
         Alert::error('Anda tidak memilik akses ini')->persistent('close');
         return redirect('data/list');
     }
     // End Check Authorization
     $data = Employee::find($id);
     $province = Province::all();
     $cities = City::all();
     $citmin = City::whereRaw('id = (select min(`id`) from cities)')->get();
     $citmax = City::whereRaw('id = (select max(`id`) from cities)')->get();
     $grade = Grade::all();
     $jabatans = Jabatan::all();
     $pt = array('sd' => 'SD', 'smp' => 'SMP', 'sma' => 'SMA', 'd3' => 'D3', 's1' => 'S1', 'S2' => 'S2');
     $citsel = unserialize($data->id_cities);
     $tls = Teamleader::where('id_users', $data->id)->get();
     $pos = ProjectOfficer::where('id_users', $data->id)->get();
     $adms = Admin::where('id_users', $data->id)->get();
     return view('dropmin/data/edit')->with('data', $data)->with('province', $province)->with('grade', $grade)->with('tls', $tls)->with('pos', $pos)->with('adms', $adms)->with('jabatans', $jabatans)->with('pt', $pt)->with('citsel', $citsel)->with('cities', $cities);
 }