<?php
namespace App\Entity;
use App\Repository\CommandeDetailsRepository;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: CommandeDetailsRepository::class)]
class CommandeDetails
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\Column]
private ?int $produit_qtt_cmd = null;
#[ORM\ManyToOne(inversedBy: 'commandeDetails')]
#[ORM\JoinColumn(nullable: false)]
private ?Commande $commande = null;
#[ORM\ManyToOne(inversedBy: 'commandeDetails')]
#[ORM\JoinColumn(nullable: false)]
private ?Produit $produit = null;
#[ORM\ManyToOne(inversedBy: 'commandeDetails')]
private ?ProduitVariant $produitVariant = null;
// ici productVariant
public function __construct()
{
}
public function getId(): ?int
{
return $this->id;
}
public function getProduitQttCmd(): ?int
{
return $this->produit_qtt_cmd;
}
public function setProduitQttCmd(int $produit_qtt_cmd): self
{
$this->produit_qtt_cmd = $produit_qtt_cmd;
return $this;
}
public function getCommande(): ?Commande
{
return $this->commande;
}
public function setCommande(?Commande $commande): self
{
$this->commande = $commande;
return $this;
}
public function getProduit(): ?Produit
{
return $this->produit;
}
public function setProduit(?Produit $produit): self
{
$this->produit = $produit;
return $this;
}
public function getProduitVariant(): ?ProduitVariant
{
return $this->produitVariant;
}
public function setProduitVariant(?ProduitVariant $produitVariant): static
{
$this->produitVariant = $produitVariant;
return $this;
}
}