You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

OrderReductionCartModel.php 2.2KB

3 yıl önce
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. <?php
  2. namespace Lc\CaracoleBundle\Model\Order;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Lc\CaracoleBundle\Doctrine\Extension\ReductionCartPropertyInterface;
  5. use Lc\CaracoleBundle\Doctrine\Extension\ReductionCartPropertyTrait;
  6. use Lc\CaracoleBundle\Doctrine\Extension\ReductionTrait;
  7. use Lc\CaracoleBundle\Doctrine\Extension\ReductionInterface;
  8. use Lc\CaracoleBundle\Model\Reduction\ReductionCartInterface;
  9. use Lc\SovBundle\Doctrine\EntityInterface;
  10. /**
  11. * @ORM\MappedSuperclass()
  12. */
  13. abstract class OrderReductionCartModel implements EntityInterface, ReductionInterface, ReductionCartPropertyInterface, OrderReductionCartInterface
  14. {
  15. use ReductionTrait;
  16. use ReductionCartPropertyTrait;
  17. /**
  18. * @ORM\Column(type="string", length=255)
  19. */
  20. protected $title;
  21. /**
  22. * @ORM\ManyToOne(targetEntity="Lc\CaracoleBundle\Model\Order\OrderShopInterface", inversedBy="orderReductionCarts")
  23. * @ORM\JoinColumn(nullable=false)
  24. */
  25. protected $orderShop;
  26. /**
  27. * @ORM\ManyToOne(targetEntity="Lc\CaracoleBundle\Model\Reduction\ReductionCartInterface")
  28. * @ORM\JoinColumn(nullable=false)
  29. */
  30. protected $reductionCart;
  31. /**
  32. * @ORM\Column(type="string", length=255, nullable=true)
  33. */
  34. protected $codeUsed;
  35. public function __toString()
  36. {
  37. return $this->title;
  38. }
  39. public function getTitle(): ?string
  40. {
  41. return $this->title;
  42. }
  43. public function setTitle(string $title): self
  44. {
  45. $this->title = $title;
  46. return $this;
  47. }
  48. public function getOrderShop(): ?OrderShopInterface
  49. {
  50. return $this->orderShop;
  51. }
  52. public function setOrderShop(?OrderShopInterface $orderShop): self
  53. {
  54. $this->orderShop = $orderShop;
  55. return $this;
  56. }
  57. public function getReductionCart(): ?ReductionCartInterface
  58. {
  59. return $this->reductionCart;
  60. }
  61. public function setReductionCart(?ReductionCartInterface $reductionCart): self
  62. {
  63. $this->reductionCart = $reductionCart;
  64. return $this;
  65. }
  66. public function getCodeUsed(): ?string
  67. {
  68. return $this->codeUsed;
  69. }
  70. public function setCodeUsed(?string $codeUsed): self
  71. {
  72. $this->codeUsed = $codeUsed;
  73. return $this;
  74. }
  75. }