Exemple #1
0
 public function index()
 {
     $user = new User($this->registry);
     $d_user = $user->getUser_id($this->kd_user);
     $univ = Session::get('univ');
     $d_univ = array();
     foreach ($univ as $univ) {
         $temp = array();
         $pb = new Penerima($this->registry);
         $cuniv = new Universitas($this->registry);
         $univDao = new UniversitasDao();
         $univDao->set_kode_in($univ);
         $cuniv = $cuniv->get_univ_by_id($univDao);
         $temp[] = $cuniv->get_nama();
         $temp[] = $pb->get_jumlah_pegawai('universitas', $univ);
         $d_univ[] = $temp;
     }
     $this->view->is_pic = Session::get('role') == 2 || Session::get('role') == 3 || Session::get('role') == 4 || Session::get('role') == 5 || Session::get('role') == 6;
     $this->view->d_univ = $d_univ;
     $this->view->d_user = $d_user;
     $this->view->d_notif = $this->get_notifikasi();
     $this->view->count_notif = count($this->view->d_notif);
     //        print_r($this->view->d_notif);
     $this->view->render('index');
 }