src/Entity/Quotation.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Doctrine\ORM\Query\Expr\Math;
  5. /**
  6.  * @ORM\Entity(repositoryClass="App\Repository\QuotationRepository")
  7.  */
  8. class Quotation
  9. {
  10.     /**
  11.      * @ORM\Id()
  12.      * @ORM\GeneratedValue()
  13.      * @ORM\Column(type="integer")
  14.      */
  15.     private $id;
  16.     /**
  17.      * @ORM\Column(type="string", length=255, nullable=true)
  18.      */
  19.     private $numero;
  20.     /**
  21.      * @ORM\Column(type="datetime", nullable=true)
  22.      */
  23.     private $date_saisie;
  24.     /**
  25.      * @ORM\Column(type="string", length=255, nullable=true)
  26.      */
  27.     private $societe;
  28.     /**
  29.      * @ORM\Column(type="string", length=255, nullable=true)
  30.      */
  31.     private $destinataire;
  32.     /**
  33.      * @ORM\Column(type="string", length=255, nullable=true)
  34.      */
  35.     private $hscode;
  36.     /**
  37.      * @ORM\Column(type="string", length=255, nullable=true)
  38.      */
  39.     private $prix;
  40.     /**
  41.      * @ORM\ManyToOne(targetEntity="App\Entity\Incoterm", inversedBy="quotations")
  42.      */
  43.     private $incoterm;
  44.     /**
  45.      * @ORM\Column(type="string", length=255, nullable=true)
  46.      */
  47.     private $quantiteMin;
  48.     /**
  49.      * @ORM\Column(type="text", nullable=true)
  50.      */
  51.     private $dimension;
  52.     /**
  53.      * @ORM\Column(type="string", length=255, nullable=true)
  54.      */
  55.     private $poidsNet;
  56.     /**
  57.      * @ORM\Column(type="string", length=255, nullable=true)
  58.      */
  59.     private $poidsBrut;
  60.     /**
  61.      * @ORM\Column(type="string", length=255, nullable=true)
  62.      */
  63.     private $provenance;
  64.     /**
  65.      * @ORM\Column(type="string", length=255, nullable=true)
  66.      */
  67.     private $delaiDeLivraison;
  68.     /**
  69.      * @ORM\Column(type="text", nullable=true)
  70.      */
  71.     private $conditionsDeReglement;
  72.     
  73.     /**
  74.      * @ORM\Column(type="text", nullable=true)
  75.      */
  76.     private $liasseDocumentaire;
  77.     /**
  78.      * @ORM\Column(type="string", length=255, nullable=true)
  79.      */
  80.     private $mandant_num;
  81.     /**
  82.      * @ORM\ManyToOne(targetEntity="App\Entity\AdminDonneurOrdre", inversedBy="quotations")
  83.      */
  84.     private $mandat;
  85.     /**
  86.      * @ORM\Column(type="string", length=255, nullable=true)
  87.      */
  88.     private $vol_contractuel;
  89.     /**
  90.      * @ORM\Column(type="string", length=255, nullable=true)
  91.      */
  92.     private $destination;
  93.     /**
  94.      * @ORM\Column(type="datetime", nullable=true)
  95.      */
  96.     private $rlce1;
  97.     /**
  98.      * @ORM\Column(type="datetime", nullable=true)
  99.      */
  100.     private $rlce2;
  101.     /**
  102.      * @ORM\Column(type="datetime", nullable=true)
  103.      */
  104.     private $rlce3;
  105.     /**
  106.      * @ORM\Column(type="datetime")
  107.      */
  108.     private $createdAt;
  109.     /**
  110.      * @ORM\Column(type="string", length=255, nullable=true)
  111.      */
  112.     private $referent;
  113.     /**
  114.      * @ORM\Column(type="string", length=255, nullable=true)
  115.      */
  116.     private $validite;
  117.     /**
  118.      * @ORM\Column(type="string", length=255, nullable=true)
  119.      */
  120.     private $mandant;
  121.     /**
  122.      * @ORM\Column(type="string", length=255, nullable=true)
  123.      */
  124.     private $duree_validite;
  125.     /**
  126.      * @ORM\Column(type="string", length=255, nullable=true)
  127.      */
  128.     private $quantite;
  129.     /**
  130.      * @ORM\ManyToOne(targetEntity="App\Entity\Devise", inversedBy="quotations")
  131.      */
  132.     private $devise;
  133.     /**
  134.      * @ORM\ManyToOne(targetEntity="App\Entity\Status", inversedBy="quotations")
  135.      */
  136.     private $status;
  137.     /**
  138.      * @ORM\ManyToOne(targetEntity="App\Entity\PaymentMethod", inversedBy="quotations")
  139.      */
  140.     private $modeDeReglement;
  141.     /**
  142.      * @ORM\ManyToOne(targetEntity="App\Entity\Emballage", inversedBy="quotations")
  143.      */
  144.     private $emballage;
  145.     /**
  146.      * @ORM\ManyToOne(targetEntity="App\Entity\Conditionnement", inversedBy="quotations")
  147.      */
  148.     private $conditionnement;
  149.     /**
  150.      * @ORM\ManyToOne(targetEntity="App\Entity\Products", inversedBy="quotations")
  151.      */
  152.     private $produit;
  153.     /**
  154.      * @ORM\ManyToOne(targetEntity="App\Entity\SousJacent", inversedBy="quotations")
  155.      */
  156.     private $sous_jacent;
  157.     /**
  158.      * @ORM\ManyToOne(targetEntity="App\Entity\Unite", inversedBy="quotations")
  159.      */
  160.     private $unite;
  161.     public function __construct()
  162.     {
  163.         $this->createdAt = new \DateTime('now');
  164.         if (!isset($this->numero)){
  165.             $this->numero 'COT'.random_int(1,900).date('s');
  166.         }else{
  167.             $this->numero 'COT'.random_int(1,900).date('s');
  168.         }
  169.         $this->mandant_num 'Mandat'.random_int(1900);
  170.     }
  171.     public function getId(): ?int
  172.     {
  173.         return $this->id;
  174.     }
  175.     public function getNumero(): ?string
  176.     {
  177.         return $this->numero;
  178.     }
  179.     public function setNumero(string $numero): self
  180.     {
  181.         $this->numero $numero;
  182.         return $this;
  183.     }
  184.     public function getSociete(): ?string
  185.     {
  186.         return $this->societe;
  187.     }
  188.     public function setSociete(string $societe): self
  189.     {
  190.         $this->societe $societe;
  191.         return $this;
  192.     }
  193.     public function getDestinataire(): ?string
  194.     {
  195.         return $this->destinataire;
  196.     }
  197.     public function setDestinataire(string $destinataire): self
  198.     {
  199.         $this->destinataire $destinataire;
  200.         return $this;
  201.     }
  202.    
  203.     public function getHscode(): ?string
  204.     {
  205.         return $this->hscode;
  206.     }
  207.     public function setHscode(string $hscode): self
  208.     {
  209.         $this->hscode $hscode;
  210.         return $this;
  211.     }
  212.     public function getMandat(): ?AdminDonneurOrdre
  213.     {
  214.         return $this->mandat;
  215.     }
  216.     public function setMandat(?AdminDonneurOrdre $mandat): self
  217.     {
  218.         $this->mandat $mandat;
  219.         return $this;
  220.     }
  221.     public function getDateSaisie(): ?\DateTimeInterface
  222.     {
  223.         return $this->date_saisie;
  224.     }
  225.     public function setDateSaisie(?\DateTimeInterface $date_saisie): self
  226.     {
  227.         $this->date_saisie $date_saisie;
  228.         return $this;
  229.     }
  230.     
  231.     public function getDimension(): ?string
  232.     {
  233.         return $this->dimension;
  234.     }
  235.     public function setDimension(string $dimension): self
  236.     {
  237.         $this->dimension $dimension;
  238.         return $this;
  239.     }
  240.     public function getPoidsBrut(): ?string
  241.     {
  242.         return $this->poidsBrut;
  243.     }
  244.     public function setPoidsBrut(string $poidsBrut): self
  245.     {
  246.         $this->poidsBrut $poidsBrut;
  247.         return $this;
  248.     }
  249.     public function getProvenance(): ?string
  250.     {
  251.         return $this->provenance;
  252.     }
  253.     public function setProvenance(string $provenance): self
  254.     {
  255.         $this->provenance $provenance;
  256.         return $this;
  257.     }
  258.     public function getDelaiDeLivraison(): ?string
  259.     {
  260.         return $this->delaiDeLivraison;
  261.     }
  262.     public function setDelaiDeLivraison(string $delaiDeLivraison): self
  263.     {
  264.         $this->delaiDeLivraison $delaiDeLivraison;
  265.         return $this;
  266.     }
  267.     public function getConditionsDeReglement(): ?string
  268.     {
  269.         return $this->conditionsDeReglement;
  270.     }
  271.     public function setConditionsDeReglement(string $conditionsDeReglement): self
  272.     {
  273.         $this->conditionsDeReglement $conditionsDeReglement;
  274.         return $this;
  275.     }
  276.     public function getLiasseDocumentaire(): ?string
  277.     {
  278.         return $this->liasseDocumentaire;
  279.     }
  280.     public function setLiasseDocumentaire(string $liasseDocumentaire): self
  281.     {
  282.         $this->liasseDocumentaire $liasseDocumentaire;
  283.         return $this;
  284.     }
  285.     public function getCreatedAt(): ?\DateTimeInterface
  286.     {
  287.         return $this->createdAt;
  288.     }
  289.     public function setCreatedAt(\DateTimeInterface $createdAt): self
  290.     {
  291.         $this->createdAt $createdAt;
  292.         return $this;
  293.     }
  294.     public function getIncoterm():?Incoterm
  295.     {
  296.         return $this->incoterm;
  297.     }
  298.     public function setIncoterm(?Incoterm $incoterm):self
  299.     {
  300.         $this->incoterm $incoterm;
  301.         return $this;
  302.     }
  303.     /**
  304.      * @return mixed
  305.      */
  306.     public function getMandantNum()
  307.     {
  308.         return $this->mandant_num;
  309.     }
  310.     /**
  311.      * @param mixed $mandant_num
  312.      * @return Quotation
  313.      */
  314.     public function setMandantNum($mandant_num)
  315.     {
  316.         $this->mandant_num $mandant_num;
  317.         return $this;
  318.     }
  319.     /**
  320.      * @return mixed
  321.      */
  322.     public function getVolContractuel()
  323.     {
  324.         return $this->vol_contractuel;
  325.     }
  326.     /**
  327.      * @param mixed $vol_contractuel
  328.      * @return Quotation
  329.      */
  330.     public function setVolContractuel($vol_contractuel)
  331.     {
  332.         $this->vol_contractuel $vol_contractuel;
  333.         return $this;
  334.     }
  335.     /**
  336.      * @return mixed
  337.      */
  338.     public function getDestination()
  339.     {
  340.         return $this->destination;
  341.     }
  342.     /**
  343.      * @param mixed $destination
  344.      * @return Quotation
  345.      */
  346.     public function setDestination($destination)
  347.     {
  348.         $this->destination $destination;
  349.         return $this;
  350.     }
  351.     public function getRlce1():?\DateTimeInterface
  352.     {
  353.         return $this->rlce1;
  354.     }
  355.     
  356.     public function setRlce1(?\DateTimeInterface $rlce1)
  357.     {
  358.         $this->rlce1 $rlce1;
  359.         return $this;
  360.     }
  361.     public function getRlce2():?\DateTimeInterface
  362.     {
  363.         return $this->rlce2;
  364.     }
  365.     public function setRlce2(?\DateTimeInterface $rlce2)
  366.     {
  367.         $this->rlce2 $rlce2;
  368.         return $this;
  369.     }
  370.     public function getRlce3():?\DateTimeInterface
  371.     {
  372.         return $this->rlce3;
  373.     }
  374.     public function setRlce3(?\DateTimeInterface $rlce3)
  375.     {
  376.         $this->rlce3 $rlce3;
  377.         return $this;
  378.     }
  379.     /**
  380.      * @return mixed
  381.      */
  382.     public function getPrix(): ?string
  383.     {
  384.         return $this->prix;
  385.     }
  386.     /**
  387.      * @param mixed $prix
  388.      * @return Quotation
  389.      */
  390.     public function setPrix(?string $prix):self
  391.     {
  392.         $this->prix $prix;
  393.         return $this;
  394.     }
  395.     /**
  396.      * @return mixed
  397.      */
  398.     public function getQuantiteMin():?string
  399.     {
  400.         return $this->quantiteMin;
  401.     }
  402.     /**
  403.      * @param mixed $quantiteMin
  404.      * @return Quotation
  405.      */
  406.     public function setQuantiteMin(?string $quantiteMin):self
  407.     {
  408.         $this->quantiteMin $quantiteMin;
  409.         return $this;
  410.     }
  411.     /**
  412.      * @return mixed
  413.      */
  414.     public function getPoidsNet():?string
  415.     {
  416.         return $this->poidsNet;
  417.     }
  418.     /**
  419.      * @param mixed $poidsNet
  420.      * @return Quotation
  421.      */
  422.     public function setPoidsNet(?string $poidsNet):self
  423.     {
  424.         $this->poidsNet $poidsNet;
  425.         return $this;
  426.     }
  427.     public function __toString(){
  428.         return $this->numero;
  429.     }
  430.     public function getReferent(): ?string
  431.     {
  432.         return $this->referent;
  433.     }
  434.     public function setReferent(?string $referent): self
  435.     {
  436.         $this->referent $referent;
  437.         return $this;
  438.     }
  439.     public function getValidite(): ?string
  440.     {
  441.         return $this->validite;
  442.     }
  443.     public function setValidite(?string $validite): self
  444.     {
  445.         $this->validite $validite;
  446.         return $this;
  447.     }
  448.     public function getMandant(): ?string
  449.     {
  450.         return $this->mandant;
  451.     }
  452.     public function setMandant(?string $mandant): self
  453.     {
  454.         $this->mandant $mandant;
  455.         return $this;
  456.     }
  457.     public function getDureeValidite(): ?string
  458.     {
  459.         return $this->duree_validite;
  460.     }
  461.     public function setDureeValidite(?string $duree_validite): self
  462.     {
  463.         $this->duree_validite $duree_validite;
  464.         return $this;
  465.     }
  466.     public function getQuantite(): ?int
  467.     {
  468.         return $this->quantite;
  469.     }
  470.     public function setQuantite(?int $quantite): self
  471.     {
  472.         $this->quantite $quantite;
  473.         return $this;
  474.     }
  475.     public function getDevise(): ?Devise
  476.     {
  477.         return $this->devise;
  478.     }
  479.     public function setDevise(?Devise $devise): self
  480.     {
  481.         $this->devise $devise;
  482.         return $this;
  483.     }
  484.     public function getStatus(): ?Status
  485.     {
  486.         return $this->status;
  487.     }
  488.     public function setStatus(?Status $status): self
  489.     {
  490.         $this->status $status;
  491.         return $this;
  492.     }
  493.     public function getModeDeReglement(): ?PaymentMethod
  494.     {
  495.         return $this->modeDeReglement;
  496.     }
  497.     public function setModeDeReglement(?PaymentMethod $modeDeReglement): self
  498.     {
  499.         $this->modeDeReglement $modeDeReglement;
  500.         return $this;
  501.     }
  502.     public function getEmballage(): ?Emballage
  503.     {
  504.         return $this->emballage;
  505.     }
  506.     public function setEmballage(?Emballage $emballage): self
  507.     {
  508.         $this->emballage $emballage;
  509.         return $this;
  510.     }
  511.     public function getConditionnement(): ?Conditionnement
  512.     {
  513.         return $this->conditionnement;
  514.     }
  515.     public function setConditionnement(?Conditionnement $conditionnement): self
  516.     {
  517.         $this->conditionnement $conditionnement;
  518.         return $this;
  519.     }
  520.     public function getProduit(): ?Products
  521.     {
  522.         return $this->produit;
  523.     }
  524.     public function setProduit(?Products $produit): self
  525.     {
  526.         $this->produit $produit;
  527.         return $this;
  528.     }
  529.     public function getSousJacent(): ?SousJacent
  530.     {
  531.         return $this->sous_jacent;
  532.     }
  533.     public function setSousJacent(?SousJacent $sous_jacent): self
  534.     {
  535.         $this->sous_jacent $sous_jacent;
  536.         return $this;
  537.     }
  538.     public function getUnite(): ?Unite
  539.     {
  540.         return $this->unite;
  541.     }
  542.     public function setUnite(?Unite $unite): self
  543.     {
  544.         $this->unite $unite;
  545.         return $this;
  546.     }
  547. }