<?php
namespace App\Entity;
use App\Repository\BondesortieRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: BondesortieRepository::class)]
class Bondesortie
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $nomprenom = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $adresse = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $telephone = null;
#[ORM\Column(type: Types::DATETIME_MUTABLE, nullable: true)]
private ?\DateTimeInterface $datecreation = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $numbs = null;
#[ORM\Column(type: Types::DATETIME_MUTABLE, nullable: true)]
private ?\DateTimeInterface $date = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $totaleqte = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $totaleht = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $totaltva = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $totalttc = null;
#[ORM\OneToMany(mappedBy: 'bondesorte', targetEntity: Lignebondesortie::class, cascade: ["remove"])]
private Collection $lignebondesorties;
#[ORM\ManyToOne(inversedBy: 'bondesorties')]
private ?Fournisseur $vendeur = null;
#[ORM\ManyToOne(inversedBy: 'bondesorties')]
private ?Client $client = null;
public function __construct()
{
$this->lignebondesorties = new ArrayCollection();
}
public function getId(): ?int
{
return $this->id;
}
public function getNomprenom(): ?string
{
return $this->nomprenom;
}
public function setNomprenom(?string $nomprenom): self
{
$this->nomprenom = $nomprenom;
return $this;
}
public function getAdresse(): ?string
{
return $this->adresse;
}
public function setAdresse(?string $adresse): self
{
$this->adresse = $adresse;
return $this;
}
public function getTelephone(): ?string
{
return $this->telephone;
}
public function setTelephone(?string $telephone): self
{
$this->telephone = $telephone;
return $this;
}
public function getDatecreation(): ?\DateTimeInterface
{
return $this->datecreation;
}
public function setDatecreation(?\DateTimeInterface $datecreation): self
{
$this->datecreation = $datecreation;
return $this;
}
public function getNumbs(): ?string
{
return $this->numbs;
}
public function setNumbs(?string $numbs): self
{
$this->numbs = $numbs;
return $this;
}
public function getDate(): ?\DateTimeInterface
{
return $this->date;
}
public function setDate(?\DateTimeInterface $date): self
{
$this->date = $date;
return $this;
}
public function getTotaleqte(): ?string
{
return $this->totaleqte;
}
public function setTotaleqte(?string $totaleqte): self
{
$this->totaleqte = $totaleqte;
return $this;
}
public function getTotaleht(): ?string
{
return $this->totaleht;
}
public function setTotaleht(?string $totaleht): self
{
$this->totaleht = $totaleht;
return $this;
}
public function getTotaltva(): ?string
{
return $this->totaltva;
}
public function setTotaltva(?string $totaltva): self
{
$this->totaltva = $totaltva;
return $this;
}
public function getTotalttc(): ?string
{
return $this->totalttc;
}
public function setTotalttc(?string $totalttc): self
{
$this->totalttc = $totalttc;
return $this;
}
/**
* @return Collection<int, Lignebondesortie>
*/
public function getLignebondesorties(): Collection
{
return $this->lignebondesorties;
}
public function addLignebondesorty(Lignebondesortie $lignebondesorty): self
{
if (!$this->lignebondesorties->contains($lignebondesorty)) {
$this->lignebondesorties->add($lignebondesorty);
$lignebondesorty->setBondesorte($this);
}
return $this;
}
public function removeLignebondesorty(Lignebondesortie $lignebondesorty): self
{
if ($this->lignebondesorties->removeElement($lignebondesorty)) {
// set the owning side to null (unless already changed)
if ($lignebondesorty->getBondesorte() === $this) {
$lignebondesorty->setBondesorte(null);
}
}
return $this;
}
public function getVendeur(): ?Fournisseur
{
return $this->vendeur;
}
public function setVendeur(?Fournisseur $vendeur): self
{
$this->vendeur = $vendeur;
return $this;
}
public function getClient(): ?Client
{
return $this->client;
}
public function setClient(?Client $client): self
{
$this->client = $client;
return $this;
}
}