Ver código fonte

提现门槛,充值测试

lizhen_gitee 2 meses atrás
pai
commit
8516d1f571

+ 6 - 0
application/api/controller/Notify.php

@@ -247,6 +247,12 @@ class Notify extends Api
         exit;
         exit;
     }
     }
 
 
+    public function vip_notify_test(){
+        $out_trade_no = input('out_trade_no','');
+        $rs = $this->vip_notify_do($out_trade_no);
+        dump($rs);
+    }
+
     //充值金币 逻辑
     //充值金币 逻辑
     private function vip_notify_do($out_trade_no){
     private function vip_notify_do($out_trade_no){
 
 

+ 10 - 2
application/api/controller/Takecash.php

@@ -69,9 +69,17 @@ class Takecash extends Api
             $this->error('请选择提现账户~');
             $this->error('请选择提现账户~');
         }
         }
 
 
-        /*if ($this->auth->idcard_status != 1) {
+        if ($this->auth->idcard_status != 1) {
             $this->error('请先完成实名认证~');
             $this->error('请先完成实名认证~');
-        }*/
+        }
+
+        if ($this->auth->gender == 1) {
+            $user_wallet = Db::name('user_wallet')->where('user_id',$this->auth->id)->find();
+            $is_vip = $this->is_vip($user_wallet['vip_endtime'],$user_wallet['vip_level']);
+            if($is_vip != 2){
+                $this->error('SVIP才能提现');
+            }
+        }
 
 
         if ($id > 0) {
         if ($id > 0) {
             $withdrawal_config = Db::name('withdrawal_config')->find($id);
             $withdrawal_config = Db::name('withdrawal_config')->find($id);