public function SiteNameProperty::submitConfigurationForm in Search API Field Map 8.2
Same name and namespace in other branches
- 8.3 src/Plugin/search_api/processor/Property/SiteNameProperty.php \Drupal\search_api_field_map\Plugin\search_api\processor\Property\SiteNameProperty::submitConfigurationForm()
- 8 src/Plugin/search_api/processor/Property/SiteNameProperty.php \Drupal\search_api_field_map\Plugin\search_api\processor\Property\SiteNameProperty::submitConfigurationForm()
- 4.x src/Plugin/search_api/processor/Property/SiteNameProperty.php \Drupal\search_api_field_map\Plugin\search_api\processor\Property\SiteNameProperty::submitConfigurationForm()
Submits a configuration form for a field based on this property.
Parameters
\Drupal\search_api\Item\FieldInterface $field: The field for which the configuration form is submitted.
array $form: An associative array containing the structure of the plugin form as built by static::buildConfigurationForm().
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the complete form.
Overrides ConfigurablePropertyBase::submitConfigurationForm
File
- src/
Plugin/ search_api/ processor/ Property/ SiteNameProperty.php, line 95
Class
- SiteNameProperty
- Defines a "site name" property.
Namespace
Drupal\search_api_field_map\Plugin\search_api\processor\PropertyCode
public function submitConfigurationForm(FieldInterface $field, array &$form, FormStateInterface $form_state) {
$values = [
'use_system_site_name' => $form_state
->getValue([
'site_name_group',
'use_system_site_name',
]),
'site_name' => $form_state
->getValue([
'site_name_group',
'site_name',
]),
];
$field
->setConfiguration($values);
}