id for "Filed Against" field in workitem
Hello,
I need to write a script that depends on the value of the "Filed Against" field in a workitem. What is the id for the field "Filed Against"? Thanks in advance for your help. |
5 answers
Hello, File Against is also called Category. So you can use the attribute id: IWorkItem.CATEGORY_PROPERTY . Or simple get its values with IWorkItem.getCategory() method. /** * Returns the 'filed against' category. * * @return the 'filed against' category * @see com.ibm.team.workitem.common.IWorkItemCommon#resolveHierarchicalName(ICategoryHandle, org.eclipse.core.runtime.IProgressMonitor) */ ICategoryHandle getCategory(); Comments
Fatos Sopjani
commented Feb 06 '13, 10:06 a.m.
Hi,
How do i get a selected item of Filed Against rather than the whole category, can i just get the value of filed against selected?
Thanks,
fatos
|
Thanks for the quick reply. I'm writing a workitem Attribute Value Providers using Javascript not Java
I need to make my custom attribute depends on the selection of the "Filed Against" attribute. Something like this referencing the id of the Filed Against <attributeDefinition> Is the id "category" ? Thanks |
Thanks for the quick reply. I'm writing a workitem Attribute Value Providers using Javascript not Java Add this to your javascript and then after it runs look at the Eclipse log for the id of the Filed Against value you selected in your work item. var filed = workItem.getValue(WorkItemAttributes.FILED_AGAINST); console.log(filed); |
Hi
I am trying to implement same Javascript but using : var filed = workItem.getValue(WorkItemAttributes.FILED_AGAINST); console.log("result:" + filed); I got DBid of the selected category something like: MESSAGE LOG: result: _gJW_cKrNEeCbw-akxBvZlA I would like to return the string value of this category. Do you know how ? Thx for help |
Hi I have not heard of a way. I ended up just using the id value in my logic, similar to using the id for the owner field. |
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.