namespace App\Jobs; use Illuminate\Bus\Queueable; use Illuminate\Queue\SerializesModels; use Illuminate\Queue\InteractsWithQueue; use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Foundation\Bus\Dispatchable; use Illuminate\Support\Facades\Log;
/** * Class InviteChecker * @package App\Jobs * 检查用户是否24小时内完成任务 */ class InviteChecker implements ShouldQueue { use Dispatchable, InteractsWithQueue, Queueable, SerializesModels; protected $user; public $tries = 2; public $timeout = 120;
/** * Create a new job instance. * * @param User $user */ public function __construct(User $user) {
$this->user = $user;
}
/** * Execute the job. * * @return void * @throws \Exception */ public function handle() {