RM.Data.deleteLink : some links are not deleted
We have RM 7.0.2 - iFix026.
We have 2 modules, in distinct components, with requirements, in the same global configuration :
We create somme satisfaction Links between requirements from A --> B ("Satisfies" links, for example) :
The result is : B1 is "Satisfied by" 3 requirements (A1, A2 and A3).
We create a widget to delete links between artifacts, and we use the "RM.Data.deleteLink" API method.
We open Module B and run the widget.
The "RM.Data.deleteLink" has a "strange" behavior :
We run again the widget, but the link A1/B1 can not be deleted ...
Why this behavior ?
Regards.
|
One answer
I have found, as well as the permissions issue mentioned above, that you need to delete the link in the correct context. If you have a mix of links created in module context and artefact context, then you'll need to do two delete calls - one for each context.
It could be that A1-> B1 is done directly to the B1 artefact, while the other two are done to the B1 artefact in the module's context
Comments
For the moment, I'm doing my development in a "JazzAdmin" context, so permissions are not the biggest constraints. I first want to make sure that the logic of how the widget works is correct.
Indeed, I am looking to correct certain links created directly on the artifact, outside the context of the module. And specifically, the links I'm looking to remove are those created directly on the artifact.
But the widget I'm developing only seeks to remove links created outside of a module context :
1/ The widget detects “malformed” links 2/ Then must first delete them one after the other 3/ Currently, the first link is deleted, but not the others, which generate an error My major problem therefore remains to understand why such behavior?
Regards
Jean-François CHAPELLE
commented Feb 11, 4:13 a.m.
In addition, I realize that an "Base Artifact" does not have the same URI as an "Module Artifact" and that changes a lot of things...
So I have to modify the logic of my Widget
Davyd Norris
commented Feb 14, 1:09 a.m.
Yes, that's what I meant in my answer above - you need to look at the context of the link and perform the delete in the correct context.
The API documentation shows how you can detect the context:
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.
Comments