I am using laravel's default notification system. The type column of the table gets populated by full class path like "App\Notifications\Upvoted" . I am only filling the data column by myself like this:
public function toDatabase($notifiable)
{
return [
"post" => $this->post,
"user" => Auth::user()
];
}
How can I add custom value for "type" column too.
As I am new to Laravel your help will be greatly appreciated.