소스 검색

登录状态

Cherry 2 년 전
부모
커밋
9fba350991
2개의 변경된 파일223개의 추가작업 그리고 218개의 파일을 삭제
  1. 16 0
      application/api/controller/User.php
  2. 207 218
      public/api.html

+ 16 - 0
application/api/controller/User.php

@@ -890,4 +890,20 @@ class User extends Api
 
         $this->success('ok', $list);
     }
+
+    /**
+     * 最后登录状态
+     *
+     * @ApiMethod (POST)
+     * @ApiParams (name="type", type="int", required=true, description="类型:1=塘主,2=用户")
+     * @ApiReturn ({"code":1,"msg":"ok"}]})
+     */
+    public function change_last_login_type()
+    {
+        $user_id = $this->auth->id;
+        $last_login_type = $this->request->post('type');
+
+        (new \app\api\model\User())->save(['last_login_type'=>$last_login_type],['id'=>$user_id]);
+        $this->success('ok');
+    }
 }

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 207 - 218
public/api.html


이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.