Ver Fonte

抽奖修改

lizhen_gitee há 1 ano atrás
pai
commit
e1f0dc2fe6
1 ficheiros alterados com 2 adições e 2 exclusões
  1. 2 2
      application/api/controller/Eggnew.php

+ 2 - 2
application/api/controller/Eggnew.php

@@ -80,7 +80,7 @@ class Eggnew extends Api
             // 查找正在开放的奖池
             $jackpot = \app\common\model\EggJackpot::where(["status"=>1,'type'=>$type])->find();
             if($jackpot) { // 有开放的奖池
-
+//                \app\common\model\EggJackpot::order("id","asc")->find();
                 $jackpot_id = $jackpot["id"];
             } else { // 没有开放的奖池
                 $jackpotInfo = \app\common\model\EggJackpot::where('type',$type)->order('weigh asc,id asc')->find();
@@ -216,7 +216,7 @@ class Eggnew extends Api
             }
             $data && $res5 = \app\common\model\EggDo::insertAll($data);
             // 扣除用户小锤子
-            $res6 = \app\common\model\User::where(["id"=>$user_id])->setDec("hammer",$num);
+            $res6 = true;
 
             // 添加到用户背包
             $backdata && $res7 = \app\common\model\GiftBack::insertAll($backdata);