Added forum topic creation feature
Fixes second half of issue #26 Signed-off-by: Gergely Polonkai (W00d5t0ck) <polesz@w00d5t0ck.info>master
parent
67bfa5f1e0
commit
4d8ae5c0f0
@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
namespace KekRozsak\FrontBundle\Form\Type;
|
||||
|
||||
use Symfony\Component\Form\AbstractType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
|
||||
|
||||
class ForumTopicType extends AbstractType
|
||||
{
|
||||
public function buildForm(FormBuilderInterface $builder, array $options)
|
||||
{
|
||||
$builder
|
||||
->add('title', null, array(
|
||||
'label' => 'Téma címe',
|
||||
'help' => 'Az új fórum téma címe',
|
||||
))
|
||||
;
|
||||
}
|
||||
|
||||
public function setDefaultOptions(OptionsResolverInterface $resolver)
|
||||
{
|
||||
$resolver->setDefaults(array(
|
||||
'data_class' => 'KekRozsak\FrontBundle\Entity\ForumTopic'
|
||||
));
|
||||
}
|
||||
|
||||
public function getName()
|
||||
{
|
||||
return 'kekrozsak_frontbundle_forumtopictype';
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue