public function ViewsRulesLoopUI::form_extract_values in Views Rules 7
Applies the values of the form to the given rule configuration.
Overrides RulesContainerPluginUI::form_extract_values
File
- rules/
views_rules.ui.inc, line 67 - Rules UI implementation for Views Rules plugins.
Class
- ViewsRulesLoopUI
- Views loop administrative UI.
Code
public function form_extract_values($form, &$form_state) {
parent::form_extract_values($form, $form_state);
$form_values = RulesPluginUI::getFormStateValues($form, $form_state);
// Extract row variable settings.
/** @var $display views_rules_iterator */
$display = $this->element
->getViewIterator();
foreach ($display
->get_rules_variable_info() as $var_name => $var_info) {
$this->element->settings[$var_name . ':var'] = $form_values['views_row'][$var_name]['var'];
$this->element->settings[$var_name . ':label'] = $form_values['views_row'][$var_name]['label'];
}
}