Limiting @mentions to groups

We have a number of independent groups in our Discourse who shouldn’t have visibility of members in other groups.

I’ve created categories for each group to which only they have access/visibility, which works fine. However, when users post or reply to a topic they can still use @mentions to include any other user in the community.

Is it possible to block this so a user can only @mention other users in their group(s)?

Or turn off @mentions full stop?

Did you have custom group mentions enabled only for “group members, admins and mods”?

All the automatic groups should be set to " nobody" or at least only “admins and mods”

2 Likes

This is what groups are set as. Still seem to be able to @ people from other groups tho.

Are you on the latest version of Discourse?

If your users are not enabled to mentions other custom groups they shouldn’t see the name of that groups in auto-complete popup if they try to write their name.

2 Likes

Yeah, I’m all up to date. Weird one…Might the settings take a while to filter through?

As far as I know, changes of this kind are usually immediate, at most a few seconds. :thinking:

It couldn’t be something to do with the WP site we are using discourse in combination with, could it?

I do not use WP, nor SSO. Surely @simon can better answer about this point.

EDIT: since the problem seems to be only on your site (until proven otherwise), share the list of plugins you’ve installed. One of them could cause the problem.
Have you tried to check if group mentions work badly even with safe mode (your-site/safe-mode)?

1 Like

I feel like our issue has less to with groups and more to do with individual users and so these setting aren’t what we need here.

So essentially, we have multiple groups

As an example:
GROUP 1: USER A, USER B
GROUP 2: USER C, USER D

Now when USER A brings up the text window and writes @ they are going to see USER C and D. This is an issue because USER A isn’t able to communicate with C or D, or know if of their existence. They can’t see any of the discussions GROUP 2, so they shouldn’t be able to see that group’s users when they bring in mentions.

Does this make sense?

Appreciate your help.

Well, they are different things, those are mentions per user, not group.
User A is able to “see” user D even if he does not know that user D belongs to another group, whether he has written post or open topic (and viceversa), until user A goes to the profile of user D.

What you want is a feature request.

In your case, would you like to disable the mentions per user and set it so that only members of the same group can “see” each other? Or at least completly disable all mentions?

Theoretically speaking:

  • the first thing is to modify the site setting enable user directory so your user can’t see the page /users and the personal profile page of other users. I do not know if the setting is retroactive for those users who already subscribe to the forum (but it is a solvable problem) and enable hide user profiles from public

  • then, ideally, you need to modify the site setting max mentions per post and set it to 0. Actually it doesn’t work, but you can ask the discourse team to improve this site setting, and when it is set to 0 the auto-complete don’t appears. If the team is interested and, secondarily, receiving requests from many other users they could also implement it.

  • the last solution I can think of is that you write a plugin or pay some developer to write it to your place by making a request on the marketplace or buy a hosted enterprise plan from discourse (in this case they can do some implementation for your site, I think, but not 100% sure).

1 Like

Ideally this is what we would like. I’ll look into your suggestions, and thanks for your help. From my perspective it makes a lot of sense as a feature as if there are ‘closed’ groups, then there should be an option for them to be un-discoverable.

Cheers!