You are here

public function MailhandlerNode::buildConfigurationForm in Mailhandler 8

File

src/Plugin/inmail/Handler/MailhandlerNode.php, line 215

Class

MailhandlerNode
Message handler that creates a node from a mail message.

Namespace

Drupal\mailhandler\Plugin\inmail\Handler

Code

public function buildConfigurationForm(array $form, FormStateInterface $form_state) {
  $form = parent::buildConfigurationForm($form, $form_state);
  $form['content_type'] = [
    '#title' => $this
      ->t('Content type'),
    '#type' => 'select',
    '#options' => $this
      ->getContentTypes(),
    '#default_value' => $this->configuration['content_type'],
    '#description' => $this
      ->t('Select a content type of a node.'),
  ];
  return $form;
}