An automatic group of group owners

Is there a way to have an automatic group which contains all group owners, in much the same way as @staff works?

I’d like to make all my group owners TL2, and to keep track of them as my site (hopefully) grows quickly. Also I want to change their powers as a group as time goes on, as well as communicate with them and have a category for them. I don’t want to make them all mods as they aren’t ready for that.

In the meantime, I can do this manually; however as our tightly managed Forum grows an automatic group would become more and more helpful.

Alternatively, how hard would this be to do as a plugin?

7 Likes

I’ve just implemented a Triggered custom badge queries for identifying current group owners.

The SQL for it is here (can be used in Data Explorer too)

SELECT DISTINCT user_id, owner, CURRENT_TIMESTAMP granted_at
FROM group_users
WHERE group_users.owner = true

It uses CURRENT_TIMESTAMP as there is no nice convenient timestamp for group ownership in the database that I can see. There is no nice trigger either so the :backfill thing can be omitted

I suggest this config:

  1. Run revocation query daily
  2. Trigger: Update daily
  3. I’m not sure about ‘Can be granted multiple times’
    The query only fires once for each user so multiple won’t be granted. But it might be needed to have the badge granted again once revoked - no sure!
4 Likes