commit 6358d6b9f6257e86de4f751da6d21fa45e05cde3 Author: Joel Pittet Date: Sat Sep 6 16:13:00 2014 -0700 fixed remove button diff --git a/core/modules/views_ui/templates/views-ui-rearrange-filter-form.html.twig b/core/modules/views_ui/templates/views-ui-rearrange-filter-form.html.twig index c5de36d..b003a89 100644 --- a/core/modules/views_ui/templates/views-ui-rearrange-filter-form.html.twig +++ b/core/modules/views_ui/templates/views-ui-rearrange-filter-form.html.twig @@ -24,5 +24,4 @@ {{ ungroupable_table }} {{ table }} - -{{ form|without('override', 'filter_groups', 'remove_groups') }} +{{ form|without('override', 'filter_groups', 'remove_groups', 'filters') }} diff --git a/core/modules/views_ui/views_ui.theme.inc b/core/modules/views_ui/views_ui.theme.inc index e024531..1f31fee 100644 --- a/core/modules/views_ui/views_ui.theme.inc +++ b/core/modules/views_ui/views_ui.theme.inc @@ -230,7 +230,11 @@ function template_preprocess_views_ui_rearrange_filter_form(&$variables) { // Title. $row[] = array( 'class' => array('group', 'group-title'), - 'data' => '' . $form['#group_options'][$group_id] . '', + 'data' => array( + '#prefix' => '', + '#markup' => $form['#group_options'][$group_id], + '#suffix' => '', + ), 'colspan' => 4, ); $rows[] = array( @@ -278,9 +282,9 @@ function template_preprocess_views_ui_rearrange_filter_form(&$variables) { $form['filters'][$id]['removed']['#attributes']['class'][] = 'js-hide'; $remove_link = array( - '#theme' => 'link', - '#path' => 'javascript:void()', - '#text' => '' . t('Remove') . '', + '#type' => 'link', + '#href' => 'javascript:void()', + '#title' => '' . t('Remove') . '', '#options' => array( 'attributes' => array( 'id' => 'views-remove-link-' . $id, @@ -316,9 +320,6 @@ function template_preprocess_views_ui_rearrange_filter_form(&$variables) { } } } - if (empty($rows)) { - $rows[] = array(array('data' => t('No fields available.'), 'colspan' => '2')); - } if (!$variables['grouping']) { $form['filter_groups']['groups'][0]['#title'] = t('Operator'); @@ -359,6 +360,7 @@ function template_preprocess_views_ui_rearrange_filter_form(&$variables) { $variables['table'] = array( '#type' => 'table', '#rows' => $rows, + '#empty' => t('No fields available.'), '#attributes' => array( 'id' => 'views-rearrange-filters', 'class' => array('arrange'),