正在显示
1 个修改的文件
包含
6 行增加
和
2 行删除
@@ -58,8 +58,12 @@ class Index extends Api | @@ -58,8 +58,12 @@ class Index extends Api | ||
58 | ]; | 58 | ]; |
59 | $res =HttpHelper::post($loginurl,$logindata); | 59 | $res =HttpHelper::post($loginurl,$logindata); |
60 | $jsonlogin=json_decode($res,true); | 60 | $jsonlogin=json_decode($res,true); |
61 | - print_r($jsonlogin);return ; | ||
62 | - return $this->success($jsondata['msg'],$jsondata['data']); | 61 | + if($jsonlogin['code']==200){ |
62 | + return $this->success($jsonlogin['msg'],$jsonlogin['data']); | ||
63 | + }else{ | ||
64 | + return $this->error("请求失败"); | ||
65 | + } | ||
66 | + | ||
63 | }else{ | 67 | }else{ |
64 | return $this->error("请求失败"); | 68 | return $this->error("请求失败"); |
65 | } | 69 | } |
-
请 注册 或 登录 后发表评论