hrjy 3 years ago
parent
commit
623c817443
66 changed files with 19 additions and 13 deletions
  1. 1 0
      app/admin/controller/auction/AuctionOrder.php
  2. 4 2
      app/api/controller/auction/AuctionProductController.php
  3. 7 7
      app/models/auction/Auction.php
  4. 3 2
      app/models/auction/AuctionOrder.php
  5. 3 0
      app/models/auction/AuctionProduct.php
  6. 1 1
      public/index/index.html
  7. 0 0
      public/index/static/js/index.0bda8e3a.js
  8. 0 0
      public/index/static/js/index.0e356d87.js
  9. 0 0
      public/index/static/js/index.3f089dd8.js
  10. 0 0
      public/index/static/js/index.7032a4f2.js
  11. 0 0
      public/index/static/js/index.9069f88a.js
  12. 0 0
      public/index/static/js/index.ec2e761d.js
  13. 0 0
      public/index/static/js/pages-cart-cart.052c83aa.js
  14. 0 0
      public/index/static/js/pages-collection-bank.5d1c7422.js
  15. 0 0
      public/index/static/js/pages-collection-zfb.253af4ee.js
  16. 0 0
      public/index/static/js/pages-hall-gsell.428c79b2.js
  17. 0 0
      public/index/static/js/pages-hall-hall.3cd756a0.js
  18. 0 0
      public/index/static/js/pages-hall-hall.4d88e85d.js
  19. 0 0
      public/index/static/js/pages-hall-hallinfo.2d642a4a.js
  20. 0 0
      public/index/static/js/pages-hall-hallinfo.73594978.js
  21. 0 0
      public/index/static/js/pages-hall-halllist.636b886c.js
  22. 0 0
      public/index/static/js/pages-hall-halllist.89cafa64.js
  23. 0 0
      public/index/static/js/pages-hall-halllist.9775243f.js
  24. 0 0
      public/index/static/js/pages-hall-halllist~pages-hall-hallpay~pages-hall-porducthall~pages-set-addressManage~pages-set-userinfo.e33a5def.js
  25. 0 0
      public/index/static/js/pages-hall-halllist~pages-hall-porducthall~pages-set-addressManage~pages-set-userinfo.9d83533e.js
  26. 0 0
      public/index/static/js/pages-hall-halllist~pages-index-index.0c743e76.js
  27. 0 0
      public/index/static/js/pages-hall-halllist~pages-index-index.9436e9c9.js
  28. 0 0
      public/index/static/js/pages-hall-halllist~pages-index-index.c06a1545.js
  29. 0 0
      public/index/static/js/pages-hall-hallpay.117b8667.js
  30. 0 0
      public/index/static/js/pages-hall-hallpay.85d38998.js
  31. 0 0
      public/index/static/js/pages-hall-hallpay.8b8e36cb.js
  32. 0 0
      public/index/static/js/pages-hall-history.6c4063ee.js
  33. 0 0
      public/index/static/js/pages-hall-history.b1c0586b.js
  34. 0 0
      public/index/static/js/pages-hall-porducthall.4e131b4f.js
  35. 0 0
      public/index/static/js/pages-hall-porducthall.4fe3069d.js
  36. 0 0
      public/index/static/js/pages-index-index.643a9df9.js
  37. 0 0
      public/index/static/js/pages-index-message.e31320c6.js
  38. 0 0
      public/index/static/js/pages-index-messageInfo.07e8da01.js
  39. 0 0
      public/index/static/js/pages-index-messageInfo.7c5aae5a.js
  40. 0 0
      public/index/static/js/pages-index-sign.6deac65a.js
  41. 0 0
      public/index/static/js/pages-index-sign.77f674e2.js
  42. 0 0
      public/index/static/js/pages-money-money.a3f2e9b4.js
  43. 0 0
      public/index/static/js/pages-money-recharge.6f9b843a.js
  44. 0 0
      public/index/static/js/pages-money-success.6d1ba76a.js
  45. 0 0
      public/index/static/js/pages-money-success.bb45cb6c.js
  46. 0 0
      public/index/static/js/pages-money-wallet.b82453f1.js
  47. 0 0
      public/index/static/js/pages-order-createOrder.6a22bf4d.js
  48. 0 0
      public/index/static/js/pages-order-order.528bd434.js
  49. 0 0
      public/index/static/js/pages-order-order.77b63fbe.js
  50. 0 0
      public/index/static/js/pages-public-forget.7410e98f.js
  51. 0 0
      public/index/static/js/pages-public-login.738beaa5.js
  52. 0 0
      public/index/static/js/pages-public-register.fc989683.js
  53. 0 0
      public/index/static/js/pages-redirect-redirect.20ab5bfa.js
  54. 0 0
      public/index/static/js/pages-set-address.bfe70350.js
  55. 0 0
      public/index/static/js/pages-set-addressManage.f58f0fe9.js
  56. 0 1
      public/index/static/js/pages-set-cropper.a459b893.js
  57. 0 0
      public/index/static/js/pages-user-gzsq.f2c56cae.js
  58. 0 0
      public/index/static/js/pages-user-myfans.ba4cdceb.js
  59. 0 0
      public/index/static/js/pages-user-myproduct.26f3ac2b.js
  60. 0 0
      public/index/static/js/pages-user-myproduct.43a3350a.js
  61. 0 0
      public/index/static/js/pages-user-shareQrCode.3f7b1931.js
  62. 0 0
      public/index/static/js/pages-user-shareQrCode.94c468a7.js
  63. 0 0
      public/index/static/js/pages-user-user.59f1ac87.js
  64. 0 0
      public/index/static/js/pages-user-user.79b6d3be.js
  65. 0 0
      public/index/static/js/pages-user-user.7c32286c.js
  66. 0 0
      public/index/static/js/pages-user-user.9314fcf3.js

+ 1 - 0
app/admin/controller/auction/AuctionOrder.php

@@ -235,6 +235,7 @@ class AuctionOrder extends AuthController
 
             $product['uid'] = $data['uid'];// 商品拥有人更新
             $product['add_time'] = time();
+            $product['order'] = $data['order_id'];
             $res = $product->save();
             if ($res){
                 if ($uid > 0){

+ 4 - 2
app/api/controller/auction/AuctionProductController.php

@@ -85,7 +85,7 @@ class AuctionProductController
         $product = AuctionProduct::where('id', $data['product_id'])->find();
         $product_ids = AuctionProduct::where('auction_id', $product['auction_id'])->column('id');
         $auction  = Auction::where('id', $product['auction_id'])->find();
-        $count = AuctionOrder::where('frequency',$auction['frequency'])->where('product_id', 'in', $product_ids)->count();
+        $count = AuctionOrder::where('frequency',$auction['frequency'])->where('uid', $request->uid())->where('product_id', 'in', $product_ids)->count();
 
         $config = SystemConfig::where('menu_name', 'auction_number')->find();
         if ($count >=  (int) preg_replace('~(,(?=[^"]*"(?:[^"]*"[^"]*")*[^"]*$)|")~', '', $config['value'])) return app('json')->fail('单场购买数量已到达最大'); // 查看当前是否已到最大
@@ -216,6 +216,7 @@ class AuctionProductController
 
             $product['uid'] = $order['uid'];// 商品拥有人更新
             $product['add_time'] = time();
+            $product['order'] = $data['order_id'];
             $res = $product->save();
             if ($res){
                 if ($uid > 0){
@@ -318,7 +319,7 @@ class AuctionProductController
         $data = UtilService::postMore([
             ['id'],
         ]);
-        $product = AuctionProduct::where('id', $data['id'])->find();
+        $product = AuctionProduct::where('id', $data['id'])->where('uid', $request->uid())->find();
         $user = User::where('uid', $request->uid())->find();
         if (!$product) return app('json')->fail('商品不存在');
 
@@ -344,6 +345,7 @@ class AuctionProductController
 
             $product->save();
             $user->save();
+            AuctionOrder::where([['uid', '=', $request->uid()], ['product_id', '=', $product['id']], ['is_gs', '=', 0]])->update(['is_gs' => 1]);// 修改订单挂售
             UserBill::expend('挂售扣除预约券', $user['uid'], 'anticipate', 'reduce_anticipate', $datas['anticipate'], $user['spread_uid'], $user['anticipate'], '挂售商品扣除预约券');
 
             Db::commit();

+ 7 - 7
app/models/auction/Auction.php

@@ -37,13 +37,9 @@ class Auction extends BaseModel
         $model->page($data['page'], $data['limit']);
         $model->order('id DESC, sort DESC');
         $id = [];
-        $booking = AuctionBooking::where([['uid', '=', $uid], ['create_time', '>', strtotime(date('Y-m-d'), time())]])->field('auction_id')->select();
-        foreach ($booking as $v) {
-            $id[] = $v['auction_id'];
-        }
-        if ($data['advance']){
-            $model->where('id', 'in', $id);
-        }
+//        if ($data['advance']){
+//            $model->where('id', 'in', $id);
+//        }
         $list = $model->select();
         $list = count($list) ? $list->toArray() : [];
         if ($list){
@@ -51,6 +47,10 @@ class Auction extends BaseModel
             {
                 $list[$k]['time'] = strtotime($v['end_time']);
                 $list[$k]['day'] = date('Y-m-d H:i:s', strtotime($v['end_time']));
+                $booking = AuctionBooking::where([['uid', '=', $uid], ['frequency', '=', $v['frequency']]])->field('auction_id')->select();
+                foreach ($booking as $value) {
+                    $id[] = $value['auction_id'];
+                }
                 if (in_array($v['id'], $id)){
                     $list[$k]['sta'] = 2; // 进入
                     $list[$k]['str'] = '进入';

+ 3 - 2
app/models/auction/AuctionOrder.php

@@ -71,9 +71,10 @@ class AuctionOrder extends BaseModel
                 $list = self::where([['uid', '=', $uid], ['status', '=', 2]])->page($data['page'], $data['limit'])->select(); //待审核订单
 
             }else if($data['type'] == 3) {
-                $list = self::where([['uid', '=', $uid], ['status', '=', 3]])->page($data['page'], $data['limit'])->select(); //完成订单
+                $list = self::where([['uid', '=', $uid], ['status', '=', 3], ['is_gs', '=', 1]])->page($data['page'], $data['limit'])->select(); //完成订单
             }else if($data['type'] == 4) {
-                $list = AuctionProduct::where([['uid', '=', $uid]])->select();
+
+                $list = self::where([['uid', '=', $uid], ['is_gs', '=', 0]])->page($data['page'], $data['limit'])->select(); //待挂售订单
             }else{
                 $list = self::where([['uid', '=', $uid], ['status', '<', 1]])->page($data['page'], $data['limit'])->select(); //过期订单
             }

+ 3 - 0
app/models/auction/AuctionProduct.php

@@ -97,6 +97,7 @@ class AuctionProduct extends BaseModel
         if ($auction){
             foreach ($auction as $k => $v) {
                 $productId = AuctionTime::where('auction_id', '=', $v['id'])->where('add_time', '=', strtotime(date('Y-m-d', time())))->column('product_id');
+
                 if ($productId){
                     $orderId = AuctionOrder::where('product_id', 'in', $productId)->where('frequency', '=', $v['frequency'])->where('status','>', 0)->column('product_id');
                     if ($orderId){
@@ -104,6 +105,8 @@ class AuctionProduct extends BaseModel
                             if (in_array($value, $productId))unset($productId[$value]);
                         }
                     }
+                    $order = AuctionProduct::where([['id', 'in', $productId], ['auction_id', '=', $v['id']], ['is_admin', '=', 2]])->column('order');// 查找今天场次没买出去的商品订单
+                    AuctionOrder::where('order_id', 'in', $order)->save(['is_gs' => 0]);//订单为未挂售状态
                     AuctionProduct::where([['id', 'in', $productId], ['auction_id', '=', $v['id']], ['is_admin', '=', 2]])->save(['is_show' => 0]);// 查找今天场次没买出去的商品下架
                     AuctionTime::where('auction_id', '=', $v['id'])->where('add_time', '<=', strtotime(date('Y-m-d', time())))->delete(); // 清除今天挂售时间
                 }

+ 1 - 1
public/index/index.html

@@ -1,2 +1,2 @@
 <!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><title>商城</title><script>var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
-            document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/index/static/index.a5c69d49.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/index/static/js/chunk-vendors.d618d095.js></script><script src=/index/static/js/index.9069f88a.js></script></body></html>
+            document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')</script><link rel=stylesheet href=/index/static/index.a5c69d49.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script src=/index/static/js/chunk-vendors.d618d095.js></script><script src=/index/static/js/index.0e356d87.js></script></body></html>

File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/index.0bda8e3a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/index.0e356d87.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/index.3f089dd8.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/index.7032a4f2.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/index.9069f88a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/index.ec2e761d.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-cart-cart.052c83aa.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-collection-bank.5d1c7422.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-collection-zfb.253af4ee.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-gsell.428c79b2.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hall.3cd756a0.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hall.4d88e85d.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hallinfo.2d642a4a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hallinfo.73594978.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist.636b886c.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist.89cafa64.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist.9775243f.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist~pages-hall-hallpay~pages-hall-porducthall~pages-set-addressManage~pages-set-userinfo.e33a5def.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist~pages-hall-porducthall~pages-set-addressManage~pages-set-userinfo.9d83533e.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist~pages-index-index.0c743e76.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist~pages-index-index.9436e9c9.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-halllist~pages-index-index.c06a1545.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hallpay.117b8667.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hallpay.85d38998.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-hallpay.8b8e36cb.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-history.6c4063ee.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-history.b1c0586b.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-porducthall.4e131b4f.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-hall-porducthall.4fe3069d.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-index-index.643a9df9.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-index-message.e31320c6.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-index-messageInfo.07e8da01.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-index-messageInfo.7c5aae5a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-index-sign.6deac65a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-index-sign.77f674e2.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-money-money.a3f2e9b4.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-money-recharge.6f9b843a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-money-success.6d1ba76a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-money-success.bb45cb6c.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-money-wallet.b82453f1.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-order-createOrder.6a22bf4d.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-order-order.528bd434.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-order-order.77b63fbe.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-public-forget.7410e98f.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-public-login.738beaa5.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-public-register.fc989683.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-redirect-redirect.20ab5bfa.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-set-address.bfe70350.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-set-addressManage.f58f0fe9.js


+ 0 - 1
public/index/static/js/pages-set-cropper.a459b893.js

@@ -1 +0,0 @@
-(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-set-cropper"],{"0404":function(e,t,n){"use strict";n.r(t);var a=n("98c3"),i=n.n(a);for(var r in a)"default"!==r&&function(e){n.d(t,e,(function(){return a[e]}))}(r);t["default"]=i.a},"7a02":function(e,t,n){"use strict";var a;n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return a}));var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("v-uni-view",{staticClass:"container"},[n("v-uni-web-view",{attrs:{"webview-styles":e.webviewStyles,src:e.webviewSrc},on:{message:function(t){arguments[0]=t=e.$handleEvent(t),e.handleMessage.apply(void 0,arguments)}}})],1)},r=[]},"98c3":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a={name:"buuug7-img-cropper",data:function(){return{webviewStyles:{},platform:"",webviewSrc:"https://zhibo.liuniu946.com/index/hybrid/html/cropper/index.html"}},mounted:function(){var e=uni.getSystemInfoSync(),t=e.platform;this.platform=t,console.log(t,"获取系统对象"),"windows"!==t&&"mac"!==t||this.handleH5Message(),window.addEventListener("message",this.handleMessage,!1)},methods:{handleMessage:function(e){console.log("消息传输",e);var t=this.platform;if(e.data.data.type){var n=e.data.data;if(console.log(t,"myself"),"android"===t||"ios"===t||"devtools"===t){var a=this.getOpenerEventChannel();a.emit("imgCropped",{data:n.dataUrl})}}},handleH5Message:function(e){var t=this;console.log("H5Message"),window.addEventListener("message",(function(e){var n=e.data.data;if(n&&"croppedData"===n.type){var a=t.getOpenerEventChannel();a.emit("imgCropped",{data:n.dataUrl})}}))}}};t.default=a},a3d8:function(e,t,n){"use strict";n.r(t);var a=n("7a02"),i=n("0404");for(var r in i)"default"!==r&&function(e){n.d(t,e,(function(){return i[e]}))}(r);var o,s=n("f0c5"),d=Object(s["a"])(i["default"],a["b"],a["c"],!1,null,"387d157a",null,!1,a["a"],o);t["default"]=d.exports}}]);

File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-gzsq.f2c56cae.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-myfans.ba4cdceb.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-myproduct.26f3ac2b.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-myproduct.43a3350a.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-shareQrCode.3f7b1931.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-shareQrCode.94c468a7.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-user.59f1ac87.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-user.79b6d3be.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-user.7c32286c.js


File diff suppressed because it is too large
+ 0 - 0
public/index/static/js/pages-user-user.9314fcf3.js


Some files were not shown because too many files changed in this diff