Ojs\JournalBundle\Controller\JournalPostController::createCreateForm PHP Метод

createCreateForm() приватный Метод

Creates a form to create a JournalPost entity.
private createCreateForm ( JournalPost $entity ) : Form
$entity Ojs\JournalBundle\Entity\JournalPost The entity
Результат Symfony\Component\Form\Form The form
    private function createCreateForm(JournalPost $entity)
    {
        $journal = $this->get('ojs.journal_service')->getSelectedJournal();
        $form = $this->createForm(new JournalPostType(), $entity, ['action' => $this->generateUrl('ojs_journal_post_create', ['journalId' => $journal->getId()]), 'method' => 'POST']);
        $form->add('submit', 'submit', ['label' => 'Create']);
        return $form;
    }