mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Ensure descriptions are translated
This commit is contained in:
parent
1185316beb
commit
3d36bcc0db
@ -32,6 +32,7 @@ use App\Utils\Traits\MakesHash;
|
|||||||
use App\Exceptions\PaymentFailed;
|
use App\Exceptions\PaymentFailed;
|
||||||
use App\Jobs\Mail\NinjaMailerJob;
|
use App\Jobs\Mail\NinjaMailerJob;
|
||||||
use App\Models\ClientGatewayToken;
|
use App\Models\ClientGatewayToken;
|
||||||
|
use Illuminate\Support\Facades\App;
|
||||||
use App\Jobs\Mail\NinjaMailerObject;
|
use App\Jobs\Mail\NinjaMailerObject;
|
||||||
use App\Utils\Traits\SystemLogTrait;
|
use App\Utils\Traits\SystemLogTrait;
|
||||||
use App\Events\Invoice\InvoiceWasPaid;
|
use App\Events\Invoice\InvoiceWasPaid;
|
||||||
@ -726,6 +727,11 @@ class BaseDriver extends AbstractPaymentDriver
|
|||||||
*/
|
*/
|
||||||
public function getDescription(bool $abbreviated = true)
|
public function getDescription(bool $abbreviated = true)
|
||||||
{
|
{
|
||||||
|
App::forgetInstance('translator');
|
||||||
|
$t = app('translator');
|
||||||
|
$t->replace(Ninja::transformTranslations($this->client->getMergedSettings()));
|
||||||
|
App::setLocale($this->client->company->locale());
|
||||||
|
|
||||||
if (! $this->payment_hash || !$this->client) {
|
if (! $this->payment_hash || !$this->client) {
|
||||||
return 'No description';
|
return 'No description';
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user