No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

FileModel.php 1.9KB

hace 3 años
hace 3 años
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <?php
  2. namespace Lc\SovBundle\Model\File;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use Gedmo\Mapping\Annotation as Gedmo;
  5. use Lc\SovBundle\Doctrine\EntityInterface;
  6. use Lc\SovBundle\Doctrine\Extension\BlameableInterface;
  7. use Lc\SovBundle\Doctrine\Extension\BlameableTrait;
  8. use Lc\SovBundle\Doctrine\Extension\DevAliasInterface;
  9. use Lc\SovBundle\Doctrine\Extension\DevAliasTrait;
  10. use Lc\SovBundle\Doctrine\Extension\SortableInterface;
  11. use Lc\SovBundle\Doctrine\Extension\SortableTrait;
  12. use Lc\SovBundle\Doctrine\Extension\TimestampableInterface;
  13. use Lc\SovBundle\Doctrine\Extension\TimestampableTrait;
  14. use Lc\SovBundle\Doctrine\Extension\TranslatableInterface;
  15. use Lc\SovBundle\Doctrine\Extension\TranslatableTrait;
  16. abstract class FileModel implements SortableInterface, BlameableInterface, TimestampableInterface, TranslatableInterface,
  17. DevAliasInterface, EntityInterface, FileInterface
  18. {
  19. use DevAliasTrait;
  20. use BlameableTrait;
  21. use TimestampableTrait;
  22. use TranslatableTrait;
  23. use SortableTrait;
  24. /**
  25. * @ORM\Column(type="string", length=255, nullable=true)
  26. */
  27. protected $path;
  28. /**
  29. * @Gedmo\Translatable
  30. * @ORM\Column(type="string", length=255, nullable=true)
  31. */
  32. protected $legend;
  33. public function __toString(){
  34. return $this->getLegend();
  35. }
  36. public function getPath(): ?string
  37. {
  38. return $this->path;
  39. }
  40. public function setPath(?string $path): self
  41. {
  42. $this->path = $path;
  43. return $this;
  44. }
  45. public function getLegend(): ?string
  46. {
  47. return $this->legend;
  48. }
  49. public function setLegend(?string $legend): self
  50. {
  51. $this->legend = $legend;
  52. return $this;
  53. }
  54. }