You are here

function domain_taxonomy_schema in Domain Taxonomy 7

Same name and namespace in other branches
  1. 6 domain_taxonomy.install \domain_taxonomy_schema()
  2. 7.3 domain_taxonomy.install \domain_taxonomy_schema()

File

./domain_taxonomy.install, line 19

Code

function domain_taxonomy_schema() {
  $schema['domain_taxonomy_access'] = array(
    'fields' => array(
      'tid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'gid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'realm' => array(
        'type' => 'varchar',
        'length' => '255',
        'not null' => TRUE,
        'default' => '',
      ),
      'grant_view' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
        'size' => 'tiny',
      ),
      'grant_update' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
        'size' => 'tiny',
      ),
      'grant_delete' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
        'size' => 'tiny',
      ),
    ),
    'primary key' => array(
      'tid',
      'gid',
      'realm',
    ),
    'indexes' => array(
      'tid' => array(
        'tid',
      ),
    ),
  );
  $schema['domain_taxonomy_source'] = array(
    'fields' => array(
      'tid' => array(
        'type' => 'int',
        'not null' => TRUE,
        'default' => 0,
      ),
      'domain_id' => array(
        'type' => 'int',
        'not null' => TRUE,
        'default' => 0,
      ),
    ),
    'primary key' => array(
      'tid',
    ),
  );
  return $schema;
}