Problem with dependent enumeration in web browser
![]()
Hello guys,
I have the following problem: I created two enumeration attributes in a workitem: Area and Subarea. In "Subarea" attribute I created a set value based on dependent enumeration. In RTC client, when I change the value in "Area" combobox, an error notification is showed in "Subarea" combobox when the value selected is not applicable. This behaviour does not occur in web browser. I'd like to know if this behaviour is possible in web browser and how I do it. Also, I'd like to know if is possible a refresh in combobox "Subareas" when I change the "Area" combobox, so that combobox "Subareas" shows only the applicable values. (now, if i select a value in Subareas combobox and then change de Area combobox, the value I selected in Subarea remains the same) Version of RTC is 4.0.3 |
2 answers
![]()
Hi, I hope the following tips can help you
1. Add a default element to the dependent enumeration, for example <Select a value>.
2. Get the id from "process configuration source" for this new value, in this case "com.xxx.process.enum.literal.l25".
3. Add a calculated value on workitem/Attribute Customization.
add de next lines to the script
//////////////////////////////
dojo.provide("com.workitem.custom.getValue.xxxxx");
dojo.require("com.ibm.team.workitem.api.common.WorkItemAttributes");
(function() {
var WorkItemAttributes = com.ibm.team.workitem.api.common.WorkItemAttributes;
dojo.declare("com.workitem.custom.getValue.xxxxx", null, {
getValue: function(attribute, workItem, configuration) {
return "com.xxx.process.enum.literal.l25"
}
});
})();
////////////
4. in the type and attribute section of the workitem type, edit the dependent enumeration, on the field calculated value by selecting the recently created script
|
Comments
yes, this should work (sub refresh to selected list)..