You are here

function serial_schema in Serial Field 7

Same name and namespace in other branches
  1. 8 serial.install \serial_schema()
  2. 6 serial.install \serial_schema()

Implements hook_schema().

File

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

Code

function serial_schema() {

  // Get the standard schema:
  module_load_include('inc', 'serial');
  $table_schema = _serial_get_table_schema();
  $schema = array();
  foreach (_serial_get_all_fields() as $field) {
    $schema[_serial_get_table_name($field->entity_type, $field->bundle, $field->field_name)] = $table_schema;
  }

  // Return the schema of all the assistant tables (one per field instance).
  return $schema;
}