2012-11-20 02:33:19 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @file
|
|
|
|
* Installation functions for History module.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Implements hook_schema().
|
|
|
|
*/
|
|
|
|
function history_schema() {
|
2017-03-04 01:20:24 +00:00
|
|
|
$schema['history'] = [
|
2012-11-20 02:33:19 +00:00
|
|
|
'description' => 'A record of which {users} have read which {node}s.',
|
2017-03-04 01:20:24 +00:00
|
|
|
'fields' => [
|
|
|
|
'uid' => [
|
2012-11-20 02:33:19 +00:00
|
|
|
'description' => 'The {users}.uid that read the {node} nid.',
|
|
|
|
'type' => 'int',
|
|
|
|
'not null' => TRUE,
|
|
|
|
'default' => 0,
|
2017-03-04 01:20:24 +00:00
|
|
|
],
|
|
|
|
'nid' => [
|
2012-11-20 02:33:19 +00:00
|
|
|
'description' => 'The {node}.nid that was read.',
|
|
|
|
'type' => 'int',
|
2016-01-26 06:46:09 +00:00
|
|
|
'unsigned' => TRUE,
|
2012-11-20 02:33:19 +00:00
|
|
|
'not null' => TRUE,
|
|
|
|
'default' => 0,
|
2017-03-04 01:20:24 +00:00
|
|
|
],
|
|
|
|
'timestamp' => [
|
2012-11-20 02:33:19 +00:00
|
|
|
'description' => 'The Unix timestamp at which the read occurred.',
|
|
|
|
'type' => 'int',
|
|
|
|
'not null' => TRUE,
|
|
|
|
'default' => 0,
|
Issue #3215062 by quietone, gambry, ravi.shankar, dww, daffie, yogeshmpawar, aarti zikre, alexpott, mfb, larowlan, longwave, catch: Update hook_schema for Y2038
2022-07-23 05:46:46 +00:00
|
|
|
'size' => 'big',
|
2017-03-04 01:20:24 +00:00
|
|
|
],
|
|
|
|
],
|
|
|
|
'primary key' => ['uid', 'nid'],
|
|
|
|
'indexes' => [
|
|
|
|
'nid' => ['nid'],
|
|
|
|
],
|
|
|
|
];
|
2012-11-20 02:33:19 +00:00
|
|
|
|
|
|
|
return $schema;
|
|
|
|
}
|
2016-01-26 06:46:09 +00:00
|
|
|
|
|
|
|
/**
|
Issue #3087644 by jibran, Berdir, alexpott, longwave, Wim Leers, amateescu, catch, xjm, larowlan, dpi, quietone: Remove Drupal 8 updates up to and including 88**
2020-01-24 23:52:03 +00:00
|
|
|
* Implements hook_update_last_removed().
|
2016-01-26 06:46:09 +00:00
|
|
|
*/
|
Issue #3087644 by jibran, Berdir, alexpott, longwave, Wim Leers, amateescu, catch, xjm, larowlan, dpi, quietone: Remove Drupal 8 updates up to and including 88**
2020-01-24 23:52:03 +00:00
|
|
|
function history_update_last_removed() {
|
2024-04-19 18:12:58 +00:00
|
|
|
return 10100;
|
Issue #3215062 by quietone, gambry, ravi.shankar, dww, daffie, yogeshmpawar, aarti zikre, alexpott, mfb, larowlan, longwave, catch: Update hook_schema for Y2038
2022-07-23 05:46:46 +00:00
|
|
|
}
|