protected function createComponentRestorePasswordForm(): Form
	{
		$form = $this->formFactory->create();
		$form->addProtection();

		$form->addHidden('hash');

		$form->addPassword('password', 'cms.user.newPassword')
			->setRequired()
			->addRule(Form::MIN_LENGTH, null, $this->minPasswordLength);
		$form->addPassword('passwordVerify', 'cms.user.passwordVerify')
			->setRequired()
			->addRule(Form::EQUAL, null, $form['password']);

		$form->addSubmit('restore', 'form.save');

		$form->onSuccess[] = [$this, 'restorePasswordFormSucceeded'];

		return $form;
	}
protected function createComponentRestorePasswordForm(): Form
	{
		$form = $this->formFactory->create();
		$form->addProtection();

		$form->addHidden('hash');

		$form->addPassword('password', 'cms.user.newPassword')
			->setRequired()
			->addRule(Form::MIN_LENGTH, null, $this->minPasswordLength);
		$form->addPassword('passwordVerify', 'cms.user.passwordVerify')
			->setRequired()
			->addRule(Form::EQUAL, null, $form['password']);

		$form->addSubmit('restore', 'form.save');

		$form->onSuccess[] = [$this, 'restorePasswordFormSucceeded'];

		return $form;
	}
protected function createComponentRestorePasswordForm ( ) : Form { $ form = $ this -> formFactory -> create ( ) ; $ form -> addProtection ( ) ; $ form -> addHidden ( 'hash' ) ; $ form -> addPassword ( 'password' , 'cms.user.newPassword' ) -> setRequired ( ) -> addRule ( Form :: MIN_LENGTH , null , $ this -> minPasswordLength ) ; $ form -> addPassword ( 'passwordVerify' , 'cms.user.passwordVerify' ) -> setRequired ( ) -> addRule ( Form :: EQUAL , null , $ form [ 'password' ] ) ; $ form -> addSubmit ( 'restore' , 'form.save' ) ; $ form -> onSuccess [ ] = [ $ this , 'restorePasswordFormSucceeded' ] ; return $ form ; }
Formular pro obnoveni hesla
@return Form
Formular pro obnoveni hesla