It's all about the answers!

Ask a question

How to get a RTC attribute original Value in Calculated Values javascript

jay cheng (618) | asked Mar 11 '16, 9:48 a.m.

Hello All,

I want to add a text log field B to log the value of Field A. That is the current value of Field A + original value of Field B.

How can I get the original value of Field B?

Also I want get the current state of the work item, tried a few ways, it did not work.

Your help would be greatly appreciated.

Jay Cheng

2 answers

permanent link
Donald Nong (14.4k314) | answered Apr 25 '16, 9:41 p.m.
Based on previous discussions, you can't do it that way.

If you have to do it using JavaScript, you may consider adding a hidden attribute containing the history of the attribute of interest.

permanent link
sam detweiler (12.5k6189201) | answered Mar 12 '16, 11:11 a.m.
the calculated value script looks like this


(function() {
    dojo.declare("com.example.ValueProvider", null, {

        getValue: function(attribute, workItem, configuration) {

return workItem.getValue(attribute-ID);


so, if you want some other  attributes value you would
note this is NOT the 'name' of the attribute, but its ID..

jay cheng commented Apr 22 '16, 10:46 a.m.

workItem.getValue(attribute-ID get the current value, not the original value

Your answer

Register or to post your answer.