public function MailchimpListsUpdateMergevarsForm::submitForm in Mailchimp 8
Same name and namespace in other branches
- 2.x modules/mailchimp_lists/src/Form/MailchimpListsUpdateMergevarsForm.php \Drupal\mailchimp_lists\Form\MailchimpListsUpdateMergevarsForm::submitForm()
Form submission handler.
Parameters
array $form: An associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Overrides FormInterface::submitForm
File
- modules/
mailchimp_lists/ src/ Form/ MailchimpListsUpdateMergevarsForm.php, line 92
Class
- MailchimpListsUpdateMergevarsForm
- Batch update Mailchimp lists mergevars.
Namespace
Drupal\mailchimp_lists\FormCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$entity_type = $this->request
->get('entity_type');
$bundle = $this->request
->get('bundle');
$field_name = $this->request
->get('field_name');
mailchimp_lists_update_member_merge_values($entity_type, $bundle, $field_name);
$this->messenger
->addStatus($this
->t('Mergevars updated.'));
}