You are here

function hook_eck_property_type_schema_alter in Entity Construction Kit (ECK) 7.2

Same name and namespace in other branches
  1. 7.3 eck.api.php \hook_eck_property_type_schema_alter()

Give the schema for your custom properties.

Parameters

array $schema: A schema array.

string $type: The property type.

1 invocation of hook_eck_property_type_schema_alter()
eck_property_type_schema in ./eck.properties.inc
The property types schemas.

File

./eck.api.php, line 107
ECK's API documentation.

Code

function hook_eck_property_type_schema_alter(array &$schema, $type) {
  if ($type == 'email') {
    $schema = array(
      'description' => 'An email',
      'type' => 'varchar',
      'length' => 256,
      'not null' => TRUE,
      'default' => '',
    );
  }
}