diff --git a/app/Controllers/Auth.php b/app/Controllers/Auth.php index b8a105c8..e69de29b 100644 --- a/app/Controllers/Auth.php +++ b/app/Controllers/Auth.php @@ -1,52 +0,0 @@ -request->getVar('username'); - $password = $this->request->getVar('password'); - - $param = array('name' => $uname, 'passwd' => $password); - $data = $model->cekuser($param)->getRowArray(); - // var_dump($data); - //exit(); - if ($data) { - - $ses_data = [ - 'nip' => $data['NIP9'], - 'nama' => $data['NAMA'], - 'kppadm' => $data['KPPADM'], - 'jabatan' => $data['NAMA_JABATAN'], - 'kantor' => $data['NAMA_KANTOR'], - 'seksi' => $data['NAMA_UNIT_ES3'] - ]; - $session->set($ses_data); - return redirect()->to(base_url('Home')); - } else { - //print_r('user tidak ada'); - //exit; - $session->setFlashdata('msg', 'User Tidak ada'); - return redirect()->to('auth'); - } - } - - public function logout() - { - $session = session(); - $session->destroy(); - return redirect()->to('auth'); - } -} diff --git a/app/Views/inc/sidebar.php b/app/Views/inc/sidebar.php index 9d7b9954..19dda028 100644 --- a/app/Views/inc/sidebar.php +++ b/app/Views/inc/sidebar.php @@ -16,10 +16,10 @@