Skip to content

Commit

Permalink
feature:2236
Browse files Browse the repository at this point in the history
add "all photos" prefilter

git-svn-id: http://piwigo.org/svn/trunk@9912 68402e56-0260-453c-a942-63ccdbb3a9ee
  • Loading branch information
patdenice committed Mar 29, 2011
1 parent eb70a11 commit 88eda5f
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 2 deletions.
15 changes: 14 additions & 1 deletion admin/batch_manager.php
Expand Up @@ -55,7 +55,7 @@

if (isset($_POST['filter_prefilter_use']))
{
$prefilters = array('caddie', 'last import', 'with no album', 'with no tag', 'with no virtual album', 'duplicates');
$prefilters = array('caddie', 'last import', 'with no album', 'with no tag', 'with no virtual album', 'duplicates', 'all photos');
if (in_array($_POST['filter_prefilter'], $prefilters))
{
$_SESSION['bulk_manager_filter']['prefilter'] = $_POST['filter_prefilter'];
Expand Down Expand Up @@ -240,6 +240,19 @@
array_from_query($query, 'id')
);
}

if ('all photos' == $_SESSION['bulk_manager_filter']['prefilter'])
{
$query = '
SELECT id
FROM '.IMAGES_TABLE.'
;';

array_push(
$filter_sets,
array_from_query($query, 'id')
);
}
}

if (isset($_SESSION['bulk_manager_filter']['category']))
Expand Down
3 changes: 2 additions & 1 deletion admin/themes/default/template/batch_manager_global.tpl
Expand Up @@ -321,12 +321,13 @@ $(document).ready(function() {
<select name="filter_prefilter">
<option value="caddie" {if $filter.prefilter eq 'caddie'}selected="selected"{/if}>{'caddie'|@translate}</option>
<option value="last import" {if $filter.prefilter eq 'last import'}selected="selected"{/if}>{'last import'|@translate}</option>
<option value="with no album" {if $filter.prefilter eq 'with no album'}selected="selected"{/if}>{'with no album'|@translate}</option> -->
<option value="with no album" {if $filter.prefilter eq 'with no album'}selected="selected"{/if}>{'with no album'|@translate}</option>
{if $ENABLE_SYNCHRONIZATION}
<option value="with no virtual album" {if $filter.prefilter eq 'with no virtual album'}selected="selected"{/if}>{'with no virtual album'|@translate}</option>
{/if}
<option value="with no tag" {if $filter.prefilter eq 'with no tag'}selected="selected"{/if}>{'with no tag'|@translate}</option>
<option value="duplicates" {if $filter.prefilter eq 'duplicates'}selected="selected"{/if}>{'duplicates'|@translate}</option>
<option value="all photos" {if $filter.prefilter eq 'all photos'}selected="selected"{/if}>{'all photos'|@translate}</option>
</select>
</li>
<li id="filter_category" {if !isset($filter.category)}style="display:none"{/if}>
Expand Down
1 change: 1 addition & 0 deletions language/en_UK/admin.lang.php
Expand Up @@ -777,4 +777,5 @@
$lang['Visit theme site'] = 'Visit theme site';
$lang['Visit language site'] = 'Visit language site';
$lang['New Version'] = 'New Version';
$lang['all photos'] = 'all photos';
?>
1 change: 1 addition & 0 deletions language/fr_FR/admin.lang.php
Expand Up @@ -788,4 +788,5 @@
$lang['Visit theme site'] = 'Visitez le site du thème';
$lang['Visit language site'] = 'Visitez le site de la langue';
$lang['New Version'] = 'Nouvelle version';
$lang['all photos'] = 'toutes les photos';
?>

0 comments on commit 88eda5f

Please sign in to comment.