public function SettingsForm::buildForm in Node Accessibility 8
Form constructor.
Parameters
array $form: An associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Return value
array The form structure.
Overrides ConfigFormBase::buildForm
File
- src/
Form/ SettingsForm.php, line 34
Class
- SettingsForm
- Defines a form that configures node_accessibility settings.
Namespace
Drupal\node_accessibility\FormCode
public function buildForm(array $form, FormStateInterface $form_state, Request $request = NULL) {
$config = $this
->config('node_accessibility.settings');
$form['alter_revision_menu'] = array(
'#type' => 'checkbox',
'#title' => $this
->t('Alter Node Revision View Page'),
'#description' => $this
->t('Designate whether or not the node revision view page should be altered to present node accessibility validation results. Cache must be rebuilt after changing this.'),
'#default_value' => $config
->get('alter_revision_menu'),
);
$form['revision_log_counting'] = array(
'#type' => 'checkbox',
'#title' => $this
->t('Enable Revision Log Problem Counting'),
'#description' => $this
->t('Designate whether or not to perform problem counting in revision log. This is convenient but may be expensive for very large tables.'),
'#default_value' => $config
->get('revision_log_counting'),
);
return parent::buildForm($form, $form_state);
}