src/Entity/AdminFinance/Bank/BankMouvement.php line 14

  1. <?php
  2. namespace App\Entity\AdminFinance\Bank;
  3. use App\Entity\AdminFinance\Bank\BankCompte;
  4. use App\Entity\AdminFinance\Bank\BankMouvementCategorie;
  5. use App\Entity\AdminFinance\Bank\BankTag;
  6. use App\Entity\AdminFinance\Bank\BankTiers;
  7. use App\Repository\AdminFinance\Bank\BankMouvementRepository;
  8. use Doctrine\DBAL\Types\Types;
  9. use Doctrine\ORM\Mapping as ORM;
  10. #[ORM\Entity(repositoryClassBankMouvementRepository::class)]
  11. class BankMouvement
  12. {
  13.     #[ORM\Id]
  14.     #[ORM\GeneratedValue]
  15.     #[ORM\Column]
  16.     private ?int $id null;
  17.     #[ORM\ManyToOne(targetEntityBankCompte::class)]
  18.     #[ORM\JoinColumn(nullabletrue)]
  19.     private ?BankCompte $compteDebit null;
  20.     #[ORM\ManyToOne(targetEntityBankCompte::class)]
  21.     #[ORM\JoinColumn(nullabletrue)]
  22.     private ?BankCompte $compteCredit null;
  23.     #[ORM\Column(length100nullabletrue)]
  24.     private ?string $description null;
  25.     #[ORM\ManyToOne(targetEntity:BankMouvementCategorie::class)]
  26.     #[ORM\JoinColumn(nullablefalse)]
  27.     private ?BankMouvementCategorie $categorie null;
  28.     #[ORM\Column]
  29.     private ?float $montant null;
  30.     #[ORM\Column(typeTypes::DATE_MUTABLE)]
  31.     private ?\DateTimeInterface $dateOperation null;
  32.     #[ORM\ManyToOne(targetEntity:BankTiers::class)]
  33.     private ?BankTiers $tiers null;
  34.     #[ORM\Column(length10nullabletrue)]
  35.     private ?string $numero null;
  36.     #[ORM\ManyToOne(targetEntity:BankTag::class, inversedBy'bankMouvements')]
  37.     private ?BankTag $tags null;
  38.     #[ORM\Column]
  39.     private ?bool $checked null;
  40.     #[ORM\Column(length5nullabletrue)]
  41.     private ?string $indexFiscal null;
  42.     public function __construct()
  43.     {
  44.         $this->dateOperation = new \DateTime();
  45.         $this->checked false;
  46.     }
  47.     public function getId(): ?int
  48.     {
  49.         return $this->id;
  50.     }
  51.     /**
  52.      * @return ?BankCompte
  53.      */
  54.     public function getCompteDebit(): ?BankCompte
  55.     {
  56.         return $this->compteDebit;
  57.     }
  58.     public function setCompteDebit(?BankCompte $compteDebit): self
  59.     {
  60.         $this->compteDebit $compteDebit;
  61.         return $this;
  62.     }
  63.     /**
  64.      * @return ?BankCompte
  65.      */
  66.     public function getCompteCredit(): ?BankCompte
  67.     {
  68.         return $this->compteCredit;
  69.     }
  70.     public function setCompteCredit(?BankCompte $compteCredit): self
  71.     {
  72.         $this->compteCredit $compteCredit;
  73.         return $this;
  74.     }
  75.     public function getDescription(): ?string
  76.     {
  77.         return $this->description;
  78.     }
  79.     public function setDescription(?string $description): self
  80.     {
  81.         $this->description $description;
  82.         return $this;
  83.     }
  84.     public function getCategorie(): ?BankMouvementCategorie
  85.     {
  86.         return $this->categorie;
  87.     }
  88.     public function setCategorie(?BankMouvementCategorie $categorie): self
  89.     {
  90.         $this->categorie $categorie;
  91.         return $this;
  92.     }
  93.     public function getMontant(): ?float
  94.     {
  95.         return $this->montant;
  96.     }
  97.     public function setMontant(float $montant): self
  98.     {
  99.         $this->montant $montant;
  100.         return $this;
  101.     }
  102.     public function getDateOperation(): ?\DateTimeInterface
  103.     {
  104.         return $this->dateOperation;
  105.     }
  106.     public function setDateOperation(\DateTimeInterface $dateOperation): self
  107.     {
  108.         $this->dateOperation $dateOperation;
  109.         return $this;
  110.     }
  111.     public function getTiers(): ?BankTiers
  112.     {
  113.         return $this->tiers;
  114.     }
  115.     public function setTiers(?BankTiers $tiers): self
  116.     {
  117.         $this->tiers $tiers;
  118.         return $this;
  119.     }
  120.     public function getNumero(): ?string
  121.     {
  122.         return $this->numero;
  123.     }
  124.     public function setNumero(?string $numero): self
  125.     {
  126.         $this->numero $numero;
  127.         return $this;
  128.     }
  129.     public function getTags(): ?BankTag
  130.     {
  131.         return $this->tags;
  132.     }
  133.     public function setTags(?BankTag $tags): self
  134.     {
  135.         $this->tags $tags;
  136.         return $this;
  137.     }
  138.     public function isChecked(): ?bool
  139.     {
  140.         return $this->checked;
  141.     }
  142.     public function setChecked(bool $checked): self
  143.     {
  144.         $this->checked $checked;
  145.         return $this;
  146.     }
  147.     public function getIndexFiscal(): ?string
  148.     {
  149.         return $this->indexFiscal;
  150.     }
  151.     public function setIndexFiscal(?string $indexFiscal): self
  152.     {
  153.         $this->indexFiscal $indexFiscal;
  154.         return $this;
  155.     }
  156.     public function getClass(): string
  157.     {
  158.         return BankMouvement::class;
  159.     }
  160. }