public function __construct(){
     parent::__construct();
     $this->_Model = loadModel('Index.Cardto');
     /*$this->_openid = $this->getParam("openid");
     if(!isset($_COOKIE['5100openid']) || empty($_COOKIE['5100openid']) ){
         if (!isset($this->_openid) && empty($this->_openid)) {
             $nowUrl = "http://".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];
             $url = "http://call.socialjia.com/Wxapp/weixin_common/oauth2.0/link.php?entid=" . C('ENT_ID') . "&url=" . urlencode($nowUrl);
             header("location:$url");
             exit;    
         }
         setcookie("5100openid", $this->_openid, time() + 86400);
         $_COOKIE['5100openid'] = $this->_openid;       
     }else{
         $this->_openid = $_COOKIE['5100openid'];    
     }*/
     $this->_openid = $this->_openId;
     //$this->_openid = 'oaCwJs_TMDNrapbDen7v1sBfdu6I';
                                                                                                             
     //$partner = $this->_Model->getPartner($this->_openid);
     
     //$this->assign('partner', $partner);
     $this->assign('openid', $this->_openid); 
     
 }               
Beispiel #2
0
 function &_getWebAction()
 {
     if (isset($this->_webaction)) {
         return $this->_webaction;
     }
     $options = $this->getOptions();
     if (!isset($options['action_id'])) {
         return false;
     }
     require_once 'Modules/WebAction/WebAction.php';
     $action = new WebAction($this->dbcon, $options['action_id']);
     if (!$action->hasData()) {
         return false;
     }
     $this->_webaction =& $action;
     return $this->_webaction;
 }
    public function __construct() {
        parent::__construct();
        $this->_Model = loadModel('Index.Cardto');
        $this->_ParModel = loadModel('Admin.Partner');
        $this->_CardAdminModel = loadModel('Admin.Card');
        //$this->_openId = 'onwtvs_nLs6xkOnslhqXXY82eEHo';                                                                                                        
        //$partner = $this->_Model->getPartner($this->_openId);
        //$this->assign('partner', $partner);

        $this->assign('title', '我的卡包');
        $this->assign('openid', $this->_openId);
    }
    public function __construct() {
        parent::__construct();
        $this->_Model = loadModel('Index.Rebate');

        $this->assign('openid', $this->_openId);
        $this->_p = $this->getParam('p');
        $this->_a = $this->getParam('a');
        $this->_m = $this->getParam('m');
        $this->assign('a', $this->_a);
        $this->assign('m', $this->_m);
        $this->assign('title', '我的返利');
        
        //查看数据库是否已更新返利
        $this->_Model->updateAllUserRebate();
    }
 public function __construct() 
 {
     parent::__construct ();
     $this->model = loadModel ( 'Index.Invitation' );
     $this->assign('title', '呼唤朋友');
 }
 public function __construct() {
     parent::__construct();
     $this->model = loadModel('Index.User');
     $this->assign('title', '个人信息');
 }