You are here

function jeditable_views_data_alter in jEditable inline content editing 6.2

Same name and namespace in other branches
  1. 6 views/jeditable.views.inc \jeditable_views_data_alter()

Implementation of hook_views_data_alter().

File

views/jeditable.views.inc, line 10

Code

function jeditable_views_data_alter(&$data) {
  foreach ($data as $table => $config) {
    foreach ($config as $item => $item_config) {
      if (isset($item_config['field']) && $item_config['field']['handler'] == 'views_handler_field_node') {
        $data[$table][$item]['field']['handler'] = 'jeditable_handler_field_node';
      }
      if (isset($item_config['field']) && $item_config['field']['handler'] == 'content_handler_field_multiple') {
        $data[$table][$item]['field']['handler'] = 'jeditable_handler_field_content';
      }
      if (isset($item_config['field']) && $item_config['field']['handler'] == 'date_handler_field_multiple') {
        $data[$table][$item]['field']['handler'] = 'jeditable_handler_field_date';
      }
      if (isset($item_config['field']) && $item_config['field']['handler'] == 'workflow_views_handler_field_sid') {
        $data[$table][$item]['field']['handler'] = 'jeditable_handler_field_sid';
      }
    }
  }
  return $data;
}