src/Entity/CRM/Instalments.php line 11
<?phpnamespace App\Entity\CRM;use App\Entity\CRM\Order;use App\Repository\InstalmentsRepository;use Doctrine\DBAL\Types\Types;use Doctrine\ORM\Mapping as ORM;#[ORM\Entity(repositoryClass: InstalmentsRepository::class)]class Instalments{#[ORM\Id]#[ORM\GeneratedValue]#[ORM\Column]private ?int $id = null;#[ORM\Column]private ?float $amount = null;#[ORM\Column]private ?int $number = null;#[ORM\Column(type: Types::DATE_MUTABLE, nullable: true)]private ?\DateTimeInterface $paymentDate = null;#[ORM\Column(type: Types::DATE_MUTABLE, nullable: true)]private ?\DateTimeInterface $paymentTerm;#[ORM\Column(nullable: true)]private bool $paid = false;#[ORM\ManyToOne(inversedBy: 'instalments')]private ?Order $orderInstance = null;#[ORM\Column(length: 255, nullable: true)]private ?string $fv = null;#[ORM\Column]private float $administrationFee = 0;private string $instalmentNumberInRelationToInstalmentsCount;#[ORM\Column(type: Types::DATE_MUTABLE, nullable: true)]private ?\DateTimeInterface $dateAdded = null;#[ORM\Column]private bool $received = false;public function __construct(){$this->received = false;}public function getId(): ?int{return $this->id;}public function getNumber(): ?int{return $this->number;}public function setNumber(int $number): static{$this->number = $number;return $this;}public function getAmount(): ?float{return $this->amount;}public function setAmount(float $amount): static{$this->amount = $amount;return $this;}public function getPaymentDate(): ?\DateTimeInterface{return $this->paymentDate;}public function setPaymentDate(?\DateTimeInterface $paymentDate): static{$this->paymentDate = $paymentDate;return $this;}public function getPaymentTerm(): ?\DateTimeInterface{return $this->paymentTerm;}public function setPaymentTerm(?\DateTimeInterface $paymentTerm): static{$this->paymentTerm = $paymentTerm;return $this;}public function isPaid(): ?bool{return $this->paid;}public function setPaid(bool $paid): static{$this->paid = $paid;return $this;}public function getOrderInstance(): ?Order{return $this->orderInstance;}public function setOrderInstance(?Order $orderInstance): static{$this->orderInstance = $orderInstance;return $this;}public function getFv(): ?string{return $this->fv;}public function setFv(?string $fv): static{$this->fv = $fv;return $this;}public function getAdministrationFee(): float{return $this->administrationFee;}public function setAdministrationFee(float $administrationFee): static{$this->administrationFee = $administrationFee;return $this;}public function getInstalmentNumberInRelationToInstalmentsCount(): string{return $this->number . '/' . count($this->orderInstance->getInstalments());}public function getDateAdded(): ?\DateTimeInterface{return $this->dateAdded;}public function setDateAdded(?\DateTimeInterface $dateAdded): static{$this->dateAdded = $dateAdded;return $this;}public function isReceived(): bool{return $this->received;}public function setReceived(bool $received): static{$this->received = $received;return $this;}}