Required Attributes For Condition is not working properly
Hello All,
(function() {
dojo.declare("com.example.Condition", null, {
matches: function(workItem, configuration) {
var workitem = com.ibm.team.workitem.api.common.WorkItemAttributes;
var severity = workItem.getValue(workitem.SEVERITY);
if(severity == "severity.literal.l5")
{
return true;
}
else
{
return false;
}
}
});
})();
Accepted answer
I have tried 'Required Attributes For Condition' recently with 6.0.2 and 6.0.4 and both works fine.
I notice that your script does not have
dojo.require("com.ibm.team.workitem.api.common.WorkItemAttributes");
(under dojo.provide("com.example.Condition");)
I did not test the script without the above line so I don't know the impact of lacking it.
"I can see Asterisk sign on "RootCauseAnalysis" field ": do you see Asterisk sign on both web and Eclipse client?
or it is only in Web client but Eclipse shows no ' Asterisk sign'?
In general, there are two things I would suggest to check with:
1) https://jazz.net/wiki/bin/view/Main/AttributeCustomization#Configuring_a_script_based_custo
check 'Enable Process Attachment Scripts property ' is set to true
2) In Eclipse client, open the project and go to Link tab > Attachment, check if you see any 0 byte .js file.
If yes, delete it and try to test again.
One other answer
In addition to Don's comment, I see over and over again that it is not clear how operational behavior works and it is frequently configured wrong and not called when the user expects it to be.
Carefully read