I'm loading view for mail
$this->mail->send('auth::emails.email_confirmation', ['url' => $confirmationEmailUrl], function ($m) use ($user, $toMail) {
$m->to($toMail, $user->name)->subject('mail');
});
And Service Provider
public function registerViews()
{
$viewPath = base_path('resources/views/modules/auth');
$sourcePath = __DIR__ . '/../Resources/views';
$this->publishes([
$sourcePath => $viewPath
]);
$this->loadViewsFrom([$viewPath, $sourcePath], 'auth');
}
Note: I'm using pingpong module structure.
Any idea. I'm getting
No hint path defined for [Auth]
error message. what's problem with this?
Try giving your service another key instead of "auth". Laravel uses that key and you might be running into conflicts.
public function registerViews()
{
$viewPath = base_path('resources/views/modules/auth');
$sourcePath = __DIR__ . '/../Resources/views';
$this->publishes([
$sourcePath => $viewPath
]);
$this->loadViewsFrom([$viewPath, $sourcePath], 'my-auth');
}
Then try
$this->mail->send('my-auth::emails.email_confirmation', ['url' => $confirmationEmailUrl], function ($m) use ($user, $toMail) {
$m->to($toMail, $user->name)->subject('mail');
});
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With