TaxSnapshotTrait
Tax snapshot: the lean column set of the VAT engine.
The columns have the same names on the payment (cms_system_payments) and the invoice
(cms_mod_invoicer_invoices), so the invoice generator copies them 1:1. The snapshot is not
recomputed after creation: what the customer saw at payment is what the invoice shows.
A null tax_treatment marks a record from before the engine (legacy).
IMPORTANT: all fields are #[ExternalReadonly]. The engine determines them on the server
(payment form through the internal bridge, invoice generator); an external Api client must
not write them.
Table of Contents
Properties
- $customerVatIdCheckId : int|null
- Applied VAT id check (`cms_system_vat_id_checks`): consultation number or manual proof.
- $customerVatIdOutageCheckId : int|null
- Record of a VIES outage on the supply date.
- $customerVatIdVerified : bool|null
- Null means the VAT id does not matter (empty or domestic); false is unverified; true is verified.
- $customerVatIdVerifiedAt : DateTime|null
- $summaryReportCode : string|null
- Supply code for the summary report (`3` services, `0` goods); null means it is not reported.
- $taxCountryCode : string|null
- Country of the applied rate (null without VAT).
- $taxDate : DateTime|null
- Date of the rate and of the seller status.
- $taxFlags : array<int, string>|null
- $taxNote : string|null
- Note in the document language (plus Czech), resolved at creation.
- $taxTreatment : string|null
- Treatment code; on a payment also the markers `INTERMEDIARY` and `CREDIT_REDEMPTION`.
Methods
- getCustomerVatIdCheckId() : int|null
- getCustomerVatIdOutageCheckId() : int|null
- getCustomerVatIdVerified() : bool|null
- getCustomerVatIdVerifiedAt() : DateTime|null
- getSummaryReportCode() : string|null
- getTaxCountryCode() : string|null
- getTaxDate() : DateTime|null
- getTaxFlags() : array<int, string>|null
- getTaxNote() : string|null
- getTaxTreatment() : string|null
- hasTaxFlag() : bool
- setCustomerVatIdCheckId() : static
- setCustomerVatIdOutageCheckId() : static
- setCustomerVatIdVerified() : static
- setCustomerVatIdVerifiedAt() : static
- setSummaryReportCode() : static
- setTaxCountryCode() : static
- setTaxDate() : static
- setTaxFlags() : static
- setTaxNote() : static
- setTaxTreatment() : static
Properties
$customerVatIdCheckId
Applied VAT id check (`cms_system_vat_id_checks`): consultation number or manual proof.
protected
int|null
$customerVatIdCheckId
= null
Attributes
- #[Column]
- $name: 'customer_vat_id_check_id'
- $type: 'integer'
- $nullable: true
- $options: ['unsigned' => true]
$customerVatIdOutageCheckId
Record of a VIES outage on the supply date.
protected
int|null
$customerVatIdOutageCheckId
= null
Attributes
- #[Column]
- $name: 'customer_vat_id_outage_check_id'
- $type: 'integer'
- $nullable: true
- $options: ['unsigned' => true]
$customerVatIdVerified
Null means the VAT id does not matter (empty or domestic); false is unverified; true is verified.
protected
bool|null
$customerVatIdVerified
= null
Attributes
- #[Column]
- $name: 'customer_vat_id_verified'
- $type: 'boolean'
- $nullable: true
$customerVatIdVerifiedAt
protected
DateTime|null
$customerVatIdVerifiedAt
= null
Attributes
- #[Column]
- $name: 'customer_vat_id_verified_at'
- $type: 'datetime'
- $nullable: true
$summaryReportCode
Supply code for the summary report (`3` services, `0` goods); null means it is not reported.
protected
string|null
$summaryReportCode
= null
Attributes
- #[Column]
- $name: 'summary_report_code'
- $type: 'string'
- $length: 1
- $nullable: true
- $options: ['fixed' => true]
$taxCountryCode
Country of the applied rate (null without VAT).
protected
string|null
$taxCountryCode
= null
Attributes
- #[Column]
- $name: 'tax_country_code'
- $type: 'string'
- $length: 2
- $nullable: true
- $options: ['fixed' => true]
$taxDate
Date of the rate and of the seller status.
protected
DateTime|null
$taxDate
= null
Attributes
- #[Column]
- $name: 'tax_date'
- $type: 'date'
- $nullable: true
$taxFlags
protected
array<int, string>|null
$taxFlags
= null
TaxFlag codes
Attributes
- #[Column]
- $name: 'tax_flags'
- $type: 'json'
- $nullable: true
$taxNote
Note in the document language (plus Czech), resolved at creation.
protected
string|null
$taxNote
= null
Attributes
- #[Column]
- $name: 'tax_note'
- $type: 'text'
- $nullable: true
$taxTreatment
Treatment code; on a payment also the markers `INTERMEDIARY` and `CREDIT_REDEMPTION`.
protected
string|null
$taxTreatment
= null
Attributes
- #[Column]
- $name: 'tax_treatment'
- $type: 'string'
- $length: 24
- $nullable: true
Methods
getCustomerVatIdCheckId()
public
getCustomerVatIdCheckId() : int|null
Return values
int|nullgetCustomerVatIdOutageCheckId()
public
getCustomerVatIdOutageCheckId() : int|null
Return values
int|nullgetCustomerVatIdVerified()
public
getCustomerVatIdVerified() : bool|null
Return values
bool|nullgetCustomerVatIdVerifiedAt()
public
getCustomerVatIdVerifiedAt() : DateTime|null
Return values
DateTime|nullgetSummaryReportCode()
public
getSummaryReportCode() : string|null
Return values
string|nullgetTaxCountryCode()
public
getTaxCountryCode() : string|null
Return values
string|nullgetTaxDate()
public
getTaxDate() : DateTime|null
Return values
DateTime|nullgetTaxFlags()
public
getTaxFlags() : array<int, string>|null
Return values
array<int, string>|nullgetTaxNote()
public
getTaxNote() : string|null
Return values
string|nullgetTaxTreatment()
public
getTaxTreatment() : string|null
Return values
string|nullhasTaxFlag()
public
hasTaxFlag(string $flag) : bool
Parameters
- $flag : string
Return values
boolsetCustomerVatIdCheckId()
public
setCustomerVatIdCheckId(int|null $customerVatIdCheckId) : static
Parameters
- $customerVatIdCheckId : int|null
Return values
staticsetCustomerVatIdOutageCheckId()
public
setCustomerVatIdOutageCheckId(int|null $customerVatIdOutageCheckId) : static
Parameters
- $customerVatIdOutageCheckId : int|null
Return values
staticsetCustomerVatIdVerified()
public
setCustomerVatIdVerified(bool|null $customerVatIdVerified) : static
Parameters
- $customerVatIdVerified : bool|null
Return values
staticsetCustomerVatIdVerifiedAt()
public
setCustomerVatIdVerifiedAt(DateTime|null $customerVatIdVerifiedAt) : static
Parameters
- $customerVatIdVerifiedAt : DateTime|null
Return values
staticsetSummaryReportCode()
public
setSummaryReportCode(string|null $summaryReportCode) : static
Parameters
- $summaryReportCode : string|null
Return values
staticsetTaxCountryCode()
public
setTaxCountryCode(string|null $taxCountryCode) : static
Parameters
- $taxCountryCode : string|null
Return values
staticsetTaxDate()
public
setTaxDate(DateTime|null $taxDate) : static
Parameters
- $taxDate : DateTime|null
Return values
staticsetTaxFlags()
public
setTaxFlags(array<int, string>|null $taxFlags) : static
Parameters
- $taxFlags : array<int, string>|null
Return values
staticsetTaxNote()
public
setTaxNote(string|null $taxNote) : static
Parameters
- $taxNote : string|null
Return values
staticsetTaxTreatment()
public
setTaxTreatment(string|null $taxTreatment) : static
Parameters
- $taxTreatment : string|null