<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\HttpFoundation\File\File;
use Vich\UploaderBundle\Mapping\Annotation as Vich;
/**
* @ORM\Entity(repositoryClass="App\Repository\BFDescriptionChallengeEditionRepository")
* @Vich\Uploadable
*/
class BFDescriptionChallengeEdition extends AbstractArrayAccess
{
/**
* @ORM\Id()
* @ORM\GeneratedValue()
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="text", nullable=true)
*/
private $longdescription;
/**
* @ORM\OneToOne(targetEntity="App\Entity\BFChallengeEdition", mappedBy="description", cascade={"persist", "remove"})
*/
private $edition;
/**
* @ORM\Column(type="string", length=255)
*/
private $labeltext;
/**
* @ORM\Column(type="string", length=255)
*/
private $labelcolor;
/**
* @ORM\Column(type="string", length=255, nullable=true)
*/
private $website;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @var string
*/
private $ranking;
/**
* @Vich\UploadableField(mapping="challenge_files", fileNameProperty="ranking")
* @var File
*/
private $rankingFile;
/**
* @ORM\Column(type="datetime" , nullable=true)
* @var \DateTime
*/
private $updatedAtRanking;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @var string
*/
private $poster;
/**
* @Vich\UploadableField(mapping="challenge_files", fileNameProperty="poster")
* @var File
*/
private $posterFile;
/**
* @ORM\Column(type="datetime" , nullable=true)
* @var \DateTime
*/
private $updatedAtPoster;
public function getId(): ?int
{
return $this->id;
}
public function getEdition(): ?BFChallengeEdition
{
return $this->edition;
}
public function setEdition(?BFChallengeEdition $edition): self
{
$this->edition = $edition;
return $this;
}
public function getLongdescription(): ?string
{
return $this->longdescription;
}
public function setLongdescription(?string $longdescription): self
{
$this->longdescription = $longdescription;
return $this;
}
public function getLabeltext(): ?string
{
return $this->labeltext;
}
public function setLabeltext(string $labeltext): self
{
$this->labeltext = $labeltext;
return $this;
}
public function getLabelcolor(): ?string
{
return $this->labelcolor;
}
public function setLabelcolor(string $labelcolor): self
{
$this->labelcolor = $labelcolor;
return $this;
}
public function getWebsite(): ?string
{
return $this->website;
}
public function setWebsite(?string $website): self
{
$this->website = $website;
return $this;
}
public function setRankingFile(File $ranking = null)
{
$this->rankingFile = $ranking;
if ($ranking) {
$this->updatedAtRanking = new \DateTime('now');
}
}
public function getRankingFile()
{
return $this->rankingFile;
}
public function setRanking($ranking)
{
$this->ranking = $ranking;
}
public function getRanking()
{
return $this->ranking;
}
public function setPosterFile(File $poster = null)
{
$this->posterFile = $poster;
if ($poster) {
$this->updatedAtPoster = new \DateTime('now');
}
}
public function getPosterFile()
{
return $this->posterFile;
}
public function setPoster($poster)
{
$this->poster = $poster;
}
public function getPoster()
{
return $this->poster;
}
}