Limiting RRC Artifact type to be linked only with certain artifact type
My customer has a unique requirement that he want's to cater in RRC. He has asked for creation of two new types of artifacts and only allow certain type of linkage (i.e. Parent/Child link) between these two types. He does not want to allow the linkage of these type of artifacts to any other artifacts,
My question is can this be accomplished in RTC? if yes then how?
Regards,
Ahmed
My question is can this be accomplished in RTC? if yes then how?
Regards,
Ahmed
3 answers
Hi Ahmed,
I'm not aware of a built-in way to restrict link types.
You could probably write a custom advisor you could apply to the Work Item Save operation that would check if the work item is of type A, links were only of type B. The problem I see with this approach is that users would still be able to create the links in the work item--they just wouldn't be able to successfully save them, which could be confusing. https://jazz.net/wiki/bin/view/Main/PreconditionFollowupCreation has information on writing advisors.
I'm not aware of a built-in way to restrict link types.
You could probably write a custom advisor you could apply to the Work Item Save operation that would check if the work item is of type A, links were only of type B. The problem I see with this approach is that users would still be able to create the links in the work item--they just wouldn't be able to successfully save them, which could be confusing. https://jazz.net/wiki/bin/view/Main/PreconditionFollowupCreation has information on writing advisors.
Ahmed,
In RRC, I don't think there's a way to completely restrict creating certain types of links to specific artifacts of a certain type. However, there is a feature in RRC called "Preferred Link Types" that can be managed through the Artifact Types editor of the Manage Project Properties UI. From the Artifact Types editor, you should be able to select certain "To" and "From" Link Types that artifacts of this Artifact Type can use. However, remember that these are only *preferences* - whenever a user goes to create a link by normal means, the menu will display, by default, the preferences you chose, but it will also present a "More..." option, which the user can chose and still create a link of a non-preferred type.
Does this make sense? Hope it helps!
Mike Jaworski
Comments
Ahmed in your post you refer to RRC and then to work items. RRC artifacts are managed by the RM application, and work items are managed by the CCM application (which is the main part of RTC). Lauren's answer is about work items.
The optimal way to address your question differs for the RM and CCM applications. I will answer for RM:
The optimal way to address your question differs for the RM and CCM applications. I will answer for RM:
-
An administrator can configure link preferences, which show up in the UI as the most convenient link types to create. These are preferences, not firm controls. The user can still select "other" on the context menu and create other link types. But most users will follow the gentle guidance of the UI options available to them. This may be sufficient for your customer.
- You could write an extension in JavaScript to check for the existence of "invalid" link types when the user is saving an artifact.
-
You could write an extension in JavaScript to "audit" a system to find any inappropriate link types. Or you could do this manually with one or more saved views.