You are here

function field_group_multiple_install in Field group multiple 7

Same name and namespace in other branches
  1. 7.x field_group_multiple.install \field_group_multiple_install()

Implements hook_install().

File

./field_group_multiple.install, line 10
field_group_multiple.install

Code

function field_group_multiple_install() {

  // set module weight higher then this of field_group
  // we want that our module starts after field_group functions
  $field_group_weight = db_select("system", "s")
    ->fields("s", array(
    "weight",
  ))
    ->condition('name', 'field_group')
    ->execute()
    ->fetchField(0);
  $field_group_multiple_weight = $field_group_weight + 1;
  db_update('system')
    ->fields(array(
    'weight' => $field_group_multiple_weight,
  ))
    ->condition('name', 'field_group_multiple')
    ->execute();
}