Explorar el Código

Merge branch 'master' of https://git.bjtdba.com/shop/php

xialei hace 1 año
padre
commit
74588be396
Se han modificado 2 ficheros con 48 adiciones y 13 borrados
  1. 12 0
      .vscode/sftp.json
  2. 36 13
      app/controller/api/user/User.php

+ 12 - 0
.vscode/sftp.json

@@ -0,0 +1,12 @@
1
+{
2
+    "name": "8.141.0.149",
3
+    "host": "8.141.0.149",
4
+    "protocol": "sftp",
5
+    "port": 22,
6
+    "username": "root",
7
+    "password": "hhq15801255760",
8
+    "remotePath": "/data/www/api.hebeiyhc.com/web",
9
+    "uploadOnSave": true,
10
+    "useTempFile": false,
11
+    "openSsh": false
12
+}

+ 36 - 13
app/controller/api/user/User.php

@@ -193,6 +193,19 @@ class User extends BaseController
193 193
         }
194 194
 
195 195
     }
196
+
197
+
198
+    public function vr_name()
199
+    {
200
+        $uid = $this->request->uid();
201
+        $data = [
202
+            "name"=>"VR转账",
203
+            "url"=>'https://show.gdjbp.com/?uid=' .$uid,
204
+        ];
205
+        return app('json')->success($data);
206
+    }
207
+
208
+
196 209
     public function  hongbao_list(){
197 210
         $pm = $this->request->param('pm');
198 211
 
@@ -722,9 +735,15 @@ class User extends BaseController
722 735
             if ($res) {
723 736
                 //赠送积分 完善实名送20个积分,同时送邀请人20个积
724 737
                 $this->sign_add($member_id, 20,1,'完善实名系统赠送20个积分','','');
738
+<<<<<<< HEAD
725 739
                 $member_info = Db::name('user')->where( array('uid' => $member_id) )->find(); 
726 740
                 if($member_info['spread_uid']){
727 741
                      //首次邀请好友奖励积分
742
+=======
743
+                $member_info = Db::name('user')->where( array('uid' => $member_id) )->find();
744
+                if($member_info['spread_uid']){
745
+                    //首次邀请好友奖励积分
746
+>>>>>>> 5a864c5d52463e1d71d2e80b95a91a2d09015473
728 747
                     $spreadUid = $member_info['spread_uid'];
729 748
                     $this->sign_add($spreadUid, 20,1,'好友完善实名系统赠送20个积分','','');
730 749
                 }
@@ -739,7 +758,11 @@ class User extends BaseController
739 758
     }
740 759
 
741 760
 
761
+<<<<<<< HEAD
742 762
         /**
763
+=======
764
+    /**
765
+>>>>>>> 5a864c5d52463e1d71d2e80b95a91a2d09015473
743 766
      * @param int $uid 用户ID
744 767
      * @param string $score 积分
745 768
      * @param int $status 积分状态
@@ -3235,7 +3258,7 @@ class User extends BaseController
3235 3258
      * 转VR
3236 3259
      */
3237 3260
     public function transition_vr()
3238
-    { 
3261
+    {
3239 3262
         $uid = $this->request->uid();
3240 3263
         $user = $this->request->userInfo();
3241 3264
         $type = $this->request->param('type', 'brokerage');
@@ -3243,11 +3266,11 @@ class User extends BaseController
3243 3266
         if ($type == 'brokerage') {
3244 3267
             $brokerage_price = Db::name('user')->where('uid', $uid)->value('brokerage_price');
3245 3268
             $no_clear_amount = Db::name('user_bill')
3246
-            ->where('uid', $uid)
3247
-            ->where('commission_type', '<>', 5)
3248
-            ->where('pm', 1)
3249
-            ->where('status', 0)
3250
-            ->sum('number');
3269
+                ->where('uid', $uid)
3270
+                ->where('commission_type', '<>', 5)
3271
+                ->where('pm', 1)
3272
+                ->where('status', 0)
3273
+                ->sum('number');
3251 3274
             $clear_amount = $brokerage_price - $no_clear_amount;
3252 3275
             if ($user['brokerage_price'] < (systemConfig('withdrawal_money'))){
3253 3276
                 return app('json')->fail('未到达提现最低额度');
@@ -3287,20 +3310,20 @@ class User extends BaseController
3287 3310
      * 转VR记录
3288 3311
      */
3289 3312
     public function transition_vr_log()
3290
-    { 
3313
+    {
3291 3314
         $uid = $this->request->uid();
3292 3315
         $type = $this->request->param('type', 1);
3293
-		[$page, $limit] = $this->getPage();
3294
-		$where = [];
3295
-		$where[] = ['uid', '=', $uid];
3316
+        [$page, $limit] = $this->getPage();
3317
+        $where = [];
3318
+        $where[] = ['uid', '=', $uid];
3296 3319
         $where[] = ['type', '=', $type];
3297
-		$query = Db::name("user_transition_vr");
3320
+        $query = Db::name("user_transition_vr");
3298 3321
         $count = $query->where($where)->count();
3299 3322
         $list = $query->page($page, $limit)->where($where)->select()->each(function ($item){
3300
-			$item['create_time'] = date("Y-m-d H:i:s", $item['create_time']);
3323
+            $item['create_time'] = date("Y-m-d H:i:s", $item['create_time']);
3301 3324
             return $item;
3302 3325
         });
3303
-		return app('json')->success('获取转VR记录成功', ['list'=>$list, 'count'=>$count]);
3326
+        return app('json')->success('获取转VR记录成功', ['list'=>$list, 'count'=>$count]);
3304 3327
     }
3305 3328
 
3306 3329