Using workflow to parse text into a date?

Hey all,

I'm trying to write a simple workflow script to extract a date in the body of an issue and set a date field with its contents.

I'm using a combination of description.indexOf() and description.substring() to extract the string, but once I have that text string containing say "21/09/2013", how can I parse that into a Youtrack date type to store in my date field?

I can't seem to spot any form of date operations/functions or anything? Am I missing something?
1 comment
I don't know a simple algorithm date parsing in workflow. It seems you should implement it manually using the mentioned methods on strings.

The 'date' field can be set by the command from workflow: issue.applyCommand("Due date " + year + "-" + days + "-" + month);

Please sign in to leave a comment.