You are here

function ds_field_row_form_format_summary_construct in Display Suite 7.2

Same name and namespace in other branches
  1. 8.4 includes/field_ui.inc \ds_field_row_form_format_summary_construct()
  2. 8.2 includes/field_ui.inc \ds_field_row_form_format_summary_construct()
  3. 8.3 includes/field_ui.inc \ds_field_row_form_format_summary_construct()

Helper function for formatter summary settings.

2 calls to ds_field_row_form_format_summary_construct()
_ds_field_ui_core_fields in includes/ds.field_ui.inc
Alter the core field on the the Field UI form.
_ds_field_ui_fields in includes/ds.field_ui.inc
Add the fields to the Field UI form.

File

includes/ds.field_ui.inc, line 2481
Field UI functions for Display Suite.

Code

function ds_field_row_form_format_summary_construct(&$table, $key) {
  $base_button = array(
    '#submit' => array(
      'field_ui_display_overview_multistep_submit',
    ),
    '#ajax' => array(
      'callback' => 'field_ui_display_overview_multistep_js',
      'wrapper' => 'field-display-overview-wrapper',
      'effect' => 'fade',
    ),
    '#field_name' => $key,
  );

  // Add the configure button.
  $table[$key]['settings_edit'] = $base_button + array(
    '#type' => 'image_button',
    '#name' => $key . '_formatter_settings_edit',
    '#src' => 'misc/configure.png',
    '#attributes' => array(
      'class' => array(
        'field-formatter-settings-edit',
      ),
      'alt' => t('Edit'),
    ),
    '#op' => 'edit',
    // Do not check errors for the 'Edit' button.
    '#limit_validation_errors' => array(),
    '#prefix' => '<div class="field-formatter-settings-edit-wrapper">',
    '#suffix' => '</div>',
  );
}