Added setFormSubmitProcessor to the HandlerConfigInterface
Added a way to apply a custom form submit processor to the handler if you require more fine-grained way to handle your form.
By default the ::handleRequest()
is used, but if you need want to do something differently you can do that as follows:
public function configure(HandlerConfigInterface $config)
{
$config->setFormSubmitProcessor(function (FormInterface $form, Request $request) {
// taken from the Symfony docs example
$form->submit($request->request->get($form->getName()));
});
}
Example it take from the symfony docs: https://symfony.com/doc/current/form/direct_submit.html