function DatelistElementFormTest::datelistDateCallback
File
-
core/
tests/ Drupal/ KernelTests/ Core/ Datetime/ DatelistElementFormTest.php, line 51
Class
- DatelistElementFormTest
- Tests Datelist functionality.
Namespace
Drupal\KernelTests\Core\DatetimeCode
public function datelistDateCallback(array &$element, FormStateInterface $form_state, ?DrupalDateTime $date = NULL) : void {
$element['datelistDateCallbackExecuted'] = [
'#value' => TRUE,
];
$form_state->set('datelistDateCallbackExecuted', TRUE);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.