diff --git a/src/Form/IllustrationType.php b/src/Form/IllustrationType.php index 66f4507..336678c 100644 --- a/src/Form/IllustrationType.php +++ b/src/Form/IllustrationType.php @@ -7,6 +7,7 @@ use Symfony\Component\OptionsResolver\OptionsResolver; use Symfony\Component\Form\Extension\Core\Type\TextType; use Symfony\Component\Form\Extension\Core\Type\SubmitType; use Symfony\Component\Form\Extension\Core\Type\HiddenType; +use Symfony\Component\Form\Extension\Core\Type\DateTimeType; use FOS\CKEditorBundle\Form\Type\CKEditorType; use Symfony\Bridge\Doctrine\Form\Type\EntityType; @@ -41,7 +42,16 @@ class IllustrationType extends AbstractType ], ] ); - + + $builder->add('submittime', + DateTimeType::class, [ + "label" =>"Date de Publication", + "date_widget" => "single_text", + "time_widget" => "single_text", + ] + ); + + if($options["by"]=="admin") { $builder->add('category', EntityType::class, [ diff --git a/templates/Home/home.html.twig b/templates/Home/home.html.twig index b2d7d25..3ed8643 100644 --- a/templates/Home/home.html.twig +++ b/templates/Home/home.html.twig @@ -194,7 +194,7 @@ {% if not items is empty %} -