id = $id; $this->title = $title; $this->content = $content; } public function build(): replyTicket { return $this->view('emails.replyTicket')->subject('工单回复提醒')->with( [ 'title' => $this->title, 'content' => $this->content, ] ); } // 发件失败处理 public function failed(Exception $e): void { NotificationLog::whereId($this->id)->update( ['status' => -1, 'error' => $e->getMessage()] ); } }