You are here

function flexslider_schema in Flex Slider 7

Same name and namespace in other branches
  1. 7.2 flexslider.install \flexslider_schema()

Implements hook_schema().

File

./flexslider.install, line 10
Installation actions for Flex Slider

Code

function flexslider_schema() {
  $schema = array();
  $schema['flexslider_optionset'] = array(
    'description' => 'Store option sets for flexslider instances.',
    'export' => array(
      'key' => 'name',
      'identifier' => 'preset',
      'default hook' => 'flexslider_default_presets',
      'api' => array(
        'owner' => 'flexslider',
        'api' => 'flexslider_default_preset',
        'minimum_version' => 1,
        'current_version' => 1,
      ),
    ),
    'fields' => array(
      'name' => array(
        'description' => 'The machine-readable option set name.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
      ),
      'title' => array(
        'description' => 'The human-readable title for this option set.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
      ),
      'theme' => array(
        'description' => 'The flexslider theme.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => 'classic',
      ),
      'imagestyle_normal' => array(
        'description' => 'The image style for normal images.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => 'flexslider_full',
      ),
      'options' => array(
        'description' => 'The options array.',
        'type' => 'blob',
        'size' => 'big',
        'serialize' => TRUE,
      ),
    ),
    'primary key' => array(
      'name',
    ),
  );
  return $schema;
}