You are here

function config_views_views_data_sample in Configuration Views 8

Same name and namespace in other branches
  1. 2.0.x config_views.views.inc \config_views_views_data_sample()

Implements hook_views_data().

File

./config_views.views.inc, line 202
Provide views data for dblog.module.

Code

function config_views_views_data_sample() {
  $data = [];
  $data['config_views']['table']['group'] = t('Configuration');
  $data['config_views']['table']['wizard_id'] = 'config_entity';
  $data['config_views']['table']['base'] = [
    'query_id' => 'config_entity_query',
    'field' => 'id',
    'title' => t('Configuration Entity'),
    'help' => t('Contains list of configuration entities.'),
  ];
  $data['config_views']['id'] = [
    'title' => t('Machine name'),
    'help' => t('Unique configuration entity ID.'),
    'field' => [
      'id' => 'config_entity_id',
    ],
    'filter' => [
      'id' => 'string',
    ],
    'argument' => [
      'id' => 'string',
    ],
    'sort' => [
      'id' => 'standard',
    ],
    'search' => [
      'id' => 'standard',
    ],
  ];
  $data['config_views']['label'] = [
    'title' => t('Label'),
    'help' => t('Label'),
    'field' => [
      'id' => 'config_entity_label',
    ],
    'filter' => [
      'id' => 'string',
    ],
    'argument' => [
      'id' => 'string',
    ],
    'sort' => [
      'id' => 'standard',
    ],
    'search' => [
      'id' => 'standard',
    ],
  ];
  $data['config_views']['type'] = [
    'title' => t('Type'),
    'help' => t('Configuration entity type.'),
    'field' => [
      'id' => 'string',
    ],
    'filter' => [
      'id' => 'string',
    ],
    'argument' => [
      'id' => 'string',
    ],
    'sort' => [
      'id' => 'standard',
    ],
    'search' => [
      'id' => 'standard',
    ],
  ];
  $data['config_views']['description'] = [
    'title' => t('Description'),
    'help' => t('Description'),
    'field' => [
      'id' => 'config_entity_description',
    ],
    'filter' => [
      'id' => 'string',
    ],
    'argument' => [
      'id' => 'string',
    ],
    'sort' => [
      'id' => 'standard',
    ],
    'search' => [
      'id' => 'standard',
    ],
  ];
  $data['config_views']['operation'] = [
    'title' => t('Operations'),
    'help' => t('Operations'),
    'field' => [
      'id' => 'config_entity_operations',
    ],
  ];
  return $data;
}