You are here

function revisioning_action_info in Revisioning 7

Same name and namespace in other branches
  1. 8 revisioning_triggers_actions.inc \revisioning_action_info()
  2. 6.4 revisioning_triggers_actions.inc \revisioning_action_info()
  3. 6 revisioning_triggers_actions.inc \revisioning_action_info()
  4. 6.3 revisioning_triggers_actions.inc \revisioning_action_info()

Implements hook_action_info().

Defines actions available in the Revisioning module.

File

./revisioning_triggers_actions.inc, line 146
Triggers and actions supported by the Revisioning module.

Code

function revisioning_action_info() {
  $action_info = array(
    'revisioning_delete_archived_action' => array(
      'type' => 'node',
      'label' => t('Delete archived revisions'),
      'configurable' => FALSE,
      'triggers' => array(
        'any',
      ),
    ),
    'revisioning_publish_latest_revision_action' => array(
      'type' => 'node',
      'label' => t('Publish the most recent pending revision'),
      // For 'configurable' => TRUE, then we must define a form function with
      // the same name as the action function with '_form' appended.
      'configurable' => FALSE,
      // 'behavior' => array('changes_property'),
      // Unlike 'node_publish_action', this is NOT a 'node_presave' action:
      'triggers' => array(
        'any',
      ),
    ),
  );
  return $action_info;
}