app/Plugin/payjp4/Entity/Payjp/CreditCard.php line 25

Open in your IDE?
  1. <?php
  2. /**
  3.  * This file is part of payjp4
  4.  *
  5.  * Copyright(c) Akira Kurozumi <info@a-zumi.net>
  6.  *
  7.  *  https://a-zumi.net
  8.  *
  9.  * For the full copyright and license information, please view the LICENSE
  10.  * file that was distributed with this source code.
  11.  */
  12. namespace Plugin\payjp4\Entity\Payjp;
  13. use Doctrine\ORM\Mapping as ORM;
  14. use Eccube\Entity\Customer;
  15. /**
  16.  * Class CreditCard
  17.  * @package Plugin\payjp4\Entity\Payjp
  18.  *
  19.  * @ORM\Table(name="plg_payjp_customer")
  20.  * @ORM\Entity(repositoryClass="Plugin\payjp4\Repository\Payjp\CreditCardRepository")
  21.  */
  22. class CreditCard
  23. {
  24.     /**
  25.      * @var int
  26.      *
  27.      * @ORM\Column(type="integer", options={"unsigned": true})
  28.      * @ORM\Id()
  29.      * @ORM\GeneratedValue(strategy="IDENTITY")
  30.      */
  31.     private $id;
  32.     /**
  33.      * @var string
  34.      *
  35.      * @ORM\Column(type="string", length=255)
  36.      */
  37.     private $payjp_id;
  38.     /**
  39.      * @var
  40.      *
  41.      * @ORM\ManyToOne(targetEntity="Eccube\Entity\Customer", inversedBy="CreditCards")
  42.      * @ORM\JoinColumn(nullable=false)
  43.      */
  44.     private $Customer;
  45.     /**
  46.      * @return int
  47.      */
  48.     public function getId(): int
  49.     {
  50.         return $this->id;
  51.     }
  52.     /**
  53.      * @return string
  54.      */
  55.     public function getPayjpId(): string
  56.     {
  57.         return $this->payjp_id;
  58.     }
  59.     public function setPayjpId(string $payjp_id): self
  60.     {
  61.         $this->payjp_id $payjp_id;
  62.         return $this;
  63.     }
  64.     /**
  65.      * @return Customer
  66.      */
  67.     public function getCustomer(): Customer
  68.     {
  69.         return $this->Customer;
  70.     }
  71.     /**
  72.      * @param Customer $customer
  73.      * @return $this
  74.      */
  75.     public function setCustomer(Customer $customer): self
  76.     {
  77.         $this->Customer $customer;
  78.         return $this;
  79.     }
  80. }