Repurposing badges for self-selected user tags

(Patrick Connolly) #1

On our forum, we’re trying to create a visible way for users to identify their skills and experience, without using plugins if possible. I was wondering whether someone could tell me whether this possible, before I get full admin access or set up my own instance to check:

I was hoping to replace the badges in this screencap with self-selected skills badges:

Was thinking we could disable standard badges, and use custom SQL queries like so:

We create a custom forum for “Skills badges” and allow anyone to create new posts titled as the skill. Anyone who “likes” the post gets a badge with the post title.

So I suppose the main question is whether the badge name can be dynamic. I suspect this is where the plan would be kiboshed. Would also be nice if badges could be removed by “unliking” the same post, but this might also be impossible without more work than I’m interested in investing :smile:

Anyhow, I appreciate any quick advice. Otherwise, I’ll just have to dig in myself

(Allen - Watchman Monitoring) #2

Yes, users can pick one badge, but not many.

It’s discussed more here

(Patrick Connolly) #3

Thanks, I appreciate that. Should work for now :smile:

I’ll update this thread if we end up scratching our own itch with anything else

(mountain) #4

How about if instead of liking a post, they can reply to a thread that relates to the skill badge they want.

I don’t know if by deleting their initial post that got them the badge then the badge would be removed? That would be perfect methinks for your needs. And come to think of it, that would be useful for me as well. Also for game-related communities where they join specific factions but the factions don’t yet have their own restricted category.

(Patrick Connolly) #5

Glad to hear it would be helpful for you too :slight_smile:

But since badges come from arbitrary SQL queries, it could be just as easily triggered by “likes” as “replies”. Likes would strike me as less noisey – only the OP would get notifications, rather than everyone.

(mountain) #6

But I’m guessing one cannot ‘un-like’ something?

Then again, if they change their mind, perhaps it is a good idea for them to contact you. Of course, depending on how important it is for them to show their skillsets (and to report if they change them).

That way they contact you and you can remove the badge manually. (Granted if that is an option in the admin CP.)

(Mittineague) #7

Do you not see “Undo Like”/

Or do you mean once initiated the undo is is ineffective?

(mountain) #8

The latter!

Don’t know if a badge can be removed (or anything triggered, really) with an ‘unlike’ action.

Also, isn’t there a time limit on when you can no longer unlike something?

(Kane York) #9

Yeah, undoing likes has a time limit.

What could work is this:

SELECT p.user_id, current_timestamp granted_at, post_id
FROM posts p /* no access control needed because restricted to one topic */
WHERE p.topic_id = 1320 /* Selection Thread */
AND p.post_number > 1
AND p.deleted_at IS NULL
AND NOT p.user_deleted
AND p.raw LIKE '%Pagophagia%'

As long as the edit window is reasonably long, I think that should be fine. And the admins can delete the old post if the window passes.