hrjy 3 年之前
父節點
當前提交
b5c3b49413

+ 1 - 1
app/admin/controller/auction/Auction.php

@@ -80,7 +80,7 @@ class Auction extends AuthController
         $f[] = Form::dateTimes('rend_time', '结束时间');
         $f[] = Form::input('sort', '排序', '0');
         $f[] = Form::input('sort', '排序', '0');
-        $f[] =  Form::checkbox('site', '开场日期', [1])->options([
+        $f[] =  Form::checkbox('site', '开场日期', [1,3,5])->options([
             ['value' => 1, 'label' => '周一'],
             ['value' => 2, 'label' => '周二'],
             ['value' => 3, 'label' => '周三'],

+ 1 - 13
app/admin/model/auction/AuctionOrder.php

@@ -81,19 +81,7 @@ class AuctionOrder extends BaseModel
             $spread = $userModel->find($user['spread_uid']);
             $spread['integral'] = $spread['integral'] + $s_price; //积分增加
             $spread->save();
-            \app\models\user\UserBill::create([
-                'uid' => $spread['uid'],
-                'link_id' => $id,
-                'pm' => 1,
-                'title' => '积分增加',
-                'category' => 'integral',
-                'type' => 'gain',
-                'mark' => '卖出商品直推'.$s_price.'积分',
-                'add_time' => time(),
-                'number' => $s_price,
-                'balance' => $spread['integral']
-
-            ]);
+            \app\models\user\UserBill::income('直推奖励', $spread['uid'], 'anticipate', 'add_anticipate', $s_price, 0, $spread['integral'], '奖励趣豆');
         }
 //        $user['anticipate'] = $user['anticipate']-$price*($product['deduct']/100); // 扣除当前卖出价格百分比的预约卷
 //        $user->save();

+ 1 - 1
app/models/auction/AuctionProduct.php

@@ -105,7 +105,7 @@ class AuctionProduct extends BaseModel
                         }
                     }
                     AuctionProduct::where([['id', 'in', $productId], ['auction_id', '=', $v['id']], ['is_admin', '=', 2]])->save(['is_show' => 0]);// 查找今天场次没买出去的商品下架
-//                self::where('auction_id', '=', $v['id'])->where('add_time', '<=', strtotime(date('Y-m-d', time())))->delete(); // 清除今天挂售时间
+                    AuctionTime::where('auction_id', '=', $v['id'])->where('add_time', '<=', strtotime(date('Y-m-d', time())))->delete(); // 清除今天挂售时间
                 }
             }