Ojs\JournalBundle\Controller\IssueController::showAction PHP Метод

showAction() публичный Метод

Finds and displays a Issue entity.
public showAction ( Request $request, $id ) : Response
$request Symfony\Component\HttpFoundation\Request
$id
Результат Symfony\Component\HttpFoundation\Response
    public function showAction(Request $request, $id)
    {
        $journal = $this->get('ojs.journal_service')->getSelectedJournal();
        if (!$this->isGranted('VIEW', $journal, 'issues')) {
            throw new AccessDeniedException("You are not authorized for view this journal's issue!");
        }
        $em = $this->getDoctrine()->getManager();
        /** @var Issue $entity */
        $entity = $em->getRepository('OjsJournalBundle:Issue')->find($id);
        $this->throw404IfNotFound($entity);
        $entity->setDefaultLocale($request->getDefaultLocale());
        $token = $this->get('security.csrf.token_manager')->refreshToken('ojs_journal_issue' . $entity->getId());
        return $this->render('OjsJournalBundle:Issue:show.html.twig', array('entity' => $entity, 'token' => $token));
    }