Same name in other branches
  1. 7.x-2.x quicktabs.install \quicktabs_schema()
  2. 8.x-1.x quicktabs.install \quicktabs_schema()

Implements hook_schema().

File

./quicktabs.install, line 11

Code

function quicktabs_schema() {
    $schema['quicktabs'] = array(
        'description' => 'The quicktabs table.',
        'export' => array(
            'key' => 'machine_name',
            'identifier' => 'quicktabs',
            'default hook' => 'quicktabs_default_quicktabs',
            'api' => array(
                'owner' => 'quicktabs',
                'api' => 'quicktabs',
                'minimum_version' => 1,
                'current_version' => 1,
            ),
            'export callback' => 'quicktabs_export',
        ),
        'fields' => array(
            'machine_name' => array(
                'description' => 'The primary identifier for a qt block.',
                'type' => 'varchar',
                'length' => 255,
                'not null' => TRUE,
            ),
            'ajax' => array(
                'description' => 'Whether this is an ajax views block.',
                'type' => 'int',
                'unsigned' => TRUE,
                'not null' => TRUE,
                'default' => 0,
            ),
            'hide_empty_tabs' => array(
                'description' => 'Whether this tabset hides empty tabs.',
                'type' => 'int',
                'size' => 'tiny',
                'unsigned' => TRUE,
                'not null' => TRUE,
                'default' => 0,
            ),
            'default_tab' => array(
                'description' => 'Default tab.',
                'type' => 'int',
                'unsigned' => TRUE,
                'not null' => TRUE,
                'default' => 0,
            ),
            'title' => array(
                'description' => 'The title of this quicktabs block.',
                'type' => 'varchar',
                'length' => 255,
                'not null' => TRUE,
            ),
            'tabs' => array(
                'description' => 'A serialized array of the contents of this qt block.',
                'type' => 'text',
                'size' => 'medium',
                'not null' => TRUE,
                'serialize' => TRUE,
            ),
            'renderer' => array(
                'description' => 'The rendering mechanism.',
                'type' => 'varchar',
                'length' => 255,
                'not null' => TRUE,
            ),
            'style' => array(
                'description' => 'The tab style.',
                'type' => 'varchar',
                'length' => 255,
                'not null' => TRUE,
            ),
            'options' => array(
                'description' => 'A serialized array of the options for this qt instance.',
                'type' => 'text',
                'size' => 'medium',
                'not null' => FALSE,
                'serialize' => TRUE,
            ),
        ),
        'primary key' => array(
            'machine_name',
        ),
    );
    return $schema;
}