New field to count the number of views of a node

This commit is contained in:
Manuel Cillero 2017-07-26 19:44:24 +02:00
parent fda0aca579
commit 673511a713
2 changed files with 13 additions and 4 deletions

View file

@ -40,6 +40,13 @@ function recently_read_schema() {
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0
),
'views' => array(
'description' => 'The number of times that the node has been read.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 1
)
),
'primary key' => array('nid', 'uid')