adrema/app/Member/DeleteJob.php

36 lines
699 B
PHP
Raw Permalink Normal View History

2021-06-24 00:12:47 +02:00
<?php
namespace App\Member;
2022-09-05 11:37:54 +02:00
use App\Setting\NamiSettings;
2021-06-24 00:12:47 +02:00
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Foundation\Bus\Dispatchable;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Queue\SerializesModels;
class DeleteJob implements ShouldQueue
{
2022-03-11 20:19:17 +01:00
use Dispatchable;
use InteractsWithQueue;
use Queueable;
use SerializesModels;
2021-06-24 00:12:47 +02:00
2022-11-16 22:08:08 +01:00
public int $namiId;
2021-06-24 00:12:47 +02:00
2022-11-16 22:08:08 +01:00
public function __construct(int $namiId)
2021-06-24 00:12:47 +02:00
{
2022-11-16 22:08:08 +01:00
$this->namiId = $namiId;
2021-06-24 00:12:47 +02:00
}
/**
* Execute the job.
*
* @return void
*/
2022-09-05 11:37:54 +02:00
public function handle(NamiSettings $setting)
2021-06-24 00:12:47 +02:00
{
2022-11-16 22:08:08 +01:00
$setting->login()->deleteMember($this->namiId);
2021-06-24 00:12:47 +02:00
}
}