SendLoanExtendJob
class SendLoanExtendJob implements ShouldQueue (View source)
Job responsible for sending a loan due date extension email.
This job asynchronously notifies the borrower that the due date of an existing loan has been successfully extended. Queueing the email ensures that the user experience remains fast and avoids delays caused by external email dispatching.
Traits
Dispatchable
InteractsWithQueue
Queueable
SerializesModels
Properties
| protected string | $loanId | The unique identifier of the loan, used to fetch the necessary data. |
Methods
__construct(string $loanId)
Create a new job instance.
void
Details
__construct(string $loanId)
Create a new job instance.
void
handle(EmailService $emailService)
Execute the job to send the due date extension email.
This method retrieves the loan based on the provided ID and requests the email service to send the extension email with the relevant details.