FormTrait
Table of Contents
Methods
- onSuccess() : void
- Passes the entered name or e-mail on; the component does nothing else.
- createComponentPasswordForm() : Form
Methods
onSuccess()
Passes the entered name or e-mail on; the component does nothing else.
public
onSuccess(Form $form, ArrayHash $values) : void
The lookup, password generation with hash storage and e-mail sending live in
Api\…\UserManager::sendNewPassword(), a shared data path reachable from the front end and
from external calls, so there is one implementation, not two copies. The Api action must
not return the password in the response or take userId from the request.
IMPORTANT: no account-existence oracle. The message is the same for an existing and a
nonexistent account (hence no messages.noUser). The manager returns a constant
Result::success and only logs internal failures, so messages.error shows in practice
only when the ApiBridge itself fails.
Parameters
- $form : Form
- $values : ArrayHash
createComponentPasswordForm()
protected
createComponentPasswordForm() : Form