src/Entity/GestionComerciale/MouvementCaisse.php line 25

Open in your IDE?
  1. <?php
  2. namespace App\Entity\GestionComerciale;
  3. use App\Entity\Clients\Client;
  4. use App\Entity\Export\Export;
  5. use App\Entity\FO\CompteBancaire;
  6. use App\Entity\Fournisseurs\Fournisseur;
  7. use App\Entity\Utilisateur\Utilisateur;
  8. use DateTime;
  9. use Doctrine\ORM\Mapping as ORM;
  10. use Gedmo\Mapping\Annotation as Gedmo;
  11. use Symfony\Component\Validator\Constraints as Assert;
  12. use Symfony\Component\Validator\ExecutionContextInterface;
  13. use App\Annotations\SecuredEntity;
  14. /**
  15.  * MouvementCaisse
  16.  *
  17.  * @ORM\Table("commerciale__mouvement_caisse")
  18.  * @ORM\Entity(repositoryClass="App\Repository\GestionComerciale\MouvementCaisseRepository")
  19.  * @Gedmo\SoftDeleteable(fieldName="dateSuppression",timeAware=false)
  20.  * @SecuredEntity(name="Mouvement de Caisse", group="COMPTABILITE")
  21.  */
  22. class MouvementCaisse
  23. {
  24.     /**
  25.      * @ORM\Column(name="id", type="integer")
  26.      * @ORM\Id
  27.      * @ORM\GeneratedValue(strategy="AUTO")
  28.      */
  29.     private $id;
  30.     /**
  31.      * @ORM\Column(name="libelle", type="string", length=255)
  32.      */
  33.     private $libelle;
  34.     /**
  35.      * @ORM\Column(name="montant", type="float")
  36.      */
  37.     private $montant;
  38.     /**
  39.      * @ORM\Column(name="EntreeSortie", type="boolean")
  40.      */
  41.     private $entreeSortie;
  42.     
  43.     /**
  44.      * @ORM\ManyToOne(targetEntity="App\Entity\Utilisateur\Utilisateur", inversedBy="mouvementsCaisse")
  45.      * @ORM\JoinColumn(nullable=true)
  46.      */
  47.     private $utilisateur;
  48.     
  49.     /**
  50.      * @ORM\Column(name="date", type="datetime", nullable=true)
  51.      */
  52.     private $date;
  53.     /**
  54.      * @ORM\Column(name="dateSuppression", type="datetime", nullable=true)
  55.      */
  56.     private $dateSuppression;
  57.     /**
  58.      * @ORM\Column(name="dateMaj", type="datetime", nullable=true)
  59.      * @Gedmo\Timestampable(on="update")
  60.      */
  61.     private $dateMaj;
  62.     
  63.     /**
  64.      * @ORM\Column(name="transfert_compta", type="boolean")
  65.      */
  66.     private $transfertCompta;
  67.     
  68.     /**
  69.      * @ORM\ManyToOne(targetEntity="App\Entity\GestionComerciale\TypeMouvementCaisse", inversedBy="mouvementsCaisse")
  70.      */
  71.     private $typeMouvementCaisse;
  72.     
  73.     /**
  74.      * @ORM\Column(name="montant_caisse", type="float")
  75.      */
  76.     private $montantCaisse;
  77.     
  78.     /**
  79.      * @ORM\OneToOne(targetEntity="App\Entity\GestionComerciale\Acompte", inversedBy="mouvementCaisse")
  80.      * @ORM\JoinColumn(nullable=true)
  81.      */
  82.     private $reglement;
  83.     
  84.     /**
  85.      * @ORM\ManyToOne(targetEntity="App\Entity\FO\CompteBancaire", inversedBy="mouvementsCaisse")
  86.      * @ORM\JoinColumn(nullable=true)
  87.      */
  88.     private $compteBancaire;
  89.     
  90.     /**
  91.      * @ORM\Column(name="date_transfert_compta", type="datetime", nullable=true)
  92.      */
  93.     private $dateTransfertCompta;
  94.     
  95.     /**
  96.      * @ORM\Column(name="compta", type="string", length=255, nullable=true)
  97.      */
  98.     private $compta;
  99.     
  100.     /**
  101.      * @ORM\ManyToOne(targetEntity="App\Entity\Fournisseurs\Fournisseur", inversedBy="mouvementsCaisse")
  102.      * @ORM\JoinColumn(nullable=true)
  103.      * @Assert\Valid
  104.      */
  105.     private $fournisseur;
  106.     
  107.     /**
  108.      * @ORM\ManyToOne(targetEntity="App\Entity\Clients\Client", inversedBy="mouvementsCaisse")
  109.      * @ORM\JoinColumn(nullable=true)
  110.      */
  111.     private $client;
  112.     /**
  113.      * @ORM\ManyToOne(targetEntity="App\Entity\Export\Export")
  114.      * @ORM\JoinColumn(nullable=true)
  115.      */
  116.     private $exportCompta;
  117.         
  118.     public function __construct()
  119.     {
  120.         $this->date = new Datetime();
  121.             $this->entreeSortie     true;
  122.             $this->transfertCompta  false;
  123.             $this->montantCaisse    0;
  124.             $this->montant          0;
  125.     }
  126.     public function getId(): int
  127.     {
  128.         return $this->id;
  129.     }
  130.     public function setLibelle(string $libelle): MouvementCaisse
  131.     {
  132.         $this->libelle $libelle;
  133.         return $this;
  134.     }
  135.     public function getLibelle(): string
  136.     {
  137.         return $this->libelle;
  138.     }
  139.     public function setMontant(float $montant): MouvementCaisse
  140.     {
  141.         $this->montant $montant;
  142.         return $this;
  143.     }
  144.     public function getMontant(): float
  145.     {
  146.         return $this->montant;
  147.     }
  148.     public function setEntreeSortie(bool $entreeSortie): MouvementCaisse
  149.     {
  150.         $this->entreeSortie $entreeSortie;
  151.         return $this;
  152.     }
  153.     public function getEntreeSortie(): bool
  154.     {
  155.         return $this->entreeSortie;
  156.     }
  157.     public function setDate(?DateTime $date): MouvementCaisse
  158.     {
  159.         $this->date $date;
  160.         return $this;
  161.     }
  162.     public function getDate(): ?DateTime
  163.     {
  164.         return $this->date;
  165.     }
  166.     public function setDateSuppression(?DateTime $dateSuppression): MouvementCaisse
  167.     {
  168.         $this->dateSuppression $dateSuppression;
  169.         return $this;
  170.     }
  171.     public function getDateSuppression(): ?DateTime
  172.     {
  173.         return $this->dateSuppression;
  174.     }
  175.     public function setDateMaj(?DateTime $dateMaj): MouvementCaisse
  176.     {
  177.         $this->dateMaj $dateMaj;
  178.         return $this;
  179.     }
  180.     public function getDateMaj(): ?DateTime
  181.     {
  182.         return $this->dateMaj;
  183.     }
  184.     public function setTransfertCompta(bool $transfertCompta): MouvementCaisse
  185.     {
  186.         $this->transfertCompta $transfertCompta;
  187.         return $this;
  188.     }
  189.     public function getTransfertCompta(): bool
  190.     {
  191.         return $this->transfertCompta;
  192.     }
  193.     public function setUtilisateur(?Utilisateur $utilisateur): MouvementCaisse
  194.     {
  195.         $this->utilisateur $utilisateur;
  196.         return $this;
  197.     }
  198.     public function getUtilisateur(): ?Utilisateur
  199.     {
  200.         return $this->utilisateur;
  201.     }
  202.     public function setTypeMouvementCaisse(?TypeMouvementCaisse $typeMouvementCaisse): MouvementCaisse
  203.     {
  204.         $this->typeMouvementCaisse $typeMouvementCaisse;
  205.         return $this;
  206.     }
  207.     public function getTypeMouvementCaisse(): ?TypeMouvementCaisse
  208.     {
  209.         return $this->typeMouvementCaisse;
  210.     }
  211.     public function setMontantCaisse(float $montantCaisse): MouvementCaisse
  212.     {
  213.         $this->montantCaisse $montantCaisse;
  214.         return $this;
  215.     }
  216.     public function getMontantCaisse(): float
  217.     {
  218.         return $this->montantCaisse;
  219.     }
  220.     public function setReglement(?Acompte $reglement): MouvementCaisse
  221.     {
  222.         $this->reglement $reglement;
  223.         return $this;
  224.     }
  225.     public function getReglement(): ?Acompte
  226.     {
  227.         return $this->reglement;
  228.     }
  229.     public function setCompteBancaire(?CompteBancaire $compteBancaire): MouvementCaisse
  230.     {
  231.         $this->compteBancaire $compteBancaire;
  232.         return $this;
  233.     }
  234.     public function getCompteBancaire(): ?CompteBancaire
  235.     {
  236.         return $this->compteBancaire;
  237.     }
  238.     public function setDateTransfertCompta(?DateTime $dateTransfertCompta): MouvementCaisse
  239.     {
  240.         $this->dateTransfertCompta $dateTransfertCompta;
  241.         return $this;
  242.     }
  243.     public function getDateTransfertCompta(): ?DateTime
  244.     {
  245.         return $this->dateTransfertCompta;
  246.     }
  247.     public function setCompta(?string $compta): MouvementCaisse
  248.     {
  249.         $this->compta $compta;
  250.         return $this;
  251.     }
  252.     public function getCompta(): ?string
  253.     {
  254.         return $this->compta;
  255.     }
  256.     public function setFournisseur(?Fournisseur $fournisseur): MouvementCaisse
  257.     {
  258.         $this->fournisseur $fournisseur;
  259.         return $this;
  260.     }
  261.     public function getFournisseur(): ?Fournisseur
  262.     {
  263.         return $this->fournisseur;
  264.     }
  265.     public function setClient(?Client $client): MouvementCaisse
  266.     {
  267.         $this->client $client;
  268.         return $this;
  269.     }
  270.     public function getClient(): ?Client
  271.     {
  272.         return $this->client;
  273.     }
  274.     public function setExportCompta(?Export $exportCompta): MouvementCaisse
  275.     {
  276.         $this->exportCompta $exportCompta;
  277.         return $this;
  278.     }
  279.     public function getExportCompta(): ?Export
  280.     {
  281.         return $this->exportCompta;
  282.     }
  283. }