Modify

Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#2910 closed enhancement (fixed)

RFE: Configuration of default forum sorting

Reported by: kasper@… Owned by: Blackhex
Priority: normal Component: DiscussionPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.10

Description

It would be great with a configuration option for forum sorting. As of now the default sorting is by ID, ascending. It would be great if you could choose which column to sort by and which direction to sort (ASC/DESC).

Attachments (0)

Change History (5)

comment:1 Changed 7 years ago by Blackhex

  • Status changed from new to assigned
  • Summary changed from Configuration of default forum sorting to RFE: Configuration of default forum sorting

OK, I'll take a look on it soon.

comment:2 Changed 7 years ago by Blackhex

  • Resolution set to fixed
  • Status changed from assigned to closed

Implemented in r3518. Don't forget to enable DiscussionApi component on 0.10.

comment:3 Changed 7 years ago by kasper@…

Thanks for the fix, but I think there's still something wrong (at least in my installation). Check it out here: http://www.eobjects.dk/trac/discussion/1?&order=id

As you can see even when I press the "ID" it always sorts descendingly. And it doesn't even change if I modify trac.ini.

In my log it says:

2008-04-16 10:31:08,179 Trac[loader] WARNING: Cannot load plugin spamfilter.ip_blacklist because it requires "dnspython>=1.3.5"
2008-04-16 10:31:08,224 Trac[loader] WARNING: Cannot load plugin spamfilter.bayes because it requires "spambayes"

Even thought I've installed both dnspython and spambayes (using APT).

Here's the important parts of trac.ini:

[components]
tracdiscussion.api.DiscussionApi = enabled
tracdiscussion.admin.DiscussionWebAdmin = enabled
tracdiscussion.core.DiscussionCore = enabled
tracdiscussion.init.DiscussionInit = enabled
tracdiscussion.search.DiscussionSearch = enabled
tracdiscussion.timeline.DiscussionTimeline = enabled
tracdiscussion.wiki.DiscussionWiki = enabled
tracdiscussion.notification.DiscussionNotifyEmail = enabled
tracspamfilter.* = enabled

[discussion]
title = Discussion
default_display = flat
forum_sort = id
forum_sort_direction = asc
topic_sort = id
topic_sort_direction = asc

Is this maybe because I upgraded from an older discussion plugin?

comment:4 Changed 7 years ago by Blackhex

No, I just forgot that direction is internally boolean and not string and I did't notice that during testing. Now it should be fixed.

comment:5 Changed 7 years ago by kasper

Great, works like a charm :)

Add Comment

Modify Ticket

Action
as closed The owner will remain Blackhex.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.