I am working with JMWE and trying to write a groovy script where I want to check whether the summary of a ticket contains a specific string and then assign a ticket to a specified user if it does.
For example:
if (issue.get("summary").toLowerCase().contains("Check Refund")) { 'user1'}
if (issue.get("summary").toLowerCase().contains("Vendor Credit Memo")) { 'user1'}
if (issue.get("summary").toLowerCase().contains("Credit and Rebill")) { 'user1'}
else { 'user2'}Is there a way to make this work? I am putting this post function on the 'create' workflow transition. I am also wondering if there is a functional wildcard to place within the quotes to parse any instance of the string, such as ("*Check Refund*").