Arrange images in Albums

andre75 - February 19, 2008 - 07:34
Project:Acidfree Albums
Version:5.x-1.x-dev
Component:User interface
Category:support request
Priority:normal
Assigned:Unassigned
Status:duplicate
Description

I just upgraded from 4.7 to 5, but all my carefully chosen sorting is gone. Is there any way to sort acidfree albums by weight or any other manual sorting mode?

#1

andre75 - February 21, 2008 - 07:46

I used Chronological order by creation date (changed it to DESC from ASC) and started modifying the post date, but the pager doesn't reflect the new album order, which is even more confusing. Without the change things work allright (the pager matches the album order).
I guess the pager lookup works somewhat different only with ASC queries?

#2

andre75 - February 21, 2008 - 07:47
Title:How do I sort the albums» Bounty: Add Sorting function to the Album

Looking through the database queries, I think there is a bug in how the pager queries are generated. I see these kind of statements:

pager_query SELECT DISTINCT(n.nid), n.title, n.created FROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE n.type <> 'acidfree' AND tn.tid = 129 AND n.status = 1 ORDER BY created DESC, nid ASC LIMIT 30, 1
_acidfree_pager_rewrite SELECT DISTINCT(n.nid) FROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE n.type <> 'acidfree' AND tn.tid = 129 AND n.status = 1 ORDER BY created DESC, nid ASC LIMIT 1 OFFSET 0

I am no expert, but doesn't it it try to order by "created DESC" and "nid ASC" ?

#3

andre75 - February 21, 2008 - 06:22
Title:Bounty: Add Sorting function to the Album» Arrange images in Albums

Comparing it to the database queries for the deafault mode:

pager_query SELECT DISTINCT(n.nid), n.title, n.created FROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE n.type <> 'acidfree' AND tn.tid = 129 AND n.status = 1 ORDER BY nid DESC LIMIT 22, 1
_acidfree_pager_rewrite SELECT DISTINCT(n.nid) FROM node n INNER JOIN term_node tn ON n.nid = tn.nid WHERE n.type <> 'acidfree' AND tn.tid = 129 AND n.status = 1 ORDER BY nid DESC LIMIT 1 OFFSET 0

My last offer still stands:
$50 for a decent sorting function:
-easy sorting
-functioning pager

#4

andre75 - February 22, 2008 - 03:18

Allright, I finally came up with a solution of my own and hereby claim my bounty :-)

#5

vhmauery - February 25, 2008 - 05:32
Status:active» duplicate

duplicate of http://drupal.org/node/224954

 
 

Drupal is a registered trademark of Dries Buytaert.