Sort topics (within category) in alphabetical order by default

I know that the issue has been discussed before and some progress has been made (and that many disagree that alphabetic sorting on topic title is useful), but to me it is. I am experimenting with Discourse to see if I can use it to replace NeuroDSS.com which contains neurosurgical classification and grading systems. The option that users can add their own classifications (and more) and discuss them on site is a great side benefit. Primarily however, I want users to go to categories easily and find the content they are looking for.

I managed to get the categories view first when accessing NeuroMind.cc, and modified @sam’s Minimal Topic List Design to allow the user to sort topics in alphabetical order by changing this piece in the header :

<script type='text/x-handlebars' data-template-name='topic-list-header.raw'>
    {{raw "topic-list-header-column" sortable='true' order='topic.title' name='topic.title'}}

This works, but the user still has to perform the sorting manually. How can this be done as a default setting when the category is opened?

Side note: I also changed

{{raw "topic-list-header-column" sortable='true' number='true' order='replies' forceName='Replies'}}

(in the original post it said order='posts' and it gave some side effects, guess that is a typo)

Any help would be greatly appreciated!

Pieter

I think if you “need” to sort by title there is something wrong with your approach. As in, you should be using categories or tags for that information rather than embedding it in the title as a string.

That depends, I guess… If someone wants to “browse” through a certain category it may be helpful if the content is sorted. Otherwise a topic may be at a different position everytime.

I realize this is not the main purpose of Discourse, but to me the lack of it is currently holding me back of proceeding. Fortunately you also offer categories as JSON in which I can do sorting to create some mobile version myself, but I prefer not to. :wink:

It would probably be easy enough to sort by title except for one problem - endless scroll.

So do an alpha sort in batches of 30?

Wouldn’t it be better to use Search?

Depends… for very large categories, yes. But if a specific category is restricted regarding adding new content, no.

We have a category explaining terms; a dictionary. Here alphabetic sorting would be handy to quickly scroll to the right term.
Why is endless scrolling a problem…? Couldn’t you just start with ‘A’ and load ‘B’ as the user scrolls down?

Or is the problem that the list can’t be made because to the browser not all topics are known yet, before the user scroll down?

I think using Tags would be the far easier way to present alphabetically grouped lists, else The Search feature.

It looks like this idea isn’t going to happen but just to share my use case - we have voting enabled for topics & want to enable users to vote for the stocks that they’d like us to add to our service so that they can invest in them (we’re a stockbroker).

The names of each topic within the dedicated category is the name of the stock.

Unless I’m missing something, it seems like the most useful way to order the list, within the category view, would be in alphabetical order, to make finding stocks that others have already requested easier.

I don’t think Tags would be right for this, as we’d only use each Tag once - one Tag for each of the stocks. And as we all know, a large proportion of users don’t use search.

My use case: One of the categories in my Discourse is a User Guide for a website. In the User Guide category I have Topics like “About”, “Getting Started”, “Searching”, etc. These Topics should be ordered in a specific way, rather than by last update or some other metric. If I could sort the Topics alphabetically, I could rename them to “1. About”, “2. Getting Started”, etc.

これ、もう実現できませんか?さまざまな用途を説明した多くのリクエストがあり、多くの人に影響を与えています。良いプラクティスを推奨するという全体の哲学は理解していますが、私が把握しているだけでも少なくとも4つのトピックがあり、それに対する多くの返信で要求がなされています…「間違ったやり方をしている」と主張するのは、要するに「みんながバカだ」と言っているのと同じくらいです :slight_smile:

少なくとも、URL にクエリ文字列(?sort=title)を付けて実行できるようにしてください。GUI の余分な機能に時間を浪費する必要がなくなります。しかし、それをほぼ不可能になるほど反対しないでください。

デフォルトで必要というわけではありません。単にそれを実行できるようにしたいだけです。

私の場合、投稿タイトルに整数を「ランク」として追加しています。これは、トピックの重要性を見直したり新しいトピックを追加したりするにつれて、時間とともに変更されます。整数は必ずしも連続しているわけではなく、その値自体も重要です。これはプライベートフォーラムであり、各トピックは(重要な)情報の一部です。最終ステップとして、そこから最適な N 個を選ぶ必要があります。ランクの見直しプロセスでは、すべてのトピックを1ページで表示し、整数も確認する必要があります。その後、ソートし直し、再度見直し、といった作業を、既存のランクの間にさまざまなランクのトピックを追加しながら継続して行います。

タグやその他の不格好な分類を使うことはできません。それではタイトルのサブセットが表示されなくなってしまうからです。検索も役立ちません。

現在は、タイトルを Excel にコピー&ペーストしてそこで全て処理し、その後戻って再編集する…という作業を繰り返しています… これは愚かです。Discourse にはタイトルでのソート機能が必要です。これは非常に基本的なことです。

p.p.s. 現時点で私が把握しているものは以下の通りです。

これについて、また新しいトピックが必要なのでしょうか?それほど強くお考えなら、Marketplace で報酬を提示するか、discourse.org でエンタープライズホスティングプランに登録してください。