lizhen_gitee vor 1 Jahr
Ursprung
Commit
0285deb32f
1 geänderte Dateien mit 9 neuen und 7 gelöschten Zeilen
  1. 9 7
      app/Console/Commands/Plantask.php

+ 9 - 7
app/Console/Commands/Plantask.php

@@ -49,16 +49,18 @@ class Plantask extends Command
                 $msg_id = $val->id;
                 dispatch((new GiftJob($msg_id))->delay(0));//加入队列
             }
-        }
 
-        //更新
-        $ids = array_column($list,'id');
+            //更新
+            $ids = array_column($list,'id');
+
+            $update = [
+                'new_task_status' => 1,
+            ];
+
+            DB::table('hx_gift_user_party')->whereIn('id',$ids)->update($update);
+        }
 
-        $update = [
-            'new_task_status' => 1,
-        ];
 
-        DB::table('hx_gift_user_party')->whereIn('id',$ids)->update($update);
 
         return 0;
     }