public function CivicrmWebformHandler::defaultConfiguration in Webform CiviCRM Integration 8.5
Gets default configuration for this plugin.
Return value
array An associative array with the default configuration.
Overrides WebformHandlerBase::defaultConfiguration
File
- src/
Plugin/ WebformHandler/ CivicrmWebformHandler.php, line 71
Class
- CivicrmWebformHandler
- CiviCRM Webform Handler plugin.
Namespace
Drupal\webform_civicrm\Plugin\WebformHandlerCode
public function defaultConfiguration() {
return [
'data' => [
'contact' => [
1 => [
'contact' => [
1 => [
'contact_type' => 'individual',
'contact_sub_type' => [],
],
],
],
],
'reg_options' => [
'validate' => 1,
],
],
'confirm_subscription' => 1,
'create_fieldsets' => 1,
// The default configuration is invoked before a webform is set to the
// plugin, so we have to default this to empty.
'new_contact_source' => '',
'civicrm_1_contact_1_contact_first_name' => 'create_civicrm_webform_element',
'civicrm_1_contact_1_contact_last_name' => 'create_civicrm_webform_element',
'civicrm_1_contact_1_contact_existing' => 'create_civicrm_webform_element',
];
}