You are here

function search_config_schema in Search configuration 8

Same name and namespace in other branches
  1. 7 search_config.install \search_config_schema()

Implements hook_schema().

File

./search_config.install, line 13
Install, update and uninstall functions for the search_config module.

Code

function search_config_schema() {
  $schema['search_config_exclude'] = [
    'description' => 'Provides a way to exclude specific entities from the search results. Note that this does not stop the entities from being indexed.',
    'fields' => [
      'entity_id' => [
        'description' => 'The node Id to exclude.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ],
      'entity_type' => [
        'description' => 'The entity type to exclude.',
        'type' => 'varchar',
        'length' => 128,
        'not null' => TRUE,
        'default' => '',
      ],
      'exclude' => [
        'description' => 'Exclusion flag. Default 1: exclude from public searches.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 1,
        'size' => 'tiny',
      ],
    ],
    'primary key' => [
      'entity_id',
      'entity_type',
    ],
  ];
  return $schema;
}