/** * 获取商业大亨人物信息,将信息保存至$_userDetail属性 */ private function _getBtoUser() { $this->_utilBTOInterface = $this->_getGlobalData('Util_BTOInterface', 'object'); $getArr = array('uName' => $this->_userAccount, 'query' => 'Charge', 'action' => 'getCharge'); $this->_utilBTOInterface->setServerUrl($this->_serverId); $this->_utilBTOInterface->setGet($getArr); $userObj = $this->_utilBTOInterface->callInterface(); if (!$userObj) { return; } //如果解析不了,将出错. $userObj = $userObj->o; $this->_userDetail = array('user_id' => $userObj->UserId, 'user_account' => $this->_userAccount, 'user_nickname' => $userObj->VUserName, 'money_total' => $userObj->ChargeTotal, 'money_month' => $userObj->Charge30Days, 'register_date' => strtotime($userObj->RegTime), 'ip' => long2ip($userObj->LoginIp)); }
/** * 获取商业大亨人物信息,将信息保存至$_userDetail属性 */ private function _getBtoUser() { import('@.Util.BTOInterface'); $this->_BTOInterface = new BTOInterface(); $getArr = array('uName' => $this->_userAccount, 'query' => 'Charge', 'action' => 'getCharge'); $this->_BTOInterface->setServerUrl($this->_serverId); $this->_BTOInterface->setGet($getArr); $userObj = $this->_BTOInterface->callInterface(); if (!$userObj) { return; } //如果解析不了,将出错. $userObj = $userObj->o; $this->_userDetail = array('user_id' => $userObj->UserId, 'user_account' => $this->_userAccount, 'user_nickname' => $userObj->VUserName, 'money_total' => $userObj->ChargeTotal, 'money_month' => $userObj->Charge30Days, 'register_date' => strtotime($userObj->RegTime), 'ip' => $this->get_client_ip()); }