Index: diaporama.install =================================================================== --- diaporama.install (revision 89) +++ diaporama.install (working copy) @@ -14,28 +14,112 @@ **/ function diaporama_schema(){ $schema['diaporama'] = array( + 'description' => t('Stores the data for a diaporama.'), 'fields' => array( - 'vid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => '0'), - 'nid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => '0'), - 'width' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'height' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'showbuttons' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'showtitles' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'randomstart' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'timer' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'alignbuttons' => array('type' => 'varchar', 'length' => 12), - 'aligntitles' => array('type' => 'varchar', 'length' => 12), - 'transition' => array('type' => 'varchar', 'length' => 12, 'not null' => TRUE), - 'speed' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE), - 'ratio' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => '1'), - 'image_node'=> array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => '0'), - 'embedded'=> array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => '0'), - 'tid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE) - ), - 'indexes' => array( - 'tid' => array('tid') - ), - 'primary key' => array('vid','nid'), + 'vid' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 0, + 'description' => t('The ID of the field, defined by the database.'), + ), + 'nid' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 0, + 'description' => t('The ID of the node that holds the diaporama.'), + ), + 'width' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('The width of the diaporama.'), + ), + 'height' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('The height of the diaporama.'), + ), + 'showbuttons' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('Setting to define if the buttons appear on the diaporama.'), + ), + 'showtitles' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('Setting to define if the titles appear on the diaporama.'), + ), + 'randomstart' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('Setting to define if the diaporama starts in a random image.'), + ), + 'timer' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('Setting to define the time to display an images.'), + ), + 'alignbuttons' => array( + 'type' => 'varchar', + 'length' => 12, + 'description' => t('Setting to define the alignment of the buttons (top or bottom).'), + ), + 'aligntitles' => array( + 'type' => 'varchar', + 'length' => 12, + 'description' => t('Setting to define the alignment of the titles (top or bottom).'), + ), + 'transition' => array( + 'type' => 'varchar', + 'length' => 12, + 'not null' => TRUE, + 'description' => t('Setting to define the type of transition.'), + ), + 'speed' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('Setting to define the speed of the transition.'), + ), + 'ratio' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 1, + 'description' => t('Setting to define if the ratio (width x height) of the images is kept.'), + ), + 'image_node' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 0, + 'description' => t('Setting to define if the image node is opened uppon click on the diaporama.'), + ), + 'embedded' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'default' => 0, + 'description' => t('Setting to permit visitors to put the diaporama on their own site.'), + ), + 'tid' => array( + 'type' => 'int', + 'unsigned' => TRUE, + 'not null' => TRUE, + 'description' => t('The taxonomy ID used by the diaporama.'), + ) + ), + 'indexes' => array( + 'tid' => array('tid') + ), + 'primary key' => array('vid','nid'), ); return $schema;