Use translation strings
This commit is contained in:
parent
7df636515f
commit
f202817852
3 changed files with 10 additions and 8 deletions
|
@ -98,7 +98,7 @@ class CheckoutAssetMail extends Mailable
|
|||
'accept_url' => $accept_url,
|
||||
'last_checkout' => $this->last_checkout,
|
||||
'expected_checkin' => $this->expected_checkin,
|
||||
'opening_line' => $this->openingLine(),
|
||||
'introduction_line' => $this->introductionLine(),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
@ -119,21 +119,21 @@ class CheckoutAssetMail extends Mailable
|
|||
return trans('mail.Asset_Checkout_Notification');
|
||||
}
|
||||
|
||||
return 'Reminder: ' . trans('mail.unaccepted_asset_reminder');
|
||||
return trans('mail.unaccepted_asset_reminder');
|
||||
}
|
||||
|
||||
private function openingLine(): string
|
||||
private function introductionLine(): string
|
||||
{
|
||||
if ($this->firstTimeSending && $this->requiresAcceptance()) {
|
||||
return 'A new item has been checked out under your name that requires acceptance, details are below.';
|
||||
return trans('mail.new_item_checked_with_acceptance');
|
||||
}
|
||||
|
||||
if ($this->firstTimeSending && !$this->requiresAcceptance()) {
|
||||
return 'A new item has been checked out under your name, details are below.';
|
||||
return trans('mail.new_item_checked');
|
||||
}
|
||||
|
||||
if (!$this->firstTimeSending && $this->requiresAcceptance()) {
|
||||
return 'An item was recently checked out under your name that requires acceptance, details are below.';
|
||||
return trans('mail.recent_item_checked');
|
||||
}
|
||||
|
||||
// we shouldn't get here but let's send a default message just in case
|
||||
|
|
|
@ -66,6 +66,8 @@ return [
|
|||
'min_QTY' => 'Min QTY',
|
||||
'name' => 'Name',
|
||||
'new_item_checked' => 'A new item has been checked out under your name, details are below.',
|
||||
'new_item_checked_with_acceptance' => 'A new item has been checked out under your name that requires acceptance, details are below.',
|
||||
'recent_item_checked' => 'An item was recently checked out under your name that requires acceptance, details are below.',
|
||||
'notes' => 'Notes',
|
||||
'password' => 'Password',
|
||||
'password_reset' => 'Password Reset',
|
||||
|
@ -88,7 +90,7 @@ return [
|
|||
'upcoming-audits' => 'There is :count asset that is coming up for audit within :threshold days.|There are :count assets that are coming up for audit within :threshold days.',
|
||||
'user' => 'User',
|
||||
'username' => 'Username',
|
||||
'unaccepted_asset_reminder' => 'You have Unaccepted Assets.',
|
||||
'unaccepted_asset_reminder' => 'Reminder: You have Unaccepted Assets.',
|
||||
'welcome' => 'Welcome :name',
|
||||
'welcome_to' => 'Welcome to :web!',
|
||||
'your_assets' => 'View Your Assets',
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
@component('mail::message')
|
||||
# {{ trans('mail.hello') }} {{ $target->present()->fullName() }},
|
||||
|
||||
{{ $opening_line }}
|
||||
{{ $introduction_line }}
|
||||
|
||||
@if (($snipeSettings->show_images_in_email =='1') && $item->getImageUrl())
|
||||
<center><img src="{{ $item->getImageUrl() }}" alt="Asset" style="max-width: 570px;"></center>
|
||||
|
|
Loading…
Add table
Reference in a new issue