mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-08-07 01:03:31 +02:00
feature 2108 added: user upload removed from core. It will come back as a
"new generation" user upload in the Community plugin. git-svn-id: http://piwigo.org/svn/trunk@8651 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -121,10 +121,6 @@ $conf['calendar_month_cell_height']=80;
|
||||
// or not ?
|
||||
$conf['newcat_default_commentable'] = true;
|
||||
|
||||
// newcat_default_uploadable : at creation, must a category be uploadable or
|
||||
// not ?
|
||||
$conf['newcat_default_uploadable'] = false;
|
||||
|
||||
// newcat_default_visible : at creation, must a category be visible or not ?
|
||||
// Warning : if the parent category is invisible, the category is
|
||||
// automatically create invisible. (invisible = locked)
|
||||
@@ -556,30 +552,6 @@ $conf['webmaster_id'] = 1;
|
||||
// If false it'll be redirected from index.php to identification.php
|
||||
$conf['guest_access'] = true;
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | upload |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
// upload_maxfilesize: maximum filesize for the uploaded pictures. In
|
||||
// kilobytes.
|
||||
$conf['upload_maxfilesize'] = 200;
|
||||
|
||||
// upload_maxheight: maximum height authorized for the uploaded images. In
|
||||
// pixels.
|
||||
$conf['upload_maxheight'] = 800;
|
||||
|
||||
// upload_maxwidth: maximum width authorized for the uploaded images. In
|
||||
// pixels.
|
||||
$conf['upload_maxwidth'] = 800;
|
||||
|
||||
// upload_maxheight_thumbnail: maximum height authorized for the uploaded
|
||||
// thumbnails
|
||||
$conf['upload_maxheight_thumbnail'] = 128;
|
||||
|
||||
// upload_maxwidth_thumbnail: maximum width authorized for the uploaded
|
||||
// thumbnails
|
||||
$conf['upload_maxwidth_thumbnail'] = 128;
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | history |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
@@ -77,8 +77,6 @@ if (!defined('USER_INFOS_TABLE'))
|
||||
define('USER_INFOS_TABLE', $prefixeTable.'user_infos');
|
||||
if (!defined('USER_FEED_TABLE'))
|
||||
define('USER_FEED_TABLE', $prefixeTable.'user_feed');
|
||||
if (!defined('WAITING_TABLE'))
|
||||
define('WAITING_TABLE', $prefixeTable.'waiting');
|
||||
if (!defined('RATE_TABLE'))
|
||||
define('RATE_TABLE', $prefixeTable.'rate');
|
||||
if (!defined('USER_CACHE_TABLE'))
|
||||
|
||||
@@ -54,7 +54,7 @@ function get_std_sql_where_restrict_filter($prefix_condition, $img_field='ic.ima
|
||||
* Execute custom notification query
|
||||
*
|
||||
* @param string action ('count' or 'info')
|
||||
* @param string type of query ('new_comments', 'unvalidated_comments', 'new_elements', 'updated_categories', 'new_users', 'waiting_elements')
|
||||
* @param string type of query ('new_comments', 'unvalidated_comments', 'new_elements', 'updated_categories', 'new_users')
|
||||
* @param string start (mysql datetime format)
|
||||
* @param string end (mysql datetime format)
|
||||
*
|
||||
@@ -143,12 +143,6 @@ function custom_notification_query($action, $type, $start, $end)
|
||||
$query .= ' AND registration_date <= \''.$end.'\'';
|
||||
}
|
||||
$query .= '
|
||||
;';
|
||||
break;
|
||||
case 'waiting_elements':
|
||||
$query = '
|
||||
FROM '.WAITING_TABLE.'
|
||||
WHERE validated = \'false\'
|
||||
;';
|
||||
break;
|
||||
default:
|
||||
@@ -177,9 +171,6 @@ function custom_notification_query($action, $type, $start, $end)
|
||||
case 'new_users':
|
||||
$field_id = 'user_id';
|
||||
break;
|
||||
case 'waiting_elements':
|
||||
$field_id = 'id';
|
||||
break;
|
||||
}
|
||||
$query = 'SELECT count(distinct '.$field_id.') as CountId
|
||||
'.$query;
|
||||
@@ -205,9 +196,6 @@ function custom_notification_query($action, $type, $start, $end)
|
||||
case 'new_users':
|
||||
$fields = array('user_id');
|
||||
break;
|
||||
case 'waiting_elements':
|
||||
$fields = array('id');
|
||||
break;
|
||||
}
|
||||
|
||||
$query = 'SELECT distinct '.implode(', ', $fields).'
|
||||
@@ -346,26 +334,6 @@ function new_users($start, $end)
|
||||
return custom_notification_query('info', 'new_users', $start, $end);
|
||||
}
|
||||
|
||||
/**
|
||||
* currently waiting pictures
|
||||
*
|
||||
* @return count waiting ids
|
||||
*/
|
||||
function nb_waiting_elements()
|
||||
{
|
||||
return custom_notification_query('count', 'waiting_elements', '', '');
|
||||
}
|
||||
|
||||
/**
|
||||
* currently waiting pictures
|
||||
*
|
||||
* @return array waiting ids
|
||||
*/
|
||||
function waiting_elements()
|
||||
{
|
||||
return custom_notification_query('info', 'waiting_elements', $start, $end);
|
||||
}
|
||||
|
||||
/**
|
||||
* There are new between two dates ?
|
||||
*
|
||||
@@ -386,8 +354,7 @@ function news_exists($start, $end)
|
||||
(nb_new_elements($start, $end) > 0) or
|
||||
(nb_updated_categories($start, $end) > 0) or
|
||||
((is_admin()) and (nb_unvalidated_comments($start, $end) > 0)) or
|
||||
((is_admin()) and (nb_new_users($start, $end) > 0)) or
|
||||
((is_admin()) and (nb_waiting_elements() > 0))
|
||||
((is_admin()) and (nb_new_users($start, $end) > 0)))
|
||||
);
|
||||
}
|
||||
|
||||
@@ -453,10 +420,6 @@ function news($start, $end, $exclude_img_cats=false, $add_url=false)
|
||||
add_news_line( $news,
|
||||
nb_new_users($start, $end), '%d new user', '%d new users',
|
||||
get_root_url().'admin.php?page=user_list', $add_url );
|
||||
|
||||
add_news_line( $news,
|
||||
nb_waiting_elements(), '%d waiting element', '%d waiting elements',
|
||||
get_root_url().'admin.php?page=upload', $add_url );
|
||||
}
|
||||
|
||||
return $news;
|
||||
|
||||
Reference in New Issue
Block a user