MessageJob.php 689 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. *
  5. * User: king/QQ:995265288
  6. * Date: 2018/3/23 下午1:56
  7. * Email: livsyitian@163.com
  8. */
  9. namespace app\Jobs;
  10. use app\common\events\Event;
  11. use app\common\services\MessageService;
  12. use Illuminate\Bus\Queueable;
  13. use Illuminate\Queue\SerializesModels;
  14. use Illuminate\Queue\InteractsWithQueue;
  15. class MessageJob extends Job
  16. {
  17. use InteractsWithQueue, Queueable, SerializesModels;
  18. public function handle()
  19. {
  20. (new MessageService())->push(
  21. $this->event->member_id,
  22. $this->event->template_id,
  23. $this->event->params,
  24. $this->event->url,
  25. $this->event->uniacid
  26. );
  27. }
  28. }