function field_test_entity_info_alter in Drupal 7
Implements hook_entity_info_alter().
File
- modules/
field/ tests/ field_test.entity.inc, line 132 - Defines an entity type.
Code
function field_test_entity_info_alter(&$entity_info) {
// Enable/disable field_test as a translation handler.
foreach (field_test_entity_info_translatable() as $entity_type => $translatable) {
$entity_info[$entity_type]['translation']['field_test'] = $translatable;
}
// Disable locale as a translation handler.
foreach ($entity_info as $entity_type => $info) {
$entity_info[$entity_type]['translation']['locale'] = FALSE;
}
}