public function popupAction()
{
$this->_helper->layout->setLayout('iframe');
// TODO make a service
$playlistId = $this->_request->getParam('id', null);
$playlist = null;
if (is_numeric($playlistId)) {
$playlist = $this->playlistRepository->find($playlistId);
} else {
$playlist = new Playlist();
}
if ($playlist instanceof \Newscoop\Entity\Playlist) {
$this->view->playlistName = $playlist->getName();
$this->view->playlistId = $playlist->getId();
}
}