You are here

function sms_devel_schema in SMS Framework 6.2

Same name and namespace in other branches
  1. 6 modules/sms_devel/sms_devel.install \sms_devel_schema()
  2. 7 modules/sms_devel/sms_devel.install \sms_devel_schema()

Implement hook_schema()

Return value

Drupal schema.

File

modules/sms_devel/sms_devel.install, line 39
SMS Development feature module: Install file

Code

function sms_devel_schema() {
  $schema['sms_devel_virtualgw'] = array(
    'description' => t('SMS virtual gateway trace log.'),
    'fields' => array(
      'id' => array(
        'description' => t('The primary identifier.'),
        'type' => 'serial',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'created' => array(
        'description' => t('The creation timestamp.'),
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'type' => array(
        'description' => t('0=out 1=in, 2=receipt'),
        'type' => 'int',
        'size' => 'tiny',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'number' => array(
        'description' => t('If type=0/2 this is recipient. If type=1 this is sender.'),
        'type' => 'varchar',
        'length' => 20,
        'not null' => TRUE,
      ),
      'message' => array(
        'description' => t('Message text.'),
        'type' => 'text',
        'size' => 'normal',
        'not null' => FALSE,
      ),
      'options' => array(
        'description' => t('Extended message options.'),
        'type' => 'text',
        'size' => 'normal',
        'not null' => FALSE,
      ),
    ),
    'unique keys' => array(),
    'primary key' => array(
      'id',
    ),
  );
  return $schema;
}