src/Entity/Paiement.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\PaiementRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use App\Entity\Abonnement;
  6. /**
  7.  * @ORM\Entity(repositoryClass=PaiementRepository::class)
  8.  */
  9. class Paiement
  10. {
  11.     /**
  12.      * @ORM\Id
  13.      * @ORM\GeneratedValue
  14.      * @ORM\Column(type="integer")
  15.      */
  16.     private $id;
  17.     /**
  18.      * @ORM\Column(type="string", length=255, nullable=true)
  19.      */
  20.     private $value;
  21.     /**
  22.      * @ORM\Column(type="string", length=255)
  23.      */
  24.     private $payinId;
  25.     /**
  26.      * @ORM\ManyToOne(targetEntity=Abonnement::class, inversedBy="paiements")
  27.      * @ORM\JoinColumn(nullable=true)
  28.      */
  29.     private $abonnement;
  30.     /**
  31.      * @ORM\Column(type="datetime_immutable", options={"default"="CURRENT_TIMESTAMP"})
  32.      */
  33.     private $createdAt;
  34.     /**
  35.      * @ORM\Column(type="string", length=255, nullable=true)
  36.      */
  37.     private $stripeInvoiceID;
  38.     /**
  39.      * @ORM\Column(type="integer", nullable=true)
  40.      */
  41.     private $stripeAmountPaid;
  42.     /**
  43.      * @ORM\Column(type="string", length=255, nullable=true)
  44.      */
  45.     private $stripeNumber;
  46.     /**
  47.      * @ORM\Column(type="string", length=255)
  48.      */
  49.     private $hostedInvoiceUrl;
  50.     /**
  51.      * @ORM\Column(type="boolean", options={"default": true})
  52.      */
  53.     private $paid;
  54.     /**
  55.      * @ORM\ManyToOne(targetEntity=Location::class, inversedBy="paiements")
  56.      */
  57.     private $location;
  58.     /**
  59.      * @ORM\ManyToOne(targetEntity=Reservation::class, inversedBy="paiements")
  60.      */
  61.     private $reservation;
  62.     /**
  63.      * @ORM\ManyToOne(targetEntity=Command::class, inversedBy="paiements")
  64.      */
  65.     private $command;
  66.     public function __construct()
  67.     {
  68.         $this->createdAt = new \DateTimeImmutable();
  69.     }
  70.     public function getId(): ?int
  71.     {
  72.         return $this->id;
  73.     }
  74.     public function getValue(): ?string
  75.     {
  76.         return $this->value;
  77.     }
  78.     public function setValue(?string $value): self
  79.     {
  80.         $this->value $value;
  81.         return $this;
  82.     }
  83.     public function getPayinId(): ?string
  84.     {
  85.         return $this->payinId;
  86.     }
  87.     public function setPayinId(string $payinId): self
  88.     {
  89.         $this->payinId $payinId;
  90.         return $this;
  91.     }
  92.     public function getAbonnement(): ?Abonnement
  93.     {
  94.         return $this->abonnement;
  95.     }
  96.     public function setAbonnement(?Abonnement $abonnement): self
  97.     {
  98.         $this->abonnement $abonnement;
  99.         return $this;
  100.     }
  101.     public function getCreatedAt(): ?\DateTimeImmutable
  102.     {
  103.         return $this->createdAt;
  104.     }
  105.     public function setCreatedAt(\DateTimeImmutable $createdAt): self
  106.     {
  107.         $this->createdAt $createdAt;
  108.         return $this;
  109.     }
  110.     public function getStripeInvoiceID(): ?string
  111.     {
  112.         return $this->stripeInvoiceID;
  113.     }
  114.     public function setStripeInvoiceID(?string $stripeInvoiceID): self
  115.     {
  116.         $this->stripeInvoiceID $stripeInvoiceID;
  117.         return $this;
  118.     }
  119.     public function getStripeAmountPaid(): ?int
  120.     {
  121.         return $this->stripeAmountPaid;
  122.     }
  123.     public function setStripeAmountPaid(?int $stripeAmountPaid): self
  124.     {
  125.         $this->stripeAmountPaid $stripeAmountPaid;
  126.         return $this;
  127.     }
  128.     public function getStripeNumber(): ?string
  129.     {
  130.         return $this->stripeNumber;
  131.     }
  132.     public function setStripeNumber(?string $stripeNumber): self
  133.     {
  134.         $this->stripeNumber $stripeNumber;
  135.         return $this;
  136.     }
  137.     public function getHostedInvoiceUrl(): ?string
  138.     {
  139.         return $this->hostedInvoiceUrl;
  140.     }
  141.     public function setHostedInvoiceUrl(string $hostedInvoiceUrl): self
  142.     {
  143.         $this->hostedInvoiceUrl $hostedInvoiceUrl;
  144.         return $this;
  145.     }
  146.     public function isPaid(): ?bool
  147.     {
  148.         return $this->paid;
  149.     }
  150.     public function setPaid(bool $paid): self
  151.     {
  152.         $this->paid $paid;
  153.         return $this;
  154.     }
  155.     public function getLocation(): ?Location
  156.     {
  157.         return $this->location;
  158.     }
  159.     public function setLocation(?Location $location): self
  160.     {
  161.         $this->location $location;
  162.         return $this;
  163.     }
  164.     public function getReservation(): ?Reservation
  165.     {
  166.         return $this->reservation;
  167.     }
  168.     public function setReservation(?Reservation $reservation): self
  169.     {
  170.         $this->reservation $reservation;
  171.         return $this;
  172.     }
  173.     public function getCommand(): ?Command
  174.     {
  175.         return $this->command;
  176.     }
  177.     public function setCommand(?Command $command): self
  178.     {
  179.         $this->command $command;
  180.         return $this;
  181.     }
  182. }