mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-03-28 17:42:57 +01:00
Trunk merge r5076 from bug:1119
bug:1119 git-svn-id: http://piwigo.org/svn/trunk@5079 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -132,6 +132,29 @@ SELECT id, name
|
||||
l10n('Categories ordered alphanumerically')
|
||||
);
|
||||
}
|
||||
// sort categories alpha-numerically reverse
|
||||
else if (isset($_POST['submitOrderAlphaNumReverse']))
|
||||
{
|
||||
$query = '
|
||||
SELECT id, name
|
||||
FROM '.CATEGORIES_TABLE.'
|
||||
WHERE id_uppercat '.
|
||||
(!isset($_GET['parent_id']) ? 'IS NULL' : '= '.$_GET['parent_id']).'
|
||||
;';
|
||||
$result = pwg_query($query);
|
||||
while ($row = pwg_db_fetch_assoc($result))
|
||||
{
|
||||
$categories[ $row['id'] ] = strtolower($row['name']);
|
||||
}
|
||||
|
||||
arsort($categories, SORT_REGULAR);
|
||||
save_categories_order(array_keys($categories));
|
||||
|
||||
array_push(
|
||||
$page['infos'],
|
||||
l10n('Categories ordered alphanumerically reverse')
|
||||
);
|
||||
}
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | Navigation path |
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
<p>
|
||||
<input class="submit" name="submitOrder" type="submit" value="{'Save order'|@translate}" {$TAG_INPUT_ENABLED}>
|
||||
<input class="submit" name="submitOrderAlphaNum" type="submit" value="{'Order alphanumerically'|@translate}" {$TAG_INPUT_ENABLED}>
|
||||
<input class="submit" name="submitOrderAlphaNumReverse" type="submit" value="{'Order alphanumerically reverse'|@translate}" {$TAG_INPUT_ENABLED}>
|
||||
</p>
|
||||
<ul class="categoryUl">
|
||||
|
||||
@@ -85,6 +86,7 @@
|
||||
<p>
|
||||
<input class="submit" name="submitOrder" type="submit" value="{'Save order'|@translate}" {$TAG_INPUT_ENABLED}>
|
||||
<input class="submit" name="submitOrderAlphaNum" type="submit" value="{'Order alphanumerically'|@translate}" {$TAG_INPUT_ENABLED}>
|
||||
<input class="submit" name="submitOrderAlphaNumReverse" type="submit" value="{'Order alphanumerically reverse'|@translate}" {$TAG_INPUT_ENABLED}>
|
||||
</p>
|
||||
|
||||
</form>
|
||||
|
||||
@@ -66,7 +66,8 @@ $lang['Caddie management'] = 'Caddie management';
|
||||
$lang['Caddie'] = 'Caddie';
|
||||
$lang['Categories authorized thanks to group associations'] = 'Categories authorized thanks to group associations';
|
||||
$lang['Categories manual order was saved'] = 'Categories manual order was saved';
|
||||
$lang['Categories ordered alphanumerically'] = 'Categories ordered alphanumerically';
|
||||
$lang['Categories ordered alphanumerically'] = 'Categories ascending alphanumerically ordered';
|
||||
$lang['Categories ordered alphanumerically reverse'] = 'Categories descending alphanumerically ordered';
|
||||
$lang['Category elements associated to the following categories: %s'] = 'Category elements associated to the following categories: %s';
|
||||
$lang['Check for upgrade failed for unknown reasons.'] = 'Check for upgrade failed for unknown reasons.';
|
||||
$lang['Check for upgrade'] = 'Check for upgrade';
|
||||
@@ -131,7 +132,8 @@ $lang['Number of thumbnails to create'] = 'Number of thumbnails to create';
|
||||
$lang['Only private categories are listed'] = 'Only private categories are listed';
|
||||
$lang['Operating system'] = 'Operating system';
|
||||
$lang['Options'] = 'Options';
|
||||
$lang['Order alphanumerically'] = 'Order alphanumerically';
|
||||
$lang['Order alphanumerically'] = 'Categories sorted in ascending order ⇓';
|
||||
$lang['Order alphanumerically inverse'] = 'Categories sorted in descending order ⇑';
|
||||
$lang['Other private categories'] = 'Other private categories';
|
||||
$lang['Page banner'] = 'Page banner';
|
||||
$lang['Parent category'] = 'Parent category';
|
||||
|
||||
@@ -66,7 +66,8 @@ $lang['Caddie management'] = 'Gestion du panier';
|
||||
$lang['Caddie'] = 'Panier';
|
||||
$lang['Categories authorized thanks to group associations'] = 'Catégories accessibles grâce à l\'appartenance aux groupes';
|
||||
$lang['Categories manual order was saved'] = 'L\'ordre manuel des catégories a été sauvegardé';
|
||||
$lang['Categories ordered alphanumerically'] = 'Catégories ordonnées alphabético-numériquement';
|
||||
$lang['Categories ordered alphanumerically'] = 'Catégories triées par ordre croissant alphabético-numériquement.';
|
||||
$lang['Categories ordered alphanumerically reverse'] = 'Catégories triées par ordre décroissant alphabético-numériquement.';
|
||||
$lang['Category elements associated to the following categories: %s'] = 'Les éléments de la catégorie ont été associés aux catégories suivantes : %s';
|
||||
$lang['Check for upgrade failed for unknown reasons.'] = 'La vérification de la dernière version sur le serveur a échouée pour une raison inconnue.';
|
||||
$lang['Check for upgrade'] = 'Dernière version ?';
|
||||
@@ -131,7 +132,8 @@ $lang['Number of thumbnails to create'] = 'Nombre de miniatures à créer';
|
||||
$lang['Only private categories are listed'] = 'Seules les catégories privées sont listées';
|
||||
$lang['Operating system'] = 'Système d\'exploitation';
|
||||
$lang['Options'] = 'Options';
|
||||
$lang['Order alphanumerically'] = 'Ordonner alphabético-numériquement';
|
||||
$lang['Order alphanumerically'] = 'Trier par ordre croissant ⇓';
|
||||
$lang['Order alphanumerically reverse'] = 'Trier par ordre décroissant ⇑';
|
||||
$lang['Other private categories'] = 'Autres catégories privées';
|
||||
$lang['Page banner'] = 'Bannière des pages';
|
||||
$lang['Parent category'] = 'Catégorie parente';
|
||||
|
||||
Reference in New Issue
Block a user