예제 #1
0
 public function index(Student $student)
 {
     $actions['active'] = [];
     $actions['trashed'] = [];
     $programs = Program::all();
     $entryYears = $student->entryYear();
     if ($this->authis->check('admin.student.student.create')) {
         $actions['active'][] = 'create';
     }
     if ($this->authis->check('admin.student.student.destroy')) {
         $actions['active'][] = 'delete';
     }
     return view('student.student.index', compact('actions', 'programs', 'entryYears'));
 }
예제 #2
0
 public function destroy($ids)
 {
     $ids = explode(',', $ids);
     Program::destroy($ids);
     return $this->formSuccess(route('admin.institute.program.index'), ['message' => 'Program studi berhasil dihapus']);
 }