zz 6 年之前
父节点
当前提交
ed26d2d303
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      app/Console/Commands/BookTest.php

+ 2 - 2
app/Console/Commands/BookTest.php

@@ -334,8 +334,8 @@ class BookTest extends Command
         $result = [];
         $result = [];
         $chapter_model = new ChapterOrder();
         $chapter_model = new ChapterOrder();
         foreach ($info as $item){
         foreach ($info as $item){
-            $to_bids = YqUserBidRelation::where('uid',$item->uid)->where('to_bid','>',0)->where('to_bid','!=','from_bid')->select('to_bid','created_at')->get();
-            $from_bids = YqUserBidRelation::where('uid',$item->uid)->where('from_bid','>',0)->where('to_bid','!=','from_bid')->select('from_bid','created_at')->get();
+            $to_bids = YqUserBidRelation::where('uid',$item->uid)->where('to_bid','>',0)->whereColumn('to_bid','!=','from_bid')->select('to_bid','created_at')->get();
+            $from_bids = YqUserBidRelation::where('uid',$item->uid)->where('from_bid','>',0)->whereColumn('to_bid','!=','from_bid')->select('from_bid','created_at')->get();
             $chapter_model->setCurrentTable($item->uid);
             $chapter_model->setCurrentTable($item->uid);
             if($to_bids){
             if($to_bids){
                 foreach ($to_bids as $v){
                 foreach ($to_bids as $v){