src/Entity/BankInfo.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\Common\Collections\ArrayCollection;
  4. use Doctrine\Common\Collections\Collection;
  5. use Doctrine\ORM\Mapping as ORM;
  6. /**
  7.  * @ORM\Entity(repositoryClass="App\Repository\InfoBancaireRepository")
  8.  */
  9. class BankInfo
  10. {
  11.     /**
  12.      * @ORM\Id()
  13.      * @ORM\GeneratedValue()
  14.      * @ORM\Column(type="integer")
  15.      */
  16.     private $id;
  17.     /**
  18.      * @ORM\Column(type="bigint", nullable=true)
  19.      */
  20.     private $idMangopay;
  21.     /**
  22.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayCard", mappedBy="idBankUser", cascade={"persist", "remove"})
  23.      */
  24.     private $mangopayCards;
  25.     /**
  26.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayBankaccount", mappedBy="idBankInfo", cascade={"persist", "remove"})
  27.      */
  28.     private $mangopayBankaccounts;
  29.     /**
  30.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayWallet", mappedBy="idBankInfo", cascade={"persist", "remove"})
  31.      */
  32.     private $mangopayWallets;
  33.     /**
  34.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayKycDocument", mappedBy="idBankInfo", cascade={"persist", "remove"})
  35.      */
  36.     private $mangopayKycDocuments;
  37.     /**
  38.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayUboDeclaration", mappedBy="idBankInfo", cascade={"persist", "remove"})
  39.      */
  40.     private $mangopayUboDeclarations;
  41.     /**
  42.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayRepudiation", mappedBy="idBankInfo", cascade={"persist", "remove"})
  43.      */
  44.     private $mangopayRepudiations;
  45.     /**
  46.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayTransfer", mappedBy="idBankInfo", cascade={"persist", "remove"})
  47.      */
  48.     private $mangopayTransfers;
  49.     /**
  50.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayPayin", mappedBy="idPayer", cascade={"persist", "remove"})
  51.      */
  52.     private $mangopayPayerPayins;
  53.     /**
  54.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayPayin", mappedBy="idCollector", cascade={"persist", "remove"})
  55.      */
  56.     private $mangopayCollectorPayins;
  57.     /**
  58.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayPayout", mappedBy="idBankInfo", cascade={"persist", "remove"})
  59.      */
  60.     private $mangopayPayouts;
  61.     /**
  62.      * @ORM\OneToMany(targetEntity="App\Entity\MangopayRefund", mappedBy="idBankInfo", cascade={"persist", "remove"})
  63.      */
  64.     private $mangopayRefunds;
  65.     
  66.     
  67.     private $cardName;
  68.     private $cardNumber;
  69.     private $cardExpirateDay;
  70.     private $cvsKey;
  71.     private $bankIdentifierCode;
  72.     private $internationalBankAccountNumber;
  73.     private $bankAdress;
  74.     private $bankCity;
  75.     private $bankPostalCode;
  76.     private $bankCountry;
  77.     /**
  78.      * @ORM\OneToOne(targetEntity="App\Entity\User", cascade={"persist", "remove"})
  79.      */
  80.     private $user;
  81.     /**
  82.      * @ORM\OneToMany(targetEntity="App\Entity\KycFile", mappedBy="idUser")
  83.      */
  84.     private $kycFiles;
  85.     public function __construct()
  86.     {
  87.         $this->mangopayCards = new ArrayCollection();
  88.         $this->mangopayBankaccounts = new ArrayCollection();
  89.         $this->mangopayWallets = new ArrayCollection();
  90.         $this->mangopayKycDocuments = new ArrayCollection();
  91.         $this->mangopayUboDeclarations = new ArrayCollection();
  92.         $this->mangopayRepudiations = new ArrayCollection();
  93.         $this->mangopayTransfers = new ArrayCollection();
  94.         $this->mangopayPayerPayins = new ArrayCollection();
  95.         $this->mangopayCollectorPayins = new ArrayCollection();
  96.         $this->mangopayPayouts = new ArrayCollection();
  97.         $this->mangopayRefunds = new ArrayCollection();
  98.         $this->kycFiles = new ArrayCollection();
  99.     }
  100.     
  101.     public function getId(): ?int
  102.     {
  103.         return $this->id;
  104.     }
  105.     public function getIdMangopay()
  106.     {
  107.         return $this->idMangopay;
  108.     }
  109.     public function setIdMangopay($idMangopay): self
  110.     {
  111.         $this->idMangopay $idMangopay;
  112.         return $this;
  113.     }
  114.     public function getCardName(): ?string
  115.     {
  116.         return $this->cardName;
  117.     }
  118.     public function setCardName(string $cardName): self
  119.     {
  120.         $this->cardName $cardName;
  121.         return $this;
  122.     }
  123.     public function getCardNumber(): ?string
  124.     {
  125.         return $this->cardNumber;
  126.     }
  127.     public function setCardNumber(?string $cardNumber): self
  128.     {
  129.         $this->cardNumber $cardNumber;
  130.         return $this;
  131.     }
  132.     public function getCardExpirateDay(): ?\DateTimeInterface
  133.     {
  134.         return $this->cardExpirateDay;
  135.     }
  136.     public function setCardExpirateDay(?\DateTimeInterface $cardExpirateDay): self
  137.     {
  138.         $this->cardExpirateDay $cardExpirateDay;
  139.         return $this;
  140.     }
  141.     public function getCvsKey(): ?int
  142.     {
  143.         return $this->cvsKey;
  144.     }
  145.     public function setCvsKey(?int $cvsKey): self
  146.     {
  147.         $this->cvsKey $cvsKey;
  148.         return $this;
  149.     }
  150.     public function getBankIdentifierCode(): ?string
  151.     {
  152.         return $this->bankIdentifierCode;
  153.     }
  154.     public function setBankIdentifierCode(?string $bankIdentifierCode): self
  155.     {
  156.         $this->bankIdentifierCode $bankIdentifierCode;
  157.         return $this;
  158.     }
  159.     public function getInternationalBankAccountNumber(): ?string
  160.     {
  161.         return $this->internationalBankAccountNumber;
  162.     }
  163.     public function setInternationalBankAccountNumber(?string $internationalBankAccountNumber): self
  164.     {
  165.         $this->internationalBankAccountNumber $internationalBankAccountNumber;
  166.         return $this;
  167.     }
  168.     
  169.     public function getBankAdress(): ?string
  170.     {
  171.         return $this->bankAdress;
  172.     }
  173.     public function setBankAdress(?string $bankAdress): self
  174.     {
  175.         $this->bankAdress $bankAdress;
  176.         return $this;
  177.     }
  178.     public function getBankCity(): ?string
  179.     {
  180.         return $this->bankCity;
  181.     }
  182.     public function setBankCity(?string $bankCity): self
  183.     {
  184.         $this->bankCity $bankCity;
  185.         return $this;
  186.     }
  187.     public function getBankPostalCode(): ?int
  188.     {
  189.         return $this->bankPostalCode;
  190.     }
  191.     public function setBankPostalCode(?int $bankPostalCode): self
  192.     {
  193.         $this->bankPostalCode $bankPostalCode;
  194.         return $this;
  195.     }
  196.     public function getBankCountry(): ?string
  197.     {
  198.         return $this->bankCountry;
  199.     }
  200.     public function setBankCountry(?string $bankCountry): self
  201.     {
  202.         $this->bankCountry $bankCountry;
  203.         return $this;
  204.     }
  205.     /**
  206.      * @return Collection|MangopayCard[]
  207.      */
  208.     public function getMangopayCards(): Collection
  209.     {
  210.         return $this->mangopayCards;
  211.     }
  212.     public function addMangopayCard(MangopayCard $mangopayCard): self
  213.     {
  214.         if (!$this->mangopayCards->contains($mangopayCard)) {
  215.             $this->mangopayCards[] = $mangopayCard;
  216.             $mangopayCard->setIdBankUser($this);
  217.         }
  218.         return $this;
  219.     }
  220.     public function removeMangopayCard(MangopayCard $mangopayCard): self
  221.     {
  222.         if ($this->mangopayCards->contains($mangopayCard)) {
  223.             $this->mangopayCards->removeElement($mangopayCard);
  224.             // set the owning side to null (unless already changed)
  225.             if ($mangopayCard->getIdBankUser() === $this) {
  226.                 $mangopayCard->setIdBankUser(null);
  227.             }
  228.         }
  229.         return $this;
  230.     }
  231.     /**
  232.      * @return Collection|MangopayBankaccount[]
  233.      */
  234.     public function getMangopayBankaccounts(): Collection
  235.     {
  236.         return $this->mangopayBankaccounts;
  237.     }
  238.     public function addMangopayBankaccount(MangopayBankaccount $mangopayBankaccount): self
  239.     {
  240.         if (!$this->mangopayBankaccounts->contains($mangopayBankaccount)) {
  241.             $this->mangopayBankaccounts[] = $mangopayBankaccount;
  242.             $mangopayBankaccount->setIdBankInfo($this);
  243.         }
  244.         return $this;
  245.     }
  246.     public function removeMangopayBankaccount(MangopayBankaccount $mangopayBankaccount): self
  247.     {
  248.         if ($this->mangopayBankaccounts->contains($mangopayBankaccount)) {
  249.             $this->mangopayBankaccounts->removeElement($mangopayBankaccount);
  250.             // set the owning side to null (unless already changed)
  251.             if ($mangopayBankaccount->getIdBankInfo() === $this) {
  252.                 $mangopayBankaccount->setIdBankInfo(null);
  253.             }
  254.         }
  255.         return $this;
  256.     }
  257.     /**
  258.      * @return Collection|MangopayWallet[]
  259.      */
  260.     public function getMangopayWallets(): Collection
  261.     {
  262.         return $this->mangopayWallets;
  263.     }
  264.     public function addMangopayWallet(MangopayWallet $mangopayWallet): self
  265.     {
  266.         if (!$this->mangopayWallets->contains($mangopayWallet)) {
  267.             $this->mangopayWallets[] = $mangopayWallet;
  268.             $mangopayWallet->setIdBankInfo($this);
  269.         }
  270.         return $this;
  271.     }
  272.     public function removeMangopayWallet(MangopayWallet $mangopayWallet): self
  273.     {
  274.         if ($this->mangopayWallets->contains($mangopayWallet)) {
  275.             $this->mangopayWallets->removeElement($mangopayWallet);
  276.             // set the owning side to null (unless already changed)
  277.             if ($mangopayWallet->getIdBankInfo() === $this) {
  278.                 $mangopayWallet->setIdBankInfo(null);
  279.             }
  280.         }
  281.         return $this;
  282.     }
  283.     /**
  284.      * @return Collection|MangopayKycDocument[]
  285.      */
  286.     public function getMangopayKycDocuments(): Collection
  287.     {
  288.         return $this->mangopayKycDocuments;
  289.     }
  290.     public function addMangopayKycDocument(MangopayKycDocument $mangopayKycDocument): self
  291.     {
  292.         if (!$this->mangopayKycDocuments->contains($mangopayKycDocument)) {
  293.             $this->mangopayKycDocuments[] = $mangopayKycDocument;
  294.             $mangopayKycDocument->setIdBankInfo($this);
  295.         }
  296.         return $this;
  297.     }
  298.     public function removeMangopayKycDocument(MangopayKycDocument $mangopayKycDocument): self
  299.     {
  300.         if ($this->mangopayKycDocuments->contains($mangopayKycDocument)) {
  301.             $this->mangopayKycDocuments->removeElement($mangopayKycDocument);
  302.             // set the owning side to null (unless already changed)
  303.             if ($mangopayKycDocument->getIdBankInfo() === $this) {
  304.                 $mangopayKycDocument->setIdBankInfo(null);
  305.             }
  306.         }
  307.         return $this;
  308.     }
  309.     /**
  310.      * @return Collection|MangopayUboDeclaration[]
  311.      */
  312.     public function getMangopayUboDeclarations(): Collection
  313.     {
  314.         return $this->mangopayUboDeclarations;
  315.     }
  316.     public function addMangopayUboDeclaration(MangopayUboDeclaration $mangopayUboDeclaration): self
  317.     {
  318.         if (!$this->mangopayUboDeclarations->contains($mangopayUboDeclaration)) {
  319.             $this->mangopayUboDeclarations[] = $mangopayUboDeclaration;
  320.             $mangopayUboDeclaration->setIdBankInfo($this);
  321.         }
  322.         return $this;
  323.     }
  324.     public function removeMangopayUboDeclaration(MangopayUboDeclaration $mangopayUboDeclaration): self
  325.     {
  326.         if ($this->mangopayUboDeclarations->contains($mangopayUboDeclaration)) {
  327.             $this->mangopayUboDeclarations->removeElement($mangopayUboDeclaration);
  328.             // set the owning side to null (unless already changed)
  329.             if ($mangopayUboDeclaration->getIdBankInfo() === $this) {
  330.                 $mangopayUboDeclaration->setIdBankInfo(null);
  331.             }
  332.         }
  333.         return $this;
  334.     }
  335.     /**
  336.      * @return Collection|MangopayRepudiation[]
  337.      */
  338.     public function getMangopayRepudiations(): Collection
  339.     {
  340.         return $this->mangopayRepudiations;
  341.     }
  342.     public function addMangopayRepudiation(MangopayRepudiation $mangopayRepudiation): self
  343.     {
  344.         if (!$this->mangopayRepudiations->contains($mangopayRepudiation)) {
  345.             $this->mangopayRepudiations[] = $mangopayRepudiation;
  346.             $mangopayRepudiation->setIdBankInfo($this);
  347.         }
  348.         return $this;
  349.     }
  350.     public function removeMangopayRepudiation(MangopayRepudiation $mangopayRepudiation): self
  351.     {
  352.         if ($this->mangopayRepudiations->contains($mangopayRepudiation)) {
  353.             $this->mangopayRepudiations->removeElement($mangopayRepudiation);
  354.             // set the owning side to null (unless already changed)
  355.             if ($mangopayRepudiation->getIdBankInfo() === $this) {
  356.                 $mangopayRepudiation->setIdBankInfo(null);
  357.             }
  358.         }
  359.         return $this;
  360.     }
  361.     /**
  362.      * @return Collection|MangopayTransfer[]
  363.      */
  364.     public function getMangopayTransfers(): Collection
  365.     {
  366.         return $this->mangopayTransfers;
  367.     }
  368.     public function addMangopayTransfer(MangopayTransfer $mangopayTransfer): self
  369.     {
  370.         if (!$this->mangopayTransfers->contains($mangopayTransfer)) {
  371.             $this->mangopayTransfers[] = $mangopayTransfer;
  372.             $mangopayTransfer->setIdBankInfo($this);
  373.         }
  374.         return $this;
  375.     }
  376.     public function removeMangopayTransfer(MangopayTransfer $mangopayTransfer): self
  377.     {
  378.         if ($this->mangopayTransfers->contains($mangopayTransfer)) {
  379.             $this->mangopayTransfers->removeElement($mangopayTransfer);
  380.             // set the owning side to null (unless already changed)
  381.             if ($mangopayTransfer->getIdBankInfo() === $this) {
  382.                 $mangopayTransfer->setIdBankInfo(null);
  383.             }
  384.         }
  385.         return $this;
  386.     }
  387.     /**
  388.      * @return Collection|MangopayPayin[]
  389.      */
  390.     public function getMangopayPayerPayins(): Collection
  391.     {
  392.         return $this->mangopayPayerPayins;
  393.     }
  394.     public function addMangopayPayerPayin(MangopayPayin $mangopayPayerPayin): self
  395.     {
  396.         if (!$this->mangopayPayerPayins->contains($mangopayPayerPayin)) {
  397.             $this->mangopayPayerPayins[] = $mangopayPayerPayin;
  398.             $mangopayPayerPayin->setIdPayer($this);
  399.         }
  400.         return $this;
  401.     }
  402.     public function removeMangopayPayerPayin(MangopayPayin $mangopayPayerPayin): self
  403.     {
  404.         if ($this->mangopayPayerPayins->contains($mangopayPayerPayin)) {
  405.             $this->mangopayPayerPayins->removeElement($mangopayPayerPayin);
  406.             // set the owning side to null (unless already changed)
  407.             if ($mangopayPayerPayin->getIdPayer() === $this) {
  408.                 $mangopayPayerPayin->setIdPayer(null);
  409.             }
  410.         }
  411.         return $this;
  412.     }
  413.     /**
  414.      * @return Collection|MangopayPayin[]
  415.      */
  416.     public function getMangopayCollectorPayins(): Collection
  417.     {
  418.         return $this->mangopayCollectorPayins;
  419.     }
  420.     public function addMangopayCollectorPayin(MangopayPayin $mangopayCollectorPayin): self
  421.     {
  422.         if (!$this->mangopayCollectorPayins->contains($mangopayCollectorPayin)) {
  423.             $this->mangopayCollectorPayins[] = $mangopayCollectorPayin;
  424.             $mangopayCollectorPayin->setIdCollector($this);
  425.         }
  426.         return $this;
  427.     }
  428.     public function removeMangopayCollectorPayin(MangopayPayin $mangopayCollectorPayin): self
  429.     {
  430.         if ($this->mangopayCollectorPayins->contains($mangopayCollectorPayin)) {
  431.             $this->mangopayCollectorPayins->removeElement($mangopayCollectorPayin);
  432.             // set the owning side to null (unless already changed)
  433.             if ($mangopayCollectorPayin->getIdCollector() === $this) {
  434.                 $mangopayCollectorPayin->setIdCollector(null);
  435.             }
  436.         }
  437.         return $this;
  438.     }
  439.     /**
  440.      * @return Collection|MangopayPayout[]
  441.      */
  442.     public function getMangopayPayouts(): Collection
  443.     {
  444.         return $this->mangopayPayouts;
  445.     }
  446.     public function addMangopayPayout(MangopayPayout $mangopayPayout): self
  447.     {
  448.         if (!$this->mangopayPayouts->contains($mangopayPayout)) {
  449.             $this->mangopayPayouts[] = $mangopayPayout;
  450.             $mangopayPayout->setIdBankInfo($this);
  451.         }
  452.         return $this;
  453.     }
  454.     public function removeMangopayPayout(MangopayPayout $mangopayPayout): self
  455.     {
  456.         if ($this->mangopayPayouts->contains($mangopayPayout)) {
  457.             $this->mangopayPayouts->removeElement($mangopayPayout);
  458.             // set the owning side to null (unless already changed)
  459.             if ($mangopayPayout->getIdBankInfo() === $this) {
  460.                 $mangopayPayout->setIdBankInfo(null);
  461.             }
  462.         }
  463.         return $this;
  464.     }
  465.     /**
  466.      * @return Collection|MangopayRefund[]
  467.      */
  468.     public function getMangopayRefunds(): Collection
  469.     {
  470.         return $this->mangopayRefunds;
  471.     }
  472.     public function addMangopayRefund(MangopayRefund $mangopayRefund): self
  473.     {
  474.         if (!$this->mangopayRefunds->contains($mangopayRefund)) {
  475.             $this->mangopayRefunds[] = $mangopayRefund;
  476.             $mangopayRefund->setIdBankInfo($this);
  477.         }
  478.         return $this;
  479.     }
  480.     public function removeMangopayRefund(MangopayRefund $mangopayRefund): self
  481.     {
  482.         if ($this->mangopayRefunds->contains($mangopayRefund)) {
  483.             $this->mangopayRefunds->removeElement($mangopayRefund);
  484.             // set the owning side to null (unless already changed)
  485.             if ($mangopayRefund->getIdBankInfo() === $this) {
  486.                 $mangopayRefund->setIdBankInfo(null);
  487.             }
  488.         }
  489.         return $this;
  490.     }
  491.     public function getUser(): ?User
  492.     {
  493.         return $this->user;
  494.     }
  495.     public function setUser(?User $user): self
  496.     {
  497.         $this->user $user;
  498.         return $this;
  499.     }
  500.     /**
  501.      * @return Collection|KycFile[]
  502.      */
  503.     public function getKycFiles(): Collection
  504.     {
  505.         return $this->kycFiles;
  506.     }
  507.     public function addKycFile(KycFile $kycFile): self
  508.     {
  509.         if (!$this->kycFiles->contains($kycFile)) {
  510.             $this->kycFiles[] = $kycFile;
  511.             $kycFile->setIdUser($this);
  512.         }
  513.         return $this;
  514.     }
  515.     public function removeKycFile(KycFile $kycFile): self
  516.     {
  517.         if ($this->kycFiles->contains($kycFile)) {
  518.             $this->kycFiles->removeElement($kycFile);
  519.             // set the owning side to null (unless already changed)
  520.             if ($kycFile->getIdUser() === $this) {
  521.                 $kycFile->setIdUser(null);
  522.             }
  523.         }
  524.         return $this;
  525.     }
  526.     
  527. }