Quelques nouveaux fichiers et modules en conf
This commit is contained in:
31
local/modules/OrderComment/Form/CommentForm.php
Normal file
31
local/modules/OrderComment/Form/CommentForm.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace OrderComment\Form;
|
||||
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Thelia\Form\BaseForm;
|
||||
|
||||
class CommentForm extends BaseForm
|
||||
{
|
||||
public function buildForm()
|
||||
{
|
||||
self::addCommentFormField($this->formBuilder);
|
||||
}
|
||||
|
||||
public static function addCommentFormField(FormBuilderInterface $formBuilder)
|
||||
{
|
||||
$formBuilder
|
||||
->add(
|
||||
'comment',
|
||||
'textarea',
|
||||
array(
|
||||
'required' => false
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
public function getName()
|
||||
{
|
||||
return "order_comment_form";
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user