removed job models for eve mail as it's no longer needed. updated all functions to the new programming method
This commit is contained in:
@@ -18,7 +18,6 @@ use App\Models\User\UserPermission;
|
||||
use App\Models\Contracts\Contract;
|
||||
use App\Models\Contracts\Bid;
|
||||
use App\Models\Contracts\AcceptedBid;
|
||||
use App\Models\Jobs\JobSendEveMail;
|
||||
|
||||
class ContractAdminController extends Controller
|
||||
{
|
||||
@@ -152,15 +151,8 @@ class ContractAdminController extends Controller
|
||||
$body .= 'Please remit contract when the items are ready to Spatial Forces. Description should be the contract identification number. Request ISK should be the bid amount.';
|
||||
$body .= 'Sincerely,<br>Spatial Forces Contracting Department';
|
||||
|
||||
//Setup the mail job
|
||||
$mail = new JobSendEveMail;
|
||||
$mail->subject = $subject;
|
||||
$mail->recipient_type = 'character';
|
||||
$mail->recipient = $bid['character_id'];
|
||||
$mail->body = $body;
|
||||
$mail->sender = $config['primary'];
|
||||
//Dispatch the mail job
|
||||
ProcessSendEveMailJob::dispatch($mail)->onQueue('mail')->delay(Carbon::now()->addSeconds(5));
|
||||
ProcessSendEveMailJob::dispatch($body, $bid['character_id'], 'character', $subject, $config['primary'])->onQueue('mail')->delay(Carbon::now()->addSeconds(5));
|
||||
|
||||
//Tidy up the contract by doing a few things.
|
||||
$this->TidyContract($contract, $bid);
|
||||
@@ -187,12 +179,8 @@ class ContractAdminController extends Controller
|
||||
//Get the esi config
|
||||
$config = config('esi');
|
||||
|
||||
$mail = new JobSendEveMail;
|
||||
$mail->sender = $config['primary'];
|
||||
$mail->subject = 'New Alliance Production Contract Available';
|
||||
$mail->recipient = $config['alliance'];
|
||||
$mail->recipient_type = 'alliance';
|
||||
$mail->body = "A new contract is available for the alliance contracting system. Please check out <a href='https://services.w4rp.space'>Services Site</a> if you want to bid on the production contract.<br><br>Sincerely,<br>Warped Intentions Leadership";
|
||||
ProcessSendEveMailJob::dispatch($mail)->onQueue('mail')->delay(Carbon::now()->addSeconds(5));
|
||||
$subject = 'New Alliance Production Contract Available';
|
||||
$body = "A new contract is available for the alliance contracting system. Please check out <a href='https://services.w4rp.space'>Services Site</a> if you want to bid on the production contract.<br><br>Sincerely,<br>Warped Intentions Leadership";
|
||||
ProcessSendEveMailJob::dispatch($body, $config['alliance'], 'alliance', $subject, $config['primary'])->onQueue('mail')->delay(Carbon::now()->addSeconds(5));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,7 +9,6 @@ use Log;
|
||||
|
||||
//Models
|
||||
use App\Models\Logistics\AnchorStructure;
|
||||
use App\Models\Jobs\JobSendEveMail;
|
||||
|
||||
class StructureRequestAdminController extends Controller
|
||||
{
|
||||
|
||||
@@ -15,7 +15,6 @@ use App\Library\Lookups\LookupHelper;
|
||||
|
||||
//Models
|
||||
use App\Models\Logistics\AnchorStructure;
|
||||
use App\Models\Jobs\JobSendEveMail;
|
||||
use App\Models\User\UserPermission;
|
||||
|
||||
class StructureRequestController extends Controller
|
||||
@@ -72,13 +71,8 @@ class StructureRequestController extends Controller
|
||||
$body .= "Warped Intentions Leadership<br>";
|
||||
|
||||
//Dispatch the mail job
|
||||
$mail = new JobSendEveMail;
|
||||
$mail->sender = $config['primary'];
|
||||
$mail->subject = "New Structure Anchor Request";
|
||||
$mail->body = $body;
|
||||
$mail->recipient = (int)$fc->character_id;
|
||||
$mail->recipient_type = 'character';
|
||||
ProcessSendEveMailJob::dispatch($mail)->onQueue('mail')->delay(Carbon::now()->addSeconds($delay));
|
||||
$subject = "New Structure Anchor Request";
|
||||
ProcessSendEveMailJob::dispatch($body, (int)$fc->character_id, 'character', $subject, $config['primary'])->onQueue('mail')->delay(Carbon::now()->addSeconds($delay));
|
||||
|
||||
$delay += 15;
|
||||
}
|
||||
|
||||
@@ -17,7 +17,6 @@ use App\Models\Moon\Price;
|
||||
use App\Models\MoonRent\MoonRental;
|
||||
use App\Models\Moon\AllianceMoon;
|
||||
use App\Models\Moon\AllianceMoonRequest;
|
||||
use App\Models\Jobs\JobSendEveMail;
|
||||
|
||||
//Library
|
||||
use App\Library\Moons\MoonCalc;
|
||||
@@ -130,13 +129,7 @@ class MoonsAdminController extends Controller
|
||||
}
|
||||
|
||||
//Setup the mail model
|
||||
$mail = new JobSendEveMail;
|
||||
$mail->sender = $config['primary'];
|
||||
$mail->subject = 'Warped Intentions Moon Request';
|
||||
$mail->body = $body;
|
||||
$mail->recipient = (int)$moon->requestor_id;
|
||||
$mail->recipient_type = 'character';
|
||||
ProcessSendEveMailJob::dispatch($mail)->onQueue('mail')->delay(Carbon::now()->addSeconds(5));
|
||||
ProcessSendEveMailJob::dispatch($body, (int)$moon->requestor_id, 'character', 'Warped Intentions Moon Request', $config['primary'])->onQueue('mail')->delay(Carbon::now()->addSeconds(5));
|
||||
|
||||
return redirect('/moons/admin/display/request')->with('success', 'Moon has been processed, and mail has been sent out.');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user