123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144 |
- <?php
- function blast_ui_install() {
- tripal_create_files_dir('tripal_blast');
- }
- function blast_ui_schema(){
- $schema['blastdb'] = array(
- 'description' => t('The base table for blastdb node'),
- 'fields' => array(
- 'nid' => array(
- 'description' => t('The primary identifier for a node.'),
- 'type' => 'serial',
- 'unsigned' => true,
- 'not null' => true,
- ),
- 'name' => array(
- 'description' => t('The human-readable name of the blast database.'),
- 'type' => 'varchar',
- 'length' => 255,
- 'not null' => true,
- ),
- 'path' => array(
- 'description' => t('The full path and filename prefix of the blast database.'),
- 'type' => 'varchar',
- 'length' => 1023,
- 'not null' => true,
- ),
- 'dbtype' => array(
- 'description' => t('Type of the blast database. Should be either n for nucleotide or p for protein.'),
- 'type' => 'varchar',
- 'length' => 15,
- 'not null' => true,
- ),
- 'dbxref_id_regex' => array(
- 'description' => t('The Regular Expression to use to extract the id from the FASTA header of the BLAST database hit.'),
- 'type' => 'text',
- ),
- 'dbxref_db_id' => array(
- 'description' => t('The Database records from this BLAST Database reference.'),
- 'type' => 'int',
- ),
- 'dbxref_linkout_type' => array(
- 'description' => t('Type of linkout to be used for this database reference.'),
- 'type' => 'varchar',
- 'length' => 50,
- 'not null' => true,
- 'default' => 'link'
- ),
- 'gbrowse_path' => array(
- 'description' => t('The gbrowse URL in the website of the target database.'),
- 'type' => 'varchar',
- 'length' => 1023,
- 'not null' => true,
- ),
- ),
-
- 'indexes' => array(
- 'name' => array('name'),
- ),
-
- 'primary key' => array('nid'),
- 'unique keys' => array(
- 'nid' => array('nid'),
- ),
- );
- return $schema;
- }
- function blast_ui_update_7101() {
-
- db_change_field('blastdb', 'dbtype', 'dbtype',
- array(
- 'description' => t('Type of the blast database. Should be either n for nucleotide or p for protein.'),
- 'type' => 'varchar',
- 'length' => 15,
- 'not null' => true,
- )
- );
-
- db_add_field(
- 'blastdb',
- 'dbxref_id_regex',
- array(
- 'description' => t('The Regular Expression to use to extract the id from the FASTA header of the BLAST database hit.'),
- 'type' => 'text',
- )
- );
- db_add_field(
- 'blastdb',
- 'dbxref_db_id',
- array(
- 'description' => t('The Database records from this BLAST Database reference.'),
- 'type' => 'int',
- )
- );
- }
- function blast_ui_update_7102() {
- db_add_field(
- 'blastdb',
- 'dbxref_linkout_type',
- array(
- 'description' => t('Type of linkout to be used for this database reference.'),
- 'type' => 'varchar',
- 'length' => 50,
- 'not null' => true,
- 'default' => 'link'
- )
- );
- }
|