You are here

function og_vocab_schema_7000 in OG Vocabulary 7

Snapshot of the schema as it was in 7.x-1.0

1 call to og_vocab_schema_7000()
og_vocab_update_7000 in ./og_vocab.install
Upgrade tables from Drupal 6 to 7.

File

./og_vocab.install, line 101
Install file for the og_vocab module.

Code

function og_vocab_schema_7000() {
  $schema['og_vocab_relation'] = array(
    'description' => t('Relate groups to vocabularies'),
    'fields' => array(
      'id' => array(
        'description' => 'Primary Key: Unique OG vocab ID.',
        'type' => 'serial',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'group_type' => array(
        'description' => "The group's entity type.",
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
      'gid' => array(
        'description' => "The group's unique ID.",
        'type' => 'int',
        'size' => 'normal',
        'not null' => TRUE,
      ),
      'vid' => array(
        'description' => 'Vocabulary ID',
        'type' => 'int',
        'not null' => TRUE,
        'default' => 0,
      ),
    ),
    'primary key' => array(
      'vid',
    ),
    'indexes' => array(
      'id' => array(
        'id',
      ),
    ),
  );
  $schema['og_vocab'] = array(
    'description' => t('Relate Og-vocab settings to bundles'),
    'fields' => array(
      'id' => array(
        'description' => 'Primary Key: Unique OG vocab ID.',
        'type' => 'serial',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'vid' => array(
        'description' => 'Vocabulary ID',
        'type' => 'int',
        'not null' => TRUE,
        'default' => 0,
      ),
      'entity_type' => array(
        'description' => "On which entity-type the widget should appear.",
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
      'bundle' => array(
        'description' => "On which bundle the widget should appear.",
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
      'settings' => array(
        'description' => 'Serialized array with field instance settings.',
        'type' => 'text',
        'serialize' => TRUE,
        'size' => 'big',
      ),
    ),
    'indexes' => array(
      'id' => array(
        'id',
      ),
    ),
  );
  return $schema;
}