function AddEventForm::buildForm

Overrides FormInterface::buildForm

File

src/Form/AddEventForm.php, line 76

Class

AddEventForm
UI form to add an event to a rule.

Namespace

Drupal\rules\Form

Code

public function buildForm(array $form, FormStateInterface $form_state, ReactionRuleConfig $rules_reaction_rule = NULL) {
    $this->reactionRule = $rules_reaction_rule;
    $form = $this->buildEventForm($form, $form_state);
    $form['actions'] = [
        '#type' => 'actions',
    ];
    $form['actions']['submit'] = [
        '#type' => 'submit',
        '#value' => $this->t('Add'),
        '#button_type' => 'primary',
    ];
    return $form;
}