Created
December 16, 2008 19:31
-
-
Save delonnewman/36744 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Implementation of hook_install(). | |
*/ | |
function provider_install() { | |
drupal_install_schema('provider'); | |
} | |
/** | |
* Implementation of hook_uninstall(). | |
*/ | |
function provider_uninstall() { | |
drupal_uninstall_schema('provider'); | |
} | |
/** | |
* Implementation of hook_schema(). | |
*/ | |
function provider_schema() { | |
$schema['providers'] = array( | |
'description' => t('Stores Provider information'), | |
'fields' => array( | |
'id' => array( | |
'type' => 'int', | |
'not null' => TRUE, | |
'description' => t('Primary Key: Unique access ID.'), | |
), | |
'user_id' => array( | |
'type' => 'int', | |
'not null' => TRUE, | |
'description' => t('Links Provider information to a specific User'), | |
), | |
'birth_date' => array( | |
'type' => 'date', | |
'not null' => FALSE, | |
'description' => t('Stores the Providers Birth Date'), | |
), | |
'address' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'city' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'state' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'zip' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'phone' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'fax' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'education_level' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'work_status' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'position' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'schedule' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'license' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'vehicle' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'travel' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'living' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'photo_file' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'resume_file' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
'background' => array( | |
'type' => 'varchar', | |
'not null' => FALSE, | |
), | |
), | |
'primary key' => array('id'), | |
); | |
return $schema; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment