Compare commits
2 Commits
1106edcb7f
...
b7d32a74e7
Author | SHA1 | Date | |
---|---|---|---|
b7d32a74e7 | |||
0a08d8bd6d |
@ -18,7 +18,7 @@ class Task2
|
|||||||
{
|
{
|
||||||
// 每5秒执行一次
|
// 每5秒执行一次
|
||||||
new Crontab('0 */1 * * * *', function () {
|
new Crontab('0 */1 * * * *', function () {
|
||||||
$phones = UserPhone::where('status' ,'!=', 2)->get();
|
$phones = UserPhone::where('created_at', '<', \Carbon\Carbon::now()->subMinutes(10))->where('status','!=',2)->get();
|
||||||
$start_time = time();
|
$start_time = time();
|
||||||
foreach ($phones as $key => $value) {
|
foreach ($phones as $key => $value) {
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user