You are here

function xmlsitemap_user_schema in XML sitemap 6

Implementation of hook_schema().

File

xmlsitemap_user/xmlsitemap_user.install, line 29
Installation file for XML sitemap user.

Code

function xmlsitemap_user_schema() {
  $schema['xmlsitemap_user'] = array(
    'description' => 'The base table for xmlsitemap_user.',
    'fields' => array(
      'uid' => array(
        'description' => 'The user ID.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'changed' => array(
        'description' => 'The Unix timestamp of the last change.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'previously_changed' => array(
        'description' => 'The Unix timestamp of the previous change.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'comments' => array(
        'description' => 'The number of comments authored from the user.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'priority_override' => array(
        'description' => 'The priority of the term in the sitemap.',
        'type' => 'float',
        'not null' => TRUE,
        'default' => -2.0,
      ),
    ),
    'primary key' => array(
      'uid',
    ),
  );
  $schema['xmlsitemap_user_role'] = array(
    'description' => 'The user roles settings table.',
    'fields' => array(
      'rid' => array(
        'description' => 'The role ID.',
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'priority' => array(
        'description' => 'The priority assigned to the role.',
        'type' => 'float',
        'not null' => TRUE,
        'default' => 0.5,
      ),
    ),
    'primary key' => array(
      'rid',
    ),
  );
  return $schema;
}