Bläddra i källkod

前台滑落红字的条件

lizhen_gitee 2 år sedan
förälder
incheckning
fddbfc88c1
1 ändrade filer med 2 tillägg och 1 borttagningar
  1. 2 1
      application/common/library/Auth.php

+ 2 - 1
application/common/library/Auth.php

@@ -577,10 +577,11 @@ class Auth
             'have_paid' => ['gt',0],
         ];
         $order_price_sum = Db::name('unishop_order')->where($map)->sum('order_price');
+        $order_price_sum = $order_price_sum ?: 0;
 
         $score = model('wallet')->getWallet($this->id,'score');//积分
 
-        if($score >= $order_price_sum){
+        if($score >= $order_price_sum*2){
             return true;
         }