Commit Graph

13 Commits

Author SHA1 Message Date
Gerhard Schlager 8e8e773e65
FIX: Use `default_enabled` for badges (#212)
because `enabled` in Badge.seed will always overwrite changes by admins
2022-11-24 14:08:39 +01:00
Gerhard Schlager 882dd61e11 FEATURE: Add new badges and rename existing badges 2022-11-23 11:07:49 +01:00
Gerhard Schlager d6c8089ca3 FIX: Use generic, static names for badges
This is necessary, because seeding badges with a translated name will result in duplicate badges whenever the default locale changes. The static name solves this.
Moreover, it's not necessary to set the description during seeding. The serializer will localize the names and descriptions at runtime.

The DB migration tries to rename the existing badges by looking them up by their translated time.
2022-11-23 11:07:49 +01:00
Gerhard Schlager 747fb0c334 FIX: Badges shouldn't be editable 2022-11-23 11:07:49 +01:00
Gerhard Schlager 865433c0a7 PERF: Improve query for "Helpdesk" badge
The old query could be extremely slow and resource intensive.
This also switches `granted_at` from the post's creation date to the date when the post was marked as solution.
2022-11-23 11:07:49 +01:00
Gerhard Schlager bbb3212258 PERF: Improve query for "Tech Support" badge
The old query could be extremely slow and resource intensive.
This also switches `granted_at` from `current_timestamp` to the date of the most recent accepted answer for each user.
2022-11-23 11:07:49 +01:00
Mark VanLandingham 52d4656011
Re-add usage of `add_directory_column` for user directory table solutions count (#140) 2021-06-22 13:18:23 -05:00
Mark VanLandingham 7351882171
Revert "Use `add_directory_column` API to add solutions count to user directory (#137)" (#139)
This reverts commit 58c594fdda.
2021-06-17 12:37:29 -05:00
Mark VanLandingham 58c594fdda
Use `add_directory_column` API to add solutions count to user directory (#137) 2021-06-17 09:31:11 -05:00
Jarek Radosz ce63d80abb
DEV: Avoid nil custom fields (#128) 2021-05-05 12:19:00 +02:00
Martin Brennan 2b12658978
FIX: Add min/max values for auto close hours (#121)
* Also add migration to cap current site settings for
solved_topics_auto_close_hours
  to the max of 175000 if they are too high
2021-02-18 13:49:39 +10:00
Krzysztof Kotlarek 230c2071ea
FEATURE: Add helpdesk and tech support badges (#84)
* FEATURE: Add helpdesk and tech support badges

When plugin is installed, we should create helpdesk and tech support
badges.

Both badges should be disabled by default
2020-02-05 11:14:12 +11:00
Joffrey JAFFEUX c0f8e2eee0
FIX: applies a unique index for accepted_answer_post_id custom field (#83) 2019-12-12 12:00:28 +01:00