How to set 'planned for' attribute to 'Unassigned' in RTC ALM
One answer
In the OSLC API, getting the work item, removing the entire entry for the planned for attribute value and PUTing the new payload - including the If-Match etag should do the trick.
In some cases such as the category there are "unassigned" values you can set.
I do not know if there is for planned for. You can try to follow the resource shape and try to find if there is a unassigned value for the planned for attribute. In any case not setting the value as explained above should create the same result.
Comments
I did a simple test. I created a work item with planned for unassigned and GET the item in OSLC.
I change the planned for to the backlog and save. Then I GET the item again.
The difference between the first state and the second is that this got added:
<pre>
"process:iteration": {
"rdf:resource": "https://elm.example.com:9443/ccm/process/iterations/_8iPSV1pmEeukW7cqqDjAuA"
},
"rtc_cm:plannedFor": {
"rdf:resource": "https://elm.example.com:9443/ccm/oslc/iterations/_8iPSV1pmEeukW7cqqDjAuA",
"rdf:type": [
{
"rdf:resource": "http://jazz.net/xmlns/prod/jazz/rtc/cm/1.0/Iteration"
}
]
}
This means that removing these entries from the payload and PUTing the new payload sets the work items planned for to "unassigned".
Sorry, I forgot to mention, I am interested in the xml+rdf structure, because we work with that in our environment. I tried to PUT the part representation without the Planned For Tag but it did not work, the planned for is still set to the initial release I set before.
For some reason PUT does partial updates on our system, without removing the attributes, we don't send.
Also, I already studied the resource shape of workitems, there is no 'unassigned' or anything similar to be found there.
It could be a bug, I found it listed as a defect from 5 years ago. They describe exactly the problem I am having and how to reproduce it with XML:
It is also listed as 'Fixed' but it does not work in ALM, maybe our system has not been updated yet??
The work item claims that this was fixed June 2016. It points to https://jazz.net/wiki/bin/view/Main/WorkItemAPIsForOSLCCM20 I looked into the example and modified my URI to
With both the iterations removed like above. This worked.
328579: OSLC-CM 2.0: Cannot set "Planned For" or "Found In" to unassigned via PUT says it was fixed in 6.0.3.