role_export.install in Role Export 7
Same filename and directory in other branches
Install, Uninstall, Schema and Update functions for role_export
File
role_export.installView source
<?php
/**
* @file
* Install, Uninstall, Schema and Update functions for role_export
*/
/**
* Implements hook_schema_alter().
*/
function role_export_schema_alter(&$schema) {
// Add machine_name field to the 'role' table.
$schema['role']['fields']['machine_name'] = array(
'description' => 'The machine name assigned by the user during creation of the role.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => '',
);
}
/**
* Implements hook_install().
*/
function role_export_install() {
db_add_field('role', 'machine_name', array(
'description' => 'The machine name assigned by the user during creation of the role.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => '',
));
}
/**
* Implements hook_uninstall().
*/
function role_export_uninstall() {
db_drop_field('role', 'machine_name');
}
Functions
Name | Description |
---|---|
role_export_install | Implements hook_install(). |
role_export_schema_alter | Implements hook_schema_alter(). |
role_export_uninstall | Implements hook_uninstall(). |