src/DcSiteBundle/Entity/ReplacementCarCondition.php line 12

Open in your IDE?
  1. <?php
  2. namespace DcSiteBundle\Entity;
  3. use Application\Sonata\MediaBundle\Entity\Media;
  4. use CoreBundle\Entity\Dealer;
  5. use DateTime;
  6. /**
  7.  * ReplacementCarCondition
  8.  */
  9. class ReplacementCarCondition
  10. {
  11.     /**
  12.      * @var integer
  13.      */
  14.     private $id;
  15.     /**
  16.      * @var string
  17.      */
  18.     private $title_ua;
  19.     /**
  20.      * @var string
  21.      */
  22.     private $title_ru;
  23.     /**
  24.      * @var Media
  25.      */
  26.     private $file;
  27.     /**
  28.      * @var Dealer
  29.      */
  30.     private $dealer;
  31.     /**
  32.      * Get id
  33.      *
  34.      * @return integer
  35.      */
  36.     public function getId()
  37.     {
  38.         return $this->id;
  39.     }
  40.     /**
  41.      * Set titleUa
  42.      *
  43.      * @param string $titleUa
  44.      *
  45.      * @return ReplacementCarCondition
  46.      */
  47.     public function setTitleUa($titleUa)
  48.     {
  49.         $this->title_ua $titleUa;
  50.         return $this;
  51.     }
  52.     /**
  53.      * Get titleUa
  54.      *
  55.      * @return string
  56.      */
  57.     public function getTitleUa()
  58.     {
  59.         return $this->title_ua;
  60.     }
  61.     /**
  62.      * Set titleRu
  63.      *
  64.      * @param string $titleRu
  65.      *
  66.      * @return ReplacementCarCondition
  67.      */
  68.     public function setTitleRu($titleRu)
  69.     {
  70.         $this->title_ru $titleRu;
  71.         return $this;
  72.     }
  73.     /**
  74.      * Get titleRu
  75.      *
  76.      * @return string
  77.      */
  78.     public function getTitleRu()
  79.     {
  80.         return $this->title_ru;
  81.     }
  82.     /**
  83.      * Set file
  84.      *
  85.      * @param Media $file
  86.      *
  87.      * @return ReplacementCarCondition
  88.      */
  89.     public function setFile(Media $file null)
  90.     {
  91.         $this->file $file;
  92.         return $this;
  93.     }
  94.     /**
  95.      * Get file
  96.      *
  97.      * @return Media
  98.      */
  99.     public function getFile()
  100.     {
  101.         return $this->file;
  102.     }
  103.     /**
  104.      * Set dealer
  105.      *
  106.      * @param Dealer $dealer
  107.      *
  108.      * @return ReplacementCarCondition
  109.      */
  110.     public function setDealer(Dealer $dealer null)
  111.     {
  112.         $this->dealer $dealer;
  113.         return $this;
  114.     }
  115.     /**
  116.      * Get dealer
  117.      *
  118.      * @return Dealer
  119.      */
  120.     public function getDealer()
  121.     {
  122.         return $this->dealer;
  123.     }
  124.     /**
  125.      * @var DateTime
  126.      */
  127.     private $begin_date;
  128.     /**
  129.      * Set beginDate
  130.      *
  131.      * @param DateTime $beginDate
  132.      *
  133.      * @return ReplacementCarCondition
  134.      */
  135.     public function setBeginDate($beginDate)
  136.     {
  137.         $this->begin_date $beginDate;
  138.         return $this;
  139.     }
  140.     /**
  141.      * Get beginDate
  142.      *
  143.      * @return DateTime
  144.      */
  145.     public function getBeginDate()
  146.     {
  147.         return $this->begin_date;
  148.     }
  149.     public function getTitle($locale)
  150.     {
  151.         return $locale === 'ua' $this->getTitleUa() : $this->getTitleRu();
  152.     }
  153. }