src/AdminBundle/Admin/Vehicles/FeatureContentAdmin.php line 12

Open in your IDE?
  1. <?php
  2. namespace AdminBundle\Admin\Vehicles;
  3. use AdminBundle\Admin\BaseAdmin;
  4. use FOS\CKEditorBundle\Form\Type\CKEditorType;
  5. use Sonata\AdminBundle\Form\FormMapper;
  6. use Symfony\Component\Form\Extension\Core\Type\HiddenType;
  7. class FeatureContentAdmin extends BaseAdmin
  8. {
  9.     protected function configureFormFields(FormMapper $formMapper): void
  10.     {
  11.         $formMapper
  12.             ->with('Основная информация', ['class' => 'col-lg-6'])
  13.                 ->add('language'HiddenType::class)
  14.                 ->add('title'null, ['label' => 'Название особенности''required' => true,])
  15.                 ->add('content'CKEditorType::class, [
  16.                     'config_name' => 'default',
  17.                     'required' => false,
  18.                     'label' => 'Контент'
  19.                 ])
  20.             ->end()
  21.         ;
  22.     }
  23. }