It's all about the answers!

Ask a question

Trying to validate Time spent attribute on task at a particular state

Ahmed Omair (41032) | asked Jul 25 '16, 7:41 a.m.
edited Jul 26 '16, 3:30 a.m. by Ralph Schoon (62.9k33645)
 I am trying to get value of time spent attribute and estimate attribute in dojo validation script using following code.

var timespent = workItem.getValue("");
var estimate = workItem.getValue("");

The above variable are giving me null result. How can i get values of these attributes?

3 answers

permanent link
Lily Wang (4.9k714) | answered Jul 25 '16, 9:31 p.m.
According to the document, "Duration" is not supported by javascript.

permanent link
Ralph Schoon (62.9k33645) | answered Jul 26 '16, 12:53 a.m.
 Please look up the attribute Ids in the web UI. The attribute Ids you show don't work for attribute customization. I think the return type is a long. 

permanent link
Ahmed Omair (41032) | answered Jul 27 '16, 4:08 a.m.
edited Jul 27 '16, 4:09 a.m.
This worked

var timespent = workItem.getValue("timeSpent");
var estimate = workItem.getValue("duration");

Your answer

Register or to post your answer.