service = $service; $this->user = $user; } /** * Build the message. * * @return \Illuminate\Mail\Mailable */ public function build(): \Illuminate\Mail\Mailable { return $this->view('mail.service-renewed') ->subject('!!! Warning !!!, New service credential have been generated !') ->text('mail.service-renewed-plain') ->with('appName', config('app.name')) ->with('service', $this->service) ->with('by', sprintf('%s %s (%s)', $this->user->first_name, $this->user->last_name, $this->user->email)) ->to( config('mail.contactsList.serviceweb', 'equipe.web@ldc.fr'), sprintf('%s service warning', config('app.name')) ); } }