function __construct()
 {
     parent::__construct();
     $this->menu_id = 24;
     $this->modules_name = 'profile';
     $this->current_user = user();
     $this->perm = current_user_permission($this->menu_id);
 }
 function __construct()
 {
     parent::__construct();
     $this->menu_id = 10;
     $this->perm = current_user_permission($this->menu_id);
     if ($this->perm->can_view != 'y') {
         redirect("admin");
     }
 }
 function __construct()
 {
     parent::__construct();
     $this->menu_id = 21;
     $this->modules_name = 'system_logs';
     $this->current_user = user();
     $this->perm = current_user_permission($this->menu_id);
     if ($this->perm->can_view != 'y') {
         redirect("admin");
     }
 }
 function __construct()
 {
     parent::__construct();
     $this->menu_id = 18;
     $this->modules_name = 'organization_charts';
     $this->current_user = user();
     $this->perm = current_user_permission($this->menu_id);
     if ($this->perm->can_view != 'y') {
         redirect("admin");
     }
 }
Esempio n. 5
0
 public function report4()
 {
     $menu_id = 36;
     $data['menu_id'] = $menu_id;
     $current_user = $this->current_user;
     $data['current_user'] = $current_user;
     $perm = current_user_permission($menu_id);
     $data['perm'] = $perm;
     if ($perm->can_view != 'y') {
         redirect("admin");
     } else {
         switch (@$_GET['act']) {
             case 'print':
                 $this->load->view('report4/print', $data);
                 break;
             case 'export':
                 $filename = "รายงานสรุปจำนวนผู้ลงทะเบียนแต่ล่ะหน่วยงาน ณ วันที่ " . date("Y-m-d_H_i_s") . ".xls";
                 header("Content-Disposition: attachment; filename=" . $filename);
                 $this->load->view('report4/print', $data);
                 break;
             default:
                 $this->template->build('report4/index', $data);
                 break;
         }
     }
 }