コード例 #1
0
ファイル: flows.php プロジェクト: joshgomez/OpenVBX
 function __construct()
 {
     parent::__construct();
     $this->load->library('applet');
     $this->section = 'flows';
     $this->admin_only($this->section);
 }
コード例 #2
0
ファイル: welcome.php プロジェクト: hharrysidhu/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->template->write('title', 'Welcome');
     $this->section = 'welcome';
     $this->admin_only($this->section);
 }
コード例 #3
0
ファイル: site.php プロジェクト: JeffaCubed/OpenVBX
 function __construct()
 {
     parent::__construct();
     $this->load->model('vbx_theme');
     $this->section = 'site settings';
     $this->admin_only($this->section);
 }
コード例 #4
0
 function __construct()
 {
     // Check of user is ingelogd in class User_Controller (core/MY_Controller)
     // User wordt naar login page geredirect als hij niet is ingelogd
     // In __construct functie zodat het geldig is op elke functie van deze klasse
     parent::__construct();
 }
コード例 #5
0
ファイル: devices.php プロジェクト: rhyselsmore/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->load->model('vbx_device');
     $this->template->write('title', 'Devices');
     $this->section = 'devices';
 }
コード例 #6
0
ファイル: audiofiles.php プロジェクト: Gameonn/OpenVBX
 function __construct()
 {
     // This is to support SWFUpload. SWFUpload will scrape all cookies via Javascript
     // and send them as POST request params. This enables the file uploader to work
     // with a proper session.
     foreach ($_POST as $key => $value) {
         // Copy any key that looks like an Openvbx session over to $_COOKIE where it's expected
         if (preg_match("/^(\\d+\\-)?openvbx_session\$/", $key)) {
             // url-decode the session key, try to preserve "+" in email addresses
             $value = $_POST[$key];
             $preserve_plus = false;
             preg_match("|s:5:\"email\";s:[0-9]+:\"(.*?)\";|", $value, $matches);
             if (strpos($matches[1], '+') !== false) {
                 $plus_temp = '___plus___';
                 $preserve_plus = true;
                 $email = str_replace('+', $plus_temp, $matches[0]);
                 $value = str_replace($matches[0], $email, $value);
             }
             $value = urldecode($value);
             if ($preserve_plus) {
                 $value = str_replace($plus_temp, '+', $value);
             }
             $_COOKIE[$key] = $value;
         }
     }
     parent::__construct();
     $this->load->library('TwimlResponse');
     $this->load->model('vbx_audio_file');
     $this->say_params = array('voice' => $this->vbx_settings->get('voice', $this->tenant->id), 'language' => $this->vbx_settings->get('voice_language', $this->tenant->id));
 }
コード例 #7
0
ファイル: numbers.php プロジェクト: tjoozey/openvbx
 function __construct()
 {
     parent::__construct();
     $this->section = 'numbers';
     $this->template->write('title', 'Numbers');
     $this->load->model('vbx_incoming_numbers');
 }
コード例 #8
0
 public function __construct()
 {
     parent::__construct();
     $this->_moduleName = 'main';
     $this->load->model('main_mdl');
     $this->load->model('RF_User_mdl');
 }
コード例 #9
0
ファイル: caches.php プロジェクト: hharrysidhu/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->user = VBX_User::get($this->session->userdata('user_id'));
     if (!$this->user->is_admin) {
         throw new SiteCachesException('Action not allowed to non-administrators');
     }
 }
コード例 #10
0
ファイル: inbox.php プロジェクト: ryanlarrabure/OpenVBX
 function __construct()
 {
     parent::__construct();
     $this->section = 'messages';
     $this->template->write('title', 'Messages');
     $this->load->helper('date');
     $this->load->model('vbx_user');
 }
コード例 #11
0
ファイル: accounts.php プロジェクト: ryanlarrabure/OpenVBX
 function __construct()
 {
     parent::__construct();
     $this->section = 'accounts';
     $this->admin_only('account settings');
     $this->template->write('title', 'Users');
     $this->load->model('vbx_device');
 }
コード例 #12
0
ファイル: catur_artikel.php プロジェクト: akemsf/RachmanHakim
 function __construct()
 {
     parent::__construct();
     $this->load->model('matur_artikel');
     $this->load->library('template_admin');
     $this->load->helper('url');
     $this->load->helper('form');
 }
コード例 #13
0
 function __construct()
 {
     parent::__construct();
     if (!$this->secure->get_user_session()->id) {
         redirect(site_url('/users/login'));
     }
     $this->load->model('quote/states_model');
     $this->load->model('users/users_model');
 }
コード例 #14
0
 function __construct()
 {
     // Check of user is ingelogd in class User_Controller (core/MY_Controller)
     // User wordt naar login page geredirect als hij niet is ingelogd
     // In __construct functie zodat het geldig is op elke functie van deze klasse
     parent::__construct();
     $this->load->library('form_validation');
     $this->load->model('lists_model');
 }
コード例 #15
0
ファイル: User_Controller.php プロジェクト: anhnt36/duan
 public function __construct()
 {
     parent::__construct();
     $this->model->load('User');
     $this->user = new User_Model();
     self::$process = '/user/show';
     self::$object = $this->user;
     $this->validate = new Validate_Library($this->user->getRules());
 }
コード例 #16
0
ファイル: account.php プロジェクト: wiserweb/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->config->load('openvbx');
     $this->load->database();
     $this->load->model('vbx_device');
     $this->template->write('title', 'Account');
     $this->user_id = $this->session->userdata('user_id');
 }
コード例 #17
0
 function __construct()
 {
     parent::__construct();
     //         if (!$this->secure->get_user_session()->id) {
     //            redirect(site_url('/users/login'));
     //        }
     //        $this->load->library('session');
     $this->load->library('pagination');
 }
コード例 #18
0
 public function __construct()
 {
     parent::__construct('user_type', 2);
     $this->load->model('users/mdl_user_clients');
     $user_clients = $this->mdl_user_clients->where('fi_user_clients.user_id', $this->session->userdata('user_id'))->get()->result();
     foreach ($user_clients as $user_client) {
         $this->user_clients[$user_client->client_id] = $user_client->client_id;
     }
 }
コード例 #19
0
ファイル: admin.php プロジェクト: ishpuniani/citportal
 function __construct()
 {
     parent::__construct();
     $username = $this->session->userdata('username');
     $current_userType = $this->get_userType($username);
     if ($current_userType != $this->type_admin) {
         $this->redirect($current_userType);
     }
     $this->load->model("database");
 }
コード例 #20
0
ファイル: upgrade.php プロジェクト: hharrysidhu/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->section = 'upgrade';
     $this->admin_only($this->section);
     // no cache
     $ci =& get_instance();
     $ci->cache->flush();
     $ci->cache->enabled(false);
 }
コード例 #21
0
 public function __construct()
 {
     parent::__construct('user_type', 2);
     $this->load->model('users/mdl_user_clients');
     $user_clients = $this->mdl_user_clients->assigned_to($this->session->userdata('user_id'))->get()->result();
     if (!$user_clients) {
         die(lang('guest_account_denied'));
     }
     foreach ($user_clients as $user_client) {
         $this->user_clients[$user_client->client_id] = $user_client->client_id;
     }
 }
コード例 #22
0
 function __construct()
 {
     parent::__construct();
     $this->folder = "user/";
     $this->module = $this->folder . "user_profile/";
     $this->http_ref = base_url() . $this->module;
     $this->load->model("user_profile_model", "model");
     $this->load->library("utils");
     $this->layout = "layout_pages/";
     $this->my_logged_data = $this->data['users']['user'];
     $this->admin_layout = "layout/main_layout";
 }
コード例 #23
0
 /**
  * on dispatch before hook
  * 
  * @param Request $request
  * @param Response $response
  */
 public static function on_dispatch_before(Request $request, Response $response)
 {
     // 检查q是否在白名单中
     $loginIgnore = false;
     $q = $request->q();
     if (!empty($q)) {
         foreach (self::$loginWhiteList as $key) {
             if (SimPHP::qMatchPattern($key, $q)) {
                 $loginIgnore = true;
                 break;
             }
         }
     }
     // 检查登录状态
     if (!$loginIgnore && !Member::isLogined()) {
         import('user/*');
         $user_Controller = new User_Controller();
         $user_Controller->login($request, $response);
         exit;
     }
     //读取最新用户信息以客户端缓存
     global $user;
     if ($user->uid) {
         $uinfo = Member::getTinyInfoByUid($user->uid, FALSE);
         $user->openid = $uinfo['openid'];
         $user->unionid = $uinfo['unionid'];
         $user->subscribe = $uinfo['subscribe'];
         $user->username = $uinfo['username'];
         $user->nickname = $uinfo['nickname'];
         $user->sex = $uinfo['sex'];
         $user->logo = $uinfo['logo'];
         //$user->ec_user_id= $uinfo['ec_user_id'];
         /*
         if (!$request->is_hashreq()) { //不是hash request,则查看购物车是否有商品
           $cartNum = Goods::getUserCartNum($user->ec_user_id);
           $user->ec_cart_num = $cartNum;
         }
         */
     }
 }
コード例 #24
0
ファイル: FT_Common.php プロジェクト: anhnt36/duan
function FT_load()
{
    $config = (require_once PATH_APPLICATION . '/config/init.php');
    autoDeleteFile();
    $arrayUrl = parseUrl();
    if (!empty($_SESSION['name'])) {
        process();
    } else {
        if (!empty($_COOKIE['name'])) {
            $_SESSION['name'] = $_COOKIE['name'];
            $_SESSION['id'] = $_COOKIE['id'];
            $_SESSION['avatar'] = $_COOKIE['avatar'];
        } else {
            if ($arrayUrl[0] == 'user' && $arrayUrl[1] == 'login') {
                $controllerObject = new User_Controller();
                $controllerObject->login();
            } else {
                headerUrl('/user/login');
            }
        }
    }
}
コード例 #25
0
ファイル: Home.php プロジェクト: Brostin08/teamjellyiss
 function __construct()
 {
     parent::__construct();
     $this->load->model('Infra_model');
 }
コード例 #26
0
ファイル: audiofiles.php プロジェクト: howethomas/OpenVBX
 function __construct()
 {
     parent::__construct();
     $this->load->model('vbx_audio_file');
 }
コード例 #27
0
ファイル: dialog.php プロジェクト: tjoozey/openvbx
 function __construct()
 {
     parent::__construct();
     $this->admin_only('dialogs');
     $this->template->set_template('dialog');
 }
コード例 #28
0
ファイル: upgrade.php プロジェクト: joshgomez/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->section = 'upgrade';
     $this->admin_only($this->section);
 }
コード例 #29
0
 public function __construct()
 {
     parent::__construct('user_type', 1);
 }
コード例 #30
0
ファイル: voicemail.php プロジェクト: JeffaCubed/OpenVBX
 public function __construct()
 {
     parent::__construct();
     $this->template->write('title', 'Voicemail');
     $this->section = 'voicemail';
 }