/[drupal]/contributions/modules/actions/actions.module
ViewVC logotype

Diff of /contributions/modules/actions/actions.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.39, Mon May 5 15:08:38 2008 UTC revision 1.40, Sun Aug 3 03:41:44 2008 UTC
# Line 1  Line 1 
1  <?php  <?php
2  // $Id: actions.module,v 1.38 2008/04/29 20:00:33 jvandyk Exp $  // $Id: actions.module,v 1.39 2008/05/05 15:08:38 jvandyk Exp $
3    
4  /**  /**
5   * @file   * @file
# Line 46  function actions_help($section) { Line 46  function actions_help($section) {
46   */   */
47  function actions_menu($may_cache) {  function actions_menu($may_cache) {
48    $items = array();    $items = array();
49    $access = user_access('administer_actions');    $access = user_access('administer actions');
50    
51    if ($may_cache) {    if ($may_cache) {
52      $items[] = array(      $items[] = array(
# Line 175  function actions_menu($may_cache) { Line 175  function actions_menu($may_cache) {
175   * Implementation of hook_perm().   * Implementation of hook_perm().
176   */   */
177  function actions_perm() {  function actions_perm() {
178    return array('administer_actions');    return array('administer actions');
179  }  }
180    
181  /**  /**
# Line 206  function actions_manage() { Line 206  function actions_manage() {
206    }    }
207    
208    $row = array();    $row = array();
209    $instances_present = db_fetch_object(db_query("SELECT aid FROM {actions} WHERE parameters != ''"));    $instances_present = db_fetch_object(db_query("SELECT aid FROM {actions} WHERE parameters <> ''"));
210    $header = array(    $header = array(
211      array('data' => t('Action type'), 'field' => 'type'),      array('data' => t('Action type'), 'field' => 'type'),
212      array('data' => t('Description'), 'field' => 'description'),      array('data' => t('Description'), 'field' => 'description'),
# Line 512  function actions_unassign($hook = NULL, Line 512  function actions_unassign($hook = NULL,
512      '#value' => $aid,      '#value' => $aid,
513    );    );
514    
515    $action = db_result(db_query("SELECT aid FROM {actions} WHERE MD5(aid) = '%s' AND parameters != ''", $aid));    $action = db_result(db_query("SELECT aid FROM {actions} WHERE MD5(aid) = '%s' AND parameters <> ''", $aid));
516    $actions = actions_get_all_actions();    $actions = actions_get_all_actions();
517    
518    $destination = 'admin/build/trigger/'. ($hook == 'nodeapi' ? 'node' : $hook);    $destination = 'admin/build/trigger/'. ($hook == 'nodeapi' ? 'node' : $hook);
# Line 1278  function system_message_action(&$object, Line 1278  function system_message_action(&$object,
1278        break;        break;
1279      default:      default:
1280        // Check context for node.        // Check context for node.
1281       if (!isset($object) && isset($context['node'])) {        if (!isset($object) && isset($context['node'])) {
1282          $node = $context['node'];          $node = $context['node'];
1283        }        }
1284        else {        else {

Legend:
Removed from v.1.39  
changed lines
  Added in v.1.40

  ViewVC Help
Powered by ViewVC 1.1.2