Is it possible to filter in Views for users that are registered on a certain domain ? (like filtering for organic group members)

thanks for this cool module!

CommentFileSizeAuthor
#3 369928-views-filter.patch4.49 KBagentrickard

Comments

agentrickard’s picture

It is theoretically possible, but I do not believe that Domain Views supports this yet. You would write a views handler for the {domain_editor} table.

agentrickard’s picture

Category: support » feature
agentrickard’s picture

Status: Active » Needs review
StatusFileSize
new4.49 KB

Here's a patch that provides arguments and filters for user domain assignments.

agentrickard’s picture

This patch is tangled up with #397116: Views relationships and DA.

ayalon’s picture

Hi agentrickard

Thanks for this patch. I tested it and it worked.

Maybe one could make the whole thing a bit more obvious :-)

I debugged more than an hour to find out, that the user domains are saved in a table domain_editor. Then I found out, that I should use the Domain Editor Filter to filter out users form a certain domain.

For a new user this is not very obvious because registered user normally aren't super users / editors.

But there are good news: It works also with "relationships". I have a list of "My friends" but I wanted to show only friends form the current page. So I used the User Relationship "requestee" and voilà: It worked!

Taxonomy?
Now I need the same thing for taxonomy. Means I need to filter taxonomy terms by domain. Is this feature planned too?

agentrickard’s picture

Version: 6.x-2.0-rc5 » 6.x-2.0-rc8

Thanks for the review!

The problem is that Domain User is taken (by another module). And the assignment of users to domains is normally done for editing purposes. What other label would you suggest?

Taxonomy is handled entirely by the Domain Taxonomy module, which is its own release. I have no plans to integrate that.

ayalon’s picture

Domain User would be the best. But because its taken we could rename it to Domain Users or Domain User Filter. Or Domain User Realm..

nonsie’s picture

I personally thing we should stick to the labels in the patch so that we do not confuse Domain Access editor grants with Domain User or Domain User Default.
The patch applies and works as expected but I am unsure about #397116: Views relationships and DA part in it.

Could you possibly split it into two patches?

agentrickard’s picture

I don't think I can split it.

agentrickard’s picture

Status: Needs review » Fixed

I went ahead and committed both to HEAD.

ayalon’s picture

Good idea! Works well on my system!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.