|
- <?php
-
- namespace Lc\CaracoleBundle\Model\Distribution;
-
- use Doctrine\ORM\Mapping as ORM;
- use Lc\CaracoleBundle\Doctrine\Extension\PayoffTrait;
- use Lc\CaracoleBundle\Model\Order\OrderPaymentInterface;
- use Lc\CaracoleBundle\Model\Order\OrderRefundInterface;
- use Lc\CaracoleBundle\Doctrine\Extension\PayoffInterface;
- use Lc\CaracoleBundle\Model\Section\SectionInterface;
- use Lc\CaracoleBundle\Model\User\UserMerchantInterface;
- use Gedmo\Mapping\Annotation as Gedmo;
- use Lc\SovBundle\Doctrine\EntityInterface;
- use Lc\SovBundle\Doctrine\Extension\BlameableNullableTrait;
- use Lc\SovBundle\Doctrine\Pattern\AbstractLightEntity;
-
- /**
- * @ORM\MappedSuperclass()
- */
- abstract class DistributionModel implements DistributionInterface, EntityInterface
- {
- /**
- * @ORM\ManyToOne(targetEntity="Lc\CaracoleBundle\Model\Section\SectionInterface")
- * @ORM\JoinColumn(nullable=false)
- */
- protected $section;
-
- /**
- * @ORM\Column(type="integer")
- */
- protected $cycleNumber;
-
- /**
- * @ORM\Column(type="integer")
- */
- protected $year;
-
- /**
- * @ORM\Column(type="string", length=32)
- */
- protected $cycleType;
-
- public function __toString()
- {
- return $this->getCycleNumber().'/'.$this->getYear();
- }
-
- public function getSection(): ?SectionInterface
- {
- return $this->section;
- }
-
- public function setSection(?SectionInterface $section): self
- {
- $this->section = $section;
-
- return $this;
- }
-
- public function getCycleNumber(): ?int
- {
- return $this->cycleNumber;
- }
-
- public function setCycleNumber(int $cycleNumber): self
- {
- $this->cycleNumber = $cycleNumber;
-
- return $this;
- }
-
- public function getYear(): ?int
- {
- return $this->year;
- }
-
- public function setYear(int $year): self
- {
- $this->year = $year;
-
- return $this;
- }
-
-
- public function getCycleType(): ?string
- {
- return $this->cycleType;
- }
-
- public function setCycleType(string $cycleType): self
- {
- $this->cycleType = $cycleType;
-
- return $this;
- }
- }
|