Access user names in a specific group?


(Nick Papadatos) #1

**Matrix Version:**v5.3.4.2
Not sure whether this can be done due to privileges but I’m trying to access users who have write permissions to a specific node on the website. Using keyword %globals_user_member_groups% returns an array of IDs but can I get the names of those users who have write permissions?
Example: ULL_Coords has a list of users with write permissions

Rational: Trying to get our users to edit our public site with Edit+

I have an asset listing page in the Portal (private) that points to the main website.
Asset Access to List: write and Include effective permissions ticked. When I log in (SSO) I see a list of pages that I have access to edit only.
I can display the group names but not who’s in them - possible?

Cheers
N


(Bart Banda) #2

Could you pass the %globals_user_member_groups% to an asset listing as a dynamic parameter root node and then list any user assets found under those root nodes?


(Nick Papadatos) #3

Hey Bart no I can’t:
Settings for the asset listing
Parameter > Array of specific asset IDs or selection group (specified assets must be children of the static related node), Set Value > %globals_user_member_groups%
This only returns the group names that I’m associated with no users. I have assets to list > User, User group and Backend User. Display formats > %asset_attribute_first_name% etc

Have I missed something?
cheers


(Bart Banda) #4

So, instead of specifying which assets to list, you’d want to just set the root nodes right? So instead of using 'Array of specific asset IDs or selection group", you’d use the “replacement root nodes for the listing” ?


(Nick Papadatos) #5

Tried that - I get a blank screen. I’m still using these settings: Source Set Value and %globals_user_member_groups% keyword.


(Bart Banda) #6

Hmm, maybe that version of Matrix doesn’t support array keywords as set root nodes for the asset listing.

Does it work if you hardcode the root node asset ids in there in an array string or a comma separated string?

Alternatively, you could use the previous method of just listing the user groups themselves, and then have a nested asset listing into the type format of that listing to then list the users within that group?


(Douglas (@finnatic at @waikato)) #7

In one of our listings we’re using the %asset_admin_permission% / %asset_write_permission% keywords -

<ul>
    <li>Users with admin:: %asset_admin_permission%</li>
    <li>Users with write: %asset_write_permission%</li>
</ul>

and they’re fairly accurate at listing the usernames.

I’m wondering if you could do something with those keywords, and some of ‘eq’ match against the current user to display or not display?


(Nick Papadatos) #8

Does it work if you hard-code the root node asset ids in there in an array string or a comma separated string?
Yes it does, if I point the asset to the group as an admin I can display the user names within the group.

Nesting another AL? I’ll give that a go as well

Thank you for your response


(Nick Papadatos) #9

Hmmm, that worked Douglas but only wen I changed the root node to the website and away from the user groups. Originally what I had was one AL pointing to the website to display standard pages the user had write access and the second pointing to the user groups to list those users who had write access but pointing both Asset Listings to the website works. I’m guessing you did the same?
Cheers
N


(Nick Papadatos) #10

Just one last question Douglas or Bart using %asset_admin_permission% displays authors and coordinators so names get duplicated in my case - is there a way to return them once?

Update: Don’t worry I know why they’re in twice


(Douglas (@finnatic at @waikato)) #11

Our listing lists all the sites assets, with details on each of those sites including the users with access. It would be nice to be able to do the reverse (list all the groups, and then all the site assets which those groups have write / admin access to) but we’ve not spent time on trying to achieve that.