From 6894d48e03c397096bb64420373afa60c397fe97 Mon Sep 17 00:00:00 2001 From: Jeremy Date: Sat, 7 Mar 2015 23:25:36 +0100 Subject: Handle forgot password --- .../CoreBundle/Form/Type/ResetPasswordType.php | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 src/Wallabag/CoreBundle/Form/Type/ResetPasswordType.php (limited to 'src/Wallabag/CoreBundle/Form/Type/ResetPasswordType.php') diff --git a/src/Wallabag/CoreBundle/Form/Type/ResetPasswordType.php b/src/Wallabag/CoreBundle/Form/Type/ResetPasswordType.php new file mode 100644 index 00000000..50ae800b --- /dev/null +++ b/src/Wallabag/CoreBundle/Form/Type/ResetPasswordType.php @@ -0,0 +1,34 @@ +add('new_password', 'repeated', array( + 'type' => 'password', + 'invalid_message' => 'The password fields must match.', + 'required' => true, + 'first_options' => array('label' => 'New password'), + 'second_options' => array('label' => 'Repeat new password'), + 'constraints' => array( + new Constraints\Length(array( + 'min' => 8, + 'minMessage' => 'Password should by at least 8 chars long', + )), + new Constraints\NotBlank(), + ), + )) + ; + } + + public function getName() + { + return 'change_passwd'; + } +} -- cgit v1.2.3