quiz_question.install in Quiz 7
Same filename and directory in other branches
- 8.4 question_types/quiz_question/quiz_question.install
- 6.6 question_types/quiz_question/quiz_question.install
- 6.3 question_types/quiz_question/quiz_question.install
- 6.4 question_types/quiz_question/quiz_question.install
- 6.5 question_types/quiz_question/quiz_question.install
- 7.6 question_types/quiz_question/quiz_question.install
- 7.4 question_types/quiz_question/quiz_question.install
- 7.5 question_types/quiz_question/quiz_question.install
The installer file for quiz_question.
File
question_types/quiz_question/quiz_question.installView source
<?php
/**
* The installer file for quiz_question.
* @file
*/
/**
* Implements hook_install().
*/
function quiz_question_install() {
}
/**
* Implements hook_schema().
*/
function quiz_question_schema() {
$schema = array();
$schema['quiz_question_properties'] = array(
'description' => 'Properties common for all quizzes',
'fields' => array(
'nid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
),
'vid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
),
'max_score' => array(
'type' => 'int',
'unsigned' => TRUE,
'default' => 0,
),
),
'primary key' => array(
'nid',
'vid',
),
);
$schema['quiz_question_latest_quizzes'] = array(
'description' => 'Stores the latest quizzes each user has been involved in',
'fields' => array(
'quiz_nid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
),
'uid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
),
'id' => array(
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
),
),
'primary key' => array(
'id',
),
);
return $schema;
}
/**
* Implements hook_uninstall().
*/
function quiz_question_uninstall() {
}
Functions
Name![]() |
Description |
---|---|
quiz_question_install | Implements hook_install(). |
quiz_question_schema | Implements hook_schema(). |
quiz_question_uninstall | Implements hook_uninstall(). |