我正在使用下面的代码并发现针对类别对象提交但在那里我无法找到该值。请帮忙。
IProjectAreaHandle projectAreaHandle = workItem.getProjectArea();
IAttribute someAttribute = workItemClient.findAttribute(projectAreaHandle, IWorkItem.CATEGORY_PROPERTY,
monitor);
IAttributeHandle iAttributeHandle = (IAttributeHandle) someAttribute;
IAttribute iAttribute = (IAttribute) repo
.itemManager().fetchCompleteItem(
iAttributeHandle, IItemManager.DEFAULT ,monitor);
Object value = workItem.getValue(iAttribute);
答案 0 :(得分:1)
下面的代码将有助于找出针对属性值的字段:
ICategoryHandle iCategoryHandle = workItem.getCategory();
ICategory iCategory1 = (ICategory) repo
.itemManager().fetchCompleteItem(
iCategoryHandle, IItemManager.DEFAULT ,monitor);
return iCategory1.getName();