Zum Inhalt springen

API reference / Quittio \ Core \ Data \ Lines

Price

final readonly class in quittio/core · uses Immutable

Quittio\Core\Data\Lines\Price · Source

Price details (BG-29). Prices may have more than two decimals.

Note: BT-148 "item gross price" is the list price before the price discount, not a price including VAT. Prices including VAT are an input for the gross price mode ($priceInclVat) and are converted by the calculator.

Properties#

PropertyTypeDescription
$baseQuantity readonly?Brick\Math\BigDecimal
$baseQuantityUnit readonlyUnitCode|RawCode|null
$discount readonly?Brick\Math\BigDecimal
$grossPrice readonly?Brick\Math\BigDecimal
$netPrice readonly?Brick\Math\BigDecimal
$priceInclVat readonly?Brick\Math\BigDecimal

Methods#

MethodDescription
->__construct()
->isGrossMode()
->with()Returns a copy with the given properties replaced.

__construct()#

public function __construct(
    ?BigDecimal $netPrice,
    ?BigDecimal $discount = null,
    ?BigDecimal $grossPrice = null,
    ?BigDecimal $baseQuantity = null,
    UnitCode|RawCode|null $baseQuantityUnit = null,
    ?BigDecimal $priceInclVat = null,
)
ParameterTypeDescription
$netPrice?Brick\Math\BigDecimal
$discount?Brick\Math\BigDecimal = null
$grossPrice?Brick\Math\BigDecimal = null
$baseQuantity?Brick\Math\BigDecimal = null
$baseQuantityUnitUnitCode|RawCode|null = null
$priceInclVat?Brick\Math\BigDecimal = null

isGrossMode()#

public function isGrossMode(): bool
Returns
bool

with()#

public function with(array<string, mixed> $changes): static

Returns a copy with the given properties replaced.

ParameterTypeDescription
$changesarray<string, mixed>
Returns
static

Die Open-Core-Pakete stehen unter der MIT-Lizenz. Die rechtlichen Formulierungen der Länderpakete sind mit einer Steuerberatung abzustimmen.