Skip to content
Snippets Groups Projects
Commit 8ef6c33b authored by Emilie Nouveau's avatar Emilie Nouveau
Browse files

Move data-th attribute work to drupal cross-site module

parent 39afcc14
No related branches found
No related tags found
No related merge requests found
...@@ -37,22 +37,6 @@ function bluecheese_preprocess_aggregator_item(&$variables) { ...@@ -37,22 +37,6 @@ function bluecheese_preprocess_aggregator_item(&$variables) {
} }
} }
/**
* Add data-th attributes to table cells in views.
*/
function bluecheese_preprocess_views_view_table(&$vars) {
$view = $vars['view'];
$handler = $view->style_plugin;
$fields = &$view->field;
$columns = $handler->sanitize_columns($options['columns'], $fields);
$result = $vars['result'];
foreach ($columns as $field => $column) {
foreach ($result as $num => $row) {
$vars['field_attributes'][$field][$num]['data-th'] = check_plain(!empty($fields[$field]) ? $fields[$field]->label() : '');
}
}
}
/** /**
* Implements hook_css_alter(). * Implements hook_css_alter().
* *
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment