You are here

function _bricks_inline_preprocess_tabledrag_form in Bricks​ 7.5

Preprocess of bricks' related table fields.

1 call to _bricks_inline_preprocess_tabledrag_form()
bricks_inline_preprocess_bricks_inline_entity_form_table in bricks_inline/bricks_inline.module
Implements hook_preprocess_HOOK() for theme_bricks_inline_entity_form_table().

File

bricks_inline/bricks_inline.module, line 102
Main file for bricks_inline module.

Code

function _bricks_inline_preprocess_tabledrag_form(&$variables) {
  $form =& $variables['form'];
  foreach (element_children($form) as $key) {
    $form[$key]['depth']['#attributes']['class'][] = 'ief-entity-depth';
  }
  $fields = array(
    'depth' => array(
      'label' => t('Depth'),
    ),
    'options' => array(
      'label' => t('Options'),
    ),
  );
  $form['#table_fields'] = array_merge($fields, $form['#table_fields']);
}