Hi,
I am doing sum of 2 number fields and then adding to original estimate.
Here is steps
1. Created 2 number fields ( numField1 and numField2 )
2. writing below code in behavior on numField1. When ever it get change then take the value and add with numField2 and then set to original estimate
def numField1 = getFieldById(getFieldChanged())
def numField1_Val = numField1.getValue()
def numField2 = getFieldById("customfield_17xxx") // numField2
def numField2_Val = numField2.getValue()
long totalnumFields = numField1 + numField2
def orgEstimate = getFieldById("timetracking_originalestimate")
orgEstimate.setFormValue(totalnumFields)
but this does not work. Through error
org.codehaus.groovy.runtime.typehandling.GroovyCastException: Cannot cast object '66' with class 'java.lang.String' to class 'long'
Look like there is some conversion required to Int but not finding it. Can anyone has any idea.