<?php
namespace App\Entity;
use App\Repository\CaseLaboratoryRepository;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
#[ORM\Entity(repositoryClass: CaseLaboratoryRepository::class), ORM\Table(name: 'case_lab_tests')]
class CaseLaboratory
{
#[ORM\Id, ORM\GeneratedValue, ORM\Column(type: 'integer')]
private $id;
#[ORM\ManyToOne(targetEntity: Cases::class, inversedBy: 'labTests'), ORM\JoinColumn(name: 'case_id', nullable: false)]
private $case;
#[ORM\ManyToOne(targetEntity: LabTest::class), ORM\JoinColumn(nullable: false)]
private $labTest;
#[ORM\Column(type: 'string', length: 255, nullable: true)]
private $instruct;
#[ORM\Column(type: 'string', length: 255, nullable: true)]
private $fileUrl;
#[ORM\ManyToOne(targetEntity: Sample::class)]
private $sample;
#[ORM\ManyToOne(targetEntity: TestMethod::class)]
private $method;
#[ORM\ManyToOne(targetEntity: Hospital::class), ORM\JoinColumn(nullable: false)]
private $hospital;
#[ORM\Column(type: 'string', length: 255, nullable: true)]
private $result;
#[ORM\Column(type: 'boolean')]
private bool $isReferral = false;
#[ORM\Column(type: 'boolean')]
private bool $isOpinion = false;
#[Gedmo\Blameable(on: 'create'), ORM\ManyToOne(targetEntity: User::class), ORM\JoinColumn(name: 'created_by')]
private $createdBy;
#[Gedmo\Blameable(on: 'update'), ORM\ManyToOne(targetEntity: User::class), ORM\JoinColumn(name: 'updated_by')]
private $updatedBy;
#[Gedmo\Timestampable(on: 'create'), ORM\Column(type: 'datetime')]
private $createdAt;
#[Gedmo\Timestampable(on: 'update'), ORM\Column(type: 'datetime')]
private $updatedAt;
public function getId(): ?int
{
return $this->id;
}
public function getCase(): ?Cases
{
return $this->case;
}
public function setCase(?Cases $case): self
{
$this->case = $case;
return $this;
}
public function getLabTest(): ?LabTest
{
return $this->labTest;
}
public function setLabTest(?LabTest $labTest): self
{
$this->labTest = $labTest;
return $this;
}
public function getInstruct(): ?string
{
return $this->instruct;
}
public function setInstruct(?string $instruct): self
{
$this->instruct = $instruct;
return $this;
}
public function getFileUrl(): ?string
{
return $this->fileUrl;
}
public function setFileUrl(?string $fileUrl): self
{
$this->fileUrl = $fileUrl;
return $this;
}
public function getResult(): ?string
{
return $this->result;
}
public function setResult(string $result): self
{
$this->result = $result;
return $this;
}
public function getSample(): ?Sample
{
return $this->sample;
}
public function setSample(?Sample $sample): self
{
$this->sample = $sample;
return $this;
}
public function getHospital(): ?Hospital
{
return $this->hospital;
}
public function setHospital(?Hospital $hospital): self
{
$this->hospital = $hospital;
return $this;
}
public function getMethod(): ?TestMethod
{
return $this->method;
}
public function setMethod(?TestMethod $method): self
{
$this->method = $method;
return $this;
}
public function getIsReferral(): ?bool
{
return $this->isReferral;
}
public function setIsReferral(bool $isReferral): self
{
$this->isReferral = $isReferral;
return $this;
}
public function getIsOpinion(): ?bool
{
return $this->isOpinion;
}
public function setIsOpinion(bool $isOpinion): self
{
$this->isOpinion = $isOpinion;
return $this;
}
public function getCreatedBy(): ?User
{
return $this->createdBy;
}
public function getUpdatedBy(): ?User
{
return $this->updatedBy;
}
public function getCreatedAt(): ?\DateTimeInterface
{
return $this->createdAt;
}
public function getUpdatedAt(): ?\DateTimeInterface
{
return $this->updatedAt;
}
}