1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-21 08:51:34 +02:00
invoiceninja/app/Services/Email/EmailObject.php

123 lines
2.7 KiB
PHP
Raw Normal View History

2023-01-15 04:44:23 +01:00
<?php
/**
* Invoice Ninja (https://invoiceninja.com).
*
* @link https://github.com/invoiceninja/invoiceninja source repository
*
2023-01-28 23:21:40 +01:00
* @copyright Copyright (c) 2023. Invoice Ninja LLC (https://invoiceninja.com)
2023-01-15 04:44:23 +01:00
*
* @license https://www.elastic.co/licensing/elastic-license
*/
namespace App\Services\Email;
2023-03-06 09:07:25 +01:00
use App\Models\Client;
2023-03-18 08:24:56 +01:00
use App\Models\ClientContact;
use App\Models\Company;
2023-03-18 08:24:56 +01:00
use App\Models\Credit;
use App\Models\CreditInvitation;
2023-03-06 09:07:25 +01:00
use App\Models\Invoice;
2023-03-18 08:24:56 +01:00
use App\Models\InvoiceInvitation;
use App\Models\Payment;
2023-03-06 09:07:25 +01:00
use App\Models\PurchaseOrder;
2023-03-18 08:24:56 +01:00
use App\Models\PurchaseOrderInvitation;
use App\Models\Quote;
2023-03-06 09:07:25 +01:00
use App\Models\QuoteInvitation;
2023-03-18 08:24:56 +01:00
use App\Models\User;
use App\Models\Vendor;
use App\Models\VendorContact;
2023-01-15 04:44:23 +01:00
use Illuminate\Mail\Mailables\Address;
/**
* EmailObject.
*/
class EmailObject
{
/** @var array[string] $args */
2023-02-16 02:36:09 +01:00
public array $to = [];
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?Address $from = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public array $reply_to = [];
2023-01-15 04:44:23 +01:00
/** @var array[Address] $args */
2023-02-16 02:36:09 +01:00
public array $cc = [];
2023-01-15 04:44:23 +01:00
/** @var array[Address] $args */
2023-02-16 02:36:09 +01:00
public array $bcc = [];
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $subject = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $body = null;
2023-01-15 04:44:23 +01:00
/** @var array{key: value} $args */
2023-02-16 02:36:09 +01:00
public array $attachments = [];
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public string $company_key;
2023-01-15 04:44:23 +01:00
public Company $company;
2023-02-16 02:36:09 +01:00
public ?object $settings = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public bool $whitelabel = false;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $logo = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $signature = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $greeting = null;
2023-01-15 04:44:23 +01:00
2023-03-06 09:07:25 +01:00
public ?int $invitation_id = null;
public InvoiceInvitation | QuoteInvitation | CreditInvitation | PurchaseOrderInvitation | null $invitation;
public ?int $entity_id = null;
2023-01-15 04:44:23 +01:00
public Invoice | Quote | Credit | PurchaseOrder | Payment | null $entity;
2023-03-06 09:07:25 +01:00
public ?int $client_id = null;
public ?Client $client;
public ?int $vendor_id = null;
2023-01-15 04:44:23 +01:00
2023-03-06 09:07:25 +01:00
public ?Vendor $vendor;
2023-01-15 04:44:23 +01:00
2023-03-06 09:07:25 +01:00
public ?int $user_id = null;
2023-01-15 04:44:23 +01:00
2023-03-06 09:07:25 +01:00
public ?User $user;
public ?int $client_contact_id = null;
public ClientContact | VendorContact | null $contact;
public ?int $vendor_contact_id = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $email_template_body = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $email_template_subject = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $html_template = null;
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $text_template = 'email.template.text';
2023-01-15 04:44:23 +01:00
/** @var array{key: value} $args */
2023-02-16 02:36:09 +01:00
public array $headers = [];
2023-01-15 04:44:23 +01:00
2023-02-16 02:36:09 +01:00
public ?string $entity_class = null;
2023-01-15 04:44:23 +01:00
/** @var array{key: value} $args */
2023-02-16 02:36:09 +01:00
public array $variables = [];
2023-02-17 22:06:53 +01:00
2023-03-06 09:07:25 +01:00
public bool $override = false;
public ?string $invitation_key = null;
/** @var array[int] $args */
public array $documents = [];
2023-03-07 12:36:50 +01:00
public ?string $template = null; //invoice //quote //reminder1
2023-03-09 00:38:08 +01:00
public array $links = [];
2023-02-16 02:36:09 +01:00
}