mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2026-01-05 08:00:51 -05:00
* Working on emailing invoices * Working on emailing and displaying email * Working on emailing and displaying email * Email invoices * Fixes for html emails * Ensure valid client prior to store * Ensure client exists when storing an entity * Update variable name send -> send_email for client_contacts * Mailable download files * Extend timeouts of password protected routes when a protected route is hit * Add default portal design to company settings * Minor fixes * Fixes for Tests * Fixes for invoicing emails * Refactors for InvoiceEmail * Implement abstractservice * Refactors for services * Refactors for emails * Fixes for Invoice Emails
37 lines
811 B
PHP
37 lines
811 B
PHP
<?php
|
|
|
|
namespace App\Mail;
|
|
|
|
use App\Utils\Ninja;
|
|
use Illuminate\Bus\Queueable;
|
|
use Illuminate\Contracts\Queue\ShouldQueue;
|
|
use Illuminate\Mail\Mailable;
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
class DownloadInvoices extends Mailable
|
|
{
|
|
use Queueable, SerializesModels;
|
|
|
|
public $file_path;
|
|
|
|
public function __construct($file_path)
|
|
{
|
|
$this->file_path = $file_path;
|
|
}
|
|
|
|
/**
|
|
* Build the message.
|
|
*
|
|
* @return $this
|
|
*/
|
|
public function build()
|
|
{
|
|
|
|
return $this->from(config('mail.from.address')) //todo this needs to be fixed to handle the hosted version
|
|
->subject(ctrans('texts.download_documents',['size'=>'']))
|
|
->markdown('email.admin.download_files', [
|
|
'file_path' => $this->file_path
|
|
]);
|
|
}
|
|
}
|