Album: listing albums in descending order

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Locked
prefab

Album: listing albums in descending order

Post by prefab »

It would be nice if albums were listed in descending order by default, and a parameter could be used for changing this ( like sortasc in News ). As a workaround the template can be modified to do this:

replace the loop

{foreach from=$albums item=album}
..$album->..
{/foreach}

with

{section name=album loop=$albums step=-1}
..$albums[album]->..
{/section}

cheers
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am
Location: Deatsville, AL

Re: Album: listing albums in descending order

Post by Elijah Lofgren »

prefab wrote: It would be nice if albums were listed in descending order by default, and a parameter could be used for changing this ( like sortasc in News ).
I started adding this in, but then I remembered that you can reorder Albums using the Album Admin Interface. I've just added more headings to make it clearer. Check out the latest SVN version of Album and you'll see something like the attached image (red box added).

Hope this helps,

Elijah

[attachment deleted by admin]
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
tsw
Power Poster
Power Poster
Posts: 1408
Joined: Tue Dec 13, 2005 10:50 pm
Location: Finland

Re: Album: listing albums in descending order

Post by tsw »

It might still be nice to have reverse order as new galleries will be at the bottom by default and one might want to show new albums first in the listing automagically :)
prefab

Re: Album: listing albums in descending order

Post by prefab »

Reordering works as advertised, but for large lists it is maybe cumbersome. Is there a way to put newly created albums at the top of the list?

Cheers
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am
Location: Deatsville, AL

Re: Album: listing albums in descending order

Post by Elijah Lofgren »

prefab wrote: Reordering works as advertised, but for large lists it is maybe cumbersome. Is there a way to put newly created albums at the top of the list?
That would make a good option. I've submitted a feature request and hopefully someday I'll get around to adding it:
http://dev.cmsmadesimple.org/tracker/in ... d=728  ;)
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
prefab

Re: Album: listing albums in descending order

Post by prefab »

Elijah Lofgren wrote: I've submitted a feature request and hopefully someday I'll get around to adding it:
http://dev.cmsmadesimple.org/tracker/in ... d=728  ;)
Thanks Elijah and keep up the good work.
Cheers
User avatar
Elijah Lofgren
Power Poster
Power Poster
Posts: 811
Joined: Mon Apr 24, 2006 1:01 am
Location: Deatsville, AL

Re: Album: listing albums in descending order

Post by Elijah Lofgren »

prefab wrote: Reordering works as advertised, but for large lists it is maybe cumbersome. Is there a way to put newly created albums at the top of the list?
I've finally added this in the latest SVN version of Album:
http://viewsvn.cmsmadesimple.org/viewsv ... m&view=rev

To use it upgrade to latest SVN of Album and call Album with something like this:

Code: Select all

{cms_module module='album'sortdesc='true'}
Enjoy,

Elijah
Note: I don't have time to take on any more projects. I'm quite busy. I may be too busy to reply to emails or messages. Thanks for your understanding. :)
prefab

Re: Album: listing albums in descending order

Post by prefab »

Elijah Lofgren wrote: I've finally added this in the latest SVN version of Album:
http://viewsvn.cmsmadesimple.org/viewsv ... m&view=rev
Hi Elijah,

I used SVN rev 98 and the option works very well. Thank you for all your good work.

Cheers
Locked

Return to “Modules/Add-Ons”