I've set the "Set Field Value to constant or Groovy expression Function" in the create transition of a subtask workflow. This function is placed after the "Creates the issue originally. " function. It should set the field "Remaining Estimate" which is a Long Field to a certain value. As groovy expression I've set "new Long(10)". But this won't work. After creating the subtask the field is empty.
Did you try moving the post-function to before the Creates the issue originally post-function?
Do you have any error in the logs? To more easily locate the execution of your script, you can try adding a log statement like this at the beginning of your script:
log.error("I am here!");
and look for "I am here!" in atlassian-jira.log
I've placed the function before and after the Create Issue.The result is the same: negative. And: the post function is called during the transition as the log shows:
2015-06-12 09:22:10,719 http-bio-8180-exec-5 ERROR reglera 562x15710x1 1ucisu2 10.100.31.121 /secure/QuickCreateIssue.jspa [jmwe.plugins.functions.SetFieldValueFunction] I am here!
This is how I defined the post function (here without logging):
This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.Read more
Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs