mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
app/Mail/MigrationFailed.php
This commit is contained in:
parent
32fc72913b
commit
e70effd404
@ -2,28 +2,27 @@
|
|||||||
|
|
||||||
namespace App\Mail;
|
namespace App\Mail;
|
||||||
|
|
||||||
use Illuminate\Bus\Queueable;
|
use App\Models\Company;
|
||||||
use Illuminate\Mail\Mailable;
|
use Illuminate\Mail\Mailable;
|
||||||
use Illuminate\Queue\SerializesModels;
|
|
||||||
|
|
||||||
class MigrationFailed extends Mailable
|
class MigrationFailed extends Mailable
|
||||||
{
|
{
|
||||||
|
|
||||||
public $exception;
|
public $exception;
|
||||||
|
|
||||||
public $content;
|
public $content;
|
||||||
public $settings;
|
|
||||||
public $company;
|
public $company;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a new message instance.
|
* Create a new message instance.
|
||||||
*
|
*
|
||||||
* @param $content
|
* @param $content
|
||||||
* @param $exception
|
* @param $exception
|
||||||
*/
|
*/
|
||||||
public function __construct($exception, $company, $content = null)
|
public function __construct($exception, Company $company, $content = null)
|
||||||
{
|
{
|
||||||
$this->exception = $exception;
|
$this->exception = $exception;
|
||||||
$this->content = $content;
|
$this->content = $content;
|
||||||
$this->settings = $company->settings;
|
|
||||||
$this->company = $company;
|
$this->company = $company;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -34,7 +33,11 @@ class MigrationFailed extends Mailable
|
|||||||
*/
|
*/
|
||||||
public function build()
|
public function build()
|
||||||
{
|
{
|
||||||
return $this->from(config('mail.from.address'), config('mail.from.name'))
|
return $this
|
||||||
->view('email.migration.failed', ['settings' => $this->settings, 'company' => $this->company]);
|
->from(config('mail.from.address'), config('mail.from.name'))
|
||||||
|
->view('email.migration.failed', [
|
||||||
|
'logo' => $this->company->present()->logo(),
|
||||||
|
'settings' => $this->company->settings,
|
||||||
|
]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -4259,6 +4259,8 @@ $LANG = array(
|
|||||||
'login_link_requested_label' => 'Login link requested',
|
'login_link_requested_label' => 'Login link requested',
|
||||||
'login_link_requested' => 'There was a request to login using link. If you did not request this, it\'s safe to ignore it.',
|
'login_link_requested' => 'There was a request to login using link. If you did not request this, it\'s safe to ignore it.',
|
||||||
'invoices_backup_subject' => 'Your invoices are ready for download',
|
'invoices_backup_subject' => 'Your invoices are ready for download',
|
||||||
|
'migration_failed_label' => 'Migration failed',
|
||||||
|
'migration_failed' => 'Looks like something went wrong with the migration for the following company:',
|
||||||
);
|
);
|
||||||
|
|
||||||
return $LANG;
|
return $LANG;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
@component('email.template.admin-light', ['logo' => 'https://www.invoiceninja.com/wp-content/uploads/2015/10/logo-white-horizontal-1.png', 'settings' => $settings])
|
@component('email.template.admin', ['logo' => $logo, 'settings' => $settings])
|
||||||
<div class="center">
|
<div class="center">
|
||||||
<h1>Whoops, migration failed for {{ $company->present()->name() }}.</h1>
|
<h1>{{ ctrans('texts.migration_failed_label') }}</h1>
|
||||||
<p>Looks like your migration failed. Here's the error message:</p>
|
<p>{{ ctrans('texts.migration_failed') }} {{ $company->present()->name() }}</p>
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
@if(\App\Utils\Ninja::isHosted())
|
@if(\App\Utils\Ninja::isHosted())
|
||||||
|
Loading…
x
Reference in New Issue
Block a user