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

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

How to constrain a field according to a user group ?

fantony-2
5-Regular Member

How to constrain a field according to a user group ?

Hello,

I wonder if it possible to constrain a field according to a user group? If my field contains valueA, valueB and valueC, only valueA and valueB will be displayed if I'm part of group1 and only valueC and valueA  will be displayed if I'm part of group1.

Thanks in advance

Regards.

Frédéric.

5 REPLIES 5
kjain-2
15-Moonstone
(To:fantony-2)

Hi Frederic,

I think you can set constraint on pick filed like value is A and B if user is part of this group and value C if user is part of other group. I think this way you can do or you want me to implement and sent you an snapshot. Tell me which is convenient for you.

Waiting for your response Frederic.

Regards

Kapil Jain

DanR.
12-Amethyst
(To:kjain-2)

Frédéric,

Open your Integrity Admin GUI, go to "Workflows and Documents" > "Types".  Select the "Type" your wish to create a constraint, then press Ctrl + E.  Click on "Constraints".  There are fours types that you can create 1) Basic, 2) Field Relationship 3) Rule 4) IBPL.  I suspect you would need a Rule constraint.

Hope that helps.

Dan

kjain-2
15-Moonstone
(To:DanR.)

Hi Daniel,

Yes you are right,  Frederic need Rule constraint in this way (Current User is part of this group) then Only Pick value A and B will visible ow Value C will visible.Hope this helps. If any issue revert me back.

Regards

Kapil Jain

Hi all, (Integrity 10.9)

There is a condition called "Check the group membership of the user performing the action" that would meet your need.

Unfortunately it is not available in Constraints (Basic, Field Relationship, Rule or IBPL)

This condition is only available for "Item Editability" and "Overrides for Fields", which does not meet your need.

A new Ideia would be include this condition on Rule Contraints.

Workaround: Using trigger to limit values "after" the user save. (:()

img001.jpg

kjain-2
15-Moonstone
(To:wcatunda-2)

Hi,

Yes you are right we can only use that way in Editability and in this case can't use. My apologize , i told without checked but on further i checked:-

First Way->

Create a Boolean field first ( we can hide this field from user access as there is no need) and then create a Pre Trigger If Current User is part of Group A then change its value to True and if Current User is part of Group B then change its value to False.

And then create a Rule Constraint On this Boolean field If it is true then Allowable Pick Value is A and B, And if Boolean field value is False then allowable Pick Value is B and C.

(Cons: But trigger doesn't work during form filling like constraints it will only work after saving.)


And 2nd Method is not look so beautiful just a approach like we can create Two Pick Field with Different-2 value can set their visibility According to user Group. But this is not so Good. ( Cons: will have to handle two fields during chart and report creation.)

Announcements


Top Tags