src/Entity/GestionComerciale/ModeExpedition.php line 21

Open in your IDE?
  1. <?php
  2. namespace App\Entity\GestionComerciale;
  3. use App\Entity\MarketPlace\MarketPlace;
  4. use App\Entity\Transporteurs\Transporteur;
  5. use DateTime;
  6. use Doctrine\ORM\Mapping as ORM;
  7. use Gedmo\Mapping\Annotation as Gedmo;
  8. use Symfony\Component\Validator\Constraints as Assert;
  9. use Symfony\Component\Validator\ExecutionContextInterface;
  10. use App\Annotations\SecuredEntity;
  11. /**
  12.  * ModeExpedition
  13.  *
  14.  * @ORM\Table("commerciale__mode_expedition")
  15.  * @ORM\Entity(repositoryClass="App\Repository\GestionComerciale\ModeExpeditionRepository")
  16.  * @Gedmo\SoftDeleteable(fieldName="dateSuppression",timeAware=false)
  17.  * @SecuredEntity(name="Mode Expedition", group="MARKETPLACE")
  18.  */
  19. class ModeExpedition
  20. {
  21.     /**
  22.      * @ORM\Column(name="id", type="integer")
  23.      * @ORM\Id
  24.      * @ORM\GeneratedValue(strategy="AUTO")
  25.      */
  26.     private $id;
  27.     /**
  28.      * @ORM\Column(name="date", type="datetime", nullable=true)
  29.      */
  30.     private $date;
  31.     /**
  32.      * @ORM\Column(name="dateMaj", type="datetime", nullable=true)
  33.      * @Gedmo\Timestampable(on="update")
  34.      */
  35.     private $dateMaj;
  36.     /**
  37.      * @ORM\Column(name="libelle", type="string", length=255, nullable=true)
  38.      */
  39.     private $libelle;
  40.     /**
  41.      * @ORM\Column(name="origine", type="string", length=255, nullable=true)
  42.      */
  43.     private $origine;
  44.     /**
  45.      * @ORM\Column(name="reference", type="string", length=255, nullable=true)
  46.      */
  47.     private $reference;
  48.    /**
  49.      * @ORM\Column(name="duree", type="integer", nullable=true)
  50.      */
  51.     private $duree;
  52.     /**
  53.      * @ORM\Column(name="position", type="integer", nullable=true)
  54.      */
  55.     private $position;
  56.     /**
  57.      * @ORM\Column(name="dateSuppression", type="datetime", nullable=true)
  58.      */
  59.     private $dateSuppression;
  60.     /**
  61.      * @ORM\ManyToOne(targetEntity="App\Entity\MarketPlace\MarketPlace")
  62.      * @ORM\JoinColumn(nullable=true)
  63.      */
  64.     private $marketPlace;
  65.   /**
  66.    * @var integer
  67.    *
  68.    * @ORM\ManyToOne(targetEntity="App\Entity\Transporteurs\Transporteur", inversedBy="commandes")
  69.    * @ORM\JoinColumn(nullable=true)
  70.    */
  71.   private $transporteur;
  72.     public function __construct()
  73.     {
  74.         $this->date = new Datetime();
  75.     }
  76.     public function getId(): int
  77.     {
  78.         return $this->id;
  79.     }
  80.     public function setDate(?DateTime $date): ModeExpedition
  81.     {
  82.         $this->date $date;
  83.         return $this;
  84.     }
  85.     public function getDate(): ?DateTime
  86.     {
  87.         return $this->date;
  88.     }
  89.     public function setLibelle(?string $libelle): ModeExpedition
  90.     {
  91.         $this->libelle $libelle;
  92.         return $this;
  93.     }
  94.     public function getLibelle(): ?string
  95.     {
  96.         return $this->libelle;
  97.     }
  98.     public function setPosition(?int $position): ModeExpedition
  99.     {
  100.         $this->position $position;
  101.         return $this;
  102.     }
  103.     public function getPosition(): ?int
  104.     {
  105.         return $this->position;
  106.     }
  107.     public function setDateMaj(?DateTime $dateMaj): ModeExpedition
  108.     {
  109.         $this->dateMaj $dateMaj;
  110.         return $this;
  111.     }
  112.     public function getDateMaj(): ?DateTime
  113.     {
  114.         return $this->dateMaj;
  115.     }
  116.     public function setReference(?string $reference): ModeExpedition
  117.     {
  118.         $this->reference $reference;
  119.         return $this;
  120.     }
  121.     public function getReference(): ?string
  122.     {
  123.         return $this->reference;
  124.     }
  125.     public function setOrigine(?string $origine): ModeExpedition
  126.     {
  127.         $this->origine $origine;
  128.         return $this;
  129.     }
  130.     public function getOrigine(): ?string
  131.     {
  132.         return $this->origine;
  133.     }
  134.     public function __toString()
  135.     {
  136.         return $this->libelle;
  137.     }
  138.     public function setDuree(?int $duree): ModeExpedition
  139.     {
  140.         $this->duree $duree;
  141.         return $this;
  142.     }
  143.     public function getDuree(): ?int
  144.     {
  145.         return $this->duree;
  146.     }
  147.     public function setDateSuppression(?DateTime $dateSuppression): ModeExpedition
  148.     {
  149.         $this->dateSuppression $dateSuppression;
  150.         return $this;
  151.     }
  152.     public function getDateSuppression(): ?DateTime
  153.     {
  154.         return $this->dateSuppression;
  155.     }
  156.     public function setMarketPlace(?MarketPlace $marketPlace): ModeExpedition
  157.     {
  158.         $this->marketPlace $marketPlace;
  159.         return $this;
  160.     }
  161.     public function getMarketPlace(): ?MarketPlace
  162.     {
  163.         return $this->marketPlace;
  164.     }
  165.     public function setTransporteur(?Transporteur $transporteur): ModeExpedition
  166.     {
  167.         $this->transporteur $transporteur;
  168.         return $this;
  169.     }
  170.     public function getTransporteur(): ?Transporteur
  171.     {
  172.         return $this->transporteur;
  173.     }
  174. }