|
|
|
@ -20,7 +20,7 @@ class Login_model extends CI_Model
@@ -20,7 +20,7 @@ class Login_model extends CI_Model
|
|
|
|
|
$regioid = $this->security->xss_clean($this->input->post('regioid')); |
|
|
|
|
|
|
|
|
|
// Search for user |
|
|
|
|
$this->db->select('id, regioid'); |
|
|
|
|
$this->db->select('id, regioid, admin, superadmin'); |
|
|
|
|
$this->db->where('username', $username); |
|
|
|
|
$this->db->where('password', sha1($password)); |
|
|
|
|
$this->db->where('regioid', $regioid); |
|
|
|
@ -35,6 +35,8 @@ class Login_model extends CI_Model
@@ -35,6 +35,8 @@ class Login_model extends CI_Model
|
|
|
|
|
$userdata = array( |
|
|
|
|
'id' => $row->id, |
|
|
|
|
'regio' => $row->regioid, |
|
|
|
|
'admin' => $row->admin, |
|
|
|
|
'superadmin' => $row->superadmin, |
|
|
|
|
'validated' => true |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|