You are here

function panels_schema_3 in Panels 6.3

Same name and namespace in other branches
  1. 7.3 panels.install \panels_schema_3()

Schema that adds the panels_layout table.

3 calls to panels_schema_3()
panels_schema in ./panels.install
Implementation of hook_schema().
panels_update_6308 in ./panels.install
Add the panels_layout table
panels_update_6309 in ./panels.install
Add the panels_renderer_pipeline table

File

./panels.install, line 98

Code

function panels_schema_3() {

  // Schema 3 is now locked. If you need to make changes, please create
  // schema 4 and add them.
  $schema = panels_schema_2();
  $schema['panels_renderer_pipeline'] = array(
    'description' => 'Contains renderer pipelines for Panels. Each pipeline contains one or more renderers and access rules to select which renderer gets used.',
    'export' => array(
      'identifier' => 'pipeline',
      'bulk export' => TRUE,
      'primary key' => 'rpid',
      'api' => array(
        'owner' => 'panels',
        'api' => 'pipelines',
        'minimum_version' => 1,
        'current_version' => 1,
      ),
    ),
    'fields' => array(
      'rpid' => array(
        'type' => 'serial',
        'description' => 'A database primary key to ensure uniqueness.',
        'not null' => TRUE,
        'no export' => TRUE,
      ),
      'name' => array(
        'type' => 'varchar',
        'length' => '255',
        'description' => 'Unique ID for this content. Used to identify it programmatically.',
      ),
      'admin_title' => array(
        'type' => 'varchar',
        'length' => '255',
        'description' => 'Administrative title for this pipeline.',
      ),
      'admin_description' => array(
        'type' => 'text',
        'size' => 'big',
        'description' => 'Administrative description for this pipeline.',
        'object default' => '',
      ),
      'weight' => array(
        'type' => 'int',
        'size' => 'small',
        'default' => 0,
      ),
      'settings' => array(
        'type' => 'text',
        'size' => 'big',
        'description' => 'Serialized settings for the actual pipeline. The contents of this field are up to the plugin that uses it.',
        'serialize' => TRUE,
        'object default' => array(),
      ),
    ),
    'primary key' => array(
      'rpid',
    ),
  );
  $schema['panels_layout'] = array(
    'description' => 'Contains exportable customized layouts for this site.',
    'export' => array(
      'identifier' => 'layout',
      'bulk export' => TRUE,
      'primary key' => 'lid',
      'api' => array(
        'owner' => 'panels',
        'api' => 'layouts',
        'minimum_version' => 1,
        'current_version' => 1,
      ),
    ),
    'fields' => array(
      'lid' => array(
        'type' => 'serial',
        'description' => 'A database primary key to ensure uniqueness.',
        'not null' => TRUE,
        'no export' => TRUE,
      ),
      'name' => array(
        'type' => 'varchar',
        'length' => '255',
        'description' => 'Unique ID for this content. Used to identify it programmatically.',
      ),
      'admin_title' => array(
        'type' => 'varchar',
        'length' => '255',
        'description' => 'Administrative title for this layout.',
      ),
      'admin_description' => array(
        'type' => 'text',
        'size' => 'big',
        'description' => 'Administrative description for this layout.',
        'object default' => '',
      ),
      'category' => array(
        'type' => 'varchar',
        'length' => '255',
        'description' => 'Administrative category for this layout.',
      ),
      'plugin' => array(
        'type' => 'varchar',
        'length' => '255',
        'description' => 'The layout plugin that owns this layout.',
      ),
      'settings' => array(
        'type' => 'text',
        'size' => 'big',
        'description' => 'Serialized settings for the actual layout. The contents of this field are up to the plugin that uses it.',
        'serialize' => TRUE,
        'object default' => array(),
      ),
    ),
    'primary key' => array(
      'lid',
    ),
  );
  $schema['cache_panels'] = drupal_get_schema_unprocessed('system', 'cache');
  return $schema;
}