Ignore:
Timestamp:
Jan 13, 2011, 4:24:18 PM (13 years ago)
Author:
plg
Message:

feature 2108 added: user upload removed from core. It will come back as a
"new generation" user upload in the Community plugin.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/functions_notification.inc.php

    r6951 r8651  
    5555 *
    5656 * @param string action ('count' or 'info')
    57  * @param string type of query ('new_comments', 'unvalidated_comments', 'new_elements', 'updated_categories', 'new_users', 'waiting_elements')
     57 * @param string type of query ('new_comments', 'unvalidated_comments', 'new_elements', 'updated_categories', 'new_users')
    5858 * @param string start (mysql datetime format)
    5959 * @param string end (mysql datetime format)
     
    146146;';
    147147      break;
    148     case 'waiting_elements':
    149       $query = '
    150   FROM '.WAITING_TABLE.'
    151   WHERE validated = \'false\'
    152 ;';
    153       break;
    154148    default:
    155149      // stop this function and return nothing
     
    177171        case 'new_users':
    178172          $field_id = 'user_id';
    179           break;
    180         case 'waiting_elements':
    181           $field_id = 'id';
    182173          break;
    183174    }
     
    206197          $fields = array('user_id');
    207198          break;
    208         case 'waiting_elements':
    209           $fields = array('id');
    210           break;
    211199      }
    212200
     
    345333{
    346334  return custom_notification_query('info', 'new_users', $start, $end);
    347 }
    348 
    349 /**
    350  * currently waiting pictures
    351  *
    352  * @return count waiting ids
    353  */
    354 function nb_waiting_elements()
    355 {
    356   return custom_notification_query('count', 'waiting_elements', '', '');
    357 }
    358 
    359 /**
    360  * currently waiting pictures
    361  *
    362  * @return array waiting ids
    363  */
    364 function waiting_elements()
    365 {
    366   return custom_notification_query('info', 'waiting_elements', $start, $end);
    367335}
    368336
     
    387355          (nb_updated_categories($start, $end) > 0) or
    388356          ((is_admin()) and (nb_unvalidated_comments($start, $end) > 0)) or
    389           ((is_admin()) and (nb_new_users($start, $end) > 0)) or
    390           ((is_admin()) and (nb_waiting_elements() > 0))
     357          ((is_admin()) and (nb_new_users($start, $end) > 0)))
    391358        );
    392359}
     
    454421        nb_new_users($start, $end), '%d new user', '%d new users',
    455422        get_root_url().'admin.php?page=user_list', $add_url );
    456 
    457     add_news_line( $news,
    458         nb_waiting_elements(), '%d waiting element', '%d waiting elements',
    459         get_root_url().'admin.php?page=upload', $add_url );
    460423  }
    461424
Note: See TracChangeset for help on using the changeset viewer.