Product code and work item displayed as a single field
I am looking to create a field that can be included in a query that simply combines the work item and a product code as something like ABC-4789. Is it possible to write your own custom attribute? Alternatively it looks like I could add a string field attribute and write an Operation Participant triggered on work item save to update a field with this information. And a third idea would be to write a javascript field validator, but that I think that may not run in all cases where a work item is created.
Any thoughts appreciated!
Any thoughts appreciated!
Accepted answer
Hello Vince,
what is the work item attribute to you want to pick ? work item number, summary, another attribute?
I understand that you want to create a custom attribute which value will be calculated,
and equal to <some_attribute> + <product_code>
If this is correct, I would use a JS provider and calculated values:
Hope it helps,
Eric.
Comments
One other answer
JavaScript would not work as far as I can tell. See the limitations described in https://jazz.net/library/article/1093 Lab 5. It might be possible to use a calculated value using Java see http://rsjazz.wordpress.com/2013/06/26/attribute-customization-java-based-value-providers-conditions-and-validators/ but it would have to grab the data from a string field and a work item type attribute.