作者 sgj
1 个管道 的构建 通过 耗费 0 秒

pay change

@@ -39,7 +39,6 @@ class LoginController extends HomeBaseController{ @@ -39,7 +39,6 @@ class LoginController extends HomeBaseController{
39 //登录凭证校验接口 39 //登录凭证校验接口
40 $loginUrl="https://api.weixin.qq.com/sns/jscode2session?appid=".$this->appId."&secret=".$this->appSecret."&js_code=".$code."&grant_type=authorization_code"; 40 $loginUrl="https://api.weixin.qq.com/sns/jscode2session?appid=".$this->appId."&secret=".$this->appSecret."&js_code=".$code."&grant_type=authorization_code";
41 $loginData=json_decode(file_get_contents($loginUrl),true); 41 $loginData=json_decode(file_get_contents($loginUrl),true);
42 - dump($loginData);  
43 if(isset($loginData['openid'])){ 42 if(isset($loginData['openid'])){
44 $users = Db::name('users')->where('open_id', $loginData['openid'])->find(); 43 $users = Db::name('users')->where('open_id', $loginData['openid'])->find();
45 if (empty($users)){ 44 if (empty($users)){