Show latest list sorted by creation date

Hi, I have seen few topics with the solution I am looking for.

I think my question is very similar to latest @abcoathup question in this post.

However, this was not answered. How can I configure my discourse site so that when users enter the main address they jump directly to mysitedomain/latest?order=created ?

And additionally, when users press on the button latest, how I configure the site so that they are re-directed to mysitedomain/latest?order=created. ?

Thanks!

4 个赞

This is not possible at the current time, nor is it planned.

You can use search, if you select “sort by latest topic”.

2 个赞

Hi @codinghorror, can you point me the way to search how I can modify this? I would love to see the latest list sorted by creation date.

1 个赞

I (kinda) solve this on my forum by using redirect links, thanks to this post:



Change yoursite.com for the name of your site.

NOTE: If you are a developer, please understand that I’m not. Please dont hate me for doing this :stuck_out_tongue_closed_eyes: I know this is not the proper way to do this.

1 个赞

I get this to work by modifying this component a litter bit, that is, adding a button for ‘sorted by date’

where I passed in a url query in setting by:

unfinished; unfinished; ?tags=unfinished
created-time; created-time; ?order=created

and check search param in the script:


  api.modifyClass("component:navigation-item", {
    active: Ember.computed("contentFilterMode", "filterMode", function() {
      let contentFilterMode = this.get("content").get("filterMode");

      if (decodeURIComponent(window.location.search) === location) { // check search param
        return contentFilterMode.includes(filter); // if includes this param, active = true;
      } else {
        return this._super(contentFilterMode, this.get("filterMode"));
      }
    })
  });

This works for me but this script will refresh whole page rather than just the inner part, is there a way I can make it only refresh inner topic component?

2 个赞

Hi @HeyRR, have you got this resolved. Would be interested as well as many of our members are requesting a possibility to order the latest page by creation date and not by activity date?

1 个赞

No luck, sorry, currently I just use the solution I mentioned above, I’m not super familiar with the structure.

1 个赞

We’d like to see this in our Discourse community. We are new to Discourse but currently finding it difficult to moderate our community and ensure no user feedback, questions etc slip through the cracks. Since we are all working across different time zones the handoff from one moderator to another can be tricky. It would be great if we could easily choose to see all activity created on a certain day. That way if there is a gap in our handover we would see any activity for the hours we were not ‘on call’ It would also help us to see who should be responding to activity based on when it was created.

1 个赞

我也支持增加这方面的支持:

我们中的一些人非常习惯于按稳定的时间顺序浏览事物;这有助于我们利用人类的空间“硬件”来跟踪我们所看到的内容。一个论坛不断变化的“最新”视图(以及所有其他视图选项和其他 UI 元素)可能会让人感到有些混乱和压力。

而且,我花了很多时间在我们新的论坛中来理解和解释“最新”实际上有两个重要的变体:“最新活跃/置顶”,如果你点击网站标题就可以看到;以及“最新创建”,如果你点击“最新”导航链接就可以看到。

目前,“最新创建”(?order=created)可以配置为“分类”视图的默认视图,但不能配置为“最新”视图的默认视图。

我们也相当怀念拥有一个“最新创建/置顶”的选项。目前,在“最新”和“分类”视图中,我们可以按时间顺序显示主题,或者在顶部显示置顶的欢迎主题,但不能同时显示两者。

3 个赞

是的,我明白了。

我认为我们需要重新考虑 Discourse 中的“主页”设置,允许任何路由成为主页,并让用户灵活选择他们想要的主页。目前菜单上有 5 到 6 个项目,但实际上我们可以通过允许“自定义…”作为主页来支持数百个项目。

3 个赞

增加趣味性:我注意到当我(通过各种方式)导航到“Top”或“Hot”时,它们的 URL 经常(但不总是)会添加 ?order=created,这会使其失去意义。还没有弄清楚是什么触发了这个问题!

2 个赞

created_at 设置为默认排序的插件:Created as Default Sort Order