1
0
-1

Status changed to "Closed" in Jira → status sent to all Zendesk tickets linked to the closed Jira → Public reply added the corresponding ZD tickets "Hi your bug has been fixed" → Close all  corresponding ZD tickets.

Would this be possible?

thanks!

    CommentAdd your comment...

    1 answer

    1.  
      1
      0
      -1

      Hello Timmy Summers

      First in the Incoming Sync make sure you are mapping the correct status: 


      def statusMap = [
             // "remote status name": "local status name"          
               "Done" : "Closed",
      def remoteStatusName = replica.status.name
      issue.setStatus(statusMap[remoteStatusName] ?: "To Do") >> This will set a default status if the ones above are not found


      Them set a comment to be created based on the replica.status.name coming from the remote node that matches the close status in your receiving instance. 


      if (replica.status.name == "Done")  {
         issue.comments = commentHelper.addComment("Hi your bug has been fixed", issue.comments)
      } else {
        issue.comments     = commentHelper.mergeComments(issue, replica)
      }


      Please let me know if this works for you, thanks! 




        CommentAdd your comment...