<?php
namespace App\Entity\Utilisateur;
use App\Entity\GestionComerciale\Commande;
use App\Entity\GestionComerciale\CommandeFournisseur;
use App\Entity\GestionComerciale\Fabrication;
use DateTime;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use Symfony\Component\Validator\Constraints as Assert;
/**
* HistoriqueIntervention
*
* @ORM\Table("utilisateur__historique_intervention")
* @ORM\Entity(repositoryClass="App\Repository\Utilisateur\HistoriqueInterventionRepository")
*/
class HistoriqueIntervention
{
/**
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
private $id;
/**
* @ORM\Column(name="date", type="datetime", nullable=true)
*/
private $date;
/**
* @ORM\Column(name="action", type="text", nullable=true)
*/
private $action;
/**
* @ORM\Column(name="dateDebut", type="datetime", nullable=true)
*/
private $dateDebut;
/**
* @ORM\Column(name="dateFin", type="datetime", nullable=true)
*/
private $dateFin;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\Utilisateur\Utilisateur", inversedBy="historiqueIntervention")
* @ORM\JoinColumn(nullable=false)
*/
private $utilisateur;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\GestionComerciale\Commande", inversedBy="historiqueIntervention")
* @ORM\JoinColumn(nullable=true)
*/
private $commande;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\GestionComerciale\Fabrication", inversedBy="historiqueIntervention")
* @ORM\JoinColumn(nullable=true)
*/
private $fabrication;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\GestionComerciale\CommandeFournisseur", inversedBy="historiqueIntervention")
* @ORM\JoinColumn(nullable=true)
*/
private $commandeFournisseur;
public function __construct()
{
$this->date = new Datetime();
$this->dateIntervention = new Datetime();
}
public function getId(): int
{
return $this->id;
}
public function setDate(?DateTime $date): HistoriqueIntervention
{
$this->date = $date;
return $this;
}
public function getDate(): ?DateTime
{
return $this->date;
}
public function setDateDebut(?DateTime $dateDebut): HistoriqueIntervention
{
$this->dateDebut = $dateDebut;
return $this;
}
public function getDateDebut(): ?DateTime
{
return $this->dateDebut;
}
public function setDateFin(?DateTime $dateFin): HistoriqueIntervention
{
$this->dateFin = $dateFin;
return $this;
}
public function getDateFin(): ?DateTime
{
return $this->dateFin;
}
public function setAction(?string $action): HistoriqueIntervention
{
$this->action = $action;
return $this;
}
public function getAction(): ?string
{
return $this->action;
}
public function setUtilisateur(?Utilisateur $utilisateur): HistoriqueIntervention
{
$this->utilisateur = $utilisateur;
return $this;
}
public function getUtilisateur(): ?Utilisateur
{
return $this->utilisateur;
}
public function setCommande(?Commande $commande): HistoriqueIntervention
{
$this->commande = $commande;
return $this;
}
public function getCommande(): ?Commande
{
return $this->commande;
}
public function setFabrication(?Fabrication $fabrication): HistoriqueIntervention
{
$this->fabrication = $fabrication;
return $this;
}
public function getFabrication(): ?Fabrication
{
return $this->fabrication;
}
public function setCommandeFournisseur(?CommandeFournisseur $commandeFournisseur): HistoriqueIntervention
{
$this->commandeFournisseur = $commandeFournisseur;
return $this;
}
public function getCommandeFournisseur(): ?CommandeFournisseur
{
return $this->commandeFournisseur;
}
}