src/Entity/Ville.php line 12

Open in your IDE?
  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. /**
  7.  * @ORM\Entity(repositoryClass="App\Repository\VilleRepository")
  8.  */
  9. class Ville
  10. {
  11.     /**
  12.      * @ORM\Id()
  13.      * @ORM\GeneratedValue()
  14.      * @ORM\Column(type="integer")
  15.      */
  16.     private $id;
  17.     /**
  18.      * @ORM\Column(type="string", length=255)
  19.      */
  20.     private $nomville;
  21.     /**
  22.      * @ORM\Column(type="string", length=255)
  23.      */
  24.     private $Adresse1;
  25.     /**
  26.      * @ORM\Column(type="string", length=255, nullable=true)
  27.      */
  28.     private $Adresse2;
  29.     /**
  30.      * @ORM\Column(type="string", length=255)
  31.      */
  32.     private $email;
  33.     /**
  34.      * @ORM\Column(type="string", length=255)
  35.      */
  36.     private $numTel;
  37.     /**
  38.      * @ORM\Column(type="string", length=255, nullable=true)
  39.      */
  40.     private $addresse3;
  41.     /**
  42.      * @ORM\Column(type="string", length=255, nullable=true)
  43.      */
  44.     private $addresse4;
  45.     /**
  46.      * @ORM\Column(type="string", length=255, nullable=true)
  47.      */
  48.     private $addresse5;
  49.     /**
  50.      * @ORM\Column(type="string", length=255, nullable=true)
  51.      */
  52.     private $addresse6;
  53.     /**
  54.      * @ORM\OneToMany(targetEntity=Utilisateur::class, mappedBy="ville")
  55.      */
  56.     private $utilisateurs;
  57.     /**
  58.      * @ORM\OneToMany(targetEntity=Agent::class, mappedBy="ville")
  59.      */
  60.     private $agents;
  61.     /**
  62.      * @ORM\OneToMany(targetEntity=ProgrammeContenaire::class, mappedBy="villeInitiale")
  63.      */
  64.     private $programmeContenaires;
  65.     /**
  66.      * @ORM\Column(type="string", length=2)
  67.      */
  68.     private $flagVille;
  69.     /**
  70.      * @ORM\Column(type="string", length=100)
  71.      */
  72.     private $logo;
  73.     /**
  74.      * @ORM\Column(type="string", length=150, nullable=true)
  75.      */
  76.     private $portBateau;
  77.     /**
  78.      * @ORM\Column(type="integer")
  79.      */
  80.     private $tauxDuJourPays;
  81.     /**
  82.      * @ORM\Column(type="boolean")
  83.      */
  84.     private $isTaux;
  85.     /**
  86.      * @ORM\Column(type="string", length=5)
  87.      */
  88.     private $monnaie;
  89.     /**
  90.      * @ORM\OneToMany(targetEntity=Position::class, mappedBy="ville")
  91.      */
  92.     private $positions;
  93.     /**
  94.      * @ORM\Column(type="string", length=255, nullable=true)
  95.      */
  96.     private $tokenurl;
  97.     /**
  98.      * @ORM\Column(type="string", length=255, nullable=true)
  99.      */
  100.     private $tokenId;
  101.     /**
  102.      * @ORM\Column(type="string", length=1500, nullable=true)
  103.      */
  104.     private $basdepage;
  105.     /**
  106.      * @ORM\Column(type="string", length=1500, nullable=true)
  107.      */
  108.     private $basdepagemco;
  109.     /**
  110.      * @ORM\Column(type="string", length=10)
  111.      */
  112.     private $cbm;
  113.     /**
  114.      * @ORM\Column(type="string", length=10)
  115.      */
  116.     private $tonne;
  117.     /**
  118.      * @ORM\Column(type="string", length=10)
  119.      */
  120.     private $kg;
  121.     /**
  122.      * @ORM\Column(type="string", length=10)
  123.      */
  124.     private $conteneur;
  125.     /**
  126.      * @ORM\Column(type="string", length=10)
  127.      */
  128.     private $kgelec;
  129.     /**
  130.      * @ORM\Column(type="string", length=5)
  131.      */
  132.     private $prefixeCode;
  133.     /**
  134.      * @ORM\OneToMany(targetEntity=Reception::class, mappedBy="ville")
  135.      */
  136.     private $receptions;
  137.     /**
  138.      * @ORM\OneToMany(targetEntity=Reception::class, mappedBy="destville")
  139.      */
  140.     private $destville;
  141.     /**
  142.      * @ORM\Column(type="string", length=255, nullable=true)
  143.      */
  144.     private $estimateddateTextAirCargo;
  145.     /**
  146.      * @ORM\Column(type="string", length=255)
  147.      */
  148.     private $estimateddateTextSeaCargo;
  149.     /**
  150.      * @ORM\OneToMany(targetEntity=CategoriePrix::class, mappedBy="ville")
  151.      */
  152.     private $categoriesPrix;
  153.     public function __construct()
  154.     {
  155.         $this->utilisateurs = new ArrayCollection();
  156.         $this->agents = new ArrayCollection();
  157.         $this->programmeContenaires = new ArrayCollection();
  158.         $this->positions = new ArrayCollection();
  159.         $this->receptions = new ArrayCollection();
  160.         $this->destville = new ArrayCollection();
  161.         $this->categoriesPrix = new ArrayCollection();
  162.     }
  163.     public function getId(): ?int
  164.     {
  165.         return $this->id;
  166.     }
  167.     public function getNomville(): ?string
  168.     {
  169.         return $this->nomville;
  170.     }
  171.     public function setNomville(string $nomville): self
  172.     {
  173.         $this->nomville = $nomville;
  174.         return $this;
  175.     }
  176.     public function getAdresse1(): ?string
  177.     {
  178.         return $this->Adresse1;
  179.     }
  180.     public function setAdresse1(string $Adresse1): self
  181.     {
  182.         $this->Adresse1 = $Adresse1;
  183.         return $this;
  184.     }
  185.     public function getAdresse2(): ?string
  186.     {
  187.         return $this->Adresse2;
  188.     }
  189.     public function setAdresse2(?string $Adresse2): self
  190.     {
  191.         $this->Adresse2 = $Adresse2;
  192.         return $this;
  193.     }
  194.     public function getEmail(): ?string
  195.     {
  196.         return $this->email;
  197.     }
  198.     public function setEmail(string $email): self
  199.     {
  200.         $this->email = $email;
  201.         return $this;
  202.     }
  203.     public function getNumTel(): ?string
  204.     {
  205.         return $this->numTel;
  206.     }
  207.     public function setNumTel(string $numTel): self
  208.     {
  209.         $this->numTel = $numTel;
  210.         return $this;
  211.     }
  212.     public function __toString(){
  213.         return $this->nomville;
  214.     }
  215.     public function getAddresse3(): ?string
  216.     {
  217.         return $this->addresse3;
  218.     }
  219.     public function setAddresse3(?string $addresse3): self
  220.     {
  221.         $this->addresse3 = $addresse3;
  222.         return $this;
  223.     }
  224.     public function getAddresse4(): ?string
  225.     {
  226.         return $this->addresse4;
  227.     }
  228.     public function setAddresse4(?string $addresse4): self
  229.     {
  230.         $this->addresse4 = $addresse4;
  231.         return $this;
  232.     }
  233.     public function getAddresse5(): ?string
  234.     {
  235.         return $this->addresse5;
  236.     }
  237.     public function setAddresse5(?string $addresse5): self
  238.     {
  239.         $this->addresse5 = $addresse5;
  240.         return $this;
  241.     }
  242.     public function getAddresse6(): ?string
  243.     {
  244.         return $this->addresse6;
  245.     }
  246.     public function setAddresse6(?string $addresse6): self
  247.     {
  248.         $this->addresse6 = $addresse6;
  249.         return $this;
  250.     }
  251.     /**
  252.      * @return Collection<int, Utilisateur>
  253.      */
  254.     public function getUtilisateurs(): Collection
  255.     {
  256.         return $this->utilisateurs;
  257.     }
  258.     public function addUtilisateur(Utilisateur $utilisateur): self
  259.     {
  260.         if (!$this->utilisateurs->contains($utilisateur)) {
  261.             $this->utilisateurs[] = $utilisateur;
  262.             $utilisateur->setVille($this);
  263.         }
  264.         return $this;
  265.     }
  266.     public function removeUtilisateur(Utilisateur $utilisateur): self
  267.     {
  268.         if ($this->utilisateurs->removeElement($utilisateur)) {
  269.             if ($utilisateur->getVille() === $this) {
  270.                 $utilisateur->setVille(null);
  271.             }
  272.         }
  273.         return $this;
  274.     }
  275.     /**
  276.      * @return Collection<int, Agent>
  277.      */
  278.     public function getAgents(): Collection
  279.     {
  280.         return $this->agents;
  281.     }
  282.     public function addAgent(Agent $agent): self
  283.     {
  284.         if (!$this->agents->contains($agent)) {
  285.             $this->agents[] = $agent;
  286.             $agent->setVille($this);
  287.         }
  288.         return $this;
  289.     }
  290.     public function removeAgent(Agent $agent): self
  291.     {
  292.         if ($this->agents->removeElement($agent)) {
  293.             if ($agent->getVille() === $this) {
  294.                 $agent->setVille(null);
  295.             }
  296.         }
  297.         return $this;
  298.     }
  299.     /**
  300.      * @return Collection<int, ProgrammeContenaire>
  301.      */
  302.     public function getProgrammeContenaires(): Collection
  303.     {
  304.         return $this->programmeContenaires;
  305.     }
  306.     public function addProgrammeContenaire(ProgrammeContenaire $programmeContenaire): self
  307.     {
  308.         if (!$this->programmeContenaires->contains($programmeContenaire)) {
  309.             $this->programmeContenaires[] = $programmeContenaire;
  310.             $programmeContenaire->setVilleInitiale($this);
  311.         }
  312.         return $this;
  313.     }
  314.     public function removeProgrammeContenaire(ProgrammeContenaire $programmeContenaire): self
  315.     {
  316.         if ($this->programmeContenaires->removeElement($programmeContenaire)) {
  317.             if ($programmeContenaire->getVilleInitiale() === $this) {
  318.                 $programmeContenaire->setVilleInitiale(null);
  319.             }
  320.         }
  321.         return $this;
  322.     }
  323.     public function getFlagVille(): ?string
  324.     {
  325.         return $this->flagVille;
  326.     }
  327.     public function setFlagVille(string $flagVille): self
  328.     {
  329.         $this->flagVille = $flagVille;
  330.         return $this;
  331.     }
  332.     public function getLogo(): ?string
  333.     {
  334.         return $this->logo;
  335.     }
  336.     public function setLogo(string $logo): self
  337.     {
  338.         $this->logo = $logo;
  339.         return $this;
  340.     }
  341.     public function getPortBateau(): ?string
  342.     {
  343.         return $this->portBateau;
  344.     }
  345.     public function setPortBateau(?string $portBateau): self
  346.     {
  347.         $this->portBateau = $portBateau;
  348.         return $this;
  349.     }
  350.     public function getTauxDuJourPays(): ?int
  351.     {
  352.         return $this->tauxDuJourPays;
  353.     }
  354.     public function setTauxDuJourPays(int $tauxDuJourPays): self
  355.     {
  356.         $this->tauxDuJourPays = $tauxDuJourPays;
  357.         return $this;
  358.     }
  359.     public function isIsTaux(): ?bool
  360.     {
  361.         return $this->isTaux;
  362.     }
  363.     public function setIsTaux(bool $isTaux): self
  364.     {
  365.         $this->isTaux = $isTaux;
  366.         return $this;
  367.     }
  368.     public function getMonnaie(): ?string
  369.     {
  370.         return $this->monnaie;
  371.     }
  372.     public function setMonnaie(string $monnaie): self
  373.     {
  374.         $this->monnaie = $monnaie;
  375.         return $this;
  376.     }
  377.     /**
  378.      * @return Collection<int, Position>
  379.      */
  380.     public function getPositions(): Collection
  381.     {
  382.         return $this->positions;
  383.     }
  384.     public function addPosition(Position $position): self
  385.     {
  386.         if (!$this->positions->contains($position)) {
  387.             $this->positions[] = $position;
  388.             $position->setVille($this);
  389.         }
  390.         return $this;
  391.     }
  392.     public function removePosition(Position $position): self
  393.     {
  394.         if ($this->positions->removeElement($position)) {
  395.             if ($position->getVille() === $this) {
  396.                 $position->setVille(null);
  397.             }
  398.         }
  399.         return $this;
  400.     }
  401.     public function getTokenUrl(): ?string
  402.     {
  403.         return $this->tokenurl;
  404.     }
  405.     public function setTokenUrl(?string $tokenurl): self
  406.     {
  407.         $this->tokenurl = $tokenurl;
  408.         return $this;
  409.     }
  410.     public function getTokenId(): ?string
  411.     {
  412.         return $this->tokenId;
  413.     }
  414.     public function setTokenId(?string $tokenId): self
  415.     {
  416.         $this->tokenId = $tokenId;
  417.         return $this;
  418.     }
  419.     public function getBasdepage(): ?string
  420.     {
  421.         return $this->basdepage;
  422.     }
  423.     public function setBasdepage(?string $basdepage): self
  424.     {
  425.         $this->basdepage = $basdepage;
  426.         return $this;
  427.     }
  428.     public function getBasdepagemco(): ?string
  429.     {
  430.         return $this->basdepagemco;
  431.     }
  432.     public function setBasdepagemco(?string $basdepagemco): self
  433.     {
  434.         $this->basdepagemco = $basdepagemco;
  435.         return $this;
  436.     }
  437.     public function getCbm(): ?string
  438.     {
  439.         return $this->cbm;
  440.     }
  441.     public function setCbm(string $cbm): self
  442.     {
  443.         $this->cbm = $cbm;
  444.         return $this;
  445.     }
  446.     public function getTonne(): ?string
  447.     {
  448.         return $this->tonne;
  449.     }
  450.     public function setTonne(string $tonne): self
  451.     {
  452.         $this->tonne = $tonne;
  453.         return $this;
  454.     }
  455.     public function getKg(): ?string
  456.     {
  457.         return $this->kg;
  458.     }
  459.     public function setKg(string $kg): self
  460.     {
  461.         $this->kg = $kg;
  462.         return $this;
  463.     }
  464.     public function getConteneur(): ?string
  465.     {
  466.         return $this->conteneur;
  467.     }
  468.     public function setConteneur(string $conteneur): self
  469.     {
  470.         $this->conteneur = $conteneur;
  471.         return $this;
  472.     }
  473.     public function getKgelec(): ?string
  474.     {
  475.         return $this->kgelec;
  476.     }
  477.     public function setKgelec(string $kgelec): self
  478.     {
  479.         $this->kgelec = $kgelec;
  480.         return $this;
  481.     }
  482.     public function getPrefixeCode(): ?string
  483.     {
  484.         return $this->prefixeCode;
  485.     }
  486.     public function setPrefixeCode(string $prefixeCode): self
  487.     {
  488.         $this->prefixeCode = $prefixeCode;
  489.         return $this;
  490.     }
  491.     /**
  492.      * @return Collection<int, Reception>
  493.      */
  494.     public function getReceptions(): Collection
  495.     {
  496.         return $this->receptions;
  497.     }
  498.     public function addReception(Reception $reception): self
  499.     {
  500.         if (!$this->receptions->contains($reception)) {
  501.             $this->receptions[] = $reception;
  502.             $reception->setVille($this);
  503.         }
  504.         return $this;
  505.     }
  506.     public function removeReception(Reception $reception): self
  507.     {
  508.         if ($this->receptions->removeElement($reception)) {
  509.             if ($reception->getVille() === $this) {
  510.                 $reception->setVille(null);
  511.             }
  512.         }
  513.         return $this;
  514.     }
  515.     /**
  516.      * @return Collection<int, Reception>
  517.      */
  518.     public function getDestville(): Collection
  519.     {
  520.         return $this->destville;
  521.     }
  522.     public function addDestville(Reception $destville): self
  523.     {
  524.         if (!$this->destville->contains($destville)) {
  525.             $this->destville[] = $destville;
  526.             $destville->setDestville($this);
  527.         }
  528.         return $this;
  529.     }
  530.     public function removeDestville(Reception $destville): self
  531.     {
  532.         if ($this->destville->removeElement($destville)) {
  533.             if ($destville->getDestville() === $this) {
  534.                 $destville->setDestville(null);
  535.             }
  536.         }
  537.         return $this;
  538.     }
  539.     public function getEstimateddateTextAirCargo(): ?string
  540.     {
  541.         return $this->estimateddateTextAirCargo;
  542.     }
  543.     public function setEstimateddateTextAirCargo(?string $estimateddateTextAirCargo): self
  544.     {
  545.         $this->estimateddateTextAirCargo = $estimateddateTextAirCargo;
  546.         return $this;
  547.     }
  548.     public function getEstimateddateTextSeaCargo(): ?string
  549.     {
  550.         return $this->estimateddateTextSeaCargo;
  551.     }
  552.     public function setEstimateddateTextSeaCargo(string $estimateddateTextSeaCargo): self
  553.     {
  554.         $this->estimateddateTextSeaCargo = $estimateddateTextSeaCargo;
  555.         return $this;
  556.     }
  557.     /**
  558.      * @return Collection<int, CategoriePrix>
  559.      */
  560.     public function getCategoriesPrix(): Collection
  561.     {
  562.         return $this->categoriesPrix;
  563.     }
  564.     public function addCategoriePrix(CategoriePrix $categoriePrix): self
  565.     {
  566.         if (!$this->categoriesPrix->contains($categoriePrix)) {
  567.             $this->categoriesPrix[] = $categoriePrix;
  568.             $categoriePrix->setVille($this);
  569.         }
  570.         return $this;
  571.     }
  572.     public function removeCategoriePrix(CategoriePrix $categoriePrix): self
  573.     {
  574.         if ($this->categoriesPrix->removeElement($categoriePrix)) {
  575.             if ($categoriePrix->getVille() === $this) {
  576.                 $categoriePrix->setVille(null);
  577.             }
  578.         }
  579.         return $this;
  580.     }
  581. }