Added env's shop_mail_from param param in all mails related to customers and shop
This commit is contained in:
parent
845f34038b
commit
fbedc8a161
|
|
@ -56,8 +56,8 @@ return [
|
|||
*/
|
||||
|
||||
'from' => [
|
||||
'address' => env('MAIL_FROM_ADDRESS', 'hello@example.com'),
|
||||
'name' => env('MAIL_FROM_NAME', 'Example'),
|
||||
'address' => env('SHOP_MAIL_FROM'),
|
||||
'name' => env('MAIL_FROM_NAME')
|
||||
],
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ use Illuminate\Contracts\Queue\ShouldQueue;
|
|||
class NewInvoiceNotification extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
|
||||
/**
|
||||
* The invoice instance.
|
||||
*
|
||||
|
|
@ -45,6 +45,7 @@ class NewInvoiceNotification extends Mailable
|
|||
$order = $this->invoice->order;
|
||||
|
||||
return $this->to($order->customer_email, $order->customer_full_name)
|
||||
->from(env('SHOP_MAIL_FROM'))
|
||||
->subject(trans('shop::app.mail.invoice.subject', ['order_id' => $order->id]))
|
||||
->view('shop::emails.sales.new-invoice');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,6 +42,7 @@ class NewOrderNotification extends Mailable
|
|||
public function build()
|
||||
{
|
||||
return $this->to($this->order->customer_email, $this->order->customer_full_name)
|
||||
->from(env('SHOP_MAIL_FROM'))
|
||||
->subject(trans('shop::app.mail.order.subject'))
|
||||
->view('shop::emails.sales.new-order');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ class NewShipmentNotification extends Mailable
|
|||
$order = $this->shipment->order;
|
||||
|
||||
return $this->to($order->customer_email, $order->customer_full_name)
|
||||
->from(env('SHOP_MAIL_FROM'))
|
||||
->subject(trans('shop::app.mail.shipment.subject', ['order_id' => $order->id]))
|
||||
->view('shop::emails.sales.new-shipment');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ class VerificationEmail extends Mailable
|
|||
public function build()
|
||||
{
|
||||
return $this->to($this->verificationData['email'])
|
||||
->from(env('SHOP_MAIL_FROM'))
|
||||
->subject('Verification email')
|
||||
->view('shop::emails.customer.verification-email')->with('data', ['email' => $this->verificationData['email'], 'token' => $this->verificationData['token']]);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@ class CustomerResetPassword extends ResetPassword
|
|||
}
|
||||
|
||||
return (new MailMessage)
|
||||
->from(env('SHOP_MAIL_FROM'))
|
||||
->subject(__('shop::app.mail.forget-password.subject') )
|
||||
->view('shop::emails.customer.forget-password', [
|
||||
'user_name' => $notifiable->name,
|
||||
|
|
|
|||
|
|
@ -9,16 +9,20 @@ use Illuminate\Contracts\Queue\ShouldQueue;
|
|||
/**
|
||||
* Subscriber Mail class
|
||||
*
|
||||
* @author Prashant Singh <prashant.singh852@webkul.com>
|
||||
* @author Prashant Singh <prashant.singh852@webkul.com> @prashant-webkul
|
||||
*
|
||||
* @copyright 2018 Webkul Software Pvt Ltd (http://www.webkul.com)
|
||||
*/
|
||||
class SubscriptionEmail extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
public $subscriptionData;
|
||||
|
||||
public function __construct($subscriptionData) {
|
||||
$this->subscriptionData = $subscriptionData;
|
||||
}
|
||||
|
||||
/**
|
||||
* Build the message.
|
||||
*
|
||||
|
|
@ -27,7 +31,8 @@ class SubscriptionEmail extends Mailable
|
|||
public function build()
|
||||
{
|
||||
return $this->to($this->subscriptionData['email'])
|
||||
->subject('subscription email')
|
||||
->view('shop::emails.customer.subscription-email')->with('data', ['content' => 'You Are Subscribed', 'token' => $this->subscriptionData['token']]);
|
||||
->from(env('SHOP_MAIL_FROM'))
|
||||
->subject('subscription email')
|
||||
->view('shop::emails.customer.subscription-email')->with('data', ['content' => 'You Are Subscribed', 'token' => $this->subscriptionData['token']]);
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue