cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X

System User Groups are not Editable

mapatil
10-Marble

System User Groups are not Editable

Hi,

I added a user to a System User group e.g Designer.

When I try to edit the system user group to remove the user, I am not able to save the setting for this user group.

I get this message that entity cannot be edited.

Is this a bug ..?

My ThingWorx version is  7.0.1-b842.

Thanks.

8 REPLIES 8
ibanham
12-Amethyst
(To:mapatil)

Are you clicking on Edit or Edit Members? Edit should be blocked for System objects.

mapatil
10-Marble
(To:ibanham)

When I do  Edit member for  System user group and remove the user, the user seems to be removed from the Edit member UI.

But when I try to get the  user groups  for the  user  using sessionInfo object's  GetCurrentUserGroups()

SessionInfo sessionInfo = (SessionInfo) EntityUtilities.findEntity("CurrentSessionInfo",

        ThingworxRelationshipTypes.Resource);

I still continue to get the Designer user group as the one of the user groups fo rthe logged in user. Even if the user was removed from the Designer's user group.

for non system user group, this does not seem to be an issue.GetCurrentUserGroups() gives the correct group.

Aanjan
12-Amethyst
(To:mapatil)

Manisha, that looks to be a bug. I'll check internally and let you know.

mapatil
10-Marble
(To:Aanjan)

Hi Ravi,

Were you able to confirm this..

-Manisha

Aanjan
12-Amethyst
(To:mapatil)

Manisha, does a system (Tomcat) restart clear the groups or does it still persist?

mapatil
10-Marble
(To:Aanjan)

Hi Ravi,

System(Tomcat) restart does not clear the groups..

-Manisha

Aanjan
12-Amethyst
(To:mapatil)

I rechecked, and was not able to reproduce your issue. Please try this –

1. Add your user (TestUser) to the Designers Group
2. Add a service called getGroups to a new Thing
3. Use this in the script section, with output set to Infotable –

// result: INFOTABLE dataShape: EntityList
var result = Users["TestUser"].GetGroups();

4. Run the service – the output should give you an Infotable with 2 rows – Users and Designers
5. Go to the Designers Group and remove the user
6. Re-run the service – you should only see 1 row with Users on it

mapatil
10-Marble
(To:Aanjan)

 

Hi,

 

 

In  my extension code, the groups for the logged in user are fetched in this way..

 

 

SessionInfo sessionInfo = (SessionInfo) EntityUtilities.findEntity("CurrentSessionInfo",

 

ThingworxRelationshipTypes.Resource);

 

 

InfoTable roles = sessionInfo.GetCurrentUserGroups() ;

 

 

So even if the UI and java script service shows that the user is removed from the groups, but the session object does not seems to be getting updated with correct user groups.

 

 

Thanks

 

Manisha

 

Announcements


Top Tags