public static function Zone::setElementState in Address 8
Sets the element state.
Parameters
array $parents: The element parents.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
array $element_state: The element state.
3 calls to Zone::setElementState()
- Zone::addTerritorySubmit in src/
Element/ Zone.php - Submit callback for adding a new territory.
- Zone::processZone in src/
Element/ Zone.php - Processes the zone form element.
- Zone::removeTerritorySubmit in src/
Element/ Zone.php - Submit callback for removing a territory.
File
- src/
Element/ Zone.php, line 273
Class
- Zone
- Provides a zone form element.
Namespace
Drupal\address\ElementCode
public static function setElementState(array $parents, FormStateInterface $form_state, array $element_state) {
$parents = array_merge([
'element_state',
'#parents',
], $parents);
NestedArray::setValue($form_state
->getStorage(), $parents, $element_state);
}