Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

76 lines
1.5KB

  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. use Lc\ShopBundle\Context\ReductionInterface;
  7. use Lc\ShopBundle\Model\AbstractDocumentEntity;
  8. use Lc\ShopBundle\Model\ReductionTrait;
  9. /**
  10. * @ORM\MappedSuperclass()
  11. */
  12. abstract class ReductionCart extends AbstractDocumentEntity
  13. {
  14. use ReductionTrait;
  15. /**
  16. * @ORM\Column(type="boolean", nullable=true)
  17. */
  18. protected $freeShipping;
  19. /**
  20. * @ORM\Column(type="string", length=25)
  21. */
  22. protected $appliedTo;
  23. /**
  24. * @ORM\Column(type="integer")
  25. */
  26. protected $priority;
  27. public function getFreeShipping(): ?bool
  28. {
  29. return $this->freeShipping;
  30. }
  31. public function setFreeShipping(?bool $freeShipping): self
  32. {
  33. $this->freeShipping = $freeShipping;
  34. return $this;
  35. }
  36. public function getAppliedTo(): ?string
  37. {
  38. return $this->appliedTo;
  39. }
  40. public function setAppliedTo(string $appliedTo): self
  41. {
  42. $this->appliedTo = $appliedTo;
  43. return $this;
  44. }
  45. public function getPriority(): ?int
  46. {
  47. return $this->priority;
  48. }
  49. public function setPriority(int $priority): self
  50. {
  51. $this->priority = $priority;
  52. return $this;
  53. }
  54. }