src/Cms/Modules/PageBundle/Entity/Page/PageProxy.php line 32

Open in your IDE?
  1. <?php
  2. namespace Cms\Modules\PageBundle\Entity\Page;
  3. use App\Entity\Content\Common\DiscriminatorInterface;
  4. use App\Entity\Content\Common\DiscriminatorTrait;
  5. use Cms\CoreBundle\Model\Interfaces\Loggable\LoggableInterface;
  6. use Cms\ModuleBundle\Entity\Proxy;
  7. use Cms\Modules\PageBundle\Model\Page\PageData;
  8. use Doctrine\Common\Collections\ArrayCollection;
  9. use Doctrine\ORM\Mapping as ORM;
  10. /**
  11.  * Class PageProxy
  12.  * @package Cms\Modules\PageBundle\Entity\Page
  13.  *
  14.  * @property PageData $data
  15.  * @property ArrayCollection|PageHistory[] $histories
  16.  * @property PageHistory $history
  17.  * @property ArrayCollection|PageDraft[] $drafts
  18.  *
  19.  * @method PageData getData()
  20.  * @method ArrayCollection|PageHistory[] getHistories()
  21.  * @method PageHistory getHistory()
  22.  * @method PageDraft getDraft()
  23.  * @method ArrayCollection|PageDraft[] getDrafts()
  24.  * @method PageProxy setData(PageData $value)
  25.  * @method PageProxy setHistory(PageHistory $value)
  26.  *
  27.  * @ORM\Entity
  28.  */
  29. class PageProxy extends Proxy implements LoggableInterfaceDiscriminatorInterface
  30. {
  31.     const TYPE 'Page';
  32.     const LOCKABLE_TYPE 'page';
  33.     const DISCR 'legacy.page';
  34.     use PageDataTrait;
  35.     use DiscriminatorTrait;
  36.     /**
  37.      * {@inheritdoc}
  38.      */
  39.     public function getLoggableDetails()
  40.     {
  41.         return array(
  42.             'id' => $this->getId(),
  43.             'title' => $this->getData()->getTitle(),
  44.             'container' => $this->getContainer()->getLoggableDetails(),
  45.         );
  46.     }
  47. }