<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Retreive user comments in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/retreive-user-comments/m-p/120400#M33074</link>
    <description>&lt;P&gt;Hello everyone,&lt;/P&gt;&lt;P&gt;Is there any way to perform a query or something similar to identify all the files that have user comments, and if possible, display the comments?&lt;/P&gt;&lt;P&gt;Is there a property to be able to obtain them using JavaScript?&lt;/P&gt;</description>
    <pubDate>Thu, 18 Jul 2024 21:16:48 GMT</pubDate>
    <dc:creator>cunhasergio</dc:creator>
    <dc:date>2024-07-18T21:16:48Z</dc:date>
    <item>
      <title>Retreive user comments</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/retreive-user-comments/m-p/120400#M33074</link>
      <description>&lt;P&gt;Hello everyone,&lt;/P&gt;&lt;P&gt;Is there any way to perform a query or something similar to identify all the files that have user comments, and if possible, display the comments?&lt;/P&gt;&lt;P&gt;Is there a property to be able to obtain them using JavaScript?&lt;/P&gt;</description>
      <pubDate>Thu, 18 Jul 2024 21:16:48 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/retreive-user-comments/m-p/120400#M33074</guid>
      <dc:creator>cunhasergio</dc:creator>
      <dc:date>2024-07-18T21:16:48Z</dc:date>
    </item>
    <item>
      <title>Re: Retreive user comments</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/retreive-user-comments/m-p/120401#M33075</link>
      <description>&lt;P&gt;When a user puts a comment on any content in Alfresco repository, an &lt;STRONG&gt;ASPECT&lt;/STRONG&gt; called "&lt;EM&gt;&lt;STRONG&gt;fm: discussable&lt;/STRONG&gt;&lt;/EM&gt;" is applied to the content node. And a child association with name "&lt;EM&gt;&lt;STRONG&gt;fm: discussion&lt;/STRONG&gt;&lt;/EM&gt;&lt;A id="yui-gen251" href="https://alfresco.dev.invesco.aws/share/page/console/admin-console/node-browser#" target="_blank" rel="noopener nofollow noreferrer"&gt;&lt;/A&gt;" and TYPE "&lt;EM&gt;&lt;STRONG&gt;fm: forum&lt;/STRONG&gt;&lt;/EM&gt;" is created that holds the node containing the comments. This&amp;nbsp; "&lt;EM&gt;&lt;STRONG&gt;fm: forum&lt;/STRONG&gt;&lt;/EM&gt;"&amp;nbsp; node holds another child association with name "cm:comments" and TYPE "&lt;EM&gt;&lt;STRONG&gt;fm: topic&lt;/STRONG&gt;&lt;/EM&gt;". Further&amp;nbsp;&lt;EM&gt;&lt;STRONG&gt;fm: topic &lt;/STRONG&gt;&lt;/EM&gt;node has a child association with name "cm:comment" and TYPE "&lt;EM&gt;&lt;STRONG&gt;fm: post&lt;/STRONG&gt;&lt;/EM&gt;". This fm&lt;img id="smileytongue" class="emoticon emoticon-smileytongue" src="https://connect.hyland.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;ost is the real comment.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can build a search query around these pointers to extract the comments for the content node.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or if you are planning to use REST API, this is available out of the box (see docs here &lt;A href="https://docs.alfresco.com/content-services/latest/develop/rest-api-guide/folders-files/#managecomments" target="_blank" rel="noopener nofollow noreferrer"&gt;https://docs.alfresco.com/content-services/latest/develop/rest-api-guide/folders-files/#managecomments&lt;/A&gt;) :&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;CODE&gt;&lt;A href="http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/nodes/" target="_blank" rel="noopener nofollow noreferrer"&gt;http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/nodes/&lt;/A&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;{id}&lt;/FONT&gt;&lt;/STRONG&gt;/comments?alf_ticket=&lt;FONT color="#0000FF"&gt;&lt;STRONG&gt;&amp;lt;ticket&amp;gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/CODE&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;/P&gt;
&lt;P&gt;&lt;CODE&gt;&lt;SPAN&gt;e.g.:&amp;nbsp;&lt;A href="http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/nodes/" target="_blank" rel="noopener nofollow noreferrer"&gt;http://localhost:8080/alfresco/api/-default-/public/alfresco/versions/1/nodes/&lt;/A&gt;&lt;FONT color="#0000FF"&gt;&lt;STRONG&gt;d2084217-8f87-42dd-a1c6-85b0b0bf86e9&lt;/STRONG&gt;&lt;/FONT&gt;/comments?alf_ticket=&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;TICKET_d3484135e30ef51b70dbe1079620f460a48984d0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;/P&gt;
&lt;P&gt;This gives you a response like:&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;{
                "entry": {
                    "createdAt": "2024-07-31T16:15:44.155+0000",
                    "createdBy": {
                        "enabled": true,
                        "firstName": "John",
                        "lastName": "Doe",
                        "displayName": "John Doe",
                        "email": "jdoe@xyz.com",
                        "emailNotificationsEnabled": true,
                        "company": {
                            "organization": "XYZ"
                        },
                        "id": "jdoe"
                    },
                    "edited": false,
                    "modifiedAt": "2024-07-31T16:15:44.155+0000",
                    "canEdit": false,
                    "modifiedBy": {
                        "enabled": true,
                        "firstName": "John",
                        "lastName": "Doe",
                        "displayName": "John Doe",
                        "email": "jdoe@xyz.com",
                        "emailNotificationsEnabled": true,
                        "company": {
                            "organization": "XYZ"
                        },
                        "id": "jdoe"
                    },
                    "canDelete": false,
                    "id": "3c2b474d-041c-42d1-93df-7cc6c3afd798",
&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;                    "content": "&amp;lt;p&amp;gt;This is a test comment&amp;lt;/p&amp;gt;"
&lt;/STRONG&gt;&lt;/FONT&gt;                }
            }&lt;/PRE&gt;
&lt;P&gt;You can take out all the comments from the response pertaining to the nodeId passed in the request.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Jul 2024 16:50:52 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/retreive-user-comments/m-p/120401#M33075</guid>
      <dc:creator>abhinavmishra14</dc:creator>
      <dc:date>2024-07-31T16:50:52Z</dc:date>
    </item>
  </channel>
</rss>

