系统徽章的锁定查询字段

这是我自 222 天前成为会员以来的第一个主题。

  1. 如何复制粘贴这段代码?

  2. 我想为 25 次成功邀请授予徽章。因此,我只需要将值 HAVING COUNT (*) >= 5 改为 HAVING COUNT (*) >= 25,并将徽章类型设置为金牌。我这样做对吗?

我找到了一个类似的话题 https://meta.discourse.org/t/promoter-badge-broken/34413,但我想确认一下,因为我对编程不太了解。

抱歉提出这个愚蠢的问题。

1 个赞

Here are the steps for enabling the SQL Badge Queries

6 个赞

Thank you Cpradio, yes I have enabled the SQL within 3 days, but its still locked.
I believe its for security purpose.
I tried to explore the Github too, but still does not know how to find the code line.

1 个赞

You can find the badge query SQL here: discourse/lib/badge_queries.rb at main · discourse/discourse · GitHub

5 个赞

Thank you very much Simon.
I put wrong keyword in searching the code in the repository.
After I found the sql query, I still confuse.

I want to open another support topic, to make another question relating to this.
Thank you.

1 个赞

This topic was automatically closed after 33 hours. New replies are no longer allowed.