Unable to copy RTC workitem description using javascript
Accepted answer
I created a calculated Value with the below script based on yours and set it to a custom attribute: medium string or HTML and this works for me:
dojo.provide("com.example.common.MyClass");
dojo.require("com.ibm.team.workitem.api.common.WorkItemAttributes");
(function() {
var WorkItemAttributes= com.ibm.team.workitem.api.common.WorkItemAttributes;
dojo.declare("com.example.common.MyClass", null, {
getValue: function(attributeId, workItem, configuration) {
var value = workItem.getValue(WorkItemAttributes.DESCRIPTION);
return value;
}
});
})();
Comments
Hi Don Yang,
Hareesh,
Glad to know it works for you.
In your codes, you use var value = workItem.getValue(WorkItemAttributes.DESCRIPTION); in which WorkItemAttributes is used but it is not defined.
Thanks