multiple invoices with one payment SDEV-421

This commit is contained in:
94924240Jeko!
2022-12-20 21:14:09 +03:00
commit c73e86e2cf
1700 changed files with 111993 additions and 0 deletions
@@ -0,0 +1,73 @@
<?php
namespace App\Classes\Modules\Transactions\DataTransferObjects;
use App\Classes\General\Interfaces\DataTransferObject;
class TransactionDetailObject implements DataTransferObject
{
/** @var string|null */
private $reference;
/** @var string|null */
private $name;
/** @var float|null */
private $quantity;
/** @var float|null */
private $price;
/**
* TransactionDetailObject constructor.
* @param string $reference
* @param string $name
* @param float $quantity
* @param float $price
*/
public function __construct(?string $reference, ?string $name , ?float $quantity, ?float $price)
{
$this->reference = $reference;
$this->name = $name;
$this->quantity = $quantity;
$this->price = $price;
}
/**
* @return string
*/
public function getReference(): ?string
{
return $this->reference;
}
/**
* @return string
*/
public function getName(): ?string
{
return $this->name;
}
/**
* @return float
*/
public function getQuantity(): ?float
{
return $this->quantity;
}
/**
* @return float
*/
public function getPrice(): ?float
{
return $this->price;
}
public function getAmount(): float
{
return $this->getQuantity() * $this->getPrice();
}
}