You are here

function ed_classified_schema in Classified Ads 6.2

Same name and namespace in other branches
  1. 5.2 ed_classified.install \ed_classified_schema()
  2. 5 ed_classified.install \ed_classified_schema()
  3. 7.2 ed_classified.install \ed_classified_schema()

Implements hook_schema().

As of Drupal 7 schema tags do not need to be translated with t() Strings should be non-markup plain text

File

./ed_classified.install, line 99

Code

function ed_classified_schema() {
  $schema['edi_classified_nodes'] = array(
    'description' => 'Stores the ed_classified node-related type.',
    'fields' => array(
      'nid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
        'description' => 'Node nid of related node.',
      ),
      'vid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
        'description' => 'Node vid (version id).',
      ),
      'expires_on' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
      'expiration_notify_last_sent' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'default' => 0,
      ),
    ),
    'primary key' => array(
      'nid',
      'vid',
    ),
  );
  return $schema;
}