src/Entity/CustomerInvoiceSettings.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\CustomerInvoiceSettingsRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. #[ORM\Entity(repositoryClassCustomerInvoiceSettingsRepository::class)]
  8. class CustomerInvoiceSettings
  9. {
  10.     #[ORM\Id]
  11.     #[ORM\GeneratedValue]
  12.     #[ORM\Column]
  13.     private ?int $id null;
  14.     #[ORM\Column(length10nullabletrue)]
  15.     private ?string $token null;
  16.     #[ORM\Column(length10nullabletrue)]
  17.     private ?string $freeField null;
  18.     #[ORM\Column(nullabletrue)]
  19.     private ?int $nextValue null;
  20.     #[ORM\Column]
  21.     private ?int $minLength null;
  22.     #[ORM\Column]
  23.     private ?int $taxRate null;
  24.     #[ORM\Column]
  25.     private ?int $invoiceDue null;
  26.     #[ORM\Column]
  27.     private bool $automaticSend;
  28.     #[ORM\Column]
  29.     private ?int $paymentTermInDays null;
  30.     #[ORM\JoinTable(name'customer_settings_invoice_interval')]
  31.     #[ORM\JoinColumn(name'customer_settings_id'referencedColumnName'id')]
  32.     #[ORM\InverseJoinColumn(name'invoice_interval_id'referencedColumnName'id')]
  33.     #[ORM\ManyToMany(targetEntityInvoiceInterval::class, inversedBy'customerInvoiceSettings')]
  34.     private Collection $invoiceIntervals;
  35.     public function __construct()
  36.     {
  37.         $this->invoiceIntervals = new ArrayCollection();
  38.     }
  39.     public function getId(): ?int
  40.     {
  41.         return $this->id;
  42.     }
  43.     public function getToken(): ?string
  44.     {
  45.         return $this->token;
  46.     }
  47.     public function setToken(?string $token): self
  48.     {
  49.         $this->token $token;
  50.         return $this;
  51.     }
  52.     public function getFreeField(): ?string
  53.     {
  54.         return $this->freeField;
  55.     }
  56.     public function setFreeField(?string $freeField): self
  57.     {
  58.         $this->freeField $freeField;
  59.         return $this;
  60.     }
  61.     public function getNextValue(): ?int
  62.     {
  63.         return $this->nextValue;
  64.     }
  65.     public function setNextValue(?int $nextValue): self
  66.     {
  67.         $this->nextValue $nextValue;
  68.         return $this;
  69.     }
  70.     public function getMinLength(): ?int
  71.     {
  72.         return $this->minLength;
  73.     }
  74.     public function setMinLength(int $minLength): self
  75.     {
  76.         $this->minLength $minLength;
  77.         return $this;
  78.     }
  79.     public function getTaxRate(): ?int
  80.     {
  81.         return $this->taxRate;
  82.     }
  83.     public function setTaxRate(int $taxRate): self
  84.     {
  85.         $this->taxRate $taxRate;
  86.         return $this;
  87.     }
  88.     public function getInvoiceDue(): ?int
  89.     {
  90.         return $this->invoiceDue;
  91.     }
  92.     public function setInvoiceDue(int $invoiceDue): self
  93.     {
  94.         $this->invoiceDue $invoiceDue;
  95.         return $this;
  96.     }
  97.     public function isAutomaticSend(): ?bool
  98.     {
  99.         return $this->automaticSend;
  100.     }
  101.     public function setAutomaticSend(bool $automaticSend): self
  102.     {
  103.         $this->automaticSend $automaticSend;
  104.         return $this;
  105.     }
  106.     /**
  107.      * @return Collection<int, InvoiceInterval>
  108.      */
  109.     public function getInvoiceIntervals(): Collection
  110.     {
  111.         return $this->invoiceIntervals;
  112.     }
  113.     public function addInvoiceInterval(InvoiceInterval $invoiceInterval): self
  114.     {
  115.         if (!$this->invoiceIntervals->contains($invoiceInterval)) {
  116.             $this->invoiceIntervals->add($invoiceInterval);
  117.         }
  118.         return $this;
  119.     }
  120.     public function removeInvoiceInterval(InvoiceInterval $invoiceInterval): self
  121.     {
  122.         $this->invoiceIntervals->removeElement($invoiceInterval);
  123.         return $this;
  124.     }
  125.     public function getPaymentTermInDays(): ?int
  126.     {
  127.         return $this->paymentTermInDays;
  128.     }
  129.     public function setPaymentTermInDays(int $paymentTermInDays): self
  130.     {
  131.         $this->paymentTermInDays $paymentTermInDays;
  132.         return $this;
  133.     }
  134. }