src/Entity/RequestForProposalResponseDocument.php line 18

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use DateTime;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Gedmo\Timestampable\Traits\TimestampableEntity;
  6. use Gedmo\Mapping\Annotation as Gedmo;
  7. /**
  8.  * To use in many templates
  9.  *
  10.  * @ORM\Entity
  11.  * @ORM\Entity(repositoryClass="App\Repository\RequestForProposalResponseDocumentRepository")
  12.  * @ORM\HasLifecycleCallbacks()
  13.  *
  14.  */
  15. class RequestForProposalResponseDocument implements EntityInterface
  16. {
  17.     use TimestampableEntity;
  18.     use BlameableEntity;
  19.     /**
  20.      * @var int
  21.      *
  22.      * @ORM\Column(name="id", type="integer")
  23.      * @ORM\Id
  24.      * @ORM\GeneratedValue(strategy="AUTO")
  25.      */
  26.     public $id;
  27.     /**
  28.      * @var string
  29.      * @ORM\Column(name="title", type="string", length=255)
  30.      */
  31.     private $title;
  32.     /**
  33.      * @Gedmo\Translatable
  34.      * @Gedmo\Slug(fields={"title"}, updatable=false)
  35.      * @ORM\Column(name="slug", type="string", length=255)
  36.      */
  37.     private $slug;
  38.     /**
  39.      * @ORM\Column(name="is_mandatory", type="boolean", nullable=true)
  40.      */
  41.     private $isMandatory;
  42.     public function __toString()
  43.     {
  44.         return (string)$this->getTitle();
  45.     }
  46.     /**
  47.      * @return string
  48.      */
  49.     public function getTitle()
  50.     {
  51.         return $this->title;
  52.     }
  53.     /**
  54.      * @param string $title
  55.      */
  56.     public function setTitle(?string $title)
  57.     {
  58.         $this->title $title == null '' $title;
  59.     }
  60.     /**
  61.      * @return int
  62.      */
  63.     public function getId(): int
  64.     {
  65.         return $this->id;
  66.     }
  67.     /**
  68.      * @param int $id
  69.      */
  70.     public function setId(int $id)
  71.     {
  72.         $this->id $id;
  73.     }
  74.     public function toString(): string
  75.     {
  76.         return $this->getUrl();
  77.     }
  78.     /**
  79.      * @return boolean
  80.      */
  81.     public function getIsMandatory(): ?bool
  82.     {
  83.         return $this->isMandatory;
  84.     }
  85.     /**
  86.      * @param boolean $isMandatory
  87.      */
  88.     public function setIsMandatory($isMandatory)
  89.     {
  90.         $this->isMandatory $isMandatory;
  91.     }
  92.     /**
  93.      * @return string
  94.      */
  95.     public function getSlug()
  96.     {
  97.         return $this->slug;
  98.     }
  99.     /**
  100.      * @param string $slug
  101.      */
  102.     public function setSlug($slug)
  103.     {
  104.         $this->slug $slug;
  105.     }
  106. }