/**
  * {@inheritDoc}
  */
 public function isPublisher(\Alchemy\Phrasea\Model\Entities\User $user)
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'isPublisher', array($user));
     return parent::isPublisher($user);
 }
Пример #2
0
 /**
  * Retrieve detailled informations about one feed
  *
  * @param  Feed $feed
  * @param  type $user
  *
  * @return array
  */
 private function list_publication(Feed $feed, $user)
 {
     return ['id' => $feed->getId(), 'title' => $feed->getTitle(), 'subtitle' => $feed->getSubtitle(), 'total_entries' => $feed->getCountTotalEntries(), 'icon' => $feed->getIconUrl(), 'public' => $feed->isPublic(), 'readonly' => !$feed->isPublisher($user), 'deletable' => $feed->isOwner($user), 'created_on' => $feed->getCreatedOn()->format(DATE_ATOM), 'updated_on' => $feed->getUpdatedOn()->format(DATE_ATOM)];
 }