wupengfei 2 years ago
parent
commit
66ceaaeb72
3 changed files with 3 additions and 4 deletions
  1. 2 1
      .idea/workspace.xml
  2. 1 2
      application/api/controller/Login.php
  3. 0 1
      application/common.php

+ 2 - 1
.idea/workspace.xml

@@ -4,6 +4,7 @@
     <list default="true" id="1a36929e-c054-4875-a943-593a74e55fa4" name="Default Changelist" comment="">
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/application/api/controller/Login.php" beforeDir="false" afterPath="$PROJECT_DIR$/application/api/controller/Login.php" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/application/common.php" beforeDir="false" afterPath="$PROJECT_DIR$/application/common.php" afterDir="false" />
     </list>
     <option name="SHOW_DIALOG" value="false" />
     <option name="HIGHLIGHT_CONFLICTS" value="true" />
@@ -180,7 +181,7 @@
       <workItem from="1668212914124" duration="17446000" />
       <workItem from="1668387546036" duration="18603000" />
       <workItem from="1668473035617" duration="5552000" />
-      <workItem from="1668559891944" duration="672000" />
+      <workItem from="1668559891944" duration="712000" />
     </task>
     <servers />
   </component>

+ 1 - 2
application/api/controller/Login.php

@@ -93,8 +93,7 @@ class Login extends Base
                //if($user_info['facility_'.$facility_type] != '' && $facility_code != $user_info['facility_'.$facility_type]) $this->exception('设备号错误');
                 if(!$user_info['facility_'.$facility_type]) User::where('id',$user_info['id'])->update(['facility_'.$facility_type=>$facility_code] );
             }
-            var_dump($user_info);
-            if(!$user_info['hx_username']) hx_register($user_info['id']);
+            if(empty($user_info['hx_username']) || !$user_info['hx_username']) hx_register($user_info['id']);
             $ret_data['token'] =  $this->createJwt($user_info['id'],$facility_code);
             Db::commit();
         }catch (\Exception $e){

+ 0 - 1
application/common.php

@@ -295,7 +295,6 @@ function get32Str($length='32'){
     );
 
     $hx_account = http_post_json('https://a1-vip5.easemob.com/1414221110068467/kefuchannelapp104968/users',json_encode($param),$token_res['access_token']);
-    var_dump($hx_account);
     if(!isset($hx_account['entities'][0]['uuid'])){
         return false;
     }