<?php
/**
* TransfertDetail.php
* Created by Stéphane Brun
* Date: 2018-09-19 at 15:11
*/
namespace App\Entity;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity()
* @ORM\Table(name="transfert_detail")
*/
class TransfertDetail
{
/**
* @ORM\Column(type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
/**
* @ORM\Column(name="quantite", type="integer")
*/
protected $quantite = 0;
/**
* has one Titre
*
* @ORM\ManyToOne(targetEntity="App\Entity\Titre")
* @ORM\JoinColumn(name="titre_id", referencedColumnName="TISBN")
*/
protected $produit;
/**
* has one Transfert
*
* @ORM\ManyToOne(targetEntity="App\Entity\Transfert", inversedBy="details")
* @ORM\JoinColumn(name="transfert_id", referencedColumnName="id")
*/
protected $transfert;
/**
* @return mixed
*/
public function getId()
{
return $this->id;
}
/**
* @return mixed
*/
public function getTransfert()
{
return $this->transfert;
}
/**
* @param Transfert $transfert
* @return TransfertDetail
*/
public function setTransfert(Transfert $transfert)
{
$this->transfert = $transfert;
return $this;
}
/**
* @return mixed
*/
public function getQuantite()
{
return $this->quantite;
}
/**
* @param mixed $quantite
* @return TransfertDetail
*/
public function setQuantite($quantite)
{
$this->quantite = $quantite;
return $this;
}
/**
* @return mixed
*/
public function getProduit()
{
return $this->produit;
}
/**
* @param titre $produit
* @return TransfertDetail
*/
public function setProduit(Titre $produit)
{
$this->produit = $produit;
return $this;
}
}