function revision_scheduler_test_entity_revision_operation_info in Revision scheduler 7
Implements hook_entity_revision_operation_info() on behalf of node.module.
File
- tests/
revision_scheduler_test/ revision_scheduler_test.module, line 6
Code
function revision_scheduler_test_entity_revision_operation_info() {
$operations['node']['test_new'] = array(
'label' => t('Test new node'),
'access callback' => TRUE,
'callback' => 'revision_scheduler_test_operation',
);
$operations['node']['test_existing'] = array(
'label' => t('Test existing node'),
'access callback' => TRUE,
'callback' => 'revision_scheduler_test_operation',
);
$operations['node']['test_permission'] = array(
'label' => t('Test permission'),
'access arguments' => array(
'bypass node access',
),
'callback' => 'revision_scheduler_test_operation',
);
$operations['node']['test_anonymous'] = array(
'label' => t('Test anonymous'),
'access callback' => TRUE,
'callback' => 'revision_scheduler_test_operation',
);
$operations['node']['test_no_access'] = array(
'label' => t('No access test'),
'access callback' => FALSE,
'callback' => 'revision_scheduler_test_operation',
);
$operations['file']['file_only'] = array(
'label' => t('File operation'),
'access callback' => TRUE,
'callback' => 'revision_scheduler_test_operation',
);
return $operations;
}