OnRenderRowDetails

Smartsite 7.9 - ...

OnRenderRowDetails is called after the row details for the library have been constructed (as xml) and before this xml is being used to actual render the html result.

This example adds a html span element to the title of each row details, containing a contenttype icon class.

The rowdetails document passed in as argument looks like this for example:

XML CopyCode image Copy Code
<results>
  <result>
    <nr>101422</nr>
    <parent>101501</parent>
    <moddate>2018-03-14T14:19:47.453</moddate>
    <fullname>Site Administrator</fullname>
    <title>Reference test</title>
    <folder>false</folder>
    <contenttype>1</contenttype>
  </result>
  <!-- other results omitted -->
</results>

After executing the OnRenderRowDetails() function, the rowdetails document looks like this:

XML CopyCode image Copy Code
<results>
  <result>
    <nr>101422</nr>
    <parent>101501</parent>
    <moddate>2018-03-14T14:19:47.453</moddate>
    <fullname>Site Administrator</fullname>
    <title>&lt;span class="cticon item content contenttype_WP"&gt;&lt;span class="icon"&gt;&lt;/span&gt;&lt;/span&gt; &lt;span class="item-title"&gt;Reference test&lt;/span&gt;</title>
    <folder>false</folder>
    <contenttype>1</contenttype>
  </result>
  <!-- other results omitted -->
</results>