It's all about the answers!

Ask a question

How to add a RTC work item tag with javascript ?


Victor PEREIRA (133) | asked Jul 25 '18, 5:25 a.m.
Hi
Could somebody help me with javascript to add tag in the workitem attribute ? A exemple ?

The code follow get a String
var myTags = workItem.getValue(WorkItemAttributes.TAGS);

But when I return myTags I have the error :
java.lang.String incompatible with java.util.Collection.

Thanks !

2 answers



permanent link
Ralph Schoon (61.4k33643) | answered Jul 25 '18, 10:40 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

If you worj in the same context as https://jazz.net/forum/questions/255039/set-a-tag-using-calculated-values-script please coordinate your work. If not see the answers there.


permanent link
Ralph Schoon (61.4k33643) | answered Jul 25 '18, 11:34 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

For all I can tell you can not set a tag using JavaScript attribute customization. The tag is a collection and the casting done in the JavaScript API does not work correctly and you get the error you mention above.

Your answer


Register or to post your answer.