You are here

function uc_webform_schema in Ubercart Webform Integration 7.2

Same name and namespace in other branches
  1. 7.3 uc_webform.install \uc_webform_schema()
  2. 7 uc_webform.install \uc_webform_schema()

Implementation of hook_field_schema.

3 calls to uc_webform_schema()
uc_webform_update_7000 in ./uc_webform.install
uc_webform_update_7010 in ./uc_webform.install
uc_webform_update_7020 in ./uc_webform.install

File

./uc_webform.install, line 10
Contains install and update functions for uc_webform.

Code

function uc_webform_schema() {
  $schema = array(
    'uc_webform' => array(
      'fields' => array(
        'nid' => array(
          'type' => 'int',
          'unsigned' => TRUE,
          'not null' => TRUE,
        ),
        'webform_nid' => array(
          'type' => 'int',
          'unsigned' => TRUE,
          'not null' => FALSE,
          'default' => 0,
        ),
        'submit' => array(
          'type' => 'int',
          'size' => 'tiny',
          'unsigned' => TRUE,
          'not null' => TRUE,
          'default' => 0,
        ),
      ),
      'primary key' => array(
        'nid',
      ),
    ),
    'uc_webform_submission' => array(
      'fields' => array(
        'sid' => array(
          'type' => 'int',
          'unsigned' => TRUE,
          'not null' => TRUE,
        ),
        'order_id' => array(
          'type' => 'int',
          'unsigned' => TRUE,
        ),
      ),
    ),
  );
  return $schema;
}