View source
<?php
function fe_nodequeue_install() {
drupal_install_schema('fe_nodequeue');
$weight = db_result(db_query("SELECT weight FROM {system} WHERE name = 'nodequeue'"));
db_query("UPDATE {system} SET weight = %d WHERE name = 'fe_nodequeue'", $weight + 1);
}
function fe_nodequeue_update_6011() {
$weight = db_result(db_query("SELECT weight FROM {system} WHERE name = 'nodequeue'"));
db_query("UPDATE {system} SET weight = %d WHERE name = 'fe_nodequeue'", $weight + 1);
}
function fe_nodequeue_uninstall() {
drupal_uninstall_schema('fe_nodequeue');
}
function fe_nodequeue_schema() {
$schema['fe_nodequeue_queue'] = array(
'description' => '',
'export' => array(
'key' => 'machine_name',
'can disable' => FALSE,
),
'fields' => array(
'qid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
'no export' => TRUE,
),
'machine_name' => array(
'description' => 'machine_name',
'type' => 'varchar',
'length' => 32,
'not null' => TRUE,
'default' => '',
),
),
'indexes' => array(
'machine_name' => array(
'machine_name',
),
),
'primary key' => array(
'qid',
),
);
return $schema;
}