Badge doesn’t show the description at all.
Version: 1.5.0.beta15
DISCOURSE_DEFAULT_LOCALE
: zh_CN
https://meta.discoursecn.org/badges/15/第一次引用
(First Quote)
It’s an old installation. The problem is that badge name is not overridden by seed_fu. Without the proper name, it can’t get the i18n key. Therefore, description is not shown.
New badges are doing fine.
#<Badge:0x0055e8cab02a80
id: 17,
name: "读者",
description: "",
badge_type_id: 3,
grant_count: 0,
created_at: Mon, 29 Sep 2014 16:55:53 UTC +00:00,
updated_at: Sat, 01 Nov 2014 01:42:51 UTC +00:00,
allow_title: false,
multiple_grant: false,
icon: "fa-certificate",
listable: true,
target_posts: false,
query:
" SELECT id user_id, current_timestamp granted_at\n FROM users\n WHERE id IN\n (\n SELECT pt.user_id\n FROM post_timings pt\n JOIN badge_posts b ON b.post_number = pt.post_number AND\n b.topic_id = pt.topic_id\n JOIN topics t ON t.id = pt.topic_id\n LEFT JOIN user_badges ub ON ub.badge_id = 17 AND ub.user_id = pt.user_id\n WHERE ub.id IS NULL AND t.posts_count > 100\n GROUP BY pt.user_id, pt.topic_id, t.posts_count\n HAVING count(*) >= t.posts_count\n )\n",
enabled: true,
auto_revoke: false,
badge_grouping_id: 1,
trigger: nil,
show_posts: false,
system: true,
image: "",
long_description: nil>
(Reader)
I tried:
-
rake db:seed_fu
success but doesn’t change the badge. - Invoked rake task in the console, not effective.
- I copied the hash and update_attributes to one old badge. The model is valid but it doesn’t change the record.