mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-07 18:44:28 -04:00
app/Mail/Gateways/ACHVerificationNotification.php
This commit is contained in:
parent
d3fcb77e49
commit
ae66496711
@ -12,23 +12,27 @@
|
|||||||
|
|
||||||
namespace App\Mail\Gateways;
|
namespace App\Mail\Gateways;
|
||||||
|
|
||||||
use Illuminate\Bus\Queueable;
|
use App\Models\Company;
|
||||||
use Illuminate\Contracts\Queue\ShouldQueue;
|
|
||||||
use Illuminate\Mail\Mailable;
|
use Illuminate\Mail\Mailable;
|
||||||
use Illuminate\Queue\SerializesModels;
|
use Illuminate\Queue\SerializesModels;
|
||||||
|
|
||||||
class ACHVerificationNotification extends Mailable
|
class ACHVerificationNotification extends Mailable
|
||||||
{
|
{
|
||||||
use Queueable, SerializesModels;
|
use SerializesModels;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var Company
|
||||||
|
*/
|
||||||
|
public $company;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a new message instance.
|
* Create a new message instance.
|
||||||
*
|
*
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function __construct()
|
public function __construct(Company $company)
|
||||||
{
|
{
|
||||||
//
|
$this->company = $company;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -38,6 +42,11 @@ class ACHVerificationNotification extends Mailable
|
|||||||
*/
|
*/
|
||||||
public function build()
|
public function build()
|
||||||
{
|
{
|
||||||
return $this->view('email.gateways.ach-verification-notification');
|
return $this
|
||||||
|
->subject(ctrans('texts.ach_verification_notification_label'))
|
||||||
|
->view('email.gateways.ach-verification-notification', [
|
||||||
|
'logo' => $this->company->present()->logo(),
|
||||||
|
'settings' => $this->company->settings,
|
||||||
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -67,12 +67,12 @@ class ACH
|
|||||||
$client_gateway_token = $this->storePaymentMethod($source, $request->input('method'), $customer);
|
$client_gateway_token = $this->storePaymentMethod($source, $request->input('method'), $customer);
|
||||||
|
|
||||||
$mailer = new NinjaMailerObject();
|
$mailer = new NinjaMailerObject();
|
||||||
$mailer->mailable = new ACHVerificationNotification();
|
$mailer->mailable = new ACHVerificationNotification(auth('contact')->user()->client->company);
|
||||||
$mailer->company = auth('contact')->user()->client->company;
|
$mailer->company = auth('contact')->user()->client->company;
|
||||||
$mailer->settings = auth('contact')->user()->client->company->settings;
|
$mailer->settings = auth('contact')->user()->client->company->settings;
|
||||||
$mailer->to_user = auth('contact')->user();
|
$mailer->to_user = auth('contact')->user();
|
||||||
|
|
||||||
NinjaMailerJob::dispatchNow($mailer);
|
NinjaMailerJob::dispatch($mailer);
|
||||||
|
|
||||||
return redirect()->route('client.payment_methods.verification', ['payment_method' => $client_gateway_token->hashed_id, 'method' => GatewayType::BANK_TRANSFER]);
|
return redirect()->route('client.payment_methods.verification', ['payment_method' => $client_gateway_token->hashed_id, 'method' => GatewayType::BANK_TRANSFER]);
|
||||||
}
|
}
|
||||||
|
@ -4254,6 +4254,8 @@ $LANG = array(
|
|||||||
'account_passwordless_login' => 'Account passwordless login',
|
'account_passwordless_login' => 'Account passwordless login',
|
||||||
'user_duplicate_error' => 'Cannot add the same user to the same company',
|
'user_duplicate_error' => 'Cannot add the same user to the same company',
|
||||||
'user_cross_linked_error' => 'User exists but cannot be crossed linked to multiple accounts',
|
'user_cross_linked_error' => 'User exists but cannot be crossed linked to multiple accounts',
|
||||||
|
'ach_verification_notification_label' => 'ACH verification',
|
||||||
|
'ach_verification_notification' => 'Connecting bank accounts require verification. Stripe will automatically sends two small deposits for this purpose. These deposits take 1-2 business days to appear on the customer\'s online statement.'
|
||||||
);
|
);
|
||||||
|
|
||||||
return $LANG;
|
return $LANG;
|
||||||
|
@ -1,14 +1,6 @@
|
|||||||
@component('email.template.master', ['design' => 'light'])
|
@component('email.template.admin', ['logo' => $logo, 'settings' => $settings])
|
||||||
@slot('header')
|
<div class="center">
|
||||||
@include('email.components.header', ['logo' => 'https://www.invoiceninja.com/wp-content/uploads/2015/10/logo-white-horizontal-1.png'])
|
<h1>{{ ctrans('texts.ach_verification_notification_label') }}</h1>
|
||||||
@endslot
|
<p>{{ ctrans('texts.ach_verification_notification') }}</p>
|
||||||
|
</div>
|
||||||
<p>Hello,</p>
|
|
||||||
|
|
||||||
<p>Connecting bank accounts require verification. Stripe will automatically sends two
|
|
||||||
small deposits for this purpose. These deposits take 1-2 business days to appear on the customer's online
|
|
||||||
statement.
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>Thank you!</p>
|
|
||||||
@endcomponent
|
@endcomponent
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
supported-color-schemes: light dark;
|
supported-color-schemes: light dark;
|
||||||
}
|
}
|
||||||
|
|
||||||
@if($settings->email_style === 'dark')
|
@if(isset($settings) && $settings->email_style === 'dark')
|
||||||
body,
|
body,
|
||||||
[data-ogsc] {
|
[data-ogsc] {
|
||||||
background-color: #1a1a1a !important;
|
background-color: #1a1a1a !important;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user