# \[Salesforce\]\[Jira\]Handling of comments

**URL:** <https://community.exalate.com/t/salesforce-jira-handling-of-comments/5552>\
**Category:** General Questions\
**Tags:** cloud-salesforce, exalate, cloud-jira, migrated\_question\
**Created:** [November 4, 2024, 8:12am UTC](https://community.exalate.com/t/salesforce-jira-handling-of-comments/5552 "2024-11-04T08:12:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![xl8bot](https://dub1.discourse-cdn.com/flex018/user_avatar/community.exalate.com/xl8bot/32/324_2.png) [@xl8bot](https://community.exalate.com/u/xl8bot)\
**Post date:** [November 4, 2024, 8:12am UTC](https://community.exalate.com/t/salesforce-jira-handling-of-comments/5552/1 "2024-11-04T08:12:29Z")

</div>

_Originally asked by Patrick Kolodziejczyk on 08 August 2023 [(original question)](https://oldcommunity.exalate.com/questions/88245498)_

* * *

Hi,

I am currently trying to synchronise :

- Content of comments from Jira to Salesforce
- Content of comments from Salesforce to Jira

My current implementation is half working :

For example, the Jira input :

**test** _italique_ underligne

Become in Salesforce:

Kolodziejczyk commented: \<p\>\<b\>test\</b\> \<em\>italique\</em\> \<ins\>\<em\>underligne\</em\>\</ins\>\</p\>

With the outgoing script on jira:

```auto
replica.comments = nodeHelper.getHtmlComments(issue)

```

And the incoming script on Salesforce

```auto
entity.comments = commentHelper.mergeComments(entity, replica) 

```

I have try to make manual modification in the incoming script of Salesforce, but it’s always consider my HTML as pur String (not interpreted).

A image content from Jira display in salesforce the result is about the same :

Kolodziejczyk commented: \<p\>\<span class=“image-wrap” style=“”\>\<img src=“/rest/api/3/attachment/content/18039”\>\</span\>\</p\>

And a image content from Salesforce is display an image but the markdown is :  
!sfdc://069Aa000000d5npIAA!

And not the name of the image.

Using Outgoing script Salesforce :

```auto
replica.comments = entity.comments

```

And incoming script Jira :

```auto
issue.comments = nodeHelper.toMarkDownComments(commentHelper.mergeComments(entity, replica))

```

My question are the following :

- How to have Salesforce understand that the body is in HTML and should be interpreted ? (That the only things that i can’t resole by custom code at the moment)  
- The image source conversion from Salesforce URL to Jira name is in the standard or should I implement it ?

* * *

#### Comments:

> **Patrick Kolodziejczyk commented on 08 August 2023**
>
> > For the Jira to Salesforce part,
> 
> It’s look like, the property isRichText on the object “FeedItem” that is created is left to false. And that field isn’t editable in the Exalate script.
> 
> In addition, it’s look like the conversion to HTML isn’t properly done.
> 
> italic is done with _and not_
> 
> underline is done with and not
> 
> Using Salesforce Inspector : _and are rejected when isRichText is witch to true._
> 
> The replacement of \*and can be done by a customisation of mergeComments, but shouldn’t be done in my point of view.
> 
> FeedItem.isRichText isn’t set to true nor accessible is a problem that can’t be fix. FeedItem properties can’t be modify in the Admin part and the Chatter configuration doesn’t inclued the capacity do modify default value of the underlying object.\*
> 
> Look like, not all FeedItem are provided on the outgoing on the salesforce side. Only the FeedItem of type “TextPost” are provided.  
> FeedItem of type “ContentPost” are missing.
> 
> Meaning comment that got an attached file aren’t provided for synchronisation.

---

<div class="post-metadata">

**Author:** ![Majid](https://dub1.discourse-cdn.com/flex018/user_avatar/community.exalate.com/majid/32/343_2.png) [@Majid](https://community.exalate.com/u/Majid)\
**Post date:** [December 4, 2024, 9:35am UTC](https://community.exalate.com/t/salesforce-jira-handling-of-comments/5552/2 "2024-12-04T09:35:21Z")

</div>


