当前位置: 首页>>代码示例>>PHP>>正文


PHP Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile方法代码示例

本文整理汇总了PHP中Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile方法的典型用法代码示例。如果您正苦于以下问题:PHP Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile方法的具体用法?PHP Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile怎么用?PHP Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Model_Broker_AjkBrokerExtend的用法示例。


在下文中一共展示了Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: handle_request_internal

 public function handle_request_internal()
 {
     header("Access-Control-Allow-Origin: *");
     $userMobile = $this->_params['userMobile'];
     //检测电话号码格式是否正确
     if (strlen($userMobile) != 11) {
         throw new Exception_Broker_BrokerMobileFormatError('电话号码格式错误', Const_APIStatus::E_BROKER_MOBILE_FORMAT_ERROR);
     }
     $brokerInfo = Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile($userMobile);
     if (!$brokerInfo) {
         throw new Exception_Broker_BrokerNotVerified('经纪人不存在', Const_APIStatus::E_BROKER_MOBILE_SEARCH_ERROR);
     }
     if ($brokerInfo->checkState != 1) {
         throw new Exception_BrokerNotFoundException('经纪人审核未通过', Const_APIStatus::E_BROKER_MOBILE_SEARCH_NOT_VERIFIED);
     }
     //查询微聊信息
     $chatInfo = Bll_Mobile_ChatInfoBll::getInstance()->onlyGetChatInfo($brokerInfo->brokerId);
     $re = array();
     $re['brokerId'] = $brokerInfo->brokerId;
     $re['companyInfo'] = $brokerInfo->company;
     $re['trueName'] = $brokerInfo->trueName;
     $re['userMobile'] = $brokerInfo->userMobile;
     $re['userPhoto'] = Util_ImageUtils::get_broker_photo_url($brokerInfo->userPhoto, '200x200');
     $re['chatId'] = $chatInfo['data']['chatId'];
     $re['twoCodeIcon'] = $chatInfo['data']['twoCodeIcon'];
     return array('status' => Const_APIStatus::RETURN_CODE_OK, 'data' => $re);
 }
开发者ID:emilymwang8,项目名称:ajk-broker,代码行数:27,代码来源:BrokerInfoByMobile.php


注:本文中的Model_Broker_AjkBrokerExtend::getBrokerInfoByMobile方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。