It's all about the answers!

Ask a question

Why are conditions for Required Attributes run even when I open a work item that does not contain the given attribute?


Susan Hanson (1.6k2201194) | asked Oct 23 '13, 7:08 a.m.
RTC 4.0.0.1

I created three Conditions that are Script-based conditions.
Then in Operational Behaviors, I have the Precondition "Required Attributes For Condition" for Save Work Item and have each of those 3 conditions specified for each of 3 Custom Attributes.  These custom attributes ONLY exist within a new work item type called "Dependency".  Each of these java script files does a console.log() message for debugging.

I have everything saved.

Then I open a TASK work item type.  Note that NONE of these 3 custom attributes for the conditions exist in this work item type.

However, in my console log, I get these console.log messages (and I get 3 of them for each javascript file.

I realize that this doesn't "hurt" anything, but I can see this causing some amount of performance overhead if these 3 javascript files is run for EVERY work item that gets opened. 

I think this is a bug .. that RTC should know that the custom attribute defined for the condition does NOT exist in the work item and therefore, NOT invoke the javascript condition.  Is this correct?  If not, can someone explain to me WHY RTC seems to need to run a condition for an attribute that doesn't exist in that work item type??

Susan

2 answers



permanent link
Stephanie Bagot (2.1k1513) | answered Oct 24 '13, 5:45 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
Do you get an error in the UI when you open the Task work item?
If not, it does sound like a defect. I would recommend opening a defect work item on jazz.net specifying this information. We don't typically support customizations such as this through the PMR process, so I believe a work item is the best way to go.

permanent link
Susan Hanson (1.6k2201194) | answered Oct 25 '13, 7:46 a.m.
no error occurs.  It look like it just runs the scripts (which I can only tell because I am debugging them for another work item type, so I have a console.log() statement in them.

I'll open a work item this weekend, it is easily reproduceable :-)
Thanks,
Susan

Your answer


Register or to post 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.