lib/composer/PhotoAlbumBundle/src/VisualMedia/PhotoAlbumBundle/Entity/BasePhotoAlbum.php line 27

Open in your IDE?
  1. <?php
  2. /**
  3. * Base Photo Album
  4. *
  5. * @author Vincent van Waasbergen <v.vanwaasbergen@visualmedia.nl>
  6. */
  7. namespace VisualMedia\PhotoAlbumBundle\Entity;
  8. use Doctrine\ORM\Mapping as ORM;
  9. use VisualMedia\LisaBundle\Component\Interfaces\EntityInterface;
  10. use VisualMedia\LisaBundle\Traits\BlameableTrait;
  11. use VisualMedia\LisaBundle\Traits\AutoIdTrait;
  12. use VisualMedia\LisaBundle\Traits\TimestampableTrait;
  13. use VisualMedia\PhotoAlbumBundle\Model\BasePhotoAlbumModel;
  14. /**
  15. * Base Photo Album
  16. *
  17. * @ORM\Entity(repositoryClass="VisualMedia\PhotoAlbumBundle\Manager\BasePhotoAlbumManager")
  18. * @ORM\Table(name="photo_album")
  19. *
  20. * @ORM\InheritanceType("SINGLE_TABLE")
  21. * @ORM\DiscriminatorColumn(name="discriminator", type="string")
  22. */
  23. class BasePhotoAlbum extends BasePhotoAlbumModel implements EntityInterface
  24. {
  25. use BlameableTrait;
  26. use AutoIdTrait;
  27. use TimestampableTrait;
  28. /**
  29. * @ORM\Column(name="title", type="string", length=255, nullable=false)
  30. */
  31. public $title;
  32. /**
  33. * @ORM\Column(name="reference", type="string", length=255, nullable=true)
  34. */
  35. public $reference;
  36. /**
  37. * @ORM\Column(name="published", type="boolean", nullable=false)
  38. */
  39. public $published = true;
  40. /**
  41. * @ORM\OneToMany(targetEntity="VisualMedia\PhotoAlbumBundle\Entity\BasePhotoAlbumPhoto", mappedBy="photoAlbum", cascade={"persist", "remove"}, orphanRemoval=true)
  42. * @ORM\OrderBy({"ordering"="ASC"})
  43. */
  44. public $photos;
  45. }