You are here

payment_webform.install in Payment for Webform 7

Installation and uninstallation functions.

File

payment_webform.install
View source
<?php

/**
 * @file
 * Installation and uninstallation functions.
 */

/**
 * Implements hook_schema().
 */
function payment_webform_schema() {
  $schema['payment_webform'] = array(
    'fields' => array(
      'cid' => array(
        'type' => 'int',
        'not null' => TRUE,
        'default' => 0,
      ),
      'pid' => array(
        'type' => 'int',
        'not null' => TRUE,
        'default' => 0,
      ),
    ),
    'primary key' => array(
      'pid',
    ),
    'foreign keys' => array(
      'pid' => array(
        'table' => 'payment',
        'columns' => array(
          'pid' => 'pid',
        ),
      ),
      'cid' => array(
        'table' => 'webform_component',
        'columns' => array(
          'cid' => 'cid',
        ),
      ),
    ),
    'indexes' => array(
      'cid' => array(
        'cid',
      ),
    ),
  );
  return $schema;
}

Functions

Namesort descending Description
payment_webform_schema Implements hook_schema().