You are here

function userpoints_update_6 in User Points 6

Same name and namespace in other branches
  1. 5.3 userpoints.install \userpoints_update_6()

File

./userpoints.install, line 218

Code

function userpoints_update_6() {
  $ret = array();
  db_add_field($ret, 'userpoints_txn', 'expirydate', array(
    'type' => 'int',
    'length' => 11,
    'not null' => TRUE,
  ));
  db_add_field($ret, 'userpoints_txn', 'expired', array(
    'type' => 'int',
    'length' => 1,
    'not null' => TRUE,
    'size' => 'tiny',
  ));
  db_add_field($ret, 'userpoints_txn', 'parent_txn_id', array(
    'type' => 'int',
  ));
  db_add_field($ret, 'userpoints_txn', 'tid', array(
    'type' => 'int',
  ));
  db_drop_primary_key($ret, 'userpoints');
  db_add_field($ret, 'userpoints', 'tid', array(
    'type' => 'int',
  ));
  db_add_field($ret, 'userpoints', 'pid', array(
    'type' => 'serial',
    'not null' => TRUE,
  ));
  db_add_primary_key($ret, 'userpoints', 'pid');
  return $ret;
}