You are here

function serial_field_schema in Serial Field 7

Implements hook_field_schema().

File

./serial.install, line 10
Install, update and uninstall functions for the Serial module.

Code

function serial_field_schema(array $field) {
  $columns = array();
  switch ($field['type']) {
    case 'serial':
      $columns['value'] = array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'sortable' => TRUE,
        'views' => TRUE,
        'index' => TRUE,
      );
      break;
  }
  return array(
    'columns' => $columns,
  );
}