<?php
namespace App\Entity\Slave;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Table(name="eposm_s_product_log")
* @ORM\Entity(repositoryClass="App\Repository\Slave\ProductLogRepository")
*/
class ProductLog
{
/**
* @ORM\Column(name="id", type="bigint")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
/**
* @ORM\Column(name="text", type="text", nullable=true)
*/
protected $text;
/**
* @ORM\Column(name="datetime", type="datetime")
*/
protected $datetime;
/**
* @ORM\Column(name="type", type="string", length=191)
*/
protected $type;
/**
* @ORM\Column(name="old_data_id", type="string", length=191, nullable=true)
*/
protected $oldDataId;
// ManyToOne
/**
* @ORM\ManyToOne(targetEntity="App\Entity\Slave\Product", inversedBy="logs")
* @ORM\JoinColumn(name="product_id", referencedColumnName="id")
*/
private $product;
/**
* @ORM\ManyToOne(targetEntity="App\Entity\Slave\Intervention", inversedBy="productLogs")
* @ORM\JoinColumn(name="intervention_id", referencedColumnName="id")
*/
private $intervention;
//
public function getId(): ?string
{
return $this->id;
}
public function getText(): ?string
{
return $this->text;
}
public function setText(?string $text): static
{
$this->text = $text;
return $this;
}
public function getDatetime(): ?\DateTimeInterface
{
return $this->datetime;
}
public function setDatetime(\DateTimeInterface $datetime): static
{
$this->datetime = $datetime;
return $this;
}
public function getType(): ?string
{
return $this->type;
}
public function setType(string $type): static
{
$this->type = $type;
return $this;
}
public function getOldDataId(): ?string
{
return $this->oldDataId;
}
public function setOldDataId(?string $oldDataId): static
{
$this->oldDataId = $oldDataId;
return $this;
}
public function getProduct(): ?Product
{
return $this->product;
}
public function setProduct(?Product $product): static
{
$this->product = $product;
return $this;
}
public function getIntervention(): ?Intervention
{
return $this->intervention;
}
public function setIntervention(?Intervention $intervention): static
{
$this->intervention = $intervention;
return $this;
}
}