src/Entity/Ruta.php line 20

  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Symfony\Component\Validator\Constraints as Assert;
  5. // use Knp\DoctrineBehaviors\Model as ORMBehaviors;
  6. use A2lix\TranslationFormBundle\Util\Knp\KnpTranslatable;
  7. use Knp\DoctrineBehaviors\Contract\Entity\TranslatableInterface;
  8. use Knp\DoctrineBehaviors\Model\Translatable\TranslatableTrait;
  9. /**
  10.  * Ruta
  11.  *
  12.  * @ORM\Table(name="ruta")
  13.  * @ORM\Entity
  14.  * @ORM\Entity(repositoryClass="App\Repository\RutaRepository")   
  15.  */
  16. class Ruta  implements TranslatableInterface
  17. {
  18.     use TranslatableTrait;
  19.     
  20.     public function __call($method$arguments)
  21.     {
  22.         return $this->proxyCurrentLocaleTranslation($method$arguments);
  23.     }   
  24.     
  25.     /**
  26.      * @var integer
  27.      * @ORM\Column(name="id", type="string", length=50)
  28.      * @ORM\Id
  29.      */
  30.     private $id;
  31.     /**
  32.      * Set id
  33.      * 
  34.      * @param string $id
  35.      * @return Ruta
  36.      */
  37.     public function setId($id)
  38.     {
  39.         $this->id $id;
  40.         
  41.         return $this;
  42.     }    
  43.     
  44.     /**
  45.      * Get id
  46.      *
  47.      * @return string
  48.      */
  49.     public function getId()
  50.     {
  51.         return $this->id;
  52.     }
  53.     /**
  54.      * __toString
  55.      *
  56.      * @return string 
  57.      */    
  58.     public function __toString()
  59.     {
  60.         return $this->getId();
  61.     }    
  62.     
  63.     
  64.     
  65. }