Questions for Confluence license has expired.

Please purchase a new license to continue using Questions for Confluence.

How to use nodeHelper.getHtmlField on custom fields ?

 
1
0
-1

Hi,


Currently, I have a custom fields called "Steps" which is the same type as "description".

In the documentation, the following method is available : 

replica.description = nodeHelper.getHtmlField(issue, "description")


Is there any solution to pass a custom field to the method ? 

I would like to convert my custom field "Steps" into html.


Thanks 

    CommentAdd your comment...

    1 answer

    1.  
      2
      1
      0

      Hi Kevin,


      Yes, this is supported. First, you’ll need to find the internal name of the custom field, to do this you can check an issue where you have the field present and populated and check this rest API endpoint:


      https://{jira_cloud_url}/rest/api/2/issue/{issueKey}


      and check the field’s internal name, it should be something like:


      customfield_10470


      After doing this, you can add this snippet to your Jira Outgoing Sync:


      replica.customKeys."HTML Field" = nodeHelper.getHtmlField(issue, "customfield_10470")


      and in your Azure Incoming Sync then you can map that customKey to any field you want, for example the description:

      workItem.description = replica.customKeys."HTML Field"


      Let me know how this goes.

      Thanks,


      Ariel

        CommentAdd your comment...