PLM 360 General Discussion

Reply
Contributor
roman.kovarik
Posts: 16
Registered: ‎03-27-2008
Message 1 of 4 (138 Views)

Time Workflow Report

138 Views, 3 Replies
06-01-2012 05:20 AM

Helo can you help me, how or if is possible to make report where I will have how much time it took between first workflow state to final workflow state?

What I need is some time report on item from one state to last state.

Thanks for help.

Product Support
piggeej
Posts: 281
Registered: ‎03-27-2012
Message 2 of 4 (134 Views)

Re: Time Workflow Report

06-01-2012 05:33 AM in reply to: roman.kovarik

Hello Roman,

Welcome to the forums!

In response to your question, yes it is possible to calculate and report the amount of time it took for an item to go between workflow stages. This can be achieved by using java script to calculate the time between dates on the workflow actions. To find the proper syntax to use for the java script, please reference the wiki help  and navigate to the developers guide section, and look under Scripting references.  



Joe Piggee
Support Specialist
Product Support
Autodesk, Inc.

Contributor
roman.kovarik
Posts: 16
Registered: ‎03-27-2008
Message 3 of 4 (108 Views)

Re: Time Workflow Report

06-12-2012 02:48 AM in reply to: piggeej

Hello Joe
Thank you for reply.
I was find your link to java script description in wiki help but I don´t know how to use this function.
I understand that I can use some Java Script and after that when some item state will be on some final state "Close". After that this java Script calculated and wrote me time in some property = fields. But what I don´t know is how to create this java script with fuction "timeStamp" from your links on wiki help.

Can you send me some example?

 

Thanks for reply.

Product Support
piggeej
Posts: 281
Registered: ‎03-27-2012
Message 4 of 4 (99 Views)

Re: Time Workflow Report

06-12-2012 08:17 AM in reply to: roman.kovarik

Roman,

 

To acess the timestamp of the transition timestamp in question you would want to use:

 

var a = item.workflowActions[i].timestamp;

 

From there it’s just a basic math calculation between the two dates and outputting that to where you needed it.



Joe Piggee
Support Specialist
Product Support
Autodesk, Inc.