Prevent specific users from modifying area and iteration in a Work Item Type
It is not supported to add READONLY or FROZEN rules on the System.IterationPath and System.AreaPath.
A work around is to create a custom field named "You cannot change this field" for example. Give it the Integer type.
In the "Rules" tap, add one WHENCHANGED rule for each field you want to protect.
In the first one, select System.AreaId in the Field Condition, and navigate to the Rules tab.
Add two rules:
Do the same for the second WHENCHANGED rule for System.IterationId
Basically, the following sequence will trigger when an unauthorized user tries to change a protect field (System.AreaId and System.IterationId linked respectively to System.AreaPath and System.IterationPath) :
Field 'You cannot change this field' cannot be empty.
At least it gets the job done :)
A work around is to create a custom field named "You cannot change this field" for example. Give it the Integer type.
In the "Rules" tap, add one WHENCHANGED rule for each field you want to protect.
In the first one, select System.AreaId in the Field Condition, and navigate to the Rules tab.
Add two rules:
- COPY
- For: the TFS group containing the users not authorized for change
- From: value
- Value: leave empty
- REQUIRED
- For: the TFS group containing the users not authorized for change
Do the same for the second WHENCHANGED rule for System.IterationId
Basically, the following sequence will trigger when an unauthorized user tries to change a protect field (System.AreaId and System.IterationId linked respectively to System.AreaPath and System.IterationPath) :
- The field value is changed to blank
- The field is set to REQUIRED
Field 'You cannot change this field' cannot be empty.
At least it gets the job done :)
Comments
Post a Comment