You are here

function commerce_price_table_ief_install in Commerce Price Table 7

Implements hook_install(). Ensures that the weight of this module is higher than the weight of the inline_entity_form module.

File

commerce_price_table_ief/commerce_price_table_ief.install, line 8

Code

function commerce_price_table_ief_install() {
  $weight = db_select('system', 's')
    ->fields('s', array(
    'weight',
  ))
    ->condition('name', 'inline_entity_form', '=')
    ->execute()
    ->fetchField();
  db_update('system')
    ->fields(array(
    'weight' => $weight + 1,
  ))
    ->condition('name', 'commerce_price_table_ief', '=')
    ->execute();
}