You are here

function power_menu_update_6001 in Power Menu 6

Updating and adding an additional language field to the table

File

./power_menu.install, line 109
just containing the stuff for install and uninstall

Code

function power_menu_update_6001() {
  $ret = array();
  $field = array(
    'type' => 'varchar',
    'length' => 100,
    'not null' => TRUE,
    'default' => '',
  );
  $current_menu = variable_get('power_menu_menu', '');
  db_add_field($ret, 'power_menu', 'menu_name', $field);
  db_add_index($ret, 'power_menu', 'menu_name', array(
    'menu_name',
  ));
  $ret[] = update_sql("UPDATE {power_menu} SET menu_name='%s'", $current_menu);
  return $ret;
}