You are here

function addressfield_form_field_ui_field_edit_form_alter in Address Field 7

Implements hook_form_BASE_FORM_ID_alter().

Removes the default values form from the field settings page. Allows the module to implement its own, more predictable default value handling, getting around #1253820 and other bugs.

File

./addressfield.module, line 570
Defines a field for attaching country-specific addresses to entities.

Code

function addressfield_form_field_ui_field_edit_form_alter(&$form, $form_state) {
  if ($form['#field']['type'] == 'addressfield') {
    $form['instance']['default_value_widget']['#access'] = FALSE;
  }
}