<?phpnamespace App\Entity\Gos;use Doctrine\ORM\Mapping as ORM;/** * CouponPackProduct * * @ORM\Entity() * @ORM\Table(name="coupon_pack_product") * @ORM\HasLifecycleCallbacks() */class CouponPackProduct{ /** * @var int * * @ORM\Column(name="id", type="integer") * @ORM\Id() * @ORM\GeneratedValue(strategy="AUTO") */ private $id; /** * @var bool * * @ORM\Column(type="boolean") */ private $isGross; /** * @var int * * @ORM\Column(type="integer") */ private $discountType; /** * @var int * * @ORM\Column(type="integer") */ private $discount; /** * @ORM\ManyToOne(targetEntity="App\Entity\Gos\Coupon", inversedBy="couponPackProducts") * @ORM\JoinColumn() */ private $coupon; /** * @ORM\ManyToOne(targetEntity="App\Entity\Gos\ProductVariant", inversedBy="couponPack") * @ORM\JoinColumn() */ private $productVariant; /** * @ORM\Column(type="datetime") */ private $createdAt; /** * @ORM\Column(type="datetime", nullable=true) */ private $updatedAt; /** * @ORM\PrePersist() */ public function prePersist() { $this->createdAt = new \DateTime(); } /** * @ORM\PreUpdate() */ public function preUpdate() { $this->updatedAt = new \DateTime(); } public function __toString() { return (string)$this->id; } /** * Constructor */ public function __construct() { } /** * Get id * * @return integer */ public function getId() { return $this->id; } /** * Set isGross * * @param bool $isGross * @return CouponPackProduct */ public function setIsGross($isGross) { $this->isGross = $isGross; return $this; } /** * Get isGross * * @return bool */ public function getIsGross() { return $this->isGross; } /** * Set discountType * * @param int $discountType * @return CouponPackProduct */ public function setDiscountType($discountType) { $this->discountType = $discountType; return $this; } /** * Get discountType * * @return int */ public function getDiscountType() { return $this->discountType; } /** * Set discount * * @param int $discount * @return CouponPackProduct */ public function setDiscount($discount) { $this->discount = $discount; return $this; } /** * Get discount * * @return int */ public function getDiscount() { return $this->discount; } /** * Set coupon * * @param Coupon $coupon * @return CouponPackProduct */ public function setCoupon(\App\Entity\Gos\Coupon $coupon) { $this->coupon = $coupon; return $this; } /** * Get coupon * * @return Coupon */ public function getCoupon() { return $this->coupon; } /** * Set productVariant * * @param ProductVariant $productVariant * @return CouponPackProduct */ public function setProductVariant(\App\Entity\Gos\ProductVariant $productVariant) { $this->productVariant = $productVariant; return $this; } /** * Get productVariant * * @return ProductVariant */ public function getProductVariant() { return $this->productVariant; } /** * Set createdAt * * @param \DateTime $createdAt * @return CouponPackProduct */ public function setCreatedAt($createdAt) { $this->createdAt = $createdAt; return $this; } /** * Get createdAt * * @return \DateTime */ public function getCreatedAt() { return $this->createdAt; } /** * Set updatedAt * * @param \DateTime $updatedAt * @return CouponPackProduct */ public function setUpdatedAt($updatedAt) { $this->updatedAt = $updatedAt; return $this; } /** * Get updatedAt * * @return \DateTime */ public function getUpdatedAt() { return $this->updatedAt; }}