protected function EntityViewDisplayEditForm::buildExtraFieldRow in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/field_ui/src/Form/EntityViewDisplayEditForm.php \Drupal\field_ui\Form\EntityViewDisplayEditForm::buildExtraFieldRow()
Builds the table row structure for a single extra field.
Parameters
string $field_id: The field ID.
array $extra_field: The pseudo-field element.
Return value
array A table row array.
Overrides EntityDisplayFormBase::buildExtraFieldRow
File
- core/
modules/ field_ui/ src/ Form/ EntityViewDisplayEditForm.php, line 73 - Contains \Drupal\field_ui\Form\EntityViewDisplayEditForm.
Class
- EntityViewDisplayEditForm
- Edit form for the EntityViewDisplay entity type.
Namespace
Drupal\field_ui\FormCode
protected function buildExtraFieldRow($field_id, $extra_field) {
$extra_field_row = parent::buildExtraFieldRow($field_id, $extra_field);
// Insert an empty placeholder for the label column.
$label = array(
'empty_cell' => array(
'#markup' => ' ',
),
);
$label_position = array_search('plugin', array_keys($extra_field_row));
$extra_field_row = array_slice($extra_field_row, 0, $label_position, TRUE) + $label + array_slice($extra_field_row, $label_position, count($extra_field_row) - 1, TRUE);
return $extra_field_row;
}