token = $token; } /** * Get the notification's delivery channels. * * @param mixed $notifiable * @return array */ public function via($notifiable) { return ['mail']; } /** * Get the mail representation of the notification. * * @param mixed $notifiable * @return \Illuminate\Notifications\Messages\MailMessage */ public function toMail($notifiable) { $url = URL::temporarySignedRoute('manager.accept.invite', now()->addDays(2), ['token' => $this->token, 'email' => $notifiable->email]); return (new MailMessage) ->subject(Auth::user()->name . ' invited you as a Manager | Clapsify') ->line('Hope you are having a great day! You have been invited as a manager!') ->line(Auth::user()->name . ' has invited you to become their manager. Please accept the invitation below to start managing with their profile.') ->action('Accept Invitation', $url) ->line('We are happy to have you 🤗'); } /** * Get the array representation of the notification. * * @param mixed $notifiable * @return array */ public function toArray($notifiable) { return [ // ]; } }