load->library('session'); $this->load->_model('Model_setting','setting'); $this->load->_model('Model_user','user'); $this->load->_model("Model_zzrecord_logs",'zzrecord_logs'); $this->load->helper('url'); } } // END Lin_Controller class //前台页面控制器 abstract class Start_Controller extends Lin_Controller { public $data; function __construct() { parent::__construct(); $setting = $this->setting->get_settings(); if(!isset($_SESSION['api']) && $this->uri->slash_segment(1) != "/" && $this->uri->slash_segment(1) != "phone/" && $this->uri->slash_segment(1) != "apt/" && $this->uri->slash_segment(1) != "outbound/" && $this->uri->slash_segment(2) != "isorder/" && $this->uri->slash_segment(2) != "waybill/" && $this->uri->slash_segment(2) != "apple/" && $this->uri->slash_segment(2) != "query/" && $this->uri->slash_segment(2) != "fhd/" && $this->uri->slash_segment(2) != "kc/" && $this->uri->slash_segment(2) != "syns/" && $this->uri->slash_segment(1) != "api/" && $this->uri->slash_segment(2) != "khjz/" && $this->uri->slash_segment(2) != "khjzfs/" && $this->uri->slash_segment(2) != "webhook/" && $this->uri->slash_segment(2) != "ttwebhook/" && $this->uri->slash_segment(2) != "sq/" && $this->uri->slash_segment(2) != "kcpd/"&& $this->uri->slash_segment(1) != "errorlog/" && $this->uri->slash_segment(1) != "apiexpress/" && $this->uri->slash_segment(1) != "apiexpressv1/" && $this->uri->slash_segment(1) != "apitt/" && $this->uri->slash_segment(1) != "queueCbt/" && $this->uri->slash_segment(1) != "zzjobs/" && ( $this->uri->slash_segment(1) != "queueOne/") && ( $this->uri->slash_segment(1) != "queueu9/") && ( $this->uri->slash_segment(1) != "apipf/") && ( $this->uri->slash_segment(1) != "apismt/") && ( $this->uri->slash_segment(1) != "queue/") && ( $this->uri->slash_segment(2) != "tjadd/") && ( $this->uri->slash_segment(2) != "xr/") && ( $this->uri->slash_segment(2) != "yswaybill/") && ( $this->uri->slash_segment(2) != "shopfxlist/")&& ( $this->uri->slash_segment(2) != "cjgx/") && ($this->uri->slash_segment(1) != "whlabelstockup/") )//如果有api { $this->session->sess_destroy(); header("Location:/"); exit("需要添加api免检"); } if(isset($_SESSION['api'])) { $u = $this->user->get_api($_SESSION['api']); if(!$u && $this->uri->slash_segment(1) != "/") { $cont = $this->uri->slash_segment(1); $action = $this->uri->slash_segment(2); if( (strpos($cont,"user") !== false) && (strpos($action,"tc") !== false) ){ header("Location:/"); die("需要重新登录"); }else{ unset($_SESSION['api']); $this->session->sess_destroy(); die("