function node_limit_role_schema in Node Limit 6
Same name and namespace in other branches
- 8 old/node_limit_role/node_limit_role.install \node_limit_role_schema()
- 7 node_limit_role/node_limit_role.install \node_limit_role_schema()
Implementation of hook_schema().
File
- node_limit_role/
node_limit_role.install, line 19 - Installation functions for module node_limit_role.
Code
function node_limit_role_schema() {
$schema['node_limit_role'] = array(
'description' => t('The table for applying node limits to a role'),
'fields' => array(
'lid' => array(
'description' => t('The {node_limit}.lid'),
'type' => 'int',
'not null' => TRUE,
),
'rid' => array(
'description' => t('The {role}.rid to which this limit applies'),
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
),
),
//the limit-user combination is unique
/**
* this means that in the future, we may allow a limit to be applied to more
* than one user. right now, though, its one-user-per-limit
*/
'primary key' => array(
'lid',
'rid',
),
);
return $schema;
}