Files
cycle_api/app/Jobs/AddPostQueue.php
2024-03-04 04:28:48 +08:00

35 lines
772 B
PHP

<?php
namespace App\Jobs;
use App\Exceptions\ModelException;
use App\Models\Api\Post\PostPushBoxModel;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Foundation\Bus\Dispatchable;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Queue\SerializesModels;
class AddPostQueue implements ShouldQueue
{
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
/**
* Create a new job instance.
*/
public function __construct()
{
//
}
/**
* Execute the job.
* @throws ModelException
*/
public function handle(array $params): void
{
$oPostPushBoxModel = new PostPushBoxModel();
$oPostPushBoxModel->addPostQueueConsumer($params);
}
}