You are here

units_field.install in Units of Measurement 7.2

Install and uninstall hooks of the Units field module.

File

units_field/units_field.install
View source
<?php

/**
 * @file
 * Install and uninstall hooks of the Units field module.
 */

/**
 * Implements hook_field_schema().
 */
function units_field_field_schema($field) {
  $schema = array();
  switch ($field['type']) {
    case 'units_value':
      $schema['columns'] = array(
        'mathematical_expression_id' => array(
          'type' => 'int',
          'length' => 10,
          'not null' => TRUE,
          'description' => 'Pointer to {units_mathematical_expression_postfix}.mathematical_expression_id that represents this mathematical expression.',
        ),
      );
      break;
  }
  return $schema;
}

Functions

Namesort descending Description
units_field_field_schema Implements hook_field_schema().