From baa5ee2d4292460425ca7f6572425f1fb1100d9d Mon Sep 17 00:00:00 2001 From: Jeremy Benoist Date: Fri, 8 Feb 2019 15:03:52 +0100 Subject: Force default_protocol to generate an url input --- src/Wallabag/ApiBundle/Form/Type/ClientType.php | 1 + src/Wallabag/CoreBundle/Form/Type/EditEntryType.php | 2 ++ src/Wallabag/CoreBundle/Form/Type/NewEntryType.php | 1 + 3 files changed, 4 insertions(+) diff --git a/src/Wallabag/ApiBundle/Form/Type/ClientType.php b/src/Wallabag/ApiBundle/Form/Type/ClientType.php index fc22538f..14dc5c44 100644 --- a/src/Wallabag/ApiBundle/Form/Type/ClientType.php +++ b/src/Wallabag/ApiBundle/Form/Type/ClientType.php @@ -20,6 +20,7 @@ class ClientType extends AbstractType 'required' => false, 'label' => 'developer.client.form.redirect_uris_label', 'property_path' => 'redirectUris', + 'default_protocol' => null, ]) ->add('save', SubmitType::class, ['label' => 'developer.client.form.save_label']) ; diff --git a/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php b/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php index 08355928..2fc4c204 100644 --- a/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php +++ b/src/Wallabag/CoreBundle/Form/Type/EditEntryType.php @@ -22,11 +22,13 @@ class EditEntryType extends AbstractType 'disabled' => true, 'required' => false, 'label' => 'entry.edit.url_label', + 'default_protocol' => null, ]) ->add('origin_url', UrlType::class, [ 'required' => false, 'property_path' => 'originUrl', 'label' => 'entry.edit.origin_url_label', + 'default_protocol' => null, ]) ->add('save', SubmitType::class, [ 'label' => 'entry.edit.save_label', diff --git a/src/Wallabag/CoreBundle/Form/Type/NewEntryType.php b/src/Wallabag/CoreBundle/Form/Type/NewEntryType.php index 7d74fee3..7af1e589 100644 --- a/src/Wallabag/CoreBundle/Form/Type/NewEntryType.php +++ b/src/Wallabag/CoreBundle/Form/Type/NewEntryType.php @@ -15,6 +15,7 @@ class NewEntryType extends AbstractType ->add('url', UrlType::class, [ 'required' => true, 'label' => 'entry.new.form_new.url_label', + 'default_protocol' => null, ]) ; } -- cgit v1.2.3