X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=src%2FWallabag%2FCoreBundle%2FForm%2FType%2FEditEntryType.php;h=c37156465314d39d602724fadd7b50c41258730f;hb=ab9eb5cdb767510c0c2b9d1b114243741f748f89;hp=2b1e1ef43c76a0c744a37ee6f985b3826ca70e4f;hpb=85ad629a3ca209907effd75f5fd7f384f42361bc;p=github%2Fwallabag%2Fwallabag.git diff --git a/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php b/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php index 2b1e1ef4..c3715646 100644 --- a/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php +++ b/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php @@ -14,17 +14,31 @@ class EditEntryType extends AbstractType public function buildForm(FormBuilderInterface $builder, array $options) { $builder - ->add('title', TextType::class, array('required' => true)) - ->add('is_public', CheckboxType::class, array('required' => false)) - ->add('save', SubmitType::class) + ->add('title', TextType::class, [ + 'required' => true, + 'label' => 'entry.edit.title_label', + ]) + ->add('is_public', CheckboxType::class, [ + 'required' => false, + 'label' => 'entry.edit.is_public_label', + 'property_path' => 'isPublic', + ]) + ->add('url', TextType::class, [ + 'disabled' => true, + 'required' => false, + 'label' => 'entry.edit.url_label', + ]) + ->add('save', SubmitType::class, [ + 'label' => 'entry.edit.save_label', + ]) ; } public function configureOptions(OptionsResolver $resolver) { - $resolver->setDefaults(array( + $resolver->setDefaults([ 'data_class' => 'Wallabag\CoreBundle\Entity\Entry', - )); + ]); } public function getBlockPrefix()